vorfeed
Member
Hi everyone,
I'm working on a third-party Allen-Bradley driver in C, and I'm trying to use the Typed Write command (0x0F 0x67) to write to the ST table on a MicroLogix 1500 Series A.
I can write to all the other data types using this same command, and I can read ST entries from this PLC just fine (using a similar command, 0x0F 0x68). For some reason, trying to write the same value to the same register using Typed Write returns error 0x10 (Illegal Command or Format). Here's what I'm sending -- is there anything obviously wrong with it? Is the datatype and/or data size wrong, maybe? Or should I be using Protected Typed Logical Write With Three Address Fields instead?
I tried asking TechConnect support, but they won't give me any help with third-party applications. I'd appreciate any advice you can give me. Thanks!
Attempting to write tag ST9:0 (data: B12345)
Datatype: 14
New string:
Char 0: 06
Char 1: 00
Char 2: 31 1
Char 3: 42 B
Char 4: 33 3
Char 5: 32 2
Char 6: 35 5
Char 7: 34 4
[padded with 0s up to and including Char 83]
LBA:
[7] [0] [9] [0]
Type/Data Parameter:
99 09 56 39 54
Write Request:
0f 00 84 0a 67 00 00 01 00 07 00 09 00 99 09 56 39 54
Sent Data : length 161
(0000) : 70 00 89 00 06 D0 8B 62 00 00
(0010) : 00 00 00 00 00 00 00 00 00 00
(0020) : 00 00 00 00 00 00 00 00 0F 00
(0030) : 02 00 A1 00 04 00 D1 06 00 00
(0040) : B1 00 75 00 07 00 4B 02 20 67
(0050) : 24 01 07 06 04 78 56 34 12 0F
(0060) : 00 84 0A 67 00 00 01 00 07 00
(0070) : 09 00 99 09 56 39 54 06 00 31
(0080) : 42 33 32 35 34 00 00 00 00 00
(0090) : 00 00 00 00 00 00 00 00 00 00
(0100) : 00 00 00 00 00 00 00 00 00 00
(0110) : 00 00 00 00 00 00 00 00 00 00
(0120) : 00 00 00 00 00 00 00 00 00 00
(0130) : 00 00 00 00 00 00 00 00 00 00
(0140) : 00 00 00 00 00 00 00 00 00 00
(0150) : 00 00 00 00 00 00 00 00 00 00
(0160) : 00
Recv'd Data: length 61
(0000) : 70 00 25 00 06 D0 8B 62 00 00
(0010) : 00 00 00 00 00 00 00 00 00 00
(0020) : 00 00 00 00 00 00 00 00 0F 00
(0030) : 02 00 A1 00 04 00 98 96 75 00
(0040) : B1 00 11 00 07 00 CB 00 00 00
(0050) : 07 06 04 78 56 34 12 4F 10 84
(0060) : 0A
error code is 10, EXT STS 0
Exiting with error (Illegal command or format) B12345 for ST9:0"
Thanks!
I'm working on a third-party Allen-Bradley driver in C, and I'm trying to use the Typed Write command (0x0F 0x67) to write to the ST table on a MicroLogix 1500 Series A.
I can write to all the other data types using this same command, and I can read ST entries from this PLC just fine (using a similar command, 0x0F 0x68). For some reason, trying to write the same value to the same register using Typed Write returns error 0x10 (Illegal Command or Format). Here's what I'm sending -- is there anything obviously wrong with it? Is the datatype and/or data size wrong, maybe? Or should I be using Protected Typed Logical Write With Three Address Fields instead?
I tried asking TechConnect support, but they won't give me any help with third-party applications. I'd appreciate any advice you can give me. Thanks!
Attempting to write tag ST9:0 (data: B12345)
Datatype: 14
New string:
Char 0: 06
Char 1: 00
Char 2: 31 1
Char 3: 42 B
Char 4: 33 3
Char 5: 32 2
Char 6: 35 5
Char 7: 34 4
[padded with 0s up to and including Char 83]
LBA:
[7] [0] [9] [0]
Type/Data Parameter:
99 09 56 39 54
Write Request:
0f 00 84 0a 67 00 00 01 00 07 00 09 00 99 09 56 39 54
Sent Data : length 161
(0000) : 70 00 89 00 06 D0 8B 62 00 00
(0010) : 00 00 00 00 00 00 00 00 00 00
(0020) : 00 00 00 00 00 00 00 00 0F 00
(0030) : 02 00 A1 00 04 00 D1 06 00 00
(0040) : B1 00 75 00 07 00 4B 02 20 67
(0050) : 24 01 07 06 04 78 56 34 12 0F
(0060) : 00 84 0A 67 00 00 01 00 07 00
(0070) : 09 00 99 09 56 39 54 06 00 31
(0080) : 42 33 32 35 34 00 00 00 00 00
(0090) : 00 00 00 00 00 00 00 00 00 00
(0100) : 00 00 00 00 00 00 00 00 00 00
(0110) : 00 00 00 00 00 00 00 00 00 00
(0120) : 00 00 00 00 00 00 00 00 00 00
(0130) : 00 00 00 00 00 00 00 00 00 00
(0140) : 00 00 00 00 00 00 00 00 00 00
(0150) : 00 00 00 00 00 00 00 00 00 00
(0160) : 00
Recv'd Data: length 61
(0000) : 70 00 25 00 06 D0 8B 62 00 00
(0010) : 00 00 00 00 00 00 00 00 00 00
(0020) : 00 00 00 00 00 00 00 00 0F 00
(0030) : 02 00 A1 00 04 00 98 96 75 00
(0040) : B1 00 11 00 07 00 CB 00 00 00
(0050) : 07 06 04 78 56 34 12 4F 10 84
(0060) : 0A
error code is 10, EXT STS 0
Exiting with error (Illegal command or format) B12345 for ST9:0"
Thanks!