Inst ToolsInst ToolsInst Tools
  • Courses
  • Automation
    • PLC
    • Control System
    • Safety System
    • Communication
    • Fire & Gas System
  • Instrumentation
    • Design
    • Pressure
    • Temperature
    • Flow
    • Level
    • Vibration
    • Analyzer
    • Control Valve
    • Switch
    • Calibration
    • Erection & Commissioning
  • Interview
    • Instrumentation
    • Electrical
    • Electronics
    • Practical
  • Q&A
    • Instrumentation
    • Control System
    • Electrical
    • Electronics
    • Analog Electronics
    • Digital Electronics
    • Power Electronics
    • Microprocessor
  • Request
Search
  • Books
  • Software
  • Projects
  • Process
  • Tools
  • Basics
  • Formula
  • Power Plant
  • Root Cause Analysis
  • Electrical Basics
  • Animation
  • Standards
  • 4-20 mA Course
  • Siemens PLC Course
Reading: Allen Bradley Bitwise Logical Operations
Share
Notification Show More
Font ResizerAa
Inst ToolsInst Tools
Font ResizerAa
  • Courses
  • Design
  • PLC
  • Interview
  • Control System
Search
  • Courses
  • Automation
    • PLC
    • Control System
    • Safety System
    • Communication
    • Fire & Gas System
  • Instrumentation
    • Design
    • Pressure
    • Temperature
    • Flow
    • Level
    • Vibration
    • Analyzer
    • Control Valve
    • Switch
    • Calibration
    • Erection & Commissioning
  • Interview
    • Instrumentation
    • Electrical
    • Electronics
    • Practical
  • Q&A
    • Instrumentation
    • Control System
    • Electrical
    • Electronics
    • Analog Electronics
    • Digital Electronics
    • Power Electronics
    • Microprocessor
  • Request
Follow US
All rights reserved. Reproduction in whole or in part without written permission is prohibited.
Inst Tools > Blog > PLC Tutorials > Allen Bradley Bitwise Logical Operations

Allen Bradley Bitwise Logical Operations

Last updated: March 4, 2021 3:22 pm
Editorial Staff
PLC Tutorials
No Comments
Share
5 Min Read
SHARE

To study the working of Allen Bradley Bitwise logical operations like AND, OR, NOT, XOR in Programmable logic Controllers (PLC).

Contents
Bitwise Logical OperationsBlock Name: Bitwise ANDBlock Name: Bitwise ORBlock Name: Bitwise XORBlock Name: Bitwise NOTPLC LADDER EXAMPLECASE 1:BITWISE Operation of AND, OR, XOR, NOT:AND Logic:OR Logic :XOR Logic :NOT Logic :CASE 2:BITWISE Operation of AND, OR, XOR, NOT:AND logic:OR Logic:XOR Logic:NOT Logic:Conclusion:

Bitwise Logical Operations

Block Name: Bitwise AND

Bitwise AND Instruction

In the above picture, there are totally three parameters,

SOURCE A – Address of First Binary Value

SOURCE B – Address of Second Binary Value

DESTINATION –AND operation result of Source A & B stored in this address

Block Name: Bitwise OR

Bitwise OR Instruction

In the above picture, there are totally three parameters,

SOURCE A –Address of First Binary Value

SOURCE B –Address of Second Binary Value

DESTINATION –OR operation result of Source A & B stored in this address

Block Name: Bitwise XOR

Bitwise XOR Instruction

In the above picture, there are totally three parameters,

SOURCE A –Address of First Binary Value

SOURCE B –Address of Second Binary Value

DESTINATION –XOR operation result of Source A & B stored in this address

Block Name: Bitwise NOT

Bitwise NOT Instruction

In the above picture, there are totally two  parameters,

SOURCE -Address of Binary Value

DESTINATION –NOT operation result of Source stored in this address

PLC LADDER EXAMPLE

Working of Bitwise logical operation in AB PLC

CASE 1:

When,

Source A : 0000 0000 0000 0000 (AND,OR & XOR)

Source B : 0000 0000 0000 0000 (AND,OR & XOR)

Source  : 0000 0000 0000 0000 (NOT)

Rung 0000:

All Bitwise operator block are connected in parallel with input condition I: 0/0. When it goes ON, each block performs its operation. Since Source addresses are having zeros except NOT block remaining blocks are resulting 0s.

BITWISE Operation of AND, OR, XOR, NOT:

AND Logic:

Source A : 0000 0000 0000 0000   (B3:0)

Source B : 0000 0000 0000 0000   (B3:1)

Destination : 0000 0000 0000 0000   (B3:2)

OR Logic :

Source A : 0000 0000 0000 0000   (B3:0)

Source B : 0000 0000 0000 0000   (B3:1)

Destination : 0000 0000 0000 0000   (B3:3)

XOR Logic :

Source A : 0000 0000 0000 0000   (B3:0)

Source B : 0000 0000 0000 0000   (B3:1)

Destination : 0000 0000 0000 0000   (B3:4)

