Real-Time Measurement and Control

cancel
Showing results for 
Search instead for 
Did you mean: 

data error through rs232 in cRIO 9074

In the project being developed we have a pair of motor drivers which use ascii codes from the parallel port. The drivers where cobtrolled with a palm that broke down recently.

So we started programming the software with labview, the program works with visa and a usb to serial and serial to parallel converter. But the motors move extremely slow

When trying to implement the same software to the crio using the rsr323 port abd the same serial to parallel converter we cant make the drivers to work. They only move in one direction no matter what code sent.

The codes sent are 20 and 21 for one motor and 40 and 41 for the other.

Anyone have any idea of what ia happening?
Message 1 of 4
(6,629 Views)

 

 Hi danielfede

 

Are you using any of the examples on LabVIEW for serial communication? Did you configured the serial port within the controller?

 

Here are some useful resources related to port configuration on RT controllers and an example for serial communication:

 

Why Are the VISA Resources on My cRIO System Not Displayed As Execution Targets in LabVIEW?

 

http://digital.ni.com/public.nsf/allkb/CBD27C15C3357295862572420068E6B1?OpenDocument

 

What is the Maximum Baud Rate for the Serial Port on the CompactRIO Controllers?

 

http://digital.ni.com/public.nsf/allkb/06304FEBA0DEFDE98625710600787CA6?OpenDocument

 

Compact RIO Operating instructions and Specification (Page 13-14)

http://www.ni.com/pdf/manuals/374639e.pdf

 

Serial data transfer between CRIO and Host

https://decibel.ni.com/content/docs/DOC-3816

 

Please post your code if possible. Maybe you are using code that is not permitted in LabVIEW RT.

 

Luis S
Application Engineer
National Instruments
Message 2 of 4
(6,617 Views)

Hi I have similar problem with servo drive

the drive have ECHO mode which reply every command it get

When I'm connecting the servo drive to the PC with RS-232 to usb it's working great using labview and all commands are extctly as i send them

but when i connect it to compact rio rs-232 port the echo of my command is distorrted, for example if i sent command "ACTIVE" i can get back "ACTITE" which the drive doesn't recongnize.

 

for some reason there problem with commincutions using cRIO rs-232 while PC usb to rs232 work fluently with the same program and same settings

 

exaqmple of the problem:

error valdiating commands in compact rio.JPG

 

serial setings

visa settings.JPG

 

the 

 

Drive: Servotronix CDHD-0062app1 (120/240 VAC)

cRIO: NI cRIO-9076

software: LabView 2013

usb: NI usb-232 188345B-02

PC: HP PRO i7 3.4 GHZ, 4GB ram
OS: windows7 64bit

 

Thank you

Or Hirshfeld

אור הירשפלד

0 Kudos
Message 3 of 4
(5,200 Views)

Is this a problem you get with only certain commands, or every command that you send?

Are you able to try it with a different servo drive, cable, or controller to see if the problem persists? If it is a problem with the controller, you might want to see if other serial communications produce any errors.

0 Kudos
Message 4 of 4
(5,155 Views)