OptoBlog

OptoNews Tech tip: Should I check to see if the output's still on?

Posted by Jean Femia on Sep 23, 2015 5:21:15 PM

FlagsWhen you turn on an output, do you set a flag and then check it to see the output's status before turning the output on again? 

Or do you just turn it on without checking?

Is setting a flag a good way to speed up the program and avoid tying up the network with unnecessary communications to I/O?

Or does it just add a lot of extra variables and decision blocks that make debugging and maintenance harder?

A recent OptoForum post answers these questions with best practices depending on your situation. 

What do you do? Add your comments and questions to the forum post as well.

And remember, the OptoForum is always open. You can get expert answers to your questions from experienced Opto 22 customers and staff.

Read the OptoForum post

Topics: Discrete control, Tips, optonews, PACs, I/O, PAC Project, OptoNews 2015-09-23

Written by Jean Femia

Jean Femia writes about technical subjects and has focused on automation and control systems for more than 15 years. She likes learning about technology and taking corners in her Honda S2000.
Find me on:

    Subscribe to Email Updates

    Recent Posts

    Posts by Topic

    see all