Audio Adapter Board not work?

Status
Not open for further replies.

tranha

Active member
Hi

I mounted the Teensy 3.2 on the Audio Board and tried to run the Hardware Test but I didn't hear any beeping and I also didn't see any thing on the Serial Monitor. I also tried to run the WavFilePlayer example as well but I still didn't see anything on the Monitor (totally blank).

Im pretty sure I mount the teensy properly. I don't know what happened :(

I am using Teensyduino 1.30. Since on the workshop video here https://www.pjrc.com/store/audio_tutorial_kit.html, Paul and Alysia used Teenyduino 1.26. Is it a problem ?

20161026_091244.jpg
 
Last edited:
What is your setup? Are you using the tutorial hardware, that has the buttons and the like? What do you have plugged into the headphone jack? I assume either a headphone or a speaker with amp... I assume you checked the obvious, like the speaker is working and volume not turned down to 0 and ...

You might try a slight mod to the Hardware_Test, which is to add something like:
Code:
    while (!Serial && (millis() < 5000)) ;
    Serial.begin(115200);
    delay(250):
    Serial.println("Start");
To give time for the Serial terminal to start, and then print a simple message to see if that comes through. Then if you don't see any outputs later like: Beep #1
You know that something is probably hanging.

Yesterday when I was playing with DAC0 and DAC1, I made a real simple version, that was modified from the above program
Which removed all of the buttons and the like, just to test hardware code. Something like:
Code:
// Advanced Microcontroller-based Audio Workshop
//
// http://www.pjrc.com/store/audio_tutorial_kit.html
// https://hackaday.io/project/8292-microcontroller-audio-workshop-had-supercon-2015
// 
// Part 1-2: Test Hardware
//
// Simple beeping is pre-loaded on the Teensy, so
// it will create sound and print info to the serial
// monitor when plugged into a PC.
//
// This program is supposed to be pre-loaded before
// the workshop, so Teensy+Audio will beep when
// plugged in.

#include <Audio.h>
#include <Wire.h>
#include <SD.h>
#include <SPI.h>
#include <SerialFlash.h>

AudioSynthWaveform    waveform1;
AudioOutputI2S        i2s1;
AudioConnection       patchCord1(waveform1, 0, i2s1, 0);
AudioConnection       patchCord2(waveform1, 0, i2s1, 1);
AudioControlSGTL5000  sgtl5000_1;
int count=1;
int a1history=0, a2history=0, a3history=0;

void setup() {
  AudioMemory(10);
  while (!Serial && (millis() < 5000)) ;
  Serial.begin(115200);
  delay(250);
  Serial.println("Begin");
  sgtl5000_1.enable();
  sgtl5000_1.volume(0.3);
  waveform1.begin(WAVEFORM_SINE);
  delay(1000);
}




void loop() {
  Serial.print("Beep #");
  Serial.println(count);
  count = count + 1;
  waveform1.frequency(440);
  waveform1.amplitude(0.9);
  wait(250);
  waveform1.amplitude(0);
  wait(1750);
}

void wait(unsigned int milliseconds)
{
  elapsedMillis msec=0;

  while (msec <= milliseconds) {
    ;
  }
}
Warning, this updated version was done on the fly, so could be issues. But it removed all other stuff like buttons and the like and simply did a beep every 2 seconds or something like that.
 
Oh nevermind, it's ok now but the Monitor only displays "Begin". It didn't display "Beep #" or something...
 
Simplest thing to try is to reboot your machine. Else look for something else open, like TYQT or some other window that is using COM9. Assuming Com9 is the comm port associated with your Teensy.
 
I would then suggest adding print statements, like one after the .enable statement, then one after the .volume command and maybe one after the .begin line, except that is probably redundant as only a pause left before it should get to the print in loop.

Also probably not going to gain you much more, but in cases like this I also add a flush...
That is I write a line like: Serial.println("After Enable"); Serial.flush();

Why, if the system is crashing or hard hanging, the flush will make sure the data is sent before that happens...

Other things to check is double check the soldering. Are all the pins soldered in and are there any solder bridges...

EDIT: Also I would always try with the most latest version of things.

Like Arduino 1.6.12 with Teensyduino 1.31.beta2 As no use debugging stuff that may have already been fixed... Also make sure that you don't have another version of the Audio library sitting around...
 
Last edited:
Great! It seems to work, I can see the Monitor displays "Beep#" now. But I plugged my headphone in the jack and I still didn't hear any beep even though the display keeps going
 
Try changing the volume line from .3 to something like .9 and see if that makes a difference...
 
hmm....it's still the same... I feel like the headphone is not connected to the Jack at all

At first, I thought it was my mistake when I de-soldered the jack and re-soldered it again. But I tried with the second brand new board and the problem still persists
 
Do you have a voltmeter handy? One simple check is the DC voltage on the headphone "virtual ground". When the headphone amp is active and working, you should see about 1.5V between the headphone ground and the actual ground on Teensy.
 
@tranha. In your first post, is that a photo of the completed project? If so, it doesn't look like you have soldered any of the Teensy pins to the audio board.

Pete
 
it seems the DMM didn't read anything. I attached a picture showing the 2 pins I measured in order to make sure Im doing this correctly.

20161026_115510.jpg
 
@tranha. In your first post, is that a photo of the completed project? If so, it doesn't look like you have soldered any of the Teensy pins to the audio board.

Pete

it's not a complete project but I want to test the Audio Board first. That's why I don't want to solder the Teensy yet, I just used the headers to mount the Teensy on the Audio Board temporarily
 
Oh yes you are right! Everything is perfect now

Thank you so much Paul and KurtE! I really do appreciate it
 
Status
Not open for further replies.
Back
Top