Go Back   Home > Forums > >

PC Based Computer music servers, crossovers, and equalization

PeppyMeter
PeppyMeter
Please consider donating to help us continue to serve you.

Ads on/off / Custom Title / More PMs / More album space / Advanced printing & mass image saving
Reply
 
Thread Tools
Old 17th July 2021, 04:41 PM   #461
rpi is offline rpi  United States
diyAudio Member
 
Join Date: Apr 2015
Location: San Francisco
New version of the PeppyMeter was released today:
GitHub - project-owner/PeppyMeter: PeppyMeter Repository

The updated documentation can found here:
Home * project-owner/PeppyMeter.doc Wiki * GitHub

New features:
- PeppyMeter can send HTTP requests with volume data to remote web servers
- PeppyMeter can receive HTTP requests and display volume data from those requests
- Added cache for needle sprites. It makes transition from one meter to another much faster. It also fixed the Pygame/SDL memory leak
- Implemented ability to embed PeppyMeter to larger screens
- New configuration parameter enables exit on touch event

Here is the video showing the example of using the PeppyMeter in the Volumio Add-on:
Volumio VU Peppy Meter (6/25/2021 version) - YouTube

Last edited by rpi; 17th July 2021 at 04:44 PM.
  Reply With Quote
Old 22nd July 2021, 11:10 AM   #462
SergeG is offline SergeG
diyAudio Member
 
Join Date: Jan 2020
Hi Rpi,


Do you remember a spell ago we (you, me and phofman) were involved into a problem with CPU spikes while switching radio stations in PeppyPlayer?
Phofman made some fixes to libasound.so.2.0.0
Hope you remember.
Looks like I’ve found a related problem while playing a test file click1.wav (full scale sine on one channel and clicks on another).
Might I ask you to play the file and share the results?
Dropbox - click1.wav - Simplify your life


Actually the file was created for a different purpose but I’ve detected a strange PeppyMeter behavior (I’m using mpd/peppyalsa plugin/PeppyMeter chain), the needles movements are ugly intermittent.
Trying to diagnose, I switched PeppyMeter off and checked ‘hexdump peppyalsa.pipe’ (peppyalsa output pipe) and saw the same terrible intermittence that was never observed while playing music.
So the problem is definitely not in PeppyMeter, but rather in the alsa-metering (tried the both libasound.so.2.0.0-s, the original and the patched) or peppyalsa.
Most probably the first as peppyalsa source is pretty straightforward.


Could you please try, I’d like to understand whether the problem is not solely mine at least


Thanks,
Serge
  Reply With Quote
Old 23rd July 2021, 03:42 AM   #463
rpi is offline rpi  United States
diyAudio Member
 
Join Date: Apr 2015
Location: San Francisco
Hi Serge,

I'm not sure what kind of issue you observed. Your file has a high level signal of constant frequency in the left channel and clicking sound in the right channel. I think PeppyMeter works as expected - the left channel hand/needle is in the right/max position and doesn't move. The right channel hand/needle shows clicks as expected.

Best regards
  Reply With Quote
Old 23rd July 2021, 08:11 AM   #464
SergeG is offline SergeG
diyAudio Member
 
Join Date: Jan 2020
Hi Rpi,


Thank you for trying!
What I observe is extremely strange. The left needle is in the max position as it should be.
The right needle reflects the clicks for a second, then drops to the min position (or just shows zero level between the clicks) and freezes for a second or two, so for a second or two, the right needle shows the minimum.
When I stop PeppyMeter and use “hexdump/cat the-fifo” I see the normal flow (max on the right and spikes on the left for a second, then the flow freezes for "one and a half" seconds and then the process repeats.
So probably the second stage of needles (freezing), i.e max on the right, min on the lift (between the clicks) is just no signal from peppyalsa, so nothing new to show/update he needles with.


Would be happy if you suggest me a more in-depth diagnostics.
I do understand nothing so far


Thanks
  Reply With Quote
Old 23rd July 2021, 06:41 PM   #465
SergeG is offline SergeG
diyAudio Member
 
Join Date: Jan 2020
Hi Rpi,


After you confirmed it’s not a general problem I started focusing on what is unique in my system.
So the problem was found and fixed.
It was snd-dummy sound driver that was used as slave.pcm in peppyalsa config.
I would not like to bother you with the details, however if you need them, I would be happy to explain.
Anyway thank you very much, you actually helped me!


Yours,
Serge
  Reply With Quote
Old 24th July 2021, 04:16 AM   #466
rpi is offline rpi  United States
diyAudio Member
 
Join Date: Apr 2015
Location: San Francisco
Hi Serge,

Good to know that you found the issue. I don't think I was helpful though.

The ALSA configuration is very confusing area. It's probably next to rocket science
I was thinking for a long time how to simplify the ALSA configuration process in the Peppy Player. I thought to represent it either as a diagram with nodes or just as a template or set of templates for .asoundrc files. BTW, Volumio player started using templates for ALSA configuration recently.

Best regards
  Reply With Quote
Old 25th July 2021, 01:31 PM   #467
SergeG is offline SergeG
diyAudio Member
 
Join Date: Jan 2020
Hi Rpi,


I’d like to ask for an advice from you if I might.
I’m creating a box with Pi4 (with mpd and PeppyMeter) + I2C connected DSP board (crossover + room equalization).
Some DSP parts (especially PEQs for room equalization) can produce positive amplification (above 0db), so some clipping may happen. I’ve already inserted a clipping detection algorithm into DSP that works, I can read per-channel clipping flags from DSP via I2C.
Now I need to display the clipping in Peppymeter anyhow.
I’m not a guru in python and especially not in pygame, so would need an advise for how to insert a clipping indicator into Peppymeter.
I believe it should be a sprite (nearly as the needle) with the same display approach (partially refreshing the background and adding new sprite).
Am I wrong? Or there is a way to inject a “static” (slowly volatile) “label” into the pygame surface?


What is the best point to create such functionality in your class structure?
Should it be a part of the meter class or meterfactory, or something else.
Peppymeter looks well structured, so there should be a logic for finding a proper place you are definitely aware of better.


Thank you,
Serge
  Reply With Quote
Old 25th July 2021, 04:45 PM   #468
rpi is offline rpi  United States
diyAudio Member
 
Join Date: Apr 2015
Location: San Francisco
Hi Serge,

As far as I understand you want to add two states indicator: one state - no clipping and another state - clipping. So it's like a LED which is shining whenever clipping happens. If this is the case then you have to create additional layer for the meter. There are currently three layers: background, indicator and foreground (optional):
Meter Anatomy * project-owner/PeppyMeter.doc Wiki * GitHub
You have to add the layer for the clipping indicator and control its state/visibility in a separate thread. You can check how background/foreground layers have been added in the meter.py.

I would recommend to setup development environment on your desktop machine (PC or Mac) and then deploy on Pi or whatever Linux machine you use. This way you can develop the visual part much faster as it can take a lot of time. I mostly use my Windows PC desktop for development and from time to time just deploy on Pi for the final testing. I use VS Code IDE with Python extension.

Best regards
  Reply With Quote
Old 26th July 2021, 08:46 AM   #469
SergeG is offline SergeG
diyAudio Member
 
Join Date: Jan 2020
>So it's like a LED which is shining whenever clipping happens.
Maybe not a LED precisely but similar to that


>to create additional layer for the meter.
Brilliant! The layer based approach will definitely simplify the things.



>I would recommend to setup development environment on your desktop machine (PC or Mac) and then deploy on Pi or whatever Linux machine you use.


I already go the same way actually :-)




Thank you very much!
Serge
  Reply With Quote
Old 5th August 2021, 01:18 AM   #470
cheapvega is offline cheapvega  United States
diyAudio Member
 
Join Date: Mar 2021
Are there any plans for a spectrum analyzer? Preferably with adjustable peak holding, just like my childhood?
  Reply With Quote

Reply


PeppyMeterHide this!Advertise here!
Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


New To Site? Need Help?

All times are GMT. The time now is 09:08 PM.


Search Engine Optimisation provided by DragonByte SEO (Pro) - vBulletin Mods & Addons Copyright © 2021 DragonByte Technologies Ltd.
Resources saved on this page: MySQL 14.29%
vBulletin Optimisation provided by vB Optimise (Pro) - vBulletin Mods & Addons Copyright © 2021 DragonByte Technologies Ltd.
Copyright ©1999-2021 diyAudio
Wiki