LogixPro Syntax, accessing individual bit values.

Galileo

Member
Join Date
Jun 2020
Location
Modesto
Posts
6
Hi,

I'm using LogixPro Simulator, and I'm experimenting with BSL.

I know how BSL works, but what I am trying to do is access the value of an individual bit which should be either 1 or 0.

Say, I am using #B3:6 to store the data and the length is 16. Then I insert a 1, a 0, and a 1 into it using BSL. The data on #b3:6 looks like
0000000000000101 - converted to decimal that is 5.

How do I access the value at index 2 on #B3:6? I want to know when that value turns into a 1. If I use the notation B3:6/2, every comparison I use treats it like a 5.
 
If I use the notation B3:6/2, every comparison I use treats it like a 5.

What instruction are you using for these 'comparisons'? I've not dealt with LogixPro, but I believe the standard comparison instructions (EQU, GRT etc) operate on the word level -- you simply can't directly look at a specific bit with those instructions.

In order to look at an individual bit, you want an instruction that operates on the bit level. The simplest such are XIC/XIO. The instruction XIC B3:6/2 will be true when that value is 1 and false when it is 0, XIO will be the opposite.
 
Last edited:
Adding, I already know about assigning an XIC or an XIO to B3:6/2. I suppose I could just throw a counter in and use that, but is there a way to pull a 1 or a 0 out so I can use a word comparison instead?
 

Similar Topics

SELECTED NEW FILE SELECTED PROCESSOR TYPE SELECTED I/O CONFIGURATIONS IM UNABLE TO CONFIGURE MY I/O’S. I HAVE A PAPER COPY OF A PROGRAM AND I...
Replies
0
Views
81
Good morning, I am currently working on the LogixPro Advanced Batch #2 Multiple Mode of Operation and got stuck very close to completion. Link...
Replies
3
Views
2,239
Hi folks, i'm pretty much new on this topic and i need some help with the dual compressor part 3 and 4, currently working on part 3 i cant make...
Replies
20
Views
5,115
Hello Gurus, I am working on the elevator exercise of LogixPro and my output on the subroutine is being energized without its flag being called...
Replies
4
Views
2,205
Hey guys, I am currently working through a PLC class using Logix Pro as the simulator. I am on the bottling exercise 3 where it grinds the glass...
Replies
1
Views
1,390
Back
Top Bottom