3 ms·
I'm not sure I've had that issue with Mobian--I definitely am able to receive phone calls while it's sleeping in the other room, so it's not like there's an inh
by qchris 6y ago
I'm not sure I've had that issue with Mobian--I definitely am able to receive phone calls while it's sleeping in the other room, so it's not like there's an inherent inability to push notifications during sleep. I think that using `libnotify-bin` is the recommended library for doing notifications at the moment, although I haven't tested it to see if it pops up during sleep.
I did my first "Hello, world" app for it on Mobian on Pinephone, linked below, with that library and that seems to work pretty well.
[1] https://github.com/quietlychris/mobian_hello https://github.com/quietlychris/mobian_hello
Edit: After some prelim testing, it does look like the notification from the example I linked doesn't get pushed to the phone while it's sleeping. Unless there's been a fix pushed in the week or so since I've updated it, looks like that's still a to-do.
- jchw 6y agoPhone calls and text messages are way different than push notifications. The modem is a separate chip on the device that can almost definitely wake up the CPU, and there is, to my knowledge, no such chip for fetching push notifications over the internet. Even if there was, you can verify by hand that apps like tdesktop don’t support any kind of central push notification service from the operating system, so it would be impossible for the device to do anything special; it simply has to be awake for traditional apps to process push notifications. Libnotify is for sending notifications to the OS for display. However “push notifications” usually refers to the system that handles the push portion. For example, APNS (Apple Push Notification Service) and FCM (Firebase Cloud Messaging.) Lacking a centralized service both on the OS side and in the cloud, it’s difficult to see how a battery-optimized push notification system could be devised. From my understanding, on today’s phones generally the CPU has to wake up periodically to poll, and if you have many individual push services that would be inefficient. (Maybe iPhone has a more clever system than just waking up the main CPU to poll, I do not know.)
- megous 6y agoYou can possibly use the modem itself for monitoring for notifications, even if the main SoC sleeps. And wake the main SoC up from the modem. It would only work over mobile data though.
- seba_dos1 6y agoDon't forget that the modem firmware is completely proprietary, so the idea is rather to make it do less, not more.
- megous 6y agoModem firmware is, but the Linux running on the modem isn't. It's under GPL. Some people would even like to run mainline Linux there, eventually. Even the userspace running on the modem can hardly be called completely proprietary. It's some busybox system + bunch of other tools that are also under GPL or other OSS licenses. I didn't measure it exactly, but it wouldn't surprise me if the amount of proprietary code in userspace of the modem is < 20%.
- seba_dos1 6y agoThe fact that the firmware contains GPLv2 code doesn't mean it's not completely proprietary. You can't modify the modem firmware and then still legally operate it in public networks under most legal jurisdictions around the world.
- megous 6y agoSure I can. Modem's firmware is split into two parts. Linux OS running on ARM CPU and modem's modem FW running on hexagon cores. It's possible to modify ARM CPU code without affecting modem's operation much at all. ARM CPU just takes care of some audio/USB and such interfacing tasks. It's laregely free to run your own tasks. The manufacturer even allows customers to build their own userspace code for the ARM CPU inside the modem and extend it this way as part of quectel open linux SDK. Anyway, the original issue was about notifications, and ability to implement them without consuming too much power. And one of ways to do it is to extend the modem this way.
- zozbot234 6y ago> generally the CPU has to wake up periodically to poll, and if you have many individual push services that would be inefficient. Even if you had many push services, waking up periodically and polling them all at the same time ought to be rather efficient.
- jchw 6y agoEven if this is true, you still need to coordinate all of them to happen at once, so it doesn't obviate the need for an OS-level service to coordinate this at least.