AB Logix Convert ASCII To Decimal

Wilks4492

Member
Join Date
Oct 2006
Location
KW
Posts
1
I am using a ControlLogix processor to serially readback data from a QuickSilver servo drive. The ASCII response I get back is as follows:

# 01 000C FFFF D41F$r

The portion of the response data I am interested in is FFFF D41F. The issue is that this response is a negative number representing a move position (-11233). Is there an easy way to convert this data? I know STOD to DINT works for data that does not contain the Hex character A-F and I have a conversion routine that works great for data that does not contain a negative response. Anyone have any suggestions?

Cheers,

Wilks
 
Nothing built in, but if using version 16+, you can roll your own using structured text as an Add-On-Instruction.

Otherwise, you are just going to have to do it manually in a subroutine.
 

Similar Topics

Hello, I am a veteran Mitsubishi programmer, but am new to AB. I have a Micrologix 1500. I am receiving a string via RS232 on Channel 1. In...
Replies
3
Views
5,008
There is a requirement to convert some projects back to Rslogix 5k , I want to check if I can convert version 30 AOIs to version 20 AOIs. Thanks
Replies
2
Views
1,043
I'm working with a customer to copy one of the machines they designed in-house several years ago. The previous PLC programmer had a thing for...
Replies
8
Views
2,073
I have an existing Logix application that is running in an L82 processor. I copied it to a new file, removed the IO configuration, and now want...
Replies
3
Views
2,201
Greetings fellow PLC programmers, I know there is a simple way to get the system date time of the RSLogix system. But, is there then a way to...
Replies
12
Views
8,564
Back
Top Bottom