# Badger 2350: Flag to know if the app has been freshly started from the OS/menu?

**URL:** <https://forums.pimoroni.com/t/badger-2350-flag-to-know-if-the-app-has-been-freshly-started-from-the-os-menu/28784>\
**Category:** Support\
**Created:** [March 19, 2026, 4:47pm UTC](https://forums.pimoroni.com/t/badger-2350-flag-to-know-if-the-app-has-been-freshly-started-from-the-os-menu/28784 "2026-03-19T16:47:39Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![jecaro](https://sea2.discourse-cdn.com/flex016/user_avatar/forums.pimoroni.com/jecaro/32/11040_2.png) [@jecaro](https://forums.pimoroni.com/u/jecaro)\
**Post date:** [March 19, 2026, 4:47pm UTC](https://forums.pimoroni.com/t/badger-2350-flag-to-know-if-the-app-has-been-freshly-started-from-the-os-menu/28784/1 "2026-03-19T16:47:39Z")

</div>

This is [the app](https://github.com/jecaro/badger2350?tab=readme-ov-file#mqttooth) I’m currently developing. It gets temperature/humidity values from a backend service via bluetooth and display it on the badger screen.

It goes like this in pseudo code:

- load state
- fetch new data from bluetooth → takes a few secs
- if the new data is very different from what’s in the state
  - store it in the state
  - refresh the display

- store the state
- set the alarm in 5 mins
- sleep waiting for the alarm or a button

It works fine when running. But when I start the app from the OS/menu. If the new data doesn’t trigger a refresh, one can think the app didn’t start at all, which is super annoying.

When starting, I’d like the display to be refreshed only, no bluetooth connection, no fetching data. I looked into the API, but I couldn’t find anything that would tell me the app was just freshly started from the OS/menu.

Any idea?

---

<div class="post-metadata">

**Author:** ![jecaro](https://sea2.discourse-cdn.com/flex016/user_avatar/forums.pimoroni.com/jecaro/32/11040_2.png) [@jecaro](https://forums.pimoroni.com/u/jecaro)\
**Post date:** [March 20, 2026, 8:10am UTC](https://forums.pimoroni.com/t/badger-2350-flag-to-know-if-the-app-has-been-freshly-started-from-the-os-menu/28784/2 "2026-03-20T08:10:51Z")

</div>

I still don’t know how to do it. But I’ve found a workaround. I can know if the badger was woken up by an alarm (what I do in the last step) with:

```auto
woken_by_alarm = badge.wake_reason() == powman.WAKE_RTC

```

This is not in the official documentation yet. Hope this info can be helpful for other people too!
