Unity2019, C#7.0
使用SerialPort模塊,以多執行緒或異步方式去監控BytesToRead,去進行讀取是沒問題的,但是我想改成用DataReceived事件做成觸發式,然而一直沒成功,試了各種設定都不行,最后發現,當對ReceivedBytesThreshold屬性進行讀寫時,運行時提示
NotImplementedException: The method or operation is not implemented.
如果是讀取,指向就是System.IO.Ports.SerialPort.get_ReceivedBytesThreshold,如果是設定則指向System.IO.Ports.SerialPort.set_ReceivedBytesThreshold,懷疑因為這樣導致了ReceivedBytesThreshold屬性實際運行中不存在,所以沒辦法觸發事件,請問有誰知道怎么會出現這個情況?
轉載請註明出處,本文鏈接:https://www.uj5u.com/qita/226725.html
標籤:Unity3D
上一篇:unity漫游
