Red Lion bit manipulation question...

Brian@HCI

Member
Join Date
Nov 2016
Location
Kansas City
Posts
19
Ok Red Lion guru's.......

I have to make sure I can grab data in 3 separate 16-bit tags and assemble only the USABLE data in each one of these into a SINGLE 16-bit word variable that is a composite of the 3 original tags.

Do I use a Gateway Block to "map" the individual variable bits to the bit locations I want them to occupy? How does one do this?

Any suggestions experts?

Brian
 
If I understand what you're wanting to do correctly I'd use Complex code within a tag to and/or/mask/multiply/add to extract the data and put it in a single destination.

Good luck,

Yosi
 
Thank you sir.

The tech support said the same thing. They said create a holding variable - and concatenate the other 3 variables into that variable by bit shifting them to the correct positions and then send this new variable to the register it needs to be in to send the data

Brian
 

Similar Topics

Happy Friday, I am trying to log scan errors related to Modbus Comms for a G306. I am able to use the system function GetDeviceStatus(x) to...
Replies
4
Views
1,925
I'm getting a error about mapping a bit to a numeric tag and it should be using a flag tag but I am. They even have the little flag icons. ???
Replies
13
Views
4,191
I've got a project where I need to send a 64 bit integer that is in 8 consecutive modbus registers to another device as a string. I see the...
Replies
16
Views
7,939
Hello all, I wonder if someone might have some insight on how to convert a 16 bit Integer value into an 8 bit array in Crimson 3. Example...
Replies
5
Views
3,457
Regards everybody. I need your help for resolve a problem with some bits that I want to write to PLC Micrologix 1400. In the HMI (Red Lion...
Replies
1
Views
3,853
Back
Top Bottom