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

Thread: Issue between Teensy Audio board and Samsung galaxy A70

  1. #1
    Junior Member
    Join Date
    Jan 2019
    Posts
    14

    Issue between Teensy Audio board and Samsung galaxy A70

    Hi guys,

    I am developing a small project where I need to send some DC signals to an android/Iphone device in order to clasify them later.
    In the most part of Android and Iphone devices, I am able to see those signals as you can check below:

    (The program that I am usingin Android to see the signals is "Wave Editor"

    Click image for larger version. 

Name:	Screenshot_2019-08-27-17-34-20-683_io.sbaud.wavstudio.jpg 
Views:	7 
Size:	46.0 KB 
ID:	17335

    and here an audacity screenshot where you can check them also:

    Click image for larger version. 

Name:	audacity.JPG 
Views:	4 
Size:	53.6 KB 
ID:	17336

    The problem that I am facing is, in the Samsung galaxy A70, I am getting the following signals:

    Click image for larger version. 

Name:	Screenshot_20190827-223144_WaveEditor.jpg 
Views:	5 
Size:	35.9 KB 
ID:	17337

    As you can see, I only see some pikes. I have tried to modify the amplitude, duration... but nothing worked. Does anyone know what could be happening?

    Below I attach you the code that I am using if it is useful.

    Thanks!

    Code:
    #include <Audio.h>
    #include <Wire.h>
    #include <SPI.h>
    #include <SD.h>
    #include <SerialFlash.h>
    
    // GUItool: begin automatically generated code
    AudioInputI2S            i2s1;           //xy=200,69
    AudioOutputUSB           usb1;           //xy=365,94
    AudioAmplifier           amp2;
    AudioSynthWaveformDc     dc1;
    AudioMixer4              mixer1;
    AudioControlSGTL5000     sgtl5000_1;     //xy=302,184
    AudioConnection          patchCord1(dc1, amp2);
    AudioConnection          patchCord2(amp2, 0, mixer1, 1);
    AudioConnection          patchCord3(mixer1, 0, usb1, 0);
    // GUItool: end automatically generated code
    
    
    const int myInput = AUDIO_INPUT_LINEIN;
    void setup() {
    
      AudioMemory(100);
    
      // Enable the audio shield, select input, and enable output
      sgtl5000_1.enable();
      sgtl5000_1.inputSelect(myInput);
      sgtl5000_1.volume(1.0);
     
    }
    
    void loop()
    {
      amp2.gain(0.5);
      dc1.amplitude(0.10);
      delay(500);
    
      amp2.gain(0.5);
      dc1.amplitude(0.15);
      delay(500);
      
      amp2.gain(0.5);
      dc1.amplitude(0.20);
      delay(500);
    }

  2. #2
    Senior Member
    Join Date
    Nov 2017
    Location
    Belgium
    Posts
    105
    If you want to output dc from the audioshield, you need to bypass(short) the output capacitors of the line outputs. They act as a high pass filter.

  3. #3
    Junior Member
    Join Date
    Jan 2019
    Posts
    14
    Hi! thanks for your reply. Maybe I didn't understand you well but I think that I am actually getting the DC as output without doing the bypass to those capacitors (correct me if I am wrong)

  4. #4
    Senior Member
    Join Date
    Nov 2017
    Location
    Belgium
    Posts
    105
    I just noticed that you are using AudioOutputUSB. You mentioned nothing about usb. Please be more specific about your setup. What Teensy? How is it wired to the A70 and other devices? The more specific your are the less we have to guess.
    What happens if you replace delay(500) with delay(5).

Posting Permissions

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