Sequence flow question

I would like to find a way to abort a sequence (water all plants) if the watering tool is not picked up.
I know I can use an “IF”, but it seems my option is to have the statement just move to something like a wait or such.
Any creative ideas?
I would ideally like it to exit the entire sequence without continuing to the next step.

There are two ways in the FB ecosystem that I am aware of (and I might be wrong about one of them).

  1. an if statement
  2. an exception <-- the one I’m not sure about

The if statement can occur pretty much anywhere…you could write a custom farmware that’s constantly checking the pinout for the water attachment, then abort. You can also do the same thing with sequences.

You could go the next step and write a custom firmware that will throw an exception under conditions that you set (e.g. your farmware would tell the firmware that it’s picking up the watering attachment and if it doesn’t sense the water attachement, then trow and exception and abort). This seems overkill, but perhaps something worth weaving into the FB OS: custom exception handlers and events.

Cheers!

1 Like

Ok, maybe a stupid question, but…
How would you execute an “Abort” from an IF statement?
As I see it, I could if into a WAIT or the like, but could not truly exit the sequence. Am I missing something basic?

*Also, it would be nice to have a way to abort a sequence manually without having to trip an E-Stop.
At his point, if i am testing a sequence and i want to stop it, I basically do an E-Stop, unlock and move on. Maybe this is the way, by design, but seems like a “Stop Sequence” would be a nice-to-have…

That’s not as stupid as is seems … As far as I know, there is no function to abort a sequence that is running yet, but its been discussed multiple times.

.Create an IF block at the end of the Tool-pickup sequence which checks if the verification pin is LOW. When the statement is true (pin is LOW), execute the Watering sequence, and if its not true leave “None” in the ELSE field. Everything behind the IF block will still be executed!

https://software.farm.bot/docs/verify-a-tool-has-been-mounted

2 Likes

So a funny thing happened today…I went out today to admire my peppers and see if any are ready for quesadillas…when I noticed the watering attachment laying in between two of the plants! It looks like it knocked off somehow and pressure washed the plants in the process. Anywho: the ability to check to see if the water tool is actually attached, and then abort, all of a sudden has more relevance to my situation :slight_smile:

I think I may start with the “Water them all with MLH” sequence and check for solid attachment before I send MLH to do it’s thing. Or check in the the base watering sequence before dispensing water (I have a base 50ml dispense sequence that I then repeat inside wrapper sequences). While it doesn’t abort, it does prevent the pressure washing of peppers, carrots, and tomatoes.

1 Like

So I have been unable to get either MLH or Selfie to run (see my post at How to adjust “stitching” to get a better FB selfie)
Aside: I would love help figuring out why I can’t run them.

Having said that, I currently have an IF sequence that does a Tool Verification.
IF a tool is present (digital “0”) it runs a sequence called “The Short Wait” (waits 5 seconds and returns to the flow.
IF a tool is not present (digital “1”) it runs a sequence called “The Long Wait” (sends an email alerting no tool present, then waits 24 hours before returning to the flow.

Short of a “Sequence Abort”, this alerts me and gives me time to get to the plot and fix the problem.
I run this right after my “Get Watering Nozzle” Sequence.
I could insert it anyplace or time, if I worry about the tool getting knocked off…

1 Like