Hi all. I am new to PLCS.net and have looked at several previously posted threads in hopes of finding the answer to my question; to no avail (it could still be there). I have a SLC 5/05 with a 1747-SDN card and am communicating to two Kollmorgan S300 servo drives. This is also my first DeviceNet project, but I managed to get the drives talking, commanding through polled I/o and some commanding over explicit messaging. Now for the question. To get a current fault code, you have request it over explicit messaging. When I request the data, I move 32 words of data from the M1 file to N23. According to the Kollmorgan documentation the structure of the returned data is:
TX_ID/TX_Status (byte1 and byte0).Word0 (N23:0)
Port=0/MSG_SIZE in bytes..........Word1 (N23:1)
Service/MACID in bytes............Word2 (N23:2)
DATA..............................Word3-31 (N23:3 through N23:31)
Simulating a faultcode 16 or 0x8000(missing main supply feed). When I request the fault code, I get a value of 4 in N23:1 (number of bytes) and -32768 in N23:3 and 0 in N23:4
I realize this number is exceeding my 16 bit word, but am no sure how to make sense of it?
I also have a similar situation whereby I am reading the actual postion, mapped to I:1.3 and I:1.4. The value of I:1.3 will go into the negative numbers and I:1.4 will then hold a value. I would like to bring them together to a single value to compare against such that when actual equals a preset, then stop the motor.
Any help would be greatly appreciated.
Regards.
TX_ID/TX_Status (byte1 and byte0).Word0 (N23:0)
Port=0/MSG_SIZE in bytes..........Word1 (N23:1)
Service/MACID in bytes............Word2 (N23:2)
DATA..............................Word3-31 (N23:3 through N23:31)
Simulating a faultcode 16 or 0x8000(missing main supply feed). When I request the fault code, I get a value of 4 in N23:1 (number of bytes) and -32768 in N23:3 and 0 in N23:4
I realize this number is exceeding my 16 bit word, but am no sure how to make sense of it?
I also have a similar situation whereby I am reading the actual postion, mapped to I:1.3 and I:1.4. The value of I:1.3 will go into the negative numbers and I:1.4 will then hold a value. I would like to bring them together to a single value to compare against such that when actual equals a preset, then stop the motor.
Any help would be greatly appreciated.
Regards.