05-05-2014 10:24 PM
Hi all,
i have problem about communication serial on RS-485 using NI VISA.
my problem is sometimes the data that must be read from power analyzer suddenly loss, can i skip that problem ? so if the data loss my program do not parsing-data from power analyzer, and then sometimes suddenly data is to high ( i think error on read VISA ) can i ignore it to ?
i did many program and still not work correctly
sorry for my bad english.
this is my video please watch
https://www.dropbox.com/s/st6qs1cbtr72m0m/bandicam%202014-05-05%2015-06-09-546.avi
Thanks~
Solved! Go to Solution.
05-06-2014 01:38 AM
Hi,
Do you use ModBus ASCII or RTU. Please post the VI for check and not a screenshot.
Kees
05-06-2014 02:08 AM
this is my update, i compare on byte count, so if byte count is 49 then the program pharsing data, if else do nothing. but in this program sometimes byte count increase continously. i dont know why the byte count increase continously.
05-06-2014 04:55 AM
Hi,
You are using ModBus RTU. You should disable the termination character.
Kees
05-06-2014 05:00 AM
which one is termination character ? could you show me ? i am newbie on this Labview program
05-06-2014 05:27 AM
is one of the inputs at 'Configure Serial port' VI. This is default true. You set it to false.
05-08-2014 01:29 AM
Would be nice if you share the result with us.
05-08-2014 08:54 PM
i've tried it and still not working. its made byte count stuck on 25. this is my screenshot
and then i record video for you, i tried something, change the delay and it success made the count byte decreased, but it will increase again. please watch this
https://www.dropbox.com/s/0scz8c2c02pgoic/Byte%20Count%20Increase.avi
note : my VI still the same
05-09-2014 01:55 AM
With the command you send the maximum number of bytes you will receive is 25. So I think it works just fine.
You send: 0A 04 00 00 00 0A 7176
That is: slave 10 (0x0A), read register (0x04), starting at address 0 (0x00 0x00), read 10 registers (0x00 0x0A) + CRC (0x7176)
That answer is: 0A 04 14 xxxx CRC
That is: 10 (0x0A), read register (0x04), number of transmitted bytes 20 (0x14), data 10 registers = 20 bytes + CRC
This adds up to 25 bytes.
05-09-2014 02:30 AM
this is the video when i disable termination character
https://www.dropbox.com/s/xvgk0eut4qvluai/Stuck%20Byte%20Count.avi
i change method to compare the first string must be read. this is my screenshot and can work perfect
but i want ask how to made a question on modbus, i've tried this modbus according in my manual device, this is the example on my manual device :
on that example, from address that I underline 0A 04 00 00 00 0A 71 76 it means first register and the number of registers to be read, isn’t right ?
But when I tried to read other parameter ( V, A, W, Var and PF on line 2 )
it didnt work, this is the result below :
could you tell me what should i do to type in write buffer ? and please give me explanation
Thanks~