- What library is the Serial transmit block from?
- Devices usually require a header/terminator. Have you set this up correctly for your device?
Hex-Code through RS-232
2 visualizzazioni (ultimi 30 giorni)
Mostra commenti meno recenti
Hi, i made a simulink model to run a few LED's. I know that the module to which the RS-232 is connected Needs for example the Hexcode 'CA00056734DS' to make all LED's light red.
First Thing i did, was reshaping the Hexcode in a Vector: [ CA 00 05 67 34 DS] because more than that can't be send in uint8 without a data Overflow.
Then i created a Counter to read out the vector-elements and send them through the Serial device after converting them into uint8.
These Vector-elements i connected with the TX-Bytes Input and to the NumBytes-input i give the in the example above the number 6 in uint 32 because 6 elements will be send through the device.
But somehow this doesn't work correctly.
Has anyone an idea where my mistake is?
Thanks a lot!
Greetings
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/157625/image.png)
1 Commento
Suneesh
il 26 Feb 2014
Risposte (0)
Vedere anche
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!