- Posts: 6803
- Thank you received: 0
Modbus communication error
6 years 9 months ago #155247
by cmorley
Replied by cmorley on topic Modbus communication error
Sorry I meant set offset to 1
Please Log in to join the conversation.
6 years 9 months ago #155248
by jsskangas
Replied by jsskangas on topic Modbus communication error
Hello
2100 and 2101 are correct. i tried them both, in hex value and in decimal.
I also tried different offsets 0-9. none made difference.
2100 and 2101 are correct. i tried them both, in hex value and in decimal.
I also tried different offsets 0-9. none made difference.
Attachment not found
Attachment not found
Please Log in to join the conversation.
6 years 9 months ago #155249
by cmorley
Replied by cmorley on topic Modbus communication error
Its about 4am here so i'm getting hazzy...
When I said element offset I meant the radio button in classiclader's modbus configuration page - it's either 0 or 1
anyways the command send seems ok but is different from your program - if I'm reading it right:
your program 0103210000018e36 broken up is 01 03 2100 0001 8e36
meaning slave 1, function 3, address 2100H, number of bytes 1, then checksome
from classicladder:
meaning slave 1, function 3, address 0834H, number of bytes 1, then checksome
oh wait - in classic ladder the '1st modbus element' must be input as a decimal 8448 - not 2100
In my test config then the message is the same as your program:
That looks better...
When I said element offset I meant the radio button in classiclader's modbus configuration page - it's either 0 or 1
anyways the command send seems ok but is different from your program - if I'm reading it right:
your program 0103210000018e36 broken up is 01 03 2100 0001 8e36
meaning slave 1, function 3, address 2100H, number of bytes 1, then checksome
from classicladder:
Code:
INFO CLASSICLADDER- Modbus I/O module to send: Lgt=8 <- Slave address-1 Function code-3 Data-8 34 0 1 C7 A4
oh wait - in classic ladder the '1st modbus element' must be input as a decimal 8448 - not 2100
In my test config then the message is the same as your program:
Code:
INFO CLASSICLADDER- Modbus I/O module to send: Lgt=8 <- Slave address-1 Function code-3 Data-21 0 0 1 8E 36
Please Log in to join the conversation.
6 years 9 months ago #155254
by jsskangas
Replied by jsskangas on topic Modbus communication error
Solved.
Thanks.
It was HEX address in VFD and one should input address in linuxnc as DEC.
now works.
Thanks.
It was HEX address in VFD and one should input address in linuxnc as DEC.
now works.
Please Log in to join the conversation.
6 years 9 months ago #155272
by cmorley
Replied by cmorley on topic Modbus communication error
Thats great!
Could you post the terminal print out of classicladder so I can see the correct returned result from the VDF - I an adding some docs to linuxcnc to help next time.
Thanks
Could you post the terminal print out of classicladder so I can see the correct returned result from the VDF - I an adding some docs to linuxcnc to help next time.
Thanks
Please Log in to join the conversation.
6 years 9 months ago #155273
by jsskangas
Replied by jsskangas on topic Modbus communication error
I will tomorrow.
Just went to sleeping...
Just went to sleeping...
Please Log in to join the conversation.
6 years 9 months ago #155310
by jsskangas
Replied by jsskangas on topic Modbus communication error
Hello
Here is some debug dump.
INFO CLASSICLADDER- Modbus I/O module received: Lgt=15 -> (Slave address-1 - Function code-3 ) A 0 0 5 0 0 0 0 0 0 0 E4 89
INFO CLASSICLADDER- Modbus I/O module to send: Lgt=8 <- Slave address-1 Function code-6 Data-20 0 0 1 43 CA
INFO CLASSICLADDER- MODBUS Length we should receive=5 (+3)
Serial config...
Serial writing...
Writing done!
select() for serial reading...
Serial reading...
8 chars found
INFO CLASSICLADDER- Modbus I/O module received: Lgt=8 -> (Slave address-1 - Function code-6 ) 20 0 0 1 43 CA
INFO CLASSICLADDER- Modbus I/O module to send: Lgt=8 <- Slave address-1 Function code-6 Data-20 1 0 0 D3 CA
INFO CLASSICLADDER- MODBUS Length we should receive=5 (+3)
Serial config...
Serial writing...
Writing done!
select() for serial reading...
Serial reading...
8 chars found
INFO CLASSICLADDER- Modbus I/O module received: Lgt=8 -> (Slave address-1 - Function code-6 ) 20 1 0 0 D3 CA
INFO CLASSICLADDER- Modbus I/O module to send: Lgt=8 <- Slave address-1 Function code-3 Data-21 0 0 5 8F F5
INFO CLASSICLADDER- MODBUS Length we should receive=12 (+3)
Serial config...
Serial writing...
Writing done!
select() for serial reading...
Serial reading...
15 chars found
INFO CLASSICLADDER- Modbus I/O module received: Lgt=15 -> (Slave address-1 - Function code-3 ) A 0 0 5 0 0 0 0 0 0 0 E4 89
INFO CLASSICLADDER- Modbus I/O module to send: Lgt=8 <- Slave address-1 Function code-6 Data-20 0 0 1 43 CA
INFO CLASSICLADDER- MODBUS Length we should receive=5 (+3)
Serial config...
Serial writing...
Writing done!
select() for serial reading...
Serial reading...
8 chars found
INFO CLASSICLADDER- Modbus I/O module received: Lgt=8 -> (Slave address-1 - Function code-6 ) 20 0 0 1 43 CA
INFO CLASSICLADDER- Modbus I/O module to send: Lgt=8 <- Slave address-1 Function code-6 Data-20 1 0 0 D3 CA
INFO CLASSICLADDER- MODBUS Length we should receive=5 (+3)
Serial config...
Serial writing...
Writing done!
select() for serial reading...
Serial reading...
8 chars found
INFO CLASSICLADDER- Modbus I/O module received: Lgt=8 -> (Slave address-1 - Function code-6 ) 20 1 0 0 D3 CA
INFO CLASSICLADDER- Modbus I/O module to send: Lgt=8 <- Slave address-1 Function code-3 Data-21 0 0 5 8F F5
INFO CLASSICLADDER- MODBUS Length we should receive=12 (+3)
Serial config...
Serial writing...
Writing done!
select() for serial reading...
Serial reading...
15 chars found
INFO CLASSICLADDER- Modbus I/O module received: Lgt=15 -> (Slave address-1 - Function code-3 ) A 0 0 5 0 0 0 0 0 0 0 E4 89
INFO CLASSICLADDER- Modbus I/O module to send: Lgt=8 <- Slave address-1 Function code-6 Data-20 0 0 1 43 CA
INFO CLASSICLADDER- MODBUS Length we should receive=5 (+3)
Serial config...
Serial writing...
Writing done!
select() for serial reading...
Serial reading...
8 chars found
INFO CLASSICLADDER- Modbus I/O module received: Lgt=8 -> (Slave address-1 - Function code-6 ) 20 0 0 1 43 CA
INFO CLASSICLADDER- Modbus I/O module to send: Lgt=8 <- Slave address-1 Function code-6 Data-20 1 0 0 D3 CA
INFO CLASSICLADDER- MODBUS Length we should receive=5 (+3)
Serial config...
Serial writing...
Writing done!
select() for serial reading...
Serial reading...
8 chars found
INFO CLASSICLADDER- Modbus I/O module received: Lgt=8 -> (Slave address-1 - Function code-6 ) 20 1 0 0 D3 CA
INFO CLASSICLADDER- Modbus I/O module to send: Lgt=8 <- Slave address-1 Function code-3 Data-21 0 0 5 8F F5
INFO CLASSICLADDER- MODBUS Length we should receive=12 (+3)
Serial config...
Serial writing...
Writing done!
select() for serial reading...
Serial reading...
15 chars found
INFO CLASSICLADDER- Modbus I/O module received: Lgt=15 -> (Slave address-1 - Function code-3 ) A 0 0 5 0 0 0 0 0 0 0 E4 89
INFO CLASSICLADDER- Modbus I/O module to send: Lgt=8 <- Slave address-1 Function code-6 Data-20 0 0 1 43 CA
INFO CLASSICLADDER- MODBUS Length we should receive=5 (+3)
Serial config...
Serial writing...
Writing done!
select() for serial reading...
Serial reading...
8 chars found
INFO CLASSICLADDER- Modbus I/O module received: Lgt=8 -> (Slave address-1 - Function code-6 ) 20 0 0 1 43 CA
INFO CLASSICLADDER- Modbus I/O module to send: Lgt=8 <- Slave address-1 Function code-6 Data-20 1 0 0 D3 CA
INFO CLASSICLADDER- MODBUS Length we should receive=5 (+3)
Serial config...
Serial writing...
Writing done!
select() for serial reading...
Serial reading...
8 chars found
INFO CLASSICLADDER- Modbus I/O module received: Lgt=8 -> (Slave address-1 - Function code-6 ) 20 1 0 0 D3 CA
INFO CLASSICLADDER- Modbus I/O module to send: Lgt=8 <- Slave address-1 Function code-3 Data-21 0 0 5 8F F5
INFO CLASSICLADDER- MODBUS Length we should receive=12 (+3)
Serial config...
Serial writing...
Writing done!
select() for serial reading...
Serial reading...
15 chars found
INFO CLASSICLADDER- Modbus I/O module received: Lgt=15 -> (Slave address-1 - Function code-3 ) A 0 0 5 0 0 0 0 0 0 0 E4 89
INFO CLASSICLADDER- Modbus I/O module to send: Lgt=8 <- Slave address-1 Function code-6 Data-20 0 0 1 43 CA
INFO CLASSICLADDER- MODBUS Length we should receive=5 (+3)
Serial config...
Serial writing...
Writing done!
select() for serial reading...
Serial reading...
8 chars found
INFO CLASSICLADDER- Modbus I/O module received: Lgt=8 -> (Slave address-1 - Function code-6 ) 20 0 0 1 43 CA
Here is some debug dump.
INFO CLASSICLADDER- Modbus I/O module received: Lgt=15 -> (Slave address-1 - Function code-3 ) A 0 0 5 0 0 0 0 0 0 0 E4 89
INFO CLASSICLADDER- Modbus I/O module to send: Lgt=8 <- Slave address-1 Function code-6 Data-20 0 0 1 43 CA
INFO CLASSICLADDER- MODBUS Length we should receive=5 (+3)
Serial config...
Serial writing...
Writing done!
select() for serial reading...
Serial reading...
8 chars found
INFO CLASSICLADDER- Modbus I/O module received: Lgt=8 -> (Slave address-1 - Function code-6 ) 20 0 0 1 43 CA
INFO CLASSICLADDER- Modbus I/O module to send: Lgt=8 <- Slave address-1 Function code-6 Data-20 1 0 0 D3 CA
INFO CLASSICLADDER- MODBUS Length we should receive=5 (+3)
Serial config...
Serial writing...
Writing done!
select() for serial reading...
Serial reading...
8 chars found
INFO CLASSICLADDER- Modbus I/O module received: Lgt=8 -> (Slave address-1 - Function code-6 ) 20 1 0 0 D3 CA
INFO CLASSICLADDER- Modbus I/O module to send: Lgt=8 <- Slave address-1 Function code-3 Data-21 0 0 5 8F F5
INFO CLASSICLADDER- MODBUS Length we should receive=12 (+3)
Serial config...
Serial writing...
Writing done!
select() for serial reading...
Serial reading...
15 chars found
INFO CLASSICLADDER- Modbus I/O module received: Lgt=15 -> (Slave address-1 - Function code-3 ) A 0 0 5 0 0 0 0 0 0 0 E4 89
INFO CLASSICLADDER- Modbus I/O module to send: Lgt=8 <- Slave address-1 Function code-6 Data-20 0 0 1 43 CA
INFO CLASSICLADDER- MODBUS Length we should receive=5 (+3)
Serial config...
Serial writing...
Writing done!
select() for serial reading...
Serial reading...
8 chars found
INFO CLASSICLADDER- Modbus I/O module received: Lgt=8 -> (Slave address-1 - Function code-6 ) 20 0 0 1 43 CA
INFO CLASSICLADDER- Modbus I/O module to send: Lgt=8 <- Slave address-1 Function code-6 Data-20 1 0 0 D3 CA
INFO CLASSICLADDER- MODBUS Length we should receive=5 (+3)
Serial config...
Serial writing...
Writing done!
select() for serial reading...
Serial reading...
8 chars found
INFO CLASSICLADDER- Modbus I/O module received: Lgt=8 -> (Slave address-1 - Function code-6 ) 20 1 0 0 D3 CA
INFO CLASSICLADDER- Modbus I/O module to send: Lgt=8 <- Slave address-1 Function code-3 Data-21 0 0 5 8F F5
INFO CLASSICLADDER- MODBUS Length we should receive=12 (+3)
Serial config...
Serial writing...
Writing done!
select() for serial reading...
Serial reading...
15 chars found
INFO CLASSICLADDER- Modbus I/O module received: Lgt=15 -> (Slave address-1 - Function code-3 ) A 0 0 5 0 0 0 0 0 0 0 E4 89
INFO CLASSICLADDER- Modbus I/O module to send: Lgt=8 <- Slave address-1 Function code-6 Data-20 0 0 1 43 CA
INFO CLASSICLADDER- MODBUS Length we should receive=5 (+3)
Serial config...
Serial writing...
Writing done!
select() for serial reading...
Serial reading...
8 chars found
INFO CLASSICLADDER- Modbus I/O module received: Lgt=8 -> (Slave address-1 - Function code-6 ) 20 0 0 1 43 CA
INFO CLASSICLADDER- Modbus I/O module to send: Lgt=8 <- Slave address-1 Function code-6 Data-20 1 0 0 D3 CA
INFO CLASSICLADDER- MODBUS Length we should receive=5 (+3)
Serial config...
Serial writing...
Writing done!
select() for serial reading...
Serial reading...
8 chars found
INFO CLASSICLADDER- Modbus I/O module received: Lgt=8 -> (Slave address-1 - Function code-6 ) 20 1 0 0 D3 CA
INFO CLASSICLADDER- Modbus I/O module to send: Lgt=8 <- Slave address-1 Function code-3 Data-21 0 0 5 8F F5
INFO CLASSICLADDER- MODBUS Length we should receive=12 (+3)
Serial config...
Serial writing...
Writing done!
select() for serial reading...
Serial reading...
15 chars found
INFO CLASSICLADDER- Modbus I/O module received: Lgt=15 -> (Slave address-1 - Function code-3 ) A 0 0 5 0 0 0 0 0 0 0 E4 89
INFO CLASSICLADDER- Modbus I/O module to send: Lgt=8 <- Slave address-1 Function code-6 Data-20 0 0 1 43 CA
INFO CLASSICLADDER- MODBUS Length we should receive=5 (+3)
Serial config...
Serial writing...
Writing done!
select() for serial reading...
Serial reading...
8 chars found
INFO CLASSICLADDER- Modbus I/O module received: Lgt=8 -> (Slave address-1 - Function code-6 ) 20 0 0 1 43 CA
INFO CLASSICLADDER- Modbus I/O module to send: Lgt=8 <- Slave address-1 Function code-6 Data-20 1 0 0 D3 CA
INFO CLASSICLADDER- MODBUS Length we should receive=5 (+3)
Serial config...
Serial writing...
Writing done!
select() for serial reading...
Serial reading...
8 chars found
INFO CLASSICLADDER- Modbus I/O module received: Lgt=8 -> (Slave address-1 - Function code-6 ) 20 1 0 0 D3 CA
INFO CLASSICLADDER- Modbus I/O module to send: Lgt=8 <- Slave address-1 Function code-3 Data-21 0 0 5 8F F5
INFO CLASSICLADDER- MODBUS Length we should receive=12 (+3)
Serial config...
Serial writing...
Writing done!
select() for serial reading...
Serial reading...
15 chars found
INFO CLASSICLADDER- Modbus I/O module received: Lgt=15 -> (Slave address-1 - Function code-3 ) A 0 0 5 0 0 0 0 0 0 0 E4 89
INFO CLASSICLADDER- Modbus I/O module to send: Lgt=8 <- Slave address-1 Function code-6 Data-20 0 0 1 43 CA
INFO CLASSICLADDER- MODBUS Length we should receive=5 (+3)
Serial config...
Serial writing...
Writing done!
select() for serial reading...
Serial reading...
8 chars found
INFO CLASSICLADDER- Modbus I/O module received: Lgt=8 -> (Slave address-1 - Function code-6 ) 20 0 0 1 43 CA
Please Log in to join the conversation.
Time to create page: 0.304 seconds
