[3.512] Album ART & track info displays one track in front of whats playing

Fixed with:

We will do QA and then release if all good (next release after the next)

Thanks for everyone for reporting it and helping us fix it

2 Likes

Been trying the code changes you submitted and this fixes the issueā€¦mostly :slight_smile:

If there is quite a bit of difference between track lengths ie 5:56 first track and 3:37 second then it will change the artwork very early, the seek bar jumps to nearly the end, then starts again from the begining until the track ends and the next one starts where the seek bar will reset to the correct position.

On the plus side the art work does not jump one track ahead. So its getting there

Again tested on the 2.457 version which does not do this.

For me, this simple fix will place Volumio firmly into the #1 spot for what is a highly contested DIY streamer market.

Once fixedā€¦take my subscription $$$!

1 Like

How early? 5 seconds early? More, less??

Which service are you using? Which hardware are you using (PI1, 2 , 3 etc)

Can you send a log?

That was from some quick testing I did yesterday.

As for details of system all in the 1st post.

Service: everything being played from local network

And by very early I mean ~20 seconds early. I have an idea that it maybe different depending on the difference in track lengths.

I posted yesterday in case any one else had tested and noticed it too.

I have fair bit of spare time today, ā€¦iā€™ll post in more detail later.

Test
I have a descending playlist starting 5.56 , 5.05 , 4.16 , 3.37 , 3.20

First track is played and track time noted when artwork changes.
Second track deleted, rebooted, wait for startup sound, click play and note when artwork changesā€¦rinse and repeat.

First track is always 5:56

If second track isā€¦

5:05 artwork usually changes when it should some times ~5 secs early

4.16 artwork changes at 4.57 http://logs.volumio.org/volumio/91bCSQx.html

3.37 art work changes at 4.52 http://logs.volumio.org/volumio/Y7r7THr.html

At this point I thought Iā€™d try and find the point where it messes up and went back to the original descendin playlist of 5.56 , 5.05 , 4.16 , 3.37 , 3.20 changing just the second track length with all the others still in the queue.

So with just the second track length changed toā€¦

4.49 artwork changes at 3.47 http://logs.volumio.org/volumio/fUIAwVH.html
4.30 artwork changes at 4.42 http://logs.volumio.org/volumio/pei9og5.html

Edit : 2 seconds before the art work changes, the seek bar shoots to the end and carries on with the new artwork untill the track finishes and then resets

Thats me done for nowā€¦Sick of listening to ā€œsweet child o mineā€ :smiley:

Not sure if this is helpfullā€¦

But if I comment out this new line you setTimeout(this.pushState.bind(this), 600);

The artwork and track data does not change before the end of the track ie its working correctly.

how everā€¦ when it gets to the point when the seek bar would otherwise jump to the end. it just goes blank until the next track starts then seems to work as normal.

Hello,

Iā€™m a bit confused by all of this nowā€¦

Thatā€™s why Iā€™d like to ask nowā€¦weā€™re talking about the same thing when I sayā€¦I often notice that the timer is already at zero, but the title is still running for a few seconds and this time delay drags on to the next one, then the next track doesnā€™t start at zero but at e.g. 5 seconds.
This stops when I simply press back/restart the title?

Sometimes Iā€™m a bit stupidā€¦ I missed your videoā€¦ okā€¦ not the same.

Sorry, I didnā€™t quite catch what you mean here. Could you help me understand better?

Are you trying the new code in the app/statemachine.js file.
Can you post your logs and experience to help out.

Ive found that it works OK up until a point. But if the track length between track 1 and track 2 differ by >50s then the artwork changes to the next track very early(+60s) and the seek bar jumps to the end, restarts with the new artwork while the 1st track finishes then the seek bar resets normal.

but if I comment out the line setTimeout(this.pushState.bind(this), 600); then the artwork seems to behave normally ie changing at the correct time
Butā€¦ at the point the seek bar would have jumped to the end, now just disapears until the end of the track.

1 Like

Where do I get this file?

Where do I put this file?

The post by Volumio results in ā€œCompare errorā€ for me.

Cheers

Thereā€™s no file to getā€¦ just instructions on which file to edit and what to change

Many thanks for clearing that up for me.

3 different highlighted colours in the code window.
May I assume I comment out the code in pink and add the code in green within my statemachine.js file?

The - (red) delete
The + (green) add

Once done the line numbers should match. ( old on the left , new on the right)

BACKUP FIRST BEFORE ā€¦

@dmonds

Did you manage to get the edit sorted ? Could you tell me im not mad :slight_smile:

I made a bit of an acidental discovery.

@volumio new code does work perfectlyā€¦IFā€¦ you do not press play until at least 27 Seconds after the startup sound.
This was with a clean install of 3.546 and other than setting up, the only mod was to edit the statemachine.js file with the new code.

Strange why 27seconds, 26 and below does exactly as I described above.
Whether the 27s is to do with the pi version or sdcard speedā€¦maybe.

Yep, updated both my 3B+ and my 4B.

3B+ seems to work semi-perfectly so far.
Have not tested my 4B yet.

I havenā€™t tried the press play less than 27 seconds after startup sound.

What are you saying happens if you press play soon after startup sound?

@dmonds
To summarize
As you know the original bug was to do with the difference between track lengths. If the first track was longer than second it caused the artwork (and details) to change early, then at the end of the track changed again to the third track. Even 1s difference in lengths would make this happen
.
.

The new code, this fixes the issueā€¦mostly
But If there is quite a bit of difference between track lengths >60s then it will change the artwork very very early, the seek bar jumps to nearly the end, then starts again from the begining until the track playing ends and the next one starts, where the seek bar will then reset to the correct position. On a plus side the artwork remains correct.
This happens if I start Volumio and as soon as the startup sound plays, I press play (or up to 27s later).

But ā€¦If you make sure you leave at least 27s after ther startup sound and there is no problem.

.
.

What is the issue that makes it semi-perfectly

Ive not tried my 3B+

In my first and only test session so farā€¦
RPi 3B+ Volumio 3.546

Timers and artwork all seem to work fine using my original music queue (listed higher up in this thread).

I control Volumio via my iPad connected to the web gui.
I have my TV connected via HDMI and use Touch Display and Now Playing plugins.
Semi-perfectly = the timers shown the two separate screens can vary by up to 4-5 seconds.
Both reset at the end of each song fine, but the UI on the TV doesnā€™t start counting for 2-5 seconds after song starts.

2nd Test session today.
If I pause and hit play again, both UIs are in sync.

Trying to hit play soon after startup soundā€¦nothing happens for about 10-15 seconds (have not timed this precisely) then I get a message on screen ā€¦ ā€œConfig Updated Player Restartedā€, then if I hit play again, things progress.

Song info including artwork switch at end of songs properly.

Also just spottedā€¦if I shift to a different browser tab (Safari on iPad), the WebUI timer does not update when I shift back.

EGā€¦timer = 1:20, shift web browser tab for 10 seconds then shift backā€¦WebUI carries on from 1:20 and wonā€™t sync again until next song, I hit pause or refresh the web browser window.

I am certain this worked properly prior to editing the file.

I have a windows tablet, android phone and laptop all which seem in sync. That sounds more like browser issues, can also be caused by wifi connection issues too.
restore your original statemachine.js and test again.

The issuses on my pi 4 Im having are similar to before.
Video(1min) cuts straight to the chase.
5 seconds into the video you can see the seek bar jump to the end, then change artwork which is ~50 seconds too early. But still playing.