send number to PIC through matlab gui

9 views (last 30 days)
uttam gavand
uttam gavand on 28 Oct 2016
Namaste,
I am communicating PIC controller with matlab GUI. Communication is ok ,data sent is comming back.
I want to send the setpoint(number) to pic.
1... I enter set point( lets say 1) in edit text, then extract number using "str2num" cmd. then i sent through "fwrite" cmd. But pic receives as ascii code corrosponding to '1'. But when i direcly send number using fwrite( in gui background), it recives exact number.
So my question is how to send number on serial port through matlab gui.
2... i can communicate on extra port( usb to serial convertor virtual port)using matlab , but i cant see same port in SIMULINK.

Answers (0)

Categories

Find more on Debugging and Analysis in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!