From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

RS422 packets missed when transmitted at repetition rate of 15ms

Hi,

 

I am trying to send RS422 serial packets using NI PXI 8431/4 module. My goal is to send serial frame repetitively at 15ms interval, but sometime the packets are missing as they don't occur at next 15ms interval.

 

I have placed serial transmission VI inside a while loop and added a "wait ms" function to set the loop timing to 15ms.

 

Can you please guide me how to achieve desired repetition interval?

 

Thanks,

 

M Mahboob

0 Kudos
Message 1 of 5
(2,139 Views)

You best use a timed loop instead of a normal while loop and not use a wait ms in that loop anymore. 

greetings from the Netherlands
0 Kudos
Message 2 of 5
(2,086 Views)

@Mahboob_ur_Rehman wrote:

I am trying to send RS422 serial packets using NI PXI 8431/4 module. My goal is to send serial frame repetitively at 15ms interval, but sometime the packets are missing as they don't occur at next 15ms interval.


How large are your packets and what baud rate are you using?  What controller are you using and what OS is it running?  How accurate do you need that interval to be?


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 3 of 5
(2,078 Views)

Sorry, I should have mentioned the details earlier. 

 

1. Packets lenght is in range of 2-3ms aproxx

2. Baud rate= 38400

3. Pxi chassis with embedded controller running Windows OS

4. Accuracy required is in mili seconds, desired is 15ms

 

Thanks,

M Mahboob 

0 Kudos
Message 4 of 5
(2,072 Views)

PS:

The chassis is PXIe-1071

Controller is PXIe-8821

0 Kudos
Message 5 of 5
(2,062 Views)