5ocworkshop

Results 34 comments of 5ocworkshop
trafficstars

It might even be useful to have a STATE_BOOT or STATE_RESET flag (or both?).

> These events are already trappable, the plugin init function is called once during boot and you can subscribe to reset events by adding a function to the `hal.driver_reset` chain....

Excellent, this is exactly what I was looking for. Is this available today or in your "to be committed in the near future" stack?

Here is what I am doing for now for the flashing portion. Is there a HAL call that will return the current alarm sub-code? I haven't been able to find...

Your example works great. I'm going to move my code over to that callback.

> Also, is there an example available of reading the spindle state via the hal.spindle.get_state call? Spindle on is one of the key things I want track. Found this too:...

Thank you for the excellent feedback and all your work and deep thought on this project. The more I learn about how you have laid it out the more impressed...

Question regarding: ``` if(state != last_state) { last_state = state; hal.port.digital_out(port, state == STATE_HOLD); } ``` Is that an elegant way of saying "Only execute the hal.port.digital_out(port) call if the...

> This is neat trick if only one element in a struct/union return value needs to be referenced. Again, no need for the temp variable. That is a very neat...

That looks very helpful for debug. Thank you!