Freelance Modbus RTU communication
Hi, is there anyway to increase the scan time for Modbus RTU (RS-485) connection in Freelance? As currently one of my modbus RTU connected system is having this problems:
1. Transmitting is counting as per normal
2. Receiving takes very long time to count
(this causes the values displayed on digivis to take a long time to update)
Scene: We have 6 generators using this Modbus RTU connection in daisy chain, thus we noticed that the values we display for the 6 gen sets are very slow.
(e.g, Gen 1 is running since 1 day ago so we see the values and signals then they it switched off and change to Gen 4 but the Gen 4 data is not coming while Gen 1 data remains there for awhile. Only after like 5 mins or so, Gen 4 data comes in but if the current increases we cannot see the change immediately.)
At first we thought it was the baudrate setting as current baudrate is 9600.
Is there really any solution to increasing the scan time?
what is Parity error in the modbus status means? How to i trace what kind of parity error is it?
Voted best answer
I guess that the long read intervall is due to revceive errors. Also the parity error indicates that.
A parity bit is a bit added to the end of a string of binary code that indicates whether the number of bits in the string with the value one is even or odd. Parity bits are used as the simplest form of error detecting code.
There are two variants of parity bits: even parity bit and odd parity bit.
In the case of even parity, for a given set of bits, the occurrences of bits whose value is 1 is counted. If that count is odd, the parity bit value is set to 1, making the total count of occurrences of 1's in the whole set(including the parity bit) an even number. If the count of 1's in a given set of bits is already even, the parity bit's value remains 0.
In the case of odd parity, the situation is reversed. For a given set of bits, if the count of bits with a value of 1 is even, the parity bit value is set to 1 making the total count of 1's in the whole set(including the parity bit) an odd number. If the count of bits with a value of 1 is odd, the count is already odd so the parity bit's value remains 0.
When the system receives a message it determins the parity by counting the 1's in the message. If the parity is found to be even, but the configuration says odd parity there is clearly an error in the received message.
Did you check whether the RS485 line is correctly terminated at both ends? Remember that both bus terminations, the one at the start of the line and the one at the end, need to be under power for a troble free communication. If for example you power the end termination through the end device and then switch off the end device, the bus is not correctly terminated and communication errors will happen.