Page 4 of 8 FirstFirst ... 23456 ... LastLast
Results 31 to 40 of 76

Thread: Stream audio from iPod touch/iPhone over bluetooth to computer

  1. #31
    Join Date
    Jun 2009
    Location
    USA
    Beans
    47
    Distro
    Ubuntu 10.04 Lucid Lynx

    Re: Stream audio from iPod touch/iPhone over bluetooth to computer

    Quote Originally Posted by TheKent View Post
    Hello. I have an iPod that I am trying to stream from, but I'm stuck at Ric123's number 6a. I can't find my iPod in 'list-sources'.
    There's only 2 sources:

    0: device.description = "Monitor of Intern lyd Analog Stereo"
    1: device.description = "Intern lyd Analog Stereo"


    Managed to get the Audio-Sources in d-feet, and executed the 'connect ()', but still no luck in list-sources. Suggestions, anyone?
    Use
    Code:
    pactl list | grep bluez_source
    to see if you can find it when your iPod is connected.

    How could you have missed this?
    http://ubuntuforums.org/showpost.php...2&postcount=25

  2. #32
    Join Date
    Jul 2010
    Beans
    2

    Re: Stream audio from iPod touch/iPhone over bluetooth to computer

    Even I had the same problem with my iPod touch, but I got it fixed now. Thank you for your help. The steps which you have mentioned are so simple, it does not take much time also. It can be done without any issues. Now I am able to connect my iPod touch over Bluetooth and have the audio playing.

  3. #33
    Join Date
    Dec 2007
    Beans
    15

    Re: Stream audio from iPod touch/iPhone over bluetooth to computer

    Quote Originally Posted by Ric123 View Post
    It works! Thanks everyone! jackflap's link worked perfectly! http://jprvita.wordpress.com/2009/12...4-a2dp-stream/
    I've upgraded to Ubuntu 10.04 by now; I have bluez 4.60 and pulseaudio 0.9.21.
    Here's how I did it for my iPod touch (3.1.3) on my Dell Inspiron 1720:
    1. I skipped step one, it was already loaded.
    2. Add "Enable=Source" right under "#Disable=Control,Source" in the "[General]" section.
    3. Restart the computer (to restart all the bluetooth 'stuff')
    4. Pair the iPod touch and the computer by clicking the bluetooth icon -> Set up new device -> Forward. Click PIN options and select '1234', Close. Enable bluetooth on the iPod; on the computer select it in the list, Forward. Type the PIN (1234) on the iPod, Connect.
    5. Install d-feet (from Synaptic) and run it (Applications -> Programming -> D-Feet). Then File -> Connect to System Bus. Under Bus Name select org.bluez and a tree will appear on the right. Under Object Paths, expand the /org/bluez/1464/hci0/dev's until you find the one with Interfaces that have org.bluez.AudioSource. Expand the AudioSource and double-click on Methods -> Connect(). A dialog will appear; just click Execute. It should say 'This method did not return anything' (I had to do it twice the first time.)
    6. Open a terminal (Accessories -> Terminal) and type pacmd and press enter.
    6a. Then type list-sources and press enter. Find the one with device.description = "Name of your iPod" then scroll up to where it says 'name: ' (under 'index: ') and copy the name somewhere without the < and >(mine was bluez_source.00_...)
    6b. Then type list-sinks and press enter. I only had one (ALSA) and copy the name just as before (mine was alsa.output.pci-000_00...)
    6c. Type exit and press enter.
    7. Now type 'pactl load-module module-loopback source=YOURSOURCE sink=YOURSINK' (for me, it was pactl load-module module-loopback source=bluez_source.00_... sink=alsa.output.pci-000_00...) and press enter! Viola! Now the iPod should play through the computer as if it were a headset!

    Note: Save the number that returns after pactl. When you disconnect your iPod, type pactl unload-module YOURNUMBER and press enter (it changes everytime; for example: pactl unload-module 25)

    megamanexent, you have to connect AudioSource, not Audio.

    Tell me if it works with the iPhone 4


    Thaaaaaaanks ,,

    Its work with Nexus One

  4. #34
    Join Date
    Oct 2010
    Beans
    2

    Re: Stream audio from iPod touch/iPhone over bluetooth to computer

    I'm trying to stream audio from my iPhone 3GS iOS 4.01 to my linux computer via Bluetooth and A2DP.

    My setup:
    (ArchLinux)
    Linux CoreNAS 2.6.34-Custom-Core #10 SMP PREEMPT Thu Aug 5 15:13:53 CEST 2010 i686 Intel(R) Atom(TM) CPU D510 @ 1.66GHz GenuineIntel GNU/Linux

    Bluez 4.69

    pulseaudio 0.9.21

    The stream actually works, but every 1/2 seconds there is a glitch in the audio. Sometimes there are pitches in the audio. The audio is being streamed at 44.1Khz and my phone is in an acceptable range of the bluetooth enabled computer.

    Pulseaudio outputs about every 5 seconds:

    I: module-loopback.c: Should buffer 36012 bytes, buffered at minimum 92178 bytes
    I: module-loopback.c: Old rate 45022 Hz, new rate 45046 Hz
    I: module-loopback.c: Loopback overall latency is 63.33 ms + 352.51 ms + 39.51 ms = 455.35 ms

    I load the loopback module as follows:

    pactl load-module module-loopback source=bluez_source.00_26_B0_8D_6F_39 sink=alsa_output.usb-Native_Instruments_Audio_2_DJ_SN-v42x7kbg-00-Audio2DJ.analog-stereo rate=44100

    Does anybody have a clue or direction to solve this issue? Thanks in advance!

  5. #35
    Join Date
    Apr 2005
    Beans
    11

    Re: Stream audio from iPod touch/iPhone over bluetooth to computer

    Quote Originally Posted by megamanexent View Post
    For those of you who stumble on this thread and really would like a script to somewhat automate the process of connecting your A2DP device, I created such a script. It uses zenity to add a GUI element so you might have to install it from the repos if it is not installed. While doing that, make sure libqt4-dbus is installed to, but it should be there already.

    You still need to add your source and sink from pacmd with list-sources and list-sinks respectively to the script. I left a spot at the top of the script to add them. Leave no space between the '=' and what you type. You can type qdbus --system org.bluez into a terminal to find your device address. It should look like /org/bluez/XXXX/hci0/dev_XX_XX_XX_XX_XX_XX where XX are numbers or letters. You only need to type the dev_XX_XX_XX_XX_XX_XX in the script. Word of cation, this script creates a file in your home directory called .bluetooth_unload, if you have a file with that name, change the script to not overwrite your file. I tried to make the script as portable as possible, but there may be something I missed so use it with discretion!!!!

    Make sure the file is executable and your done. You can run the script from console, or add a launcher to your gnome menu to get the full GUI effect. Gnome-Do is also a good launcher too.
    You mention in your code that it works with 9.10. That is not my experience. The instructions (using qdbus) at the beginning of the code and the code that sets the 'device' variable will not work with ubuntu 9.10. This is because bluez doesn't support introspection in the version included with 9.10.

  6. #36
    Join Date
    Jun 2009
    Location
    USA
    Beans
    47
    Distro
    Ubuntu 10.04 Lucid Lynx

    Re: Stream audio from iPod touch/iPhone over bluetooth to computer

    Quote Originally Posted by hohlraum View Post
    You mention in your code that it works with 9.10. That is not my experience. The instructions (using qdbus) at the beginning of the code and the code that sets the 'device' variable will not work with ubuntu 9.10. This is because bluez doesn't support introspection in the version included with 9.10.
    hohlram- see post(s)
    http://ubuntuforums.org/showpost.php...3&postcount=10
    http://ubuntuforums.org/showpost.php...2&postcount=25

    In order to stream audio over bluetooth in Karmic, you have to upgrade the version of bluez from source (unless you find a .deb of the new version)( or use backports?). The new version will have the code for A2DP streaming.

    The problem you're seeing is that you need to have module-bluetooth-discover for pulseaudio installed and loaded. As http://jprvita.wordpress.com/2009/12...4-a2dp-stream/ states: "If it’s not loaded you can use pactl to load it manually or configure PulseAudio to load it on startup in /etc/pulse/default.pa" The script will not set up A2DP streaming entirely in Karmic, which I did mention. You still have to follow the instructions for the initial set-up, then my script will become useful.

  7. #37
    Join Date
    Apr 2005
    Beans
    11

    Re: Stream audio from iPod touch/iPhone over bluetooth to computer

    Quote Originally Posted by megamanexent View Post
    hohlram- see post(s)
    http://ubuntuforums.org/showpost.php...3&postcount=10
    http://ubuntuforums.org/showpost.php...2&postcount=25

    In order to stream audio over bluetooth in Karmic, you have to upgrade the version of bluez from source (unless you find a .deb of the new version)( or use backports?). The new version will have the code for A2DP streaming.

    The problem you're seeing is that you need to have module-bluetooth-discover for pulseaudio installed and loaded. As http://jprvita.wordpress.com/2009/12...4-a2dp-stream/ states: "If it’s not loaded you can use pactl to load it manually or configure PulseAudio to load it on startup in /etc/pulse/default.pa" The script will not set up A2DP streaming entirely in Karmic, which I did mention. You still have to follow the instructions for the initial set-up, then my script will become useful.
    I should have explained a bit better. Karmic and your instructions on the first page work just fine with all existing/available packages for Karmic (no upgrading required). Your script works fine as well if a few parts are modified to use dbus-send instead of qdbus.

  8. #38
    Join Date
    Apr 2005
    Beans
    11

    Re: Stream audio from iPod touch/iPhone over bluetooth to computer

    So now that everyone is awake has anyone figured out a way to control your phone/device from the computer? Normally you've got bt headphones (pause/play, skip forward/reverse, vol up/down) controlling (AVRCP profile) the device but since the computer "is/are" the head phones there must be a way to do it via dbus methods maybe? Didn't see anything obvious using d-peek
    Last edited by hohlraum; December 3rd, 2010 at 07:35 PM.

  9. #39
    Join Date
    Jun 2009
    Location
    USA
    Beans
    47
    Distro
    Ubuntu 10.04 Lucid Lynx

    Re: Stream audio from iPod touch/iPhone over bluetooth to computer

    hohlraum - Ahh! Now I understand, thank you! I'm not to confident in using dbus-send, but I will try to rewrite the script. Sorry about that, I should have personally tested the script on Karmic.


    Quote Originally Posted by hohlraum View Post
    So now that everyone is awake has anyone figured out a way to control your phone/device from the computer? Normally you've got bt headphones (pause/play, skip forward/reverse, vol up/down) controlling (AVRCP profile) the device but since the computer "is/are" the head phones there must be a way to do it via dbus methods maybe? Didn't see anything obvious using d-peek
    Using d-feet, I see some control methods under org.bluez.Headset. But I don't think that will help. For now I just use veency with vncviewer !!

    Maybe somebody will eventually write something to accomplish this. I would if I knew how.

  10. #40
    Join Date
    Apr 2005
    Beans
    11

    Re: Stream audio from iPod touch/iPhone over bluetooth to computer

    Actually, I'm dumb. There is no reason to use dbus-send (although it would remove the scripts dependancy on qdbus). Your method for retreiving the device path is really the only issue as it uses introspection which bluez under karmic doesn't support. I'll post the fix that doesn't use introspection (its just one extra command to get the bt adapter path).

Page 4 of 8 FirstFirst ... 23456 ... LastLast

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •