Hello Guest it is March 29, 2024, 03:59:09 AM

Author Topic: Macro for monitoring a DRO  (Read 3401 times)

0 Members and 1 Guest are viewing this topic.

Macro for monitoring a DRO
« on: July 08, 2013, 07:08:47 PM »
Hi all.

I wrote a brain that look at the A axis DRO to the output #3 and to be on only when the DRO is between 1.000 and 1.500in.

This is for a solenoid that blow air to a carbide saw.

Work great but would also like to add another function to have that output on only when the saw move forward or only when cutting and turn it off when

it goes in reverse or retract. The problem I have is when the saw go back to the 1.000in position, it still between 1.000 and 1.500in

Can it be done.

Thanks a lot.


Jeff

Offline poppabear

*
  • *
  •  2,235 2,235
  • Briceville, TN, USA
    • View Profile
Re: Macro for monitoring a DRO
« Reply #1 on: July 13, 2013, 10:10:35 AM »
set up a conditional output in your brain that does this:

Use your already existing logic for your output #3, but pipe it into an "AND" instruction.

the other part of the AND, compare your current position to your last position,
if the subtraction is > than 0 your moving forward and this will keep your AND condition true.
if the movement is =< than 0 your stopped or moving backward (thus the second leg of the AND
conduit would not be true, and thus your output3 would be off.

If you have trouble doing the positioning math in the brain, you could do that part in the MacroPump,
push the answer into a UDRO then have the Brain look at that........ OR, just do it all in the MP.

Scott
fun times