Closed mateusz-holenko closed 4 years ago
Thanks this is merged but has been revisited a bit with https://github.com/enjoy-digital/litesdcard/commit/532eccbcceb9f81dc7b08c8a0fe224822c7f1c74. It is assuming a cd
pin defined like this: https://github.com/enjoy-digital/litex/commit/2e59dc329d57f5cbacc69eae6020f1099103a956.
Thanks!
Moving the declaration of card_detect
to phy.py
might have changed the order in which CSRs are genreated so we'll have to verify if the Linux driver we PRed in https://github.com/litex-hub/linux-on-litex-vexriscv/pull/133 still works.
Yes the software will indeed need to be adapted, sorry for breaking it, but card detection is something that belongs to the PHY.
This adds a new CSR exposing a bit indicating if the card is present. If there is no card detection pin available in the HW it's assume that the card is inserted.