Action Button Toggle

Hello,
I recently upgraded to the SLB. Hats off to Sienci Labs for another great product! I currently have my vacuum connected to AUX 1 powered output. It toggles flawlessly when I start and stop my machine. I would like to add the ability to toggle it on and off from one of my action buttons. I’m running macros on the other 2 buttons but have not been able to find/create/edit any code to toggle AUX 1 off and on from a single button. Helpful input would be appreciated.
Thank you!

1 Like

Hey Jeffw,

Welcomes to the playground.

I’m no macro wizard, but remembered a simular topic with an attemp to toggle something via an estop button. It might give some useful info andor insights.

Here’s some info found in the manual about auxing things, you prolly know but if not, tadaaa.

And who knows, one of the wizards stops by, waves a hand, and make it all work.

Thank you for the response. I read that post too. I was unable to get the code to work. I was getting various errors. I ran the 3 lines (changing the port to P2) but it did not respond. I’m not great at writing code so it’s certainly possible the fault was mine. If it was I couldn’t find it. Here is what I tried to run %global.toggle = global.toggle 0 : 1|%command = global.toggle == 1 “M64P2” : “M65P2”|[command]

@JeffW I couldn’t write the code, but I can see that you have left the ? marks out of yours compared to the one that @Spamming_Eddie linked to.

Interesting. It basically cut and pasted the code with the exception of P2. I just entered the question marks in the macro, when I updated the settings it eliminated the question marks. Appears to be a coding thing above my understanding… thanks for the input!

@JeffW It’s way above mine, too. What do you mean by “updated the settings”?

Once I put the code into the macro on the Tools/Action Button3/ Button3 Macro (in gSender) it asks me if I want to apply the settings. When I click on the button, the settings are updated and the question marks disappear.

@JeffW I just duplicated that issue. I re-read the post the @Spamming_Eddie linked to and that reminded me that the action buttons are limited in the macros that they can run.

Thank you for the info! Maybe a request for a future update?

@JeffW It couldn’t hurt. @chrismakesstuff seems to know about this from the exchange at the link that @Spamming_Eddie posted here. You can always add it as a gSender suggestion here on the forum.

Yes @JeffW sorry to say but there’s two limitations going on here that both relate to the current firmware that runs on the SLB:

  1. The Action buttons themselves don’t have the ability to store logic like the ‘?’ needed to make a toggle work
  2. Even though gSender CAN process this type of logic, there’s no way currently for the Action buttons to send a message to gSender to run the g-code on gSender’s side

Now that being said, there is technically a solution to this still which is to use a modified version of the SLB firmware that supports “NGC expressions” which you can find here: Auto-squaring on the SLB - #20 by chrismakesstuff

Then once you’ve flashed it, it’ll give you the ability to stick an SD card into your SLB and store macro files on it, where you can call those macros with the Action buttons. It’s pretty slick and I’ve only got some rudimentary documentation on it for now (Technical Manual - SuperLongBoard), but if you’re keep to give it a shot there’s certainly other information out there about it. Anyway, I hope that helps :slight_smile:

Thank you for the reply! I will check it out. Although I must admit the thought of flashing the firmware gives me the cold sweats…