Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

serial communication over RS-232 using c programming

Hello, 

 

I want to establish the serial communication from the RS-232 port in sberio 9627 to another microcontroller( PIC ) using C programming

 

To test the communication I have written a simple program that sends 'Hello' at once through /dev/ttyS0( i have attached the code below) and on the receiver side I have used the putty to see the data through the COM port ( here I use the TTL to USB converter), but I can see only the garbage pattern ( that I have attached below ) not the real data.

when I send the data from /dev/ttyS0 I can see in the oscilloscope that some are data able written onto the ports ( attached below).

 

I can receive the data when I connect to the USB port of Sberio 9627, 

so should i disable the serial console to use as UART/ serial communication, if so how can I do it? 

 

could anyone know y I am not able to see the written data or if it is the port issue? 

 

 

 

 

Download All
0 Kudos
Message 1 of 2
(2,403 Views)

Dear  karnati28,

 

are you trying to access from an FPGA? If this is the case, the Serial ports an sbRIO cannot be directly accessed through FPGA. You can access the ports from the Real-Time section. You can use Serial VIs and functions to communicate with devices connected to those ports.

If you need to use FPGA, you may need extra Hardware, see the following link for more information: https://knowledge.ni.com/KnowledgeArticleDetails?id=kA00Z000000PA4xSAG&l=en-GB

0 Kudos
Message 2 of 2
(2,311 Views)