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

Thread: Teensy 3.6 SD card writing program

  1. #1
    Junior Member
    Join Date
    Jul 2019
    Posts
    7

    Teensy 3.6 SD card writing program

    I am using Teensy 3.6 connected to a custom radio receiver unit. I have a transmitter unit which is transmitting data. The program works fine when I am using the serial monitor. However, everything locks down when I am writing data to an SD card. The command SD.open is returning false every time I am using it. The SD card writing function works fine if I use it separately with another program. I am writing a string and have tested it int but nothing works. I am using the SD.h library. Is it a timing issue or a hardware issue? Please let me what you think. thanks!

  2. #2
    Senior Member
    Join Date
    Oct 2012
    Location
    Portland OR
    Posts
    652
    Does the radio also use SPI? Is there any chance of a SPI bus conflict between the custom radio receiver unit and the SD card?
    EDIT: nevermind, assuming you are using the built-in SD card socket on the T3.6 using 4-bit SDIO that is separate from the regular SPI bus.
    However, since the libraries date back to earlier Teensy models which generally used the regular 1-bit SPI port to connect to a SD card, there is still a chance of (for example) having the wrong pin select set in software.
    Last edited by JBeale; 08-20-2019 at 07:26 PM.

  3. #3
    Junior Member
    Join Date
    Jul 2019
    Posts
    7
    The pins are not physically shared between the SD card and the SPI lines. Can there still be conflicts?

  4. #4
    Senior Member
    Join Date
    Jul 2014
    Posts
    2,283
    If you don't show us the source code, we cannot tell.

  5. #5
    Senior Member+ defragster's Avatar
    Join Date
    Feb 2015
    Posts
    9,303
    What is powering the 'custom radio receiver unit'? Does the SD access fail when the Radio is not in use?

  6. #6
    Junior Member
    Join Date
    Jul 2019
    Posts
    7
    How do you think I can test that?

  7. #7
    Junior Member
    Join Date
    Jul 2019
    Posts
    7
    Do I have to check that in the library file?

Tags for this Thread

Posting Permissions

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