Home > Net >  Is it feasible to programmatically power cycle sdio?
Is it feasible to programmatically power cycle sdio?

Time:09-25

I have an sdio device made for linux and windows that I need to power cycle. Of course I can manually remove and reinsert it to achieve this, but that is highly inconvenient and I would prefer some way to fully automate the procedure. How would I do this? Is there some obscure cmd line utilities? C library? Does this functionality have to be built into the driver? Is it even possible?

I've been reading about mmc on linux, haven't been able to find much yet on the windows side. Everything so far seems very complicated, vague, and opaque as opposed to say USB which has many ways to achieve this feat including the wonderful libftdi. At this point it seems like it might be impossible for sdio, but that seems weird to me.

CodePudding user response:

Not in any generic way. The SDIO interface has a VDD power supply pin, a specific implementation might provide external power control. If the board is your own design, then it is for you to implement that as in this example (though do read the question and answer, as the design shown is flawed). You would then control the power via a GPIO.

The SDIO specification does provide a "reset" command that may achieve what you need. There are various types of reset:

  • CMD0 - GO_IDLE_STATE
  • CMD15 - GO_INACTIVE_STATE
  • CMD52 (for I/O not memory cards) - Write 1 to CCCR I/O Abort RES bit
  • Related