mnaylor
2008-08-08 18:10:13 UTC
I recently installed the PCI-8432/2 card hoping that it would increase reliability of a system I am working on -- RS232 communications had been working fine, but a previous card I had been using had reliability issues. After installing this NI card, I am no longer receiving replys to messages that I send out (software is unchanged from previous state that has been working for a long period of time). I am developing under cygwin using g++ compiler on an XP embedded system. The port is being opened with the following parameters: rrPort_ = open(rrDevice_,O_RDWR|O_NOCTTY|O_NDELAY,0666); struct termios t_s; tcgetattr(rrPort_,&t_s); t_s.c_iflag = 0; t_s.c_oflag = 0; t_s.c_lflag = 0; t_s.c_cc[VMIN] = 0; t_s.c_cc[VTIME] = 1; t_s.c_cflag &= ~(CSIZE|PARENB); t_s.c_cflag |= CS8;and then setting the baud rate appropriately applying parameter changes...With these parameters, the write() calls work fine -- the device I am communicating with repsonds correctly, but my read() calls (that work fine with other RS232 ports not on the NI card) receive no information. I've tried two different NI cards. Also, as another test I put an RS232 break-out box in the middle of the line connecting the two devices which shows LEDs for each pin... it appears that the voltages when running with the NI card are significantly less than with other RS232 ports -- the LEDs are much dimmer. I would appreciate any ideas or tips that might help me solve this problem...Thanks!