nettogrisen
Lifetime Supporting Member
Disclaimer: I'm in over my head here
Hi, I'm trying to establish a 2 wire modbus connection between 4 Telemecanique altivar 61 VFD's as slaves and a compactlogix L32E as master. I need to read some data from the drives: speed reference, frequency reference, amps and such and I need to be able to control the frequency reference and to be able to start/stop.
On my desk I have one ATV and the compactlogix connected via an 1761-NET-AIC. Between the CL and the net-aic I have a 1761-CBL-PM02 cable and between the ATV and the net-aic I have 2 wires: A-A and B-B, on the net-aic side I have wired A-Term and a terminating resistor on the ATV side.
I have set up the ATV communication, speed ref. and cmd. channel 1 to modbus, and I have followed the CIG-AP129A-EN-P publication from RA's knowledgebase on how to copy the tasks, UDT's and tags from the modbusmaster.acd file.
In my sample program I have set the following:
Mod_Active 1
Mod_Cmd_Number 1
Mod_Commands[0].Enable 1
Mod_Commands[0].SlaveAddress 1
Mod_Commands[0].FunctionCode 4
Mod_Commands[0].StartingAddress 9001 (Acceleration time in the ATV, it's supposed to read "30")
Mod_Commands[0].NumberofPoints 1
When running this none of the communication LED's on the CL or the net-aic lights up, and in the Modbus_Interface > Program Tags > Mod_Status[0].Functioncode I get "-2" wich is an errorcode meaning "Command is not sent because the number of bits
exeeds 320 or arry limits in the Master were exeeded."
I then changed Mod_Data_arry_Max from 250 to 10000 and now the communication lights are blinking and the MsgCountRec and MsgCountTrans are almost match each other like they are supposed to (MsgContRec was 0 before), but I still don't get any data and Mod_Commands[0].EchoReceived wich is supposed to equal Mod_Commands[0].Enable is 0 and I get a minor fault saying
"Arithmetic overflow. Result of an aritmetic instruction out of range." The errorcode in Mod_Status[0].Functioncode is now -124 wich I don't get at all.
Lowering the Mod_Data_arry_Max to under 10000 I get the same errors as when it was 250.
Setting Mod_Data_arry_Max to 10000 I feel that I have gotten some kind of communication running, but it just leads to alot of other problems, so I'm not sure if it's right or wrong.
I know that this isn't very well explained, but it's hard as I am not excatly sure what I'm doing.
I hope that somebody that has done this before is able to help me.
Regards
Hi, I'm trying to establish a 2 wire modbus connection between 4 Telemecanique altivar 61 VFD's as slaves and a compactlogix L32E as master. I need to read some data from the drives: speed reference, frequency reference, amps and such and I need to be able to control the frequency reference and to be able to start/stop.
On my desk I have one ATV and the compactlogix connected via an 1761-NET-AIC. Between the CL and the net-aic I have a 1761-CBL-PM02 cable and between the ATV and the net-aic I have 2 wires: A-A and B-B, on the net-aic side I have wired A-Term and a terminating resistor on the ATV side.
I have set up the ATV communication, speed ref. and cmd. channel 1 to modbus, and I have followed the CIG-AP129A-EN-P publication from RA's knowledgebase on how to copy the tasks, UDT's and tags from the modbusmaster.acd file.
In my sample program I have set the following:
Mod_Active 1
Mod_Cmd_Number 1
Mod_Commands[0].Enable 1
Mod_Commands[0].SlaveAddress 1
Mod_Commands[0].FunctionCode 4
Mod_Commands[0].StartingAddress 9001 (Acceleration time in the ATV, it's supposed to read "30")
Mod_Commands[0].NumberofPoints 1
When running this none of the communication LED's on the CL or the net-aic lights up, and in the Modbus_Interface > Program Tags > Mod_Status[0].Functioncode I get "-2" wich is an errorcode meaning "Command is not sent because the number of bits
exeeds 320 or arry limits in the Master were exeeded."
I then changed Mod_Data_arry_Max from 250 to 10000 and now the communication lights are blinking and the MsgCountRec and MsgCountTrans are almost match each other like they are supposed to (MsgContRec was 0 before), but I still don't get any data and Mod_Commands[0].EchoReceived wich is supposed to equal Mod_Commands[0].Enable is 0 and I get a minor fault saying
"Arithmetic overflow. Result of an aritmetic instruction out of range." The errorcode in Mod_Status[0].Functioncode is now -124 wich I don't get at all.
Lowering the Mod_Data_arry_Max to under 10000 I get the same errors as when it was 250.
Setting Mod_Data_arry_Max to 10000 I feel that I have gotten some kind of communication running, but it just leads to alot of other problems, so I'm not sure if it's right or wrong.
I know that this isn't very well explained, but it's hard as I am not excatly sure what I'm doing.
I hope that somebody that has done this before is able to help me.
Regards