GE RX3i Bit Offset command

NetNathan

Lifetime Supporting Member
Join Date
Nov 2011
Location
Corona, CA
Posts
2,199
I have an integer coming from an IO Link device into my PLC.
The first 2 bits of the integer are digital status bits of 2 alarms in the device and the next 14 bits are the integer value counts for Temperature.

How do I do a "Bit Offset" in GE Machine Edition to get rid of 1st 2 bits?
 
Assuming the "first two digits" are the two least significant digits, the simplest way is to just divide the integer by four. I'm pretty sure the integer divide truncates the result.
If you need to ensure there's no roundoff AND the integer with hex FFFC first. You could also do a bit shift right by two places. The problem with either of the latter two is that you might run into type casting issues and need to create two different variables assigned to the same address but with different data types.
 
Just divide by 4?
Sure. As long as the integer division truncates the result, division by four is the same as shifting the bit pattern right by two places.
I don't have an Rx3i to try it on. It works for a 90-30. The 90-70 used to give you an option to truncate or round when doing an integer divide, so I'm not sure what options are available for the Rx3i.
 
if you did want to use the first two bits for the alarm functions, you could use a MOVE and output an integer into a series of free boleen registers, %G for instance. Then each bit would reside in its own register space.
 

Similar Topics

I have a system using Rx3I CRU320 redundant CPU with Proficy Machine Edition Software. In the hardware configuration of each CPU module, under...
Replies
14
Views
376
Hi, we are using Rx3i CRU320 redundant PLC system and we noticed a discrepancy between Primary and Secondary controller. Couple of variables (DI)...
Replies
8
Views
270
Hi there, I'm doing some extensive testing and commissioning with a slew of new Emerson PACSystems RX3i PLCs. It would be convenient to...
Replies
5
Views
96
Hi there, Trying to get some ascii serial communications working via RS485 (COMMREQ functions). I have attached our wiring for the COM2...
Replies
1
Views
964
Hello all, First time poster, long time viewer of these forums. Could not find my solution on here. We have had issues with a Comm Fail on an...
Replies
2
Views
364
Back
Top Bottom