T_4.1 + audio shield -> BT speaker?

RenMan

Member
Good morning, everyone!

I'm working on an elaborate prop for my yard for Halloween and I'm wanting to use the Teensy 4.1 w/ the audio shield to control/play the music. My question is about sending that mixed signal from the audio shield to my BT speakers. I'm almost entirely ignorant of the details of BT radio and the I2S interface, so my question for more knowledgeable people is this: can I purchase a USB host cable and an approved BT dongle (per the "T3.6 USB Host - Bluetooth" thread) and expect to connect with my DIY BT speakers (which use this amp/BT board)?

For example, is the output of the audio shield hardwired to the DAC and to the 1/8" output jack or can it be routed elsewhere? There's just so much I don't know.
 
With the audio shield there are 2 different outputs:

  • The 3.5mm audio connector meant for headphones
  • The 3 pins for line out

So if your bluetooth connection plugs into a headphone jack, you would plug it into the 3.5mm jack which has 3 connections (TRS). Here is a site I found via a google search:

If your bluetooth connection has wires, you typically would connect these wires to the audio board. In general, the bluetooth should say 'line out' and not 'headphone' for this connection. If you look on the back side of the audio adapter, there is a set of 5 pins inside the box labeled line out.

Code:
    G         G
    L    G    R

The row with 3 pins is labeled L (for left), G (for ground), and R (for right). Above the row are 2 unlabeled pins and the middle pin being missing. These are alternate ground pins.

So if your device has 4 pins (left, left ground, right, right ground), you would connect the L to the left pin, the left ground pin to the pin above L, and similarly the right pin to R, and the right ground to the pin above the R.

If your device has 3 pins (left, ground, right), you would connect them to L, G, and R.

If your device needs power, you would hook the device's ground pin to one of the ground pins on the Teensy (either the pin next to pin 0 on the left side, the pin between the VIN and 3.3V pins on the right side, or the other two ground pins) and you would connect the device's power pin (sometimes labeled VCC, PWR, VIN, etc.) to either the 3.3v pin (3rd pin on the right side) or the VIN pin (1st pin on the left side). You would need to look at the device to see if it wants 5 volt power or 3.3 volt power.

It would have been nice if the audio shield had duplicated the VIN/ground/3.3v pins on the PCB as 3 more pins. It would have made powering self contained external boards slightly simpler to power. But since it doesn't, you might have to solder in power/ground wires when you are soldering pins to the audio shield (or use the alternate 3.3v/ground pins on the Teensy).

For normal speakers connected with a wire, you would typically need a stereo amplifier between the audio shield and the speakers (unless they include amplification).

Generally, when I do wired speakers for desktop use, I pick a set of speakers with the 3.5mm cable (with 3 pins) that are made to plug into phone headphone jacks, and they include the proper amplification.

If you post a link to the bluetooth device that you want to buy, I'm sure somebody can say what precise wiring will be needed. I haven't used bluetooth myself.
 
Last edited:
Thanks so much for the speedy reply, Michael!

I'm having a hard time parsing your response however. I've already built the BT speakers and I didn't opt to include an 1/8" jack for analog input, hence the need for BT. I normally connect to them wirelessly from my phone.

I was asking about using the USB host cable and probably this BT dongle. So right out of the gate I don't understand what you mean by "if your bluetooth connection plugs into a headphone jack". The pins you mention on the audio shield seem to carry the line level analog signal and I don't understand what that would have to do with the USB cable plus the dongle.

Pardon my obtuseness if there's something obvious that I'm missing, and thanks for helping!

Ed
 
Thanks so much for the speedy reply, Michael!

I'm having a hard time parsing your response however. I've already built the BT speakers and I didn't opt to include an 1/8" jack for analog input, hence the need for BT. I normally connect to them wirelessly from my phone.

I was asking about using the USB host cable and probably this BT dongle. So right out of the gate I don't understand what you mean by "if your bluetooth connection plugs into a headphone jack". The pins you mention on the audio shield seem to carry the line level analog signal and I don't understand what that would have to do with the USB cable plus the dongle.

Pardon my obtuseness if there's something obvious that I'm missing, and thanks for helping!

Ed

Sorry I thought you were talking about the audio adapter which can be mounted on top of or under the Teensy. I missed you mentioning USB host.

For the USB host stuff, you typically would use one of the 5 pin cables that were made for computers internally in the past to hook up USB 2.0 from the chassis to the computer motherboard.

On the Teensy 4.1, you would typically solder a 5 pin male header to the 5 internal pins (next to pins 2-6) on the Teensy 4.1, and then plug in the header cable to that.

You could also cut the header off of the cable, and directly solder the wires to the Teensy.

The way I do it when I want to use USB host is to solder a 5 pin female header to the Teensy and then use 5 long male/male pins in the header to mount the cable, because I prefer not to have male pins jutting out from the board (it prevents random short circuits if something lands on the board connecting a ground pin to the power pin).

The cable provides a standard USB 2.0 A female plug that you should be able to plug in any standard USB 2.0 A male cable.

In terms of what dongles work and such, somebody else would have to answer it, because I generally don't use the USB host stuff.
 
Ah, ok. The sanity check I was looking for was something like: "that can't work, the bluetooth dongle can only receive, not transmit audio information" or some such thing. I'm ignorant enough that I have no idea.

But at least it won't cost me much to buy these parts and see what happens. The interesting part for me will be a) trying to "send" the audio stream to the USB host and b) trying to make the dongle pair with my BT speakers. I can imagine either of those failing easily.
 
I'm wishing now that I had included a 1/8" jack on the speakers. You know, it might be easier to just open them up and modify them to include that! ;)
 
Back
Top