Hei there,
I was wondering, is there a way to send out a last osc message to an oled display after turning off the Bela?
I have a C++ project which is using the OSCSender class to pass the data to another program running in the background. Also, I have implemented a switch, as described in this post:
https://forum.bela.io/d/261-suggestions-on-adding-a-power-on-off-switch/22
My idea is: you press the button, than the display is saying "Bye bye" or something, than the Bela is turning off.
So I already tried:
- send a last OSC message inside the cleanup() function -> didn't work
- periodically checking for Bela_stopRequested() in the render() function and sending out the message if its becoming true -> didn't work
I was wondering, if it's possible to check periodically for the state of either pin P9.09 or P9.27 or both. Or is there a way to pass in some functionality right before the cleanup() function is called?