Forum Rule: Always post complete source code & details to reproduce any issue!
Page 4 of 4 FirstFirst ... 2 3 4
Results 76 to 81 of 81

Thread: Teensy 4.0 I2S Support

  1. #76
    On the pinout reference card, I had to make some compromises for the sake of simplicity and limited space. So the 5 data signals are labeled "IN1, OUT1A, OUT1B, OUT1C, OUT1D", which implies the mode of stereo input and 8 channel output. 1 of these 5 is on a bottom side pad, because again so many difficult trade offs were required in assigning the pinout.
    Shouldn't this be labeled as SAI1A, SAI1B, SAI1C, SAI1D, SAI1E, and SAI2IN SAI2OUT? For my project I'm going to be converting some of the outputs as inputs. The OUT1A, OUT1B, OUT1C, OUT1D can be either in or out. However, I'm pretty sure the SAI2 is fixed as an in/out combination (no option for switching them to out/out or in/in), unless I'm mistaken. I also know this is not necessarily supported in software yet.

    ===============

    I just completed a design of a board. I had some success with the breadboard, but loose wires are causing me pain. So i'm going to PCB now and I'm antsy to give it a go. I'll probably order the board later today. I have PCM5242, PCM1865, and ESP32WROOM all on one 4-layer board. There is also an expansion header for the SAI2 ports for future testing. Here is how I have it hooked up.

    PCM5242 (balanced/single ended output x2)
    - CLOCKS 1 (BCLK1, LRCLK1, MCLK1)
    - DATA OUT1A
    PCM1865 (balanced/single ended input x4, with mic pre)
    - CLOCKS 1
    - DATA1 = IN1 (CHANNELS 1 + 2 OF PCM1865)
    - DATA2 = OUT1D (PLANNED FOR INPUT AS OPPOSED TO OUTPUT, CHANNELS 3+4 OF PCM1865)
    ESP32 (A2DP input or output, not simultaneous)
    - CLOCKS 1
    - DATA FROM ESP32 TO T4 = OUT1C (WHEN SINK, RECEIVING BT-AUDIO IN, INPUT ON TEENSY)
    - DATA TO ESP32 FROM T4 = OUT1B (WHEN SOURCE, SENDING BT-AUDIO OUT)
    EXPANSION HEADER
    - CLOCKS 2 (BCLK2, LRCLK2, MCLK2)
    - DATA OUT = OUT2
    - DATA IN = IN2

    On the breadboard I've confirmed that the PCM5242 hooked to OUT1A, and the PCM1865 hooked to IN1 is working with the audio passthrough sketch. The rest is unconfirmed but like I said, the breadboard is causing issues. I'm hoping that when this board is built I'll get at the very minimum 2 channels output and 2 channels input working with stability. Then the other two input channels, and the ESP32 will be a project that will require software. Hopefully it's hooked up right at least.

    I included a footprint for a 100OHM resistor on both MCLK1 and MCLK2. I'm not sure if it's needed or not. It also seems that there might be a way to "adjust" the MCLK levels in software instead of the resistor?

    Once I finish staring at the layout and schematic a little longer I'll order the board and start putting it together for testing. I found a few errors this morning, after about a month or more of designing it (and years of research). I guess sometimes you just need to hit "print" and keep your fingers crossed. :-)

    Click image for larger version. 

Name:	Teensy4 - PCM5242 - PCM1865 - ESP32 - Front.jpg 
Views:	31 
Size:	128.5 KB 
ID:	18169

  2. #77
    I didn't ask anything specific but would love to hear your feedback on my digital audio mixer project details so far. Would a schematic help to get feedback? I haven't decided how far I want to share the full project yet, but I can be convinced. I might just share the schematic and not the PCB, I think Blackaddr did this with his guitar pedal.

    I can't find the thread where Paul hooked up a T4 to the CS42448 board. If anyone can link to it I would appreciate it. I thought we had a confirmation that it was working. I would like to review the pinouts with what I posted above to make sure I've at least chosen the right data lines for my project... Lines that will have the most likelyhood to work.

    I also plan on sending assembled samples to a few peope who have interest in helping with the software, paid or unpaid. The drivers for the chips I'm using will be open source. I'll also want to integrate with OSC protocol to control the mixer (open sound control). I do realize my project will be as much work in software as it has been in hardware. But I figure having a correctly designed PCB will make it easier to find the help - so that's where I'm at. :-)

    Any feedback on the board so far?

    Edit: that's right, the CS42448 is using TDM and my design opted for non-TDM to utilize all the new SAI lines on the T4. That's why the T4 helped me more forward. I would have needed TDM for my project on the 3.6. The board I've designed can technically be stacked, to get two PCM5242 and two PCM1865's working on the same lines under different addresses with TDM.

  3. #78
    Senior Member Blackaddr's Avatar
    Join Date
    Mar 2017
    Location
    Canada
    Posts
    247
    You might want to create your own separate project thread for discussing your mixer design, it may get more views that way.

  4. #79
    Quote Originally Posted by Blackaddr View Post
    You might want to create your own separate project thread for discussing your mixer design, it may get more views that way.
    Ok, yes. Thanks for pointing that out. My original reply regarding the renaming of SAI ports was on topic but my project wasn't. I'll build one of these and then create a new post with my findings and questions.

  5. #80
    Junior Member
    Join Date
    Oct 2019
    Posts
    3
    I just put together my own version of the audio shield on a board, and I'm pretty sure that the rev D schematic that is posted here is incorrect. It lists pin 8 on teensy -> sgtl 5000 pin 26 and pin 7 on teensy -> sgtl 5000 pin 25. I found that I needed to flip those two lines to get audio out of the codec. Other than that everything seems to work hunky dory.

  6. #81
    Senior Member
    Join Date
    Dec 2015
    Location
    LA
    Posts
    143
    Quote Originally Posted by jbrodsky View Post
    I just put together my own version of the audio shield on a board, and I'm pretty sure that the rev D schematic that is posted here is incorrect. It lists pin 8 on teensy -> sgtl 5000 pin 26 and pin 7 on teensy -> sgtl 5000 pin 25. I found that I needed to flip those two lines to get audio out of the codec. Other than that everything seems to work hunky dory.
    I think your correct on that. The table above the schematic is correct.

Posting Permissions

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