Welcome to the Pycom forum Forum
    • \[\[global:header.categories\]\]
    • \[\[global:header.recent\]\]
    • \[\[global:header.tags\]\]
    • \[\[global:header.popular\]\]
    • Login

    Explore Pybytes | Official Documentation | Report a Firmware Bug/Issue | GitHub

    SD card wire

    Scheduled Pinned Locked Moved WiPy 2&3
    9 Posts 4 Posters 2.5k Views 4 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • L Offline
      livius
      last edited by livius

      hi,

      i try to understand sd card connections to WIpy2.0 without expansion board
      alt text

      but i am confused about pinout and docs
      in pinout i have
      P12 MOSI
      P11 MISO
      P23 sdCLK
      P4 sdCMD???

      in docs:
      https://docs.pycom.io/pycom_esp32/library/machine.SD.html
      P8: DAT0, P23: SCLK and P4: CMD no external pull-up resistors are needed.
      why P8?

      normally i will be connect as:

      MOSI - P12
      MISO - P11
      SCK - P23
      CS to "any pin"
      

      how to really connect this spi device?

      think about people first, then computers

      L 1 Reply Last reply Reply Quote 0
      • L Offline
        livius @livius
        last edited by livius

        @livius
        i reply myself ;-)
        i see that i misunderstand doc - doc is about direct access to sd
        by sd interface to dat0
        alt text

        Do i understand this now corectly? Can someone point me?
        And more question in doc is:
        and the current implementation only works in 1-bit mode
        what limitation it create? And when it will be changed?
        I am new in sd card interface.

        UPDATE
        I understand now 1-bit mode
        there are also 4 bit mode - but 1 bit is enough for start playing

        think about people first, then computers

        1 Reply Last reply Reply Quote 0
        • L Offline
          livius
          last edited by

          Finally got it - this was so simple :)
          here is really good overview if someone start like i with SD playing
          http://www.ti.com/lit/an/slaa281b/slaa281b.pdf

          think about people first, then computers

          L S 2 Replies Last reply Reply Quote 0
          • L Offline
            Les-A @livius
            last edited by

            @livius For anyone referencing this, the link to TI has changed - just search ti.com for slaa281b and you'll find a forum entry with a link embedded in the document which contains a link to a .zip c example.

            1 Reply Last reply Reply Quote 0
            • S Offline
              SciWax @livius
              last edited by SciWax

              @livius Sorry for pulling the thread up again. I would like to ditch the expansion board to save money and use an external SD-card module like the level shifting sd module from this supplier: https://www.sparkfun.com/products/13743

              Right now, I'm using a Wipy mounted on an expansion board to connect a SD card to the WiPy. I do that, because I need to use the internal FTP of the WiPy.

              Can I just wire a SD card module like in your example? Did it work in a stable manner? I had no issues so far using the expansion board v3.

              I also found the following schematic for the expansion board v2. At the top, you can see how the sd module is wired on the expansion board. Mostlikely I would use that setup then:

              https://github.com/wipy/wipy/blob/master/hardware/ExpansionBoard-v1.2/ExpansionBoard-v1.2_Schematics.pdf

              robert-hhR 1 Reply Last reply Reply Quote 0
              • robert-hhR Offline
                robert-hh @SciWax
                last edited by

                @SciWax The schematic is for Expansion board 1.2 with WiPy 1.3. That wiring will not work with the esp32 modules. Just use the wiring as detailed in the Pinout:

                P8: DAT0, P23: SCLK and P4: CMD

                I have made my own carrier board using that wiring and it works fine.

                S 1 Reply Last reply Reply Quote 1
                • S Offline
                  SciWax @robert-hh
                  last edited by SciWax

                  @robert-hh thank you, rob! I guess I don't need a sd-card module then and can directly connect the SD card to these pins like in this thread:

                  https://forum.pycom.io/topic/2589/wipy-with-external-microsd-card-module?_=1644102331573
                  https://forum.pycom.io/topic/2589/wipy-with-external-microsd-card-module/5?_=1644102135472

                  I guess you just soldered a card slot to your carrier board, which is directly connected to these pins on the Pycom board like suggested in the linked thread?

                  robert-hhR 1 Reply Last reply Reply Quote 0
                  • robert-hhR Offline
                    robert-hh @SciWax
                    last edited by

                    @SciWax said in SD card wire:

                    I guess you just soldered a card slot to your carrier board,

                    Kind of yes. I used a small carrier board avoiding the SMD soldering. The link to the board is here: https://github.com/robert-hh/Pycom-baseboard with KiCad files for PCB and schematics. The USB/Serial adapter consumes quite a bit of current (~10mA).
                    The board contains also the espressif logic for firmware updates. I put that board usually in a small metal box, which then serves somewhat as ground plane for a quarter wavelength antenna.

                    S 1 Reply Last reply Reply Quote 1
                    • S Offline
                      SciWax @robert-hh
                      last edited by

                      @robert-hh thank you for the link, rob! I will look into it!

                      1 Reply Last reply Reply Quote 0

                      Hello! It looks like you're interested in this conversation, but you don't have an account yet.

                      Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

                      With your input, this post could be even better 💗

                      Register Login
                      • 1 / 1
                      • First post
                        Last post

                      Pycom on Twitter

                      Pycom