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

Thread: Teensy 3.6 SD Card Problems with external power

  1. #1
    Junior Member
    Join Date
    Jan 2021
    Posts
    6

    Teensy 3.6 SD Card Problems with external power

    Hello Folks,
    I run into some problems whenn using my Teensy 3.6 with external power.
    I'm trying to run a project with a GPS shield, IMU and pressure Sensor. All data shall be saved on a MicroSD Card on the built in card slot. Everything works fine when I power the Teensy over USB but when I try to power the microcontroller externally the controller is not able to open the SD card for writing and reading.
    As a power source I'm using two 1.5 Mono D cells with a 5V voltage step up regulator (Pololu U3V12F5).
    If I'm giving the setup power over the USB cable first and then pull on the external power and removing the USB cable it works too but I don't allways want to start the system over USB and then switching to external.

    After googling for a while I cannot find any suggestions for troubleshooting the explained problem.
    Has anyone of you any suggestions?

    thanks in advance
    Louis

    I will add a schematic of the project.Click image for larger version. 

Name:	Unbenannt.PNG 
Views:	43 
Size:	81.3 KB 
ID:	23484
    Last edited by RASTA_SUG; 01-28-2021 at 03:32 PM.

  2. #2
    Senior Member+ MichaelMeissner's Avatar
    Join Date
    Nov 2012
    Location
    Ayer Massachussetts
    Posts
    4,029
    Note in your schematic, you connect the ground wire from the power & converter to the AGND pin (between VIN and 3.3v on the right side if the USB connector is facing up). On the Teensy 3.2, 3.5, and 3.6 that pin is the analog ground pin, that has extra filtering for analog inputs. While often times you can use that pin as a ground, for digital inputs, etc. you should probably use one of the normal ground pins. There are several ground pins you can use:

    • The first pin on the left side (next to pin 0);
    • The pin on the right side between pin 13 and A22;
    • The middle pin in the row of pins in front of the micro-SD card; (and)
    • The two ground pins on the inner row of 5 pins below the DP/DM/5v pins.


    On the Teensy LC, 4.0, and 4.1 you could use that pin, since those boards do not have a separate analog ground.

    Without cutting the solder pad between VUSB and VIN, you should be careful to only have one power source (either USB or external).

  3. #3
    Junior Member
    Join Date
    Jan 2021
    Posts
    6
    Quote Originally Posted by MichaelMeissner View Post
    Note in your schematic, you connect the ground wire from the power & converter to the AGND pin (between VIN and 3.3v on the right side if the USB connector is facing up). On the Teensy 3.2, 3.5, and 3.6 that pin is the analog ground pin, that has extra filtering for analog inputs. While often times you can use that pin as a ground, for digital inputs, etc. you should probably use one of the normal ground pins. There are several ground pins you can use:

    • The first pin on the left side (next to pin 0);
    • The pin on the right side between pin 13 and A22;
    • The middle pin in the row of pins in front of the micro-SD card; (and)
    • The two ground pins on the inner row of 5 pins below the DP/DM/5v pins.


    On the Teensy LC, 4.0, and 4.1 you could use that pin, since those boards do not have a separate analog ground.

    Without cutting the solder pad between VUSB and VIN, you should be careful to only have one power source (either USB or external).
    Hello Michael,
    thanks for the advise! (:
    I've changed it but the problem still remains

  4. #4
    Junior Member
    Join Date
    Jan 2021
    Posts
    6
    Ok after various tries with different Teensys and SD-cards it turned out that the SD card was in some way corrupted. I tried another one and everything works perfect.
    But its still confusing to me bc the corrupt SD is working when the Teensy is powerd via USB or when its pluged in directly to PC
    Nevertheless I'll just change the SD to a new one and will have a close eye on the behaviour

    cheers
    Louis

  5. #5
    Senior Member
    Join Date
    Nov 2018
    Location
    Netherlands
    Posts
    154
    It looks like you have a CR2032 battery on the 3v3 circuit? It guess you actually want to have that on the Vbat pin.

    Or is this ment to be a big capacitor? I know upon writing on these sd cards they can draw a lot of current for a very short tome. It is nice to have like a 470uF capacitor over the 3V3/GND of the Teensy.

  6. #6
    Junior Member
    Join Date
    Jan 2021
    Posts
    6
    Yes I already saw this one too Iíve changed that to Vbat 🙈
    Would it be good to put a capacitor between the step up regulator and VIN?

  7. #7
    Junior Member
    Join Date
    Jan 2021
    Posts
    6
    And if the CR2032 would worked like a capacitor shouldnít that be aware of the current spikes?
    But as I said the system is working quite stable with another SD card.

    PS the only thing that gets my head off is the f****** GPS Module but I think thatís quite common

  8. #8
    Senior Member
    Join Date
    Nov 2018
    Location
    Netherlands
    Posts
    154
    These step-up modules generally are noisemakers.
    It is always a good idea to consider and extra capacitor. I do like to use RC filters so a few ohms resistor followed with a big capacitor, that will create a little voltage drop but gets rid of a lot of noise.

  9. #9
    Junior Member
    Join Date
    Jan 2021
    Posts
    6
    Ok thanks for the advice. Iíll definitely consider this in the next revision
    What values for resistor an cap would you suggest? Like 10 Ohm and 470 uF?

  10. #10
    Senior Member
    Join Date
    Nov 2018
    Location
    Netherlands
    Posts
    154
    These are nice values to start with.
    It kind off depends on the current drawn, and the space that is available.

    If too much voltage drops over the resistor lower the value and of possible increase the cap. If you have enough space to use 1000uF just use that. It won't hurt to use higher vales here. Use a low esr capacitor!

    This actually creates a low pass filter, not as sharp as an LC filter but helps a lot on your powersupply noise. The values are not that critical here.

Posting Permissions

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