Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

serial communication from simulink to labview

hello everybody,

i have problems with establishing serial communication from simulink(where the data is generated) to labview (version 2010).

i tried everything but it won t work.can you please help me on this one pleaaase.

thanks ^^

0 Kudos
Message 1 of 8
(4,952 Views)

Hello Hades

 

This looks good. Is Simulink sending from another computer to the same port, with same baudrate etc.

Or is simulink running on the same pc communicating through another port?

greetings from the Netherlands
0 Kudos
Message 2 of 8
(4,936 Views)

hello , thanks for your reply ^^

the communiation is between two PC where the data is generated with smulink and in the second one we receive data and display it with labview

in matlab i used a send serial block connected with my system.

 

0 Kudos
Message 3 of 8
(4,932 Views)

Are you sure that all is in ascii (text format) and that it is no binary?

greetings from the Netherlands
0 Kudos
Message 4 of 8
(4,909 Views)

thanks so far for your replies,

to clarify any confusion this is my system in simulink.

the data are decimal values

thanks again, hope i ll receive a reply from you guys soon cause i really need to progress in my project

Download All
0 Kudos
Message 5 of 8
(4,892 Views)

hello,

in fact i discovered that the serial communication between the two applications can not be done because of the cable used .

so i decided to do this application in the same PC using virtual ports with VSPD.

and so i did the simulation, the data was sent but none was received in labview.

what can i do ?? pliiiiiiiiiiz

0 Kudos
Message 6 of 8
(4,871 Views)

hades1992,

 

I can't really speak much about the virtual serial port software, but can you see them in MAX?  Have you tested communication in MAX?  Have you attempted to run one of the shipping examples for serial like Simple Serial.vi?

Wayne T. | Application Engineer | National Instruments
0 Kudos
Message 7 of 8
(4,824 Views)

About your data, I still have the impression that you send binary data, and the first question is:

Are there any characters found on the receiving part in LabVIEW.

Use the 

C:\Program Files (x86)\National Instruments\LabVIEW 2013\examples\Instrument IO\Serial\Continuous Serial Write and Read.vi

and select no endcharacters and the correct baudrate etc,

start the vi and send the data from simulink

press read after sending and ask to start with 10 characters and see what happens. 

greetings from the Netherlands
0 Kudos
Message 8 of 8
(4,805 Views)