[SOLVED] Queue clears on reboot
#2
(2026-01-11, 02:47 PM)µpod Wrote: Summary:
Whenever the system restarts or is manually restarted, the queue clears.

Observed Behaviour:
Whenever the system is automatically restarted (i.e. when play is paused and the screen is switched off for the appropriate period) or is restarted manually (by holding both volume buttons and toggling the display switch), the queue is cleared.  This persists through multiple restarts.  

Notably, if the SD card is ejected and then reinserted, the queue is mysteriously restored.

Possibly also worth noting: i primarily use my device for Podcasts, which is why this issue is so noteworthy to me.

Expected Behaviour:
I would expect the queue to persist through restarts.

It's good to have the workaround of ejecting and reinserting the SD card to restore the queue in a pinch, but this also, of course, puts wear on the SD card slot, and these slots do seem to wear out comparatively quickly ime.

System info:
ESP32 v. 2.0.0
SAMD21 v. 6.0
Collator Generic

Please let me know if there's something i'm missing or doing wrong; any additional troubleshooting i could perform; and/or any additional info i could provide to help make sense of this.  Thanks so much in advance for any help and advice!

The queue might not get serialised in the case of a hard reset, as it doesn't do a proper shut down, so that case is expected. It should however persist the queue if it's shut down properly though (ie paused and switched off). The queue on disk is probably still there (in a file `.queue.playlist` in the root of the SD card), but it seems that something's going wrong with the code responsible for saving/loading the state the queue was in. The serialisation/deserialisation happens in the UnmountRequest and SDStateChanged event handlers, so that would explain why ejecting and reinserting the card would restore the queue. 2.0.0 does move the audio fsm initialisation to later in the boot sequence, so it's likely that it now misses the initial SD state change and never restores the queue.

There's an open issue for this here: https://codeberg.org/cool-tech-zone/tang...issues/461. I'll try get a fix for this working shortly.
  Reply


Messages In This Thread
[SOLVED] Queue clears on reboot - by µpod - 2026-01-11, 02:47 PM
RE: Queue clears on reboot - by ailurux - 2026-01-12, 12:13 PM

Forum Jump: