Forum Rule: Always post complete source code & details to reproduce any issue!
Results 1 to 7 of 7

Thread: can't make audio work on my teensy 3.6+audio board

  1. #1
    Junior Member
    Join Date
    Dec 2017
    Posts
    9

    can't make audio work on my teensy 3.6+audio board

    Hello, I have recently baught a teensy 3.6 board and the audio board and i soldered pins to both boards. I set up all the buttons and potentiometers the teensy 3.6, and the way I have the two boards connected is that they are both placed on a breadboard, and i have wires to connect both boards.

    For connecting the two boards, I only placed wires according to where the audio pins are placed (pins 9, 11, 13, 18, 19, 22, and 23), therefore there is not a connection on every pin like there would be if the two boards were stacked on each other. I uploaded the code Part_1_02_hardware_test so that I could test if everything is working fine. The buttons work, the potentiometers work (although one of the pots are broken and give weird values when its not at 0 or vcc) so all that is left to test is the sound, but I don't get any output sound when connecting headphones. The headphones work when I plug them in the computer so i know that that is not the problem.

    I tried to attach some pictures to this post that show my setup, but when i try to attach the pictures i get an error saying that the attachment failed. If anyone knows why the audio is not working please let me know, I will appreciate your help.

    Thanks.
    Last edited by numero uno; 12-15-2017 at 05:25 AM.

  2. #2
    Senior Member+ Theremingenieur's Avatar
    Join Date
    Feb 2014
    Location
    Colmar, France
    Posts
    1,901
    Try to reduce the resolution of your pictures, attachments are limited in size.

    Without pictures and code (see forum rules on top if the page), nobody will be able to guess the cause of your problem. Just a simple question: While you thought of doing all the data connections between the Teensy and the Audio module on your breadboard, did you also think of the Audio board's power supply?

  3. #3
    Junior Member
    Join Date
    Dec 2017
    Posts
    9
    Yes I did connect the ground and vcc to the audio board. Thanks for the tip on resizing the images, here they are. The code that i uploaded is Part1_02_hardware_test from the examples in teensyduino. But i commented out all that has to do with the A2 input because I don't have a third potentiometer for now.
    Attached Thumbnails Attached Thumbnails Click image for larger version. 

Name:	20171214_223518.jpg 
Views:	33 
Size:	123.4 KB 
ID:	12289   Click image for larger version. 

Name:	20171214_223455.jpg 
Views:	26 
Size:	119.8 KB 
ID:	12290  


  4. #4
    Senior Member+ Theremingenieur's Avatar
    Join Date
    Feb 2014
    Location
    Colmar, France
    Posts
    1,901
    I’d not try to test everything together from the beginning because it can be complicated to find the cause if there were multiple issues.
    At first, I’d create a test sketch to play only a let’s say 400Hz sine wave through both audio outputs of the SGTL5000.
    In a second step, I’d write a sketch to only read the buttons and potentiometers and to output the result on the serial monitor.
    Then, after everything works separately, I’d try to combine everything.

  5. #5
    Junior Member
    Join Date
    Dec 2017
    Posts
    9
    Okay, I've made a sketch that only tests the sound. Here it is:
    Code:
    #include <Audio.h>
    
    AudioSynthWaveform    waveform1;
    AudioOutputI2S        i2s1;
    AudioConnection       patchCord1(waveform1, 0, i2s1, 0);
    AudioConnection       patchCord2(waveform1, 0, i2s1, 1);
    AudioControlSGTL5000  sgtl5000_1;
    
    void setup() {
      AudioMemory(10);
      sgtl5000_1.enable();
      sgtl5000_1.volume(0.3);
      waveform1.begin(WAVEFORM_SINE);
      waveform1.frequency(440);
      waveform1.amplitude(0.9);
    }
    
    void loop() {}
    it still doesn't make sound though... do i need to solder a potentiometer on the audio board to control the volume?

  6. #6
    Senior Member PaulStoffregen's Avatar
    Join Date
    Nov 2012
    Posts
    18,355
    You've got the audio shield oriented backwards. Just rotate it 180 degrees.

    Click image for larger version. 

Name:	audio.jpg 
Views:	44 
Size:	22.4 KB 
ID:	12298

    EDIT: oh, or maybe this wiring takes that into account? The photo is a bit too blurry to see where all the same-color wires really go...

  7. #7
    Junior Member
    Join Date
    Dec 2017
    Posts
    9
    thank you Paul, the board was indeed backwards!

Posting Permissions

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