3

I am trying to reconfigure my "line in" as another "analog out" and use it alongside with the default analog out port.

I am using an onboard realtek sound card. It is very simple to do this in windows with driver gui but no way to do it in linux apparently.

Linux localhost 3.9.9-1-ARCH #1 SMP PREEMPT Wed Jul 3 22:45:16 CEST 2013 x86_64 GNU/Linux

  • 1
    You might want to provide more details here. For example, despite/other than the tags, you haven't told us anything about your software setup (version numbers, kernel, driver, audio-stack, ...). (Describe/name the driver GUI you use in Windows?) I won't have useful input anyway, but you could make it easier for someone who might. – hunter2 Jul 08 '13 at 09:38
  • Can't remember the program I do it in Windows but I believe there is only one, which is the official Realtek driver and suite. – Etherealone Jul 08 '13 at 17:14
  • I suggest you also add card's model number and driver. Use 'lspci' and 'lsmod' if you don't know. You have both ALSA and PulseAudio installed, right? (I assume from the tag ...) ...(Can't believe I'm still on SE ... sleepytime) – hunter2 Jul 08 '13 at 17:22

2 Answers2

0

Does what I described in this U&L Q&A titled: how to pipe audio output to mic input provide you with an adequate solution?

The original article that described this method is titled: Redirect Audio Out to Mic In (Linux).

General Steps

  1. Run the application pavucontrol.

  2. Go to the "Input Devices" tab, and select "Show: Monitors" from the bottom of the window. If your computer is currently playing audio, you should see a bar showing the volume of the output:

  3. Now start an application that can record audio such as audacity.

  4. Click the input device button ("ALSA Capture from") and pick "Monitor of Internal Audio Analog Stereo")

slm
  • 363,520
  • 117
  • 767
  • 871
  • The problem is not the port being muted. The port's job is 'line-out' by default. But I want to reconfigure it as analog output. I can do that in Windows via realtek driver (when I connect something, it pops up asking what I connected, I can plug headphones into mic port and make it work that way) – Etherealone Jul 08 '13 at 17:15
  • Wuh? "Line-in" != "line-out" ... (Re-read your question) – hunter2 Jul 08 '13 at 17:24
  • @Tolga - double check the interface, I thought you could reconfig. the line in/out there as well. – slm Jul 08 '13 at 20:24
  • @hunter2 that would be line-in. slm, I cannot find it. :( – Etherealone Jul 08 '13 at 20:37
  • @Tolga - does this new approach meet your needs? – slm Jul 09 '13 at 23:08
0

It is described here on AskUbuntu.

There are some problems with pygtk in the script (on Arch at least).

I solved it by running the main script with python2 and the other scripts it installs with python.

I managed to do it, but changes revert after rebooting. (Update: This can be worked around; see the bottom of this post.)

I did it via a GUI in python called HDA Analyzer that can be fetched and used from the ALSA website like the following:

wget -O run.py http://www.alsa-project.org/hda-analyzer.py

sudo python run.py (Their page doesn't say sudo, but if you don't do
it with sudo, it will download the scripts but fail to run them and
complain about privileges.)

Now this will make the GUI start, but its usage is not explained, and it's not exactly newbie-friendly. So to make life easier I'll explain how I did it. In my case, it was a matter of two clicks; the tricky part was locating exactly what needs to be clicked.

(Note: You may explore all the nodes one by one, but don't modify anything you don't understand. Any modification (e.g. ticking a checkbox) becomes effective immediately; there's no apply button.)

The list contains many nodes called Node[0x##] followed by any of AUD_OUT, AUD_IN, AUD_MIX, PIN and VENDOR. The only ones you have to look in are the PIN ones.

There are multiple types of PIN nodes; the type we want will fill the whole window with panels/control groups (It helps to stretch or maximize the window), as in this screenshot. (The site prevented me from inserting the image inline, sorry.)

Inside the Config Default field, some nodes will have in the first line Jack Connection: N/A; we need the ones that say Jack Connection: Jack as in the screenshot.

To change a Line-In to an output jack, look until you find the node that says Jack Type: Line In. (And notice the Jack Location2: Rear and Jack Color: Blue.)

Then, in the three checkboxes in the Widget Control group below, uncheck IN and check OUT.

Using the same way, you can assign any of the front or rear jacks to either input or output.

Now if you close the window, it will ask whether you want to revert changes. Saying yes reverts them immediately; saying no keeps them but only for this session.

If you want to keep your changes permanently, don't close HDA Analyzer yet. Instead, click "Exp" (Export) at the bottom-left and use Save As to write the python script to a file. Now copy that file to something like /etc/hda-mods.py and edit /etc/rc.local as root (e.g. using gksudo gedit /etc/rc.local) and append python /etc/hda-mods.py right before exit 0, then save it and reboot. Your changes should survive.