[alsa-devel] HDA Analyzer
Hi HDA developers,
I am trying to write a small tool for control and analyze HDA codecs (something like more powerful GUI brother for Takashi's hda-verb). For rapid development, I chose python and pygtk2 gtk bindings. At this time, only basic things are implemented and not all widget types are supported in detail, but routing and volume control is implemented. If you are interested to check this preview and send me ideas to make this tool better, the code is available at URL bellow (or in alsa.git repo - see www.alsa-project.org).
http://git.alsa-project.org/?p=alsa.git;a=tree;f=hda-analyzer
Planned features:
- support all widget types in detail - allow assign custom names to nodes for better orientation - raw verb r/w ops - save a text output of codec configuration for driver developers (maybe some diff) - run aplay or speaker-test directly from GUI - run arecord directly from GUI with some simple scope to analyze input - sysfs support for actual HDA driver
Jaroslav
----- Jaroslav Kysela perex@perex.cz Linux Kernel Sound Maintainer ALSA Project, Red Hat, Inc.
At Fri, 28 Nov 2008 11:29:27 +0100 (CET), Jaroslav Kysela wrote:
Hi HDA developers,
I am trying to write a small tool for control and analyze HDA codecs (something like more powerful GUI brother for Takashi's hda-verb). For rapid development, I chose python and pygtk2 gtk bindings. At this time, only basic things are implemented and not all widget types are supported in detail, but routing and volume control is implemented. If you are interested to check this preview and send me ideas to make this tool better, the code is available at URL bellow (or in alsa.git repo - see www.alsa-project.org).
http://git.alsa-project.org/?p=alsa.git;a=tree;f=hda-analyzer
This looks good. Thanks for your work!
I got some errors when clicking some widgets:
Traceback (most recent call last): File "./hda_analyzer.py", line 96, in selection_changed_cb self.load(c, node) File "./hda_analyzer.py", line 119, in load self.__build_node(n) File "./hda_analyzer.py", line 464, in __build_node hbox.pack_start(self.__build_connection_list(node)) File "./hda_analyzer.py", line 253, in __build_connection_list for i in node.connections: TypeError: 'NoneType' object is not iterable Traceback (most recent call last): File "./hda_analyzer.py", line 96, in selection_changed_cb self.load(c, node) File "./hda_analyzer.py", line 119, in load self.__build_node(n) File "./hda_analyzer.py", line 466, in __build_node vbox.pack_start(self.__build_amps(node), False, False) File "./hda_analyzer.py", line 343, in __build_amps node.out_amp and node.amp_vals_out or None) File "./hda_analyzer.py", line 294, in build_caps str = 'Offset:\t\t\t%d\n' % caps.ofs TypeError: %d format: a number is required, not NoneType Traceback (most recent call last): File "./hda_analyzer.py", line 96, in selection_changed_cb self.load(c, node) File "./hda_analyzer.py", line 119, in load self.__build_node(n) File "./hda_analyzer.py", line 466, in __build_node vbox.pack_start(self.__build_amps(node), False, False) File "./hda_analyzer.py", line 343, in __build_amps node.out_amp and node.amp_vals_out or None) File "./hda_analyzer.py", line 294, in build_caps str = 'Offset:\t\t\t%d\n' % caps.ofs TypeError: %d format: a number is required, not NoneType Traceback (most recent call last): File "./hda_analyzer.py", line 96, in selection_changed_cb self.load(c, node) File "./hda_analyzer.py", line 119, in load self.__build_node(n) File "./hda_analyzer.py", line 466, in __build_node vbox.pack_start(self.__build_amps(node), False, False) File "./hda_analyzer.py", line 343, in __build_amps node.out_amp and node.amp_vals_out or None) File "./hda_analyzer.py", line 294, in build_caps str = 'Offset:\t\t\t%d\n' % caps.ofs TypeError: %d format: a number is required, not NoneType Traceback (most recent call last): File "./hda_analyzer.py", line 96, in selection_changed_cb self.load(c, node) File "./hda_analyzer.py", line 119, in load self.__build_node(n) File "./hda_analyzer.py", line 466, in __build_node vbox.pack_start(self.__build_amps(node), False, False) File "./hda_analyzer.py", line 343, in __build_amps node.out_amp and node.amp_vals_out or None) File "./hda_analyzer.py", line 294, in build_caps str = 'Offset:\t\t\t%d\n' % caps.ofs TypeError: %d format: a number is required, not NoneType Traceback (most recent call last): File "./hda_analyzer.py", line 96, in selection_changed_cb self.load(c, node) File "./hda_analyzer.py", line 119, in load self.__build_node(n) File "./hda_analyzer.py", line 466, in __build_node vbox.pack_start(self.__build_amps(node), False, False) File "./hda_analyzer.py", line 343, in __build_amps node.out_amp and node.amp_vals_out or None) File "./hda_analyzer.py", line 294, in build_caps str = 'Offset:\t\t\t%d\n' % caps.ofs TypeError: %d format: a number is required, not NoneType
Happend on widgets like
Node 0x21 [Volume Knob Widget] wcaps 0x600080: Mono Volume-Knob: delta=0, steps=32, direct=0, val=64 Unsolicited: tag=0x00, enabled=0 Connection: 0
and
Node 0x22 [Audio Mixer] wcaps 0x20010f: Stereo Amp-In Amp-Out Amp-In caps: ofs=0x00, nsteps=0x00, stepsize=0x00, mute=1 Amp-In vals: [0x00 0x00] [0x80 0x80] [0x00 0x00] [0x00 0x00] [0x00 0x00] [0x80 0x80] [0x80 0x80] [0x80 0x80] [0x80 0x80] Amp-Out caps: N/A Amp-Out vals: [0x00 0x00] Connection: 9 0x18 0x19 0x1a 0x1b 0x1c 0x1d 0x14 0x15 0x0b
Takashi
On Fri, 28 Nov 2008, Takashi Iwai wrote:
http://git.alsa-project.org/?p=alsa.git;a=tree;f=hda-analyzer
This looks good. Thanks for your work!
Thanks.
Happend on widgets like
Both errors should be fixed now.
and
Node 0x22 [Audio Mixer] wcaps 0x20010f: Stereo Amp-In Amp-Out Amp-In caps: ofs=0x00, nsteps=0x00, stepsize=0x00, mute=1 Amp-In vals: [0x00 0x00] [0x80 0x80] [0x00 0x00] [0x00 0x00] [0x00 0x00] [0x80 0x80] [0x80 0x80] [0x80 0x80] [0x80 0x80] Amp-Out caps: N/A Amp-Out vals: [0x00 0x00]
^^^^^^^^^^^
It looks wrong, but I'm not a big expert for HDA codecs. Are amp values available/writable when caps are N/A?
Jaroslav
----- Jaroslav Kysela perex@perex.cz Linux Kernel Sound Maintainer ALSA Project, Red Hat, Inc.
At Fri, 28 Nov 2008 16:58:51 +0100 (CET), Jaroslav Kysela wrote:
On Fri, 28 Nov 2008, Takashi Iwai wrote:
http://git.alsa-project.org/?p=alsa.git;a=tree;f=hda-analyzer
This looks good. Thanks for your work!
Thanks.
Happend on widgets like
Both errors should be fixed now.
and
Node 0x22 [Audio Mixer] wcaps 0x20010f: Stereo Amp-In Amp-Out Amp-In caps: ofs=0x00, nsteps=0x00, stepsize=0x00, mute=1 Amp-In vals: [0x00 0x00] [0x80 0x80] [0x00 0x00] [0x00 0x00] [0x00 0x00] [0x80 0x80] [0x80 0x80] [0x80 0x80] [0x80 0x80] Amp-Out caps: N/A Amp-Out vals: [0x00 0x00]
^^^^^^^^^^^
It looks wrong, but I'm not a big expert for HDA codecs. Are amp values available/writable when caps are N/A?
There is a global amp-cap definition.
Takashi
On Fri, 28 Nov 2008, Takashi Iwai wrote:
Node 0x22 [Audio Mixer] wcaps 0x20010f: Stereo Amp-In Amp-Out Amp-In caps: ofs=0x00, nsteps=0x00, stepsize=0x00, mute=1 Amp-In vals: [0x00 0x00] [0x80 0x80] [0x00 0x00] [0x00 0x00] [0x00 0x00] [0x80 0x80] [0x80 0x80] [0x80 0x80] [0x80 0x80] Amp-Out caps: N/A Amp-Out vals: [0x00 0x00]
^^^^^^^^^^^
It looks wrong, but I'm not a big expert for HDA codecs. Are amp values available/writable when caps are N/A?
There is a global amp-cap definition.
OK, so it would be better to show the global amp-cap definition in the GUI with a "copy" identification. Thanks.
Jaroslav
----- Jaroslav Kysela perex@perex.cz Linux Kernel Sound Maintainer ALSA Project, Red Hat, Inc.
At Fri, 28 Nov 2008 17:08:16 +0100 (CET), Jaroslav Kysela wrote:
On Fri, 28 Nov 2008, Takashi Iwai wrote:
Node 0x22 [Audio Mixer] wcaps 0x20010f: Stereo Amp-In Amp-Out Amp-In caps: ofs=0x00, nsteps=0x00, stepsize=0x00, mute=1 Amp-In vals: [0x00 0x00] [0x80 0x80] [0x00 0x00] [0x00 0x00] [0x00 0x00] [0x80 0x80] [0x80 0x80] [0x80 0x80] [0x80 0x80] Amp-Out caps: N/A Amp-Out vals: [0x00 0x00]
^^^^^^^^^^^
It looks wrong, but I'm not a big expert for HDA codecs. Are amp values available/writable when caps are N/A?
There is a global amp-cap definition.
OK, so it would be better to show the global amp-cap definition in the GUI with a "copy" identification. Thanks.
Not really. The amp-caps in each node show the capability overrides. If you copy the output, you don't know whether it's an override (although the same value) or a local one.
Takashi
On Fri, 28 Nov 2008, Takashi Iwai wrote:
At Fri, 28 Nov 2008 17:08:16 +0100 (CET), Jaroslav Kysela wrote:
On Fri, 28 Nov 2008, Takashi Iwai wrote:
Node 0x22 [Audio Mixer] wcaps 0x20010f: Stereo Amp-In Amp-Out Amp-In caps: ofs=0x00, nsteps=0x00, stepsize=0x00, mute=1 Amp-In vals: [0x00 0x00] [0x80 0x80] [0x00 0x00] [0x00 0x00] [0x00 0x00] [0x80 0x80] [0x80 0x80] [0x80 0x80] [0x80 0x80] Amp-Out caps: N/A Amp-Out vals: [0x00 0x00]
^^^^^^^^^^^
It looks wrong, but I'm not a big expert for HDA codecs. Are amp values available/writable when caps are N/A?
There is a global amp-cap definition.
OK, so it would be better to show the global amp-cap definition in the GUI with a "copy" identification. Thanks.
Not really. The amp-caps in each node show the capability overrides. If you copy the output, you don't know whether it's an override (although the same value) or a local one.
I put ' (Global)' suffix to the frame label when global caps are used in my local source tree. So it should be clear for users.
Jaroslav
----- Jaroslav Kysela perex@perex.cz Linux Kernel Sound Maintainer ALSA Project, Red Hat, Inc.
At Fri, 28 Nov 2008 17:32:05 +0100 (CET), Jaroslav Kysela wrote:
On Fri, 28 Nov 2008, Takashi Iwai wrote:
At Fri, 28 Nov 2008 17:08:16 +0100 (CET), Jaroslav Kysela wrote:
On Fri, 28 Nov 2008, Takashi Iwai wrote:
Node 0x22 [Audio Mixer] wcaps 0x20010f: Stereo Amp-In Amp-Out Amp-In caps: ofs=0x00, nsteps=0x00, stepsize=0x00, mute=1 Amp-In vals: [0x00 0x00] [0x80 0x80] [0x00 0x00] [0x00 0x00] [0x00 0x00] [0x80 0x80] [0x80 0x80] [0x80 0x80] [0x80 0x80] Amp-Out caps: N/A Amp-Out vals: [0x00 0x00]
^^^^^^^^^^^
It looks wrong, but I'm not a big expert for HDA codecs. Are amp values available/writable when caps are N/A?
There is a global amp-cap definition.
OK, so it would be better to show the global amp-cap definition in the GUI with a "copy" identification. Thanks.
Not really. The amp-caps in each node show the capability overrides. If you copy the output, you don't know whether it's an override (although the same value) or a local one.
I put ' (Global)' suffix to the frame label when global caps are used in my local source tree. So it should be clear for users.
OK, but please don't change the proc output.
Takashi
participants (2)
-
Jaroslav Kysela
-
Takashi Iwai