Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Mobile and Embedded
  4. Udp Socket in an Android foreground service sleeps

Udp Socket in an Android foreground service sleeps

Scheduled Pinned Locked Moved Unsolved Mobile and Embedded
qudpsocketqtserviceandroid
1 Posts 1 Posters 18 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • A Offline
    A Offline
    arlecchino
    wrote last edited by
    #1

    There is a foreground service (QtService) binding QUdpSockets. One for listening readyRead signal and the other for broadcasting via eventloop timer.
    In readyRead there is fired a notification.
    Both becomes heavily reduced when Android device is not used.
    So from e.g. sending every 5 minutes datagram, the dgrams are reduced to once an hour and later only a few times per day.
    The periodic sending is logged by my app, but seems Android network stack doesn't push it in the air.
    So not sure if Android or the QUdpSocket is delaying.
    For the listening socket it mostly works, but sometimes you have to switch on display to get notification.
    Every app setting I could found, like background data usage, battery optimisation aso, is set to advance for the app activity.
    Any tips how you can provide stable udp socket services with Qt and Android?

    1 Reply Last reply
    0

    • Login

    • Login or register to search.
    • First post
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Get Qt Extensions
    • Unsolved