Can't send texts while device is sleeping (sometimes)

All my devices are on 1.1.15 3xTbeam0.7 and 1x heltec Phone app version 1.1.02 . I have the Heltec connected to serial port for debugging. And One Tbeam running off battery to test functionality.

Clicking from Heltec to None in the BLE on the Phone app. If the Heltec goes to sleep. Then it is none discoverable until it does a periodic wake, Only spotted by the activity on my serial monitor. I conclude from this that scan for devices on the app is not waking the modules.

The data sheet suggest that BLE is switched off in all forms of sleep. I am guessing this is where the issue is. Not sure if there is a coding method to directly communicate with the BLE device to put into low power mode and wake to full power Via ULP processor coding mode when activity has been seen. This direct coding of devices would also have to be used for the other peripherals such as WiFi and main core to sleep. Rather than use the blanket esp32 Sleep(); . Not seen any example code of this on the internet, so quite possibly can’t be done

Other issue found when i pair with the Tbeam. Sending a packet to the Heltec. The Heltec wakes , But If it is badly formed packet. The Heltec just goes back to sleep rather respond with I am here but did not receive packet correctly.

I have the same issue. The app will say device sleep. I can’t bring the device back from sleep without hitting the reset bottom on the device.

the default behavior of the device code is to mostly be asleep (except listening to lora for incoming packets). Every few minutes (though these thresholds are configurable) it wakes to check in with the phone to see if the phone has anything it wants the device to do.

For the tbeam (and a few other boards) where we can detect USB power, the default behavior is to stay awake if we are connected to USB pwoer.

Ok. So on battery, the device will wake itself to process any queued up message on the phone? Will it keep listening for incoming messages over the RF?

yep - (unless changed by custom settings) we always leave the lora radio listening. And when we occasionally check in with the phone the phone will send the device any queued messages it has.

1 Like

I observed that the device never woke to process queued messages. Now I upgrade to 1.2.6 with newest Android app, when device is asleep, I can’t even type a message into the queue.

I am also seeing the behavior which distant_ias is seeing where you cannot even type new messages into the android app when the device is asleep. This is using 1.2.17 connected to a T-Beam

The net effect of this is, that you kind of have to catch the device while it’s awake to send any messages, since you can’t queue them up on the phone.

1 Like

Hmm. That’s really odd. Just to check: you are using a Bluetooth connection to the phone and you haven’t changed any of the advanced settings?

I can confirm this on all alpha releases I have tested. Before the app will let you enter a message, the device needs to be awake and paired recently.


@Havealoha so if the phone says the device is sleeping it isn’t letting you enter a message at all during those intervals?

That’s the behavior I have experienced. I have not yet seen this on both of the devices I am using however, so it doesn’t seem to happen universally.

1 Like

I’ve only seen it a few times. Usually though, if it’s sleeping, I can add a new message.

I’m thinking it happens when I’ve added more than one device to the phone. That messes up other stuff too, especially messages. It would be nice to be able to switch the whole app between devices especially when all you want to do is a quick setting change or message test. I’ve resorted to clearing app data and cache.

1 Like

Ok thanks. I’ll try to repro it.

This AM, after device and phone were idle for >7 hours, app says device is sleeping but I can’t enter text into the send message field. After switching to this chrome app and back to Meshtastic app, the send field was responsive again. At no time did I touch the device. Device sleep settings are default, no other nodes in range.

1 Like

Ooh that’s a super good description and very helpful!

Somehow the text box won’t let me type while the TBeam sleeps.

1 Like

(I moved your post here - because I suspect it is the same thing @Havealoha mentioned and I’ll investigate this weekend)

I did some additional testing, and can reliably repro the behavior of not being able to type a message into the android app in some cases where it reports the radio as being asleep.


  1. When radio is connected AND asleep you can indeed type in messages that are queued up for the radio when it wake ups. This all works well.

  2. When radio is out of Bluetooth range of the phone, the android interface makes it appear as if the radio is still connected but asleep. However, you cannot type in messages (to be expected).

  3. Resetting the radio via hardware switch is required to recover from this state when back in range of the radio. EDIT: I am going to double check this again by letting they phone/radio sit in range for several radio wake cycles to be sure.

To sum this up:

It appears to all be working as expected under the hood, but the android app interface incorrectly reports the radio as being connected and asleep when it is actually out of range of the bluetooth connection. This state does not recover without some intervention when you bring the radio back in range of the phone.

The thing that makes this a little bit non-obvious, I think, is the fact that the T-beam radio I am using has somewhat limited bluetooth range, so it was pretty easy to ‘break’ the connection between the phone and radio without realizing it.

1 Like

I think I’ve fixed this. It will be included in the next release (this weekend or possibly monday)

1 Like