added state restoration which allows bluetooth to wake up app even when it's shut down, but i don't have a way to test it yet