question about write to serial
조회 수: 5 (최근 30일)
이전 댓글 표시

I want to write this string to the serial, but the signal is wrong. How to wirte this code? Thank you!!!
댓글 수: 4
Walter Roberson
2024년 11월 5일
When you are measuring the wire signal levels of RS232, then the Start and Stop bits are unavoidable.
Side note: the Start bit is a different length than the Stop bit. I seem to recall that the Stop bit is half of the length of other bits.
답변 (1개)
Supraja
2024년 11월 11일
Hi,
It seems like sending deimal values inside the function would help in this case.
Please use the code as below:
write(app.SerialObject, [85, 86, 87, 88], "uint8"); % Decimal equivalents of binary numbers
Refer to 'write' function documentation below for further reference:
I hope this helps!
댓글 수: 0
참고 항목
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!