Skip to content
Pre-order Genesis or Genesis XL v1.8 for Spring to lock in savings
Pre-order Genesis or Genesis XL v1.8 and save big
December 2, 2022 Software Update

December 2, 2022 Software Update

Today we have a few new updates for you, mostly pertaining to Lua helpers and featured sequences. Here’s what’s new:

New Lua helpers

The latest version of FarmBot OS includes the following new Lua helpers, giving you even more advanced capabilities and convenience when using Lua to program your FarmBot.

  • mount_tool(slot) mounts the tool provided in the argument. Under the hood, this helper uses mostly the same code as our original Mount Tool featured sequence.
  • dismount_tool() dismounts the currently mounted tool into it’s assigned slot. Under the hood, this helper uses mostly the same code as our original Dismount Tool featured sequence.
  • get_xyz() returns a table with the current x, y, and z coordinates of the FarmBot. This is superior to get_position() because this new function gets the coordinates from FarmBot’s state tree rather than sending a firmware request. This allows get_xyz() to be used in watcher functions while a movement is occurring in the main Lua process.
  • safe_z() returns the value of the SAFE HEIGHT setting. Note that safe_z() on it’s own does not initiate a movement, and it should not be confused with adding a safe_z=true argument to a move or move_absolute command.

Please refer to the documentation linked above for simple code examples of each of the new helpers!

Mow All Weeds featured sequence

We’ve published a new featured sequence called Mow All Weeds that uses the FarmBot Genesis v1.6+ Rotary Tool 1 with the weed whacking implement to perform powered weeding on all weeds in the garden.

It uses the load sensing capabilities of the Farmduino to monitor if the Rotary Tool motor goes over the max load threshold as set in custom settings. If the max load is exceeded, FarmBot will halt its movements, turn off the Rotary Tool, return to the staging position, and try again. The total number of attempts is configurable in custom settings as well.

This new sequence uses all of the latest hardware and software we’ve developed over the last year and is a culmination of what our technology stack is capable of. Let us know what you think!

And if you’re unfamiliar with the Rotary Tool, check out this video:

Featured sequence updates

Because all of their code has been conveniently turned into new Lua helpers, we’ve published updates to our Mount Tool and Dismount Tool featured sequences. Now, each sequence is just a single line of Lua code! Note: Make sure you are running the latest version of FBOS before upgrading these sequences.

Wait with Job Progress Tracking

We’ve got one more featured sequence to share today called Wait with Job Progress Tracking, which does just what it says in the name. If you need your FarmBot to wait for a long period of time (up to 5 minutes), you can use this command and FarmBot will create a job to track the progress of the waiting. This can be useful if only to give piece of mind that things are still in motion!

Miscellaneous

  • Support token life has been extended to 7 days.
  • When a staff member is logged into an account with a support token, there is a second logout option to Logout and Destroy Token, allowing us to not keep support tokens active longer than necessary.
Previous article December 14, 2022 Software Update
Next article All FarmBot kits: on sale through Cyber Monday!