NOT Logic :

Source: 0000 0000 0000 0000   (B3:0)

Destination : 1111 1111 1111 1111  (B3:5)

DATA FILE FOR CASE 1:

Bitwise Instructions

CASE 2:

When,

Source A : 0010  0101 0100 0001   (AND,OR & XOR)

Source B : 0001 0001 0001  0001  (AND,OR & XOR)

Source  :0101 0100 1000 0111 (NOT)

PLC Program using Bitwise Instructions

Rung 0000:

I:0/0 giving input condition to all Bitwise Blocks. When it goes ON, value placed in Source A and Source B performs respective operation depends on blocks.

BITWISE Operation of AND, OR, XOR, NOT:

AND logic:

Source A : 0010  0101 0100 0001   (B3:0)

Source B : 0001 0001 0001  0001  (B3:1)

Destination : 0000 0001 0000 0001  (B3:2)

OR Logic:

Source A : 0010  0101 0100 0001   (B3:0)

Source B : 0001 0001 0001  0001  (B3:1)

Destination : 0011 0101 0101 0001  (B3:3)

XOR Logic:

Source A : 0010  0101 0100 0001   (B3:0)

Source B : 0001 0001 0001  0001  (B3:1)

Destination : 0011 0100 0101 0000  (B3:4)

NOT Logic:

Source: 0101 0100 1000 0111 (B3:0)

Destination : 1010 1011 0111 1000  (B3:5)

DATA FILE FOR CASE 2:

Data File for Bitwise Logics

Conclusion:

We can use this explanation to understand the working of Bitwise logical operation like AND, OR, NOT, XOR in Allen Bradley Programmable logic Controllers (PLC).

Author : Hema Sundaresan

If you liked this article, then please subscribe to our YouTube Channel for PLC and SCADA video tutorials.

You can also follow us on Facebook and Twitter to receive daily updates.

Read Next:

How to use Converters in PLC

Ladder Logic using Toggle Switch

Basics of Interlocking in PLC

PLC Configuration Systems

Boolean Algebra using PLC

Don't Miss Our Updates
Be the first to get exclusive content straight to your email.
We promise not to spam you. You can unsubscribe at any time.
Invalid email address
You've successfully subscribed !

Continue Reading

Electrical Earthing Calculations
Free InTouch SCADA Tutorial Course for Beginners
Compare Servo Motor and Stepper Motor
Elevator Control: PLC Program with 5-Second Floor Stops
PLC Programming for Garden Sprinkler System
How to use Sub Routines with Allen Bradley PLC
Share This Article
Facebook Whatsapp Whatsapp LinkedIn Copy Link
Share
Leave a Comment

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Stay Connected

128.3kFollowersLike
69.1kFollowersFollow
210kSubscribersSubscribe
38kFollowersFollow

Categories

Explore More

What is SCADA ? How does SCADA Works ?
Why is 24 Volts Commonly used in PLC Systems?
PLC Programming Videos
Always ON and OFF Bit using Ladder Logic and Statement List
Why Are Charcoal and Salt Added to an Earthing Pit?
PLC Timer Practice Exercise: Coffee Machine Programming
PLC Timer Instructions
PLC Analog Input Scaling

Keep Learning

Parameters of SRT_DINT instruction

Tia Portal – OB20 Time Delay Interrupt Organization Block

PLC Boxes Sorting Based on Height

PLC Programming: Sorting and Distribution of Boxes by Height

PLC Sequential Operation Example Program

PLC Sequential Operation Example Program

Omron PLC Mixing System

Mixing Program with Timers and Counters in Omron PLC

Structured Text PID control loop in PLC

How to Program PID Control in PLC with Structured Text?

How to set password in Siemens HMI

How to Password Protect HMI in Siemens TIA Portal?

Address Overlapping in Tia Portal

How to Check Address Overlapping in Tia Portal?

PLC Retrofitting Project

What is a PLC Retrofitting Project? – Importance, Procedure

Learn More

Absolute and Gauge Pressure

Difference Between Absolute and Gauge Pressure

Questions on Pneumatic Control Loop

Questions on Pneumatic Control Loop

Transformers Questions & Answers Part-2

Transformers Questions & Answers Part-2

Pressure Gauge Problems

Pressure Gauge Problems

Hard-Wired Control Logic for the Pressure Alarm

Hard-Wired Control Logic for the Pressure Alarm

Upgrading and Migration of PLC Systems

Upgrading and Migration of PLC Systems

Testing and Validation in PLC Development

Testing and Validation in PLC Development

Chlorine dioxide measurement principle

Chlorine dioxide Analyzer Principle

Menu

  • About
  • Privacy Policy
  • Copyright

Quick Links

  • Learn PLC
  • Helping Hand
  • Part Time Job

YouTube Subscribe

Follow US
All rights reserved. Reproduction in whole or in part without written permission is prohibited.
Welcome Back!

Sign in to your account

Username or Email Address
Password

Lost your password?