VS1053b - Strange VU meter readings

Writing software for systems that use VLSI Solution's devices as slave codecs to a host microcontroller.
Post Reply
perlix
User
Posts: 2
Joined: Mon 2018-03-12 23:24

VS1053b - Strange VU meter readings

Post by perlix » Tue 2018-03-13 0:13

Hello,

After enabling the VU meter function from VS1053b patches version 2.50, I'm confused by the readings from the AICTRL3 register.

This code inside loop() (using Adafruit's VS1053 library)

Code: Select all

uint16_t vu_values = musicPlayer.sciRead(VS1053_SCI_AICTRL3);
Serial.print(highByte(vu_values));
Serial.print(",");
Serial.println(lowByte(vu_values));
produces the following output on the Arduino IDE serial plotter:
Image
The yellow line (low byte, right channel) seems OK, but the green line (high byte, left channel) seems to represent a different signal property. The corresponding audio sounded like well balanced stereo.

Help would be much appreciated.
Thanks - Paul

User avatar
pasi
VLSI Staff
Posts: 1466
Joined: Thu 2010-07-15 16:04

Re: VS1053b - Strange VU meter readings

Post by pasi » Mon 2018-04-16 17:04

Hi,
It actually looks like the green one is what it's supposed to be - a leaking maximum decibel value in 1.5dB steps.

After finding the bug (signed multiplication instead of unsigned) it looks like the right channel value is the instantaneous dB value of the signal.

I fixed the bug and hopefully get to update the patches soon enough.
Visit https://www.facebook.com/VLSISolution VLSI Solution on Facebook

perlix
User
Posts: 2
Joined: Mon 2018-03-12 23:24

Re: VS1053b - Strange VU meter readings

Post by perlix » Mon 2018-04-16 20:54

Hi pasi,

Thanks for looking into this issue and for fixing it in version 2.51!
Readings are OK now:

Image

User avatar
pasi
VLSI Staff
Posts: 1466
Joined: Thu 2010-07-15 16:04

Re: VS1053b - Strange VU meter readings

Post by pasi » Wed 2018-04-18 14:46

Thanks for reporting the issue and reporting that it got fixed!
Visit https://www.facebook.com/VLSISolution VLSI Solution on Facebook

Post Reply