Introduction to ControlLogix GSV Command (Battery Low)
In this post, we will discuss how to use the ControlLogix GSV Command to find the Battery Low bit in the system. Older processors, such as the L6x and earlier used a battery in the default configuration. A battery option is also available on the newer processors (such as the L7x). Use this option if the processor will be powered down for long periods (greater than a week at a time).
If the battery is low, a battery status light energizes on the processor. When this light energizes, you have just 1 to 2 days to replace the battery without the risk of loosing your program the next time the processor powers down. The problem with this is that we don’t check the processor status lights until there is a problem. Using the GSV command, we can access the battery low bit in the system, and energize a light on a panel. We could also use this battery low bit to show a warning on an HMI, such as a PanelviewPlus, or FactoryTalk View Station.
The Help File in Studio 5000 is a tremendous resource for exploring the features of the GSV command. In this post, we’ll walk through the procedure step by step to access the battery low bit.
Create your tag
The battery low bit is part of the MiorFaultBits in the system, which is a DINT. The Battery Low bit will be on bit #10 of this tag. Go to the controller tag database, and in “Edit Tags” mode, create a tag named “MinorFaults”, and the data type is a DINT.
Add your logic
Here, we’ll add the GSV Command into the MainRoutine as shown, then finalize your edits:
Check your battery
Now, open the controller tag database, and look at your “MinorFaults” tag. We will be in “Monitor Tags” mode. I’ve added a description to Bit 10. If the battery is low or missing, Bit 10 will turn on.
If we remove the battery, we see the battery low bit (MinorFaults.10) goes true. We can then use this bit in logic as a warning that battery replacement is needed.
For another application using the GSV command, visit the tutorial on the WallClockTime object!
— Ricky Bryce