0% found this document useful (0 votes)
26 views4 pages

Logix Platform - How To Convert 64-Bit Real Value To 32-Bit Float

The document discusses how to convert 64-bit real values to 32-bit floats for Logix controllers, which only support single precision floats. It explains the bit layout differences and how to convert the 64-bit data received as two DINT tags to a 32-bit real tag by only supporting numbers within the exponent range of -127 to 127.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
26 views4 pages

Logix Platform - How To Convert 64-Bit Real Value To 32-Bit Float

The document discusses how to convert 64-bit real values to 32-bit floats for Logix controllers, which only support single precision floats. It explains the bit layout differences and how to convert the 64-bit data received as two DINT tags to a 32-bit real tag by only supporting numbers within the exponent range of -127 to 127.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 4

10/5/24, 18:50 Logix Platform: How to convert 64-bit Real value to 32-bit Float

ID: QA2538 | Access Levels: TechConnect

Logix Platform: How to convert 64-bit Real


value to 32-bit Float

Document ID QA2538

Published Date 03/03/2020

Summary
Logix Platform: How to convert 64-bit Real value to 32-bit Float

Question
Do Logix Controllers support Double Precision Floating Point?

Answer
At this stage, Logix platform only supports Native Single precision float data only.

This technote explains layout difference between extended 64-bit and 32-bit IEEE
numbers and way to convert from 64 bit to Real Logix Tag.

Some measurement devices provide data in 64-bit double precision IEEE Float format.

Because Logix platform can handle only 32-bit single precision float data, incoming data
must be converted before use.

Usually 64-bit data will arrive to the Logix platform in a form of 2 DINT tags.

The following bit layout shows differences between 64 and 32-bit floating point values

https://rockwellautomation.custhelp.com/app/answers/answer_view/a_id/36632 1/4
10/5/24, 18:50 Logix Platform: How to convert 64-bit Real value to 32-bit Float

64-bit value:

Mantissa - 52 bits

Exponent - 11 bits

Sign - 1 bit

32-bit value:

Mantissa - 23 bits

Exponent - 8 bits

Sign - 1 bit

Only numbers with an exponent -127...+127 can be converted.

https://rockwellautomation.custhelp.com/app/answers/answer_view/a_id/36632 2/4
10/5/24, 18:50 Logix Platform: How to convert 64-bit Real value to 32-bit Float

Special ’Thank You’ to www.mrPLC.com A-B forum members for their contribution to this
technote.

Attachments

File
Float_64.ACD

DISCLAIMER

https://rockwellautomation.custhelp.com/app/answers/answer_view/a_id/36632 3/4
10/5/24, 18:50 Logix Platform: How to convert 64-bit Real value to 32-bit Float

This knowledge base web site is intended to provide general technical information on a particular subject
or subjects and is not an exhaustive treatment of such subjects. Accordingly, the information in this web
site is not intended to constitute application, design, software or other professional engineering advice or
services. Before making any decision or taking any action, which might affect your equipment, you should
consult a qualified professional advisor.

ROCKWELL AUTOMATION DOES NOT WARRANT THE COMPLETENESS, TIMELINESS OR


ACCURACY OF ANY OF THE DATA CONTAINED IN THIS WEB SITE AND MAY MAKE CHANGES
THERETO AT ANY TIME IN ITS SOLE DISCRETION WITHOUT NOTICE. FURTHER, ALL
INFORMATION CONVEYED HEREBY IS PROVIDED TO USERS "AS IS." IN NO EVENT SHALL
ROCKWELL BE LIABLE FOR ANY DAMAGES OF ANY KIND INCLUDING DIRECT, INDIRECT,
INCIDENTAL, CONSEQUENTIAL, LOSS PROFIT OR DAMAGE, EVEN IF ROCKWELL AUTOMATION
HAVE BEEN ADVISED ON THE POSSIBILITY OF SUCH DAMAGES.

ROCKWELL AUTOMATION DISCLAIMS ALL WARRANTIES WHETHER EXPRESSED OR IMPLIED IN


RESPECT OF THE INFORMATION (INCLUDING SOFTWARE) PROVIDED HEREBY, INCLUDING THE
IMPLIED WARRANTIES OF FITNESS FOR A PARTICULAR PURPOSE, MERCHANTABILITY, AND
NON-INFRINGEMENT. Note that certain jurisdictions do not countenance the exclusion of implied
warranties; thus, this disclaimer may not apply to you.

https://rockwellautomation.custhelp.com/app/answers/answer_view/a_id/36632 4/4

You might also like