Search results

  1. J

    T4.x: Using 2-bit or 4-bit SPI to drive display D/C pin

    As we know, The T4 SPI peripheral can only toggle one CS pin, and the CS pin selection is no longer in the transmit data FIFO. Being able to control multiple CS pins from the transmit FIFO was useful for driving SPI displays because the displays often have a Data/Command pin that needs to be...
  2. J

    Problem reading from SD card directly into PSRAM

    For 4.1, please use 7. 6 also works in my test but 7 is probably safer. I don't know if any change is needed for 3.6.
  3. J

    Problem reading from SD card directly into PSRAM

    I found the fix. Change #if defined(ARDUINO_TEENSY41) IOMUXC_SW_PAD_CTL_PAD_DSE(1) | to #if defined(ARDUINO_TEENSY41) IOMUXC_SW_PAD_CTL_PAD_DSE(6) | The SD -> PSRAM test case is passing reliably now. I will submit a pull request...
  4. J

    Problem reading from SD card directly into PSRAM

    With IOMUXC_SW_PAD_CTL_PAD_PUS(3), it takes longer to fail but still fails. edit: This may not be true. I may have just gotten lucky.
  5. J

    Problem reading from SD card directly into PSRAM

    I think this is the equivalent for T4.1 https://github.com/greiman/SdFat-beta/blob/master/src/SdCard/SdioTeensy.cpp#L308-L309 . IOMUXC_SW_PAD_CTL_PAD_PUS(1) means 47K ohm pullup. I can try IOMUXC_SW_PAD_CTL_PAD_PUS(3) for 22K ohm pullup.
  6. J

    Problem reading from SD card directly into PSRAM

    Same here. I tried with Arduino 1.8.13 and Teensyduino 1.54 beta5 and it didn't fix the problem.
  7. J

    Problem reading from SD card directly into PSRAM

    @Frank B: I haven't informed Bill Greimann. I didn't think it's the SdFat library's fault. I will try with the 1.54 beta see if the same thing happens there.
  8. J

    Problem reading from SD card directly into PSRAM

    I tried reflowing the solder and adding more solder to make sure the connection is good but it didn't fix the problem. I will try the 1.54 beta. Thanks. I used a file around 100MB.
  9. J

    Problem reading from SD card directly into PSRAM

    Hi, I'm having trouble reading directly from the SD card into PSRAM. I'm using a Teensy 4.1 with one 8MB PSRAM chip. When I pass a pointer in PSRAM to the FsFile read function, the read would often fail. The same read succeeds reliably when I pass a pointer in the internal RAM. The T4.1 is not...
  10. J

    Opus codec library

    If you don't need to deal with files then it's actually simpler. Most of the code I wrote for opus has to do with ogg files. You just need to call the libopus encode/decode function to turn PCM samples into opus frames and back.
  11. J

    Opus codec library

    I got the low-mem ogg reader done and cleaned up the libopus build. I also enabled the assembly optimizations but it didn't make a noticeable difference. The code size is about 100k and the memory usage is about 50k. A teensy 3.5/3.6/4 will be required because of the memory usage. Low bitrate...
  12. J

    Opus codec library

    I looked into the memory usage more. I think a lot of it comes from the ogg demuxer. If I call the underlying opus_decoder_create, it only allocates 28k of memory. The problem is this: The ogg format consists of pages, which can be up to 64kB. Each frame can contain multiple packets (a packet...
  13. J

    Opus codec library

    I deleted all the files that look like they're for the encoder to get something building sooner. The opus decoder doesn't have a sample rate converter. The opusfile docs recommend the speex resampler. I plan to just change the I2S registers to make the output run at 48kHz.
  14. J

    Opus codec library

    I got the opus decoder to build in the Arduino IDE with a lot of include path hacks and file moves. What I can say is this: First, it's hard to build. To decode opus, you need libogg, libopus and libopusfile. All three of them use autoconf but without the ability to add compiler flags to define...
Back
Top