LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

visa write in Modbus

Dear All,

 

I am communicating a device on modbus protocol.

 

i have kept it under observation for 2-3 days.

 

I am able to communicate it properly til then, but after that 2-3 days time out error comes.

 

Setup is as follows:

 

i have connected the labview program on COM5, have used a virtual com port pair software to transfer its data to other port(name is com0com) say on com4.

 

now this com 4 is connected to the instrument, and also i can observe the number of bytes transmitted and received with the slave.

 

Till 2-3 days the bytes are transfered and received also, but after that the transmitted bytes doesnt increase, so i debugged in the modbus library of labview,

 

In MB Serial Transmit vi bytes are also written on the port as the return count (8) is given on visa write vi .

 

then also the counter for transmitted bytes doesnt increase.

 

I am not able trace where the exact problem is,

 

any suggestions..

 

 

Regards,

 

Shrek

 

0 Kudos
Message 1 of 2
(913 Views)

Hello,

 

The only fault I know was in the modbus Slave library regarding coils, however that one has probably been fixed a while ago i guess, and is easy to fix yourself. The master library however works like a charm Smiley Surprised

 

If the problem persists, these could be some options?

 

1 - ignore that virtual com port software and connect directly. If that works long-term you know whats wrong

2 - If that not works, run a little bench test on the equipment. Speed up the communication and see how the instrument behaves. Try writing a lot of holding registers and see the handling of thoes, and the time delay before the instrument answers. Some instruments may react terrible after a while under pressure, and may have some buffer issues, or do not keep up but still acknowledge that the registers have been set, but internally it processes the data afterwards. giving these slower instruments some processing time might solve something. If this crashes before 2-3 days you might know the fault

3 - A work around if still stuck is re-establishing the communication when it times out. If that doesnt work its instrument related as you actually must reset the instrument?

 

My feeling points towards point 1

 

Hope this is of any help.

 

 

0 Kudos
Message 2 of 2
(758 Views)