ALSA Volume Control plasmoid

Plasma 4 Extensions

Source (link to git-repo or to original if based on someone elses unmodified work): Add the source-code for this project on opencode.net

6
8 .3
Description:

Plasmoid controls alsa devices by mouse. You can add plasmoid to panel (both vertical && horisontal) or to workspace.
You must install python-alsaaudio or similar in your distributive.
Last changelog:

6 years ago

v.0.25
* fixed audiodevice detecting error;
* added detecting multiple audiodevices in system;
* added color managment of font and panel sliders with support opacity;
* added device rescan without restart plasmoid;
* added plasmatooltip with representation
device volume in panel;

v.0.27
* added Rescan button to Panel Devices Settings;
* added color control for slider handlers;

v.0.28
* fixed cardindex detection;

v.0.30
* improved stop control of tracking thread;
* added detect system color of text for first start;

v.0.35
* changed method of thread complete;

v.036
* text is replaced by icons in Common Device Panel;

v.0.37
* fixed warning in import module errors;

v.0.41.2 :
* added restore of device volume;
* added retrieve restored volume parameters;
* fixed slider`s mouseRelease & doubleClick events for common events;
* fixed the freez at plasmoid's init;
* some fixes & improvements;

v.0.42.2 :
* some fixes & improvements;

v.0.42.3 :
* fixed initiate;
* improve initiate;

v.0.43.5 :
* fixed the applet init at case without available audio devices;
* some fixes && improvements;

v.0.50.0 :
* fixed changing a color of horizontal slider's handler;
* refactoring;
* added slider's size Settings;
* added displaying a changes of slider's color & size into Settings;

v.0.51.0 :
* added sensitivity for sliders;

v.0.51.1 :
* reimplemented the retrieve of restored volume parameters;
* some fixes for disconnect SLOTs at close;

v.0.51.2 :
* added the restriction of notification;
* reimplemented tooltip;

C

F1ash

9 years ago

Hi, you can update plasmoid ;)
Tested on Fedora14, Kubuntu10.10

Report

C

F1ash

9 years ago

I need the output of plasmoidviewer to the console.
Crash usually occur from a premature call to the tracking thread, although the script does not suggest such a possibility.

Report

madegirah

9 years ago

Было бы круто добавить в плазмоид управление громкостью звука при помощи поворота колёсика мыши при наведении курсора на пламоид на панели, как это сделано в дефолтном kmix

Report

C

F1ash

9 years ago

В Панели Настроек плазмоида выбираются отображаемые в панели устройства , и они управляются колесом мыши.
-----------
This is done already.

Report

bartman2589

9 years ago

Any answers on what I posted about this plasmoid not working on Kubuntu?

Report

C

F1ash

9 years ago

For bartman2589 :
Answer below not for you. I thought about your questions.

Report

bartman2589

9 years ago

I know it wasn't for me, but the 'add comment screen' (the one I'm typing this from right now) clearly says near the bottom that "All text must be in English." right below where it has a checkbox for 'Notify me via email of responses to this message.'. There's a reason for that. It's so that on this clearly english speaking site that everyone who visits the site is able to follow along with the comments. The person I pointed this out to needs to be aware of this since they completely ignored it. It doesn't help other people who come here seeking answers if they can't read the comments in the same language as the rest of the site. If they need help in their language they should go to a site in their language or use a translator, for example I don't go to japanese sites and post in english because I know that not everyone there would be able to read my post, it's part of what's called 'Netiquette' or 'Internet Etiquette', just like when you visit a foreign country it's expected that you make an effort to speak in the native language of that country out of respect for that country.

Report

bartman2589

9 years ago

I'm guessing you missed the part below the emote icons that says "All text must be in English."

Report

bartman2589

9 years ago

I was hoping to use this plasmoid to be able to easily access the volume sliders on a couple different channels of my onboard sound since the 'Master' channel doesn't work properly on my system (doesn't do anything actually), and the PCM slider only seems to affect digital input (like from playing a .wav or .mp3 file or watching a video) it doesn't have any effect on the volume of the other channels (as one might reasonably expect), as a result when I turn down the volume of things using my keyboard volume controls things like my CD channel (to which I have my tv tuner card connected) are unaffected and continue to play at whatever volume was previously set.

However I am having a few problems using this plasmoid:

1. when I click on the plasmoid and the window opens with the sliders for the volume controls I can't see any text at all except what's on the mute buttons and the rescan button. I can see the sliders and the scrollbar but no text at all other than what I mentioned.

2. when I open the settings page I don't see any text at all, just various icons.

3. when I try to close the plasmoid (when it's running on my taskbar) it crashes my plasma desktop. Only thing that still responds is the mouse/keyboard and my dropdown terminal (I use Tilda (a gnome app) because I like the fact that it can be set to 100% width, unlike yakuake).

I'm using the Oxygen theme that comes with Kubuntu/KDE 4.5.5 from the Kubuntu Updates PPA (black plasmoid backgrounds with a glossy look to them).

here is the output I get when I run it using plasmoidviewer:

Bus::open: Can not get ibus-daemon's address.
IBusInputContext::createInputContext: no connection to ibus-daemon
plasmoidviewer(2492)/kdecore (services) KServiceFactory::findServiceByDesktopPath: "" not found
plasmoidviewer(2492)/libplasma Plasma::FrameSvg::resizeFrame: Invalid size QSizeF(0, 0)
plasmoidviewer(2492)/libplasma Plasma::FrameSvg::resizeFrame: Invalid size QSizeF(0, 0)

I would appreciate any help you can provide in getting this plasmoid working.

Thank you,
bartman2589

Report

bartman2589

9 years ago

One minor correction, when I say I don't see any text on the setup screen for the plasmoid I meant to say I don't see any on the Colors page of it, only the buttons that open up the color choosers, no text at all to tell me what each button is used to choose the color for.

Report

C

F1ash

9 years ago

"answer below" == "answer above"

One minor correction, when I say I don't see any text on the setup screen for the plasmoid I meant to say I don't see any on the Colors page of it, only the buttons that open up the color choosers, no text at all to tell me what each button is used to choose the color for.
----
default Settings of colour is black and opacity. Therefore you do not see them. Set it manual.

Report

bartman2589

9 years ago

Ok, but why don't you make it so that the text in the color settings panels show up in black like all the other text in the settings panel so that people can know what each color button is for. You could even use a small box to display a sample of the color currently selected for that item that way people aren't just presented with a screen with color buttons, they might actually be able to know what each color picker button is for before they choose a color instead of having to guess. Also, I tried setting all of them to white in the hopes that it would make a difference but on my system it didn't even apply the color changes to the plasmoid, only to the text on the color settings tab that I previously was unable to see, and just like with when I tried to remove the plasmoid from my taskbar when I try to close the settings window my entire desktop freezes, I have to restart my computer in order to get things working again. It doesn't do me any good to change the colors unless this problem is fixed so that my desktop doesn't lockup. Any ideas? I've already done everything you've told everyone above to do in terms of installing certain packages.

Report

C

F1ash

9 years ago

I made correction. Try new version, please.

Report

C

F1ash

9 years ago

About freez after Settings close :
at this point is expected to stop the thread of tracking the changing status of audiodevices. Just one of your previous posts to me, it is clear that stopping the thread does not occur. I'm sure know how to do this.

For quick correction : uncomment line 161 in
def stopWaitingVolumeChange(self) in file
~/.kde/share/apps/plasma/plasmoids/plasmaVolume/contents/code/main.py

I'll correct it in the next version.

Report

C

F1ash

9 years ago

For example :
http://img.flashtux.org/img132dbe31e2e0x9f249c0d.png

Color settings should look like.
So I think that you have occurred incorrect installation of the plasmoid.
I set up a plasmoid in a standard way:
Panel Tool Box -- Add Widgets -- Get New Widgets -- (Download... or Instal...).
Manual installation is successful too.

https://github.com/F1ash/plasmaVolume
This link is to validate the contents of the zip.

About default colors: I'll try to fix it quickly.

Report

C

F1ash

9 years ago

"answer below" == "answer above"

One minor correction, when I say I don't see any text on the setup screen for the plasmoid I meant to say I don't see any on the Colors page of it, only the buttons that open up the color choosers, no text at all to tell me what each button is used to choose the color for.
----
default Settings of colour is black and opacity. Therefore you do not see them. Set it manual.

Report

C

F1ash

9 years ago

One minor correction, when I say I don't see any text on the setup screen for the plasmoid I meant to say I don't see any on the Colors page of it, only the buttons that open up the color choosers, no text at all to tell me what each button is used to choose the color for.
----
default Settings of colour is black and opacity. Therefore you do not see them. Set it manual.

Report

bartman2589

9 years ago

also I wanted to tell you there appears to be an error in the way it's packaged, when I use the install instruction provided (after I rename the zip file to match the instructions), I get an error message basically saying that the metadata.desktop file is not present. I was able to work around this by repackaging it by extracting everything to a folder and then adding the contents of the folder (not the folder itself) to a new zip file.

Report

tittiatcoke

9 years ago

Hi,

I really would like to use your applet, but I can't seem to get it working.

When adding the plasmoid, I get the following error :


Traceback (most recent call last):
File "/usr/share/kde4/apps/plasma_scriptengine_python/pyappletscript.py", line 75, in init
self.pyapplet.init()
File "/home/hq000006/.kde4/share/apps/plasma/plasmoids/plasmaVolume/contents/code/main.py", line 130, in init
self.initContent()
File "/home/hq000006/.kde4/share/apps/plasma/plasmoids/plasmaVolume/contents/code/main.py", line 194, in initContent
for audioDevice in alsaaudio.mixers(card) :
alsaaudio.ALSAAudioError: No such file or directory

I have python-alsaaudio installed, but am running openSUSE. Do you know what I am missing in this case ?

Thanks

Great work !!

Report

C

F1ash

9 years ago

You can try execute manually in console :
$ python
....
>>> import alsaaudio
>>> alsaaudio.cards()
For example:
[u'Intel', u'psci', ...]

if list is empty then python-alsaaudio not detected your audiodevice.

Report

tittiatcoke

9 years ago

The output is


hq000006@HQVMT4XX20:~> python
Python 2.7 (r27:82500, Aug 07 2010, 16:54:59) [GCC] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import alsaaudio
>>> alsaaudio.cards()
[u'Intel', u'ThinkPadEC']
>>>


So I guess that my soundcard is recognized. Anything else I can try ?

thanks for your help.

Report

C

F1ash

9 years ago

I made cardindex detection by another method. Please, try to install now.

Report

tittiatcoke

9 years ago

Sorry for not coming back to you earlier, but the change indeed worked. The plasmoid is now detecting the device and I can control the volume.

Somehow I do not see any text on the plasmoid, but this could be caused by my plasma desktop theme.

Thanks for solving the issue.

Report

C

F1ash

9 years ago

Execute, please:
>>> for i in xrange(100) :
... try :
... print alsaaudio.mixers(i)
... except alsaaudio.ALSAAudioError :
... print i, ' error'
... continue


script : http://fpaste.org/fLrP/

may be error in detecting cardindex
I must sure in it...

Report

C

F1ash

9 years ago

You can try execute manually in console :
$ python
....
>>> import alsaaudio
>>> alsaaudio.cards()
For example:
[u'Intel', u'psci', ...]

if list is empty then python-alsaaudio not detected your audiodevice.

Report

6 years ago

v.0.25
* fixed audiodevice detecting error;
* added detecting multiple audiodevices in system;
* added color managment of font and panel sliders with support opacity;
* added device rescan without restart plasmoid;
* added plasmatooltip with representation
device volume in panel;

v.0.27
* added Rescan button to Panel Devices Settings;
* added color control for slider handlers;

v.0.28
* fixed cardindex detection;

v.0.30
* improved stop control of tracking thread;
* added detect system color of text for first start;

v.0.35
* changed method of thread complete;

v.036
* text is replaced by icons in Common Device Panel;

v.0.37
* fixed warning in import module errors;

v.0.41.2 :
* added restore of device volume;
* added retrieve restored volume parameters;
* fixed slider`s mouseRelease & doubleClick events for common events;
* fixed the freez at plasmoid's init;
* some fixes & improvements;

v.0.42.2 :
* some fixes & improvements;

v.0.42.3 :
* fixed initiate;
* improve initiate;

v.0.43.5 :
* fixed the applet init at case without available audio devices;
* some fixes && improvements;

v.0.50.0 :
* fixed changing a color of horizontal slider's handler;
* refactoring;
* added slider's size Settings;
* added displaying a changes of slider's color & size into Settings;

v.0.51.0 :
* added sensitivity for sliders;

v.0.51.1 :
* reimplemented the retrieve of restored volume parameters;
* some fixes for disconnect SLOTs at close;

v.0.51.2 :
* added the restriction of notification;
* reimplemented tooltip;

12345678910
234
product-maker nick87720z_double Mar 30 2014 9 excellent
product-maker Henri Sep 19 2013 9 excellent
product-maker RAIDENSUB Apr 26 2013 9 excellent
product-maker unikum111 Dec 12 2012 9 excellent
product-maker Phrosztbyte Sep 07 2012 9 excellent
product-maker StrikeHoreges Dec 10 2011 9 excellent
product-maker Hanau2010 Sep 18 2011 9 excellent
product-maker tcat Aug 28 2011 9 excellent
product-maker tamra Aug 25 2011 9 excellent
product-maker lux0506 Aug 07 2011 9 excellent
product-maker kaiserhg Jul 26 2011 9 excellent
product-maker saigkill Jul 01 2011 9 excellent
product-maker JeremiahMosser Jun 01 2011 9 excellent
product-maker adrruiz May 30 2011 9 excellent
product-maker valek2282 May 26 2011 9 excellent
product-maker Zorael May 08 2011 9 excellent
product-maker elkooder Apr 29 2011 9 excellent
product-maker nicotine Apr 27 2011 9 excellent
product-maker hithirdwavedust Apr 20 2011 9 excellent
product-maker Infosoft Apr 04 2011 9 excellent
product-maker CatchTime Apr 03 2011 9 excellent
product-maker ZLv Mar 18 2011 9 excellent
product-maker nerdykid Mar 04 2011 9 excellent
product-maker dagobert Mar 03 2011 3 bad
product-maker swiftscythe Mar 03 2011 9 excellent
product-maker pierigno Mar 02 2011 9 excellent
product-maker tils Mar 01 2011 9 excellent
product-maker theZest Feb 28 2011 9 excellent
product-maker kem Feb 26 2011 9 excellent
product-maker marcocingolani Feb 25 2011 3 bad
product-maker ashley194 Feb 24 2011 9 excellent
product-maker darkmas Feb 23 2011 9 excellent
product-maker SeaJey Feb 21 2011 9 excellent
product-maker Murz Feb 20 2011 9 excellent
product-maker schleby Feb 20 2011 9 excellent
product-maker Alesvol Feb 20 2011 9 excellent
Be the first to comment
david96
Sep 15 2013
elkooder
Apr 29 2011
kent57
Mar 10 2011
madegirah
Mar 06 2011
Murz
Feb 20 2011
max99
Feb 20 2011
File (click to download) Version Description Downloads Date Filesize DL OCS-Install MD5SUM
*Needs pling-store or ocs-url to install things
Pling
0 Affiliates
Details
license
version
0.51.2
updated Apr 01 2014
added Feb 20 2011
downloads 24h
0
mediaviews 24h 0
pageviews 24h 1