sdmmc_periph.c 1.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. // Copyright 2015-2020 Espressif Systems (Shanghai) PTE LTD
  2. //
  3. // Licensed under the Apache License, Version 2.0 (the "License");
  4. // you may not use this file except in compliance with the License.
  5. // You may obtain a copy of the License at
  6. //
  7. // http://www.apache.org/licenses/LICENSE-2.0
  8. //
  9. // Unless required by applicable law or agreed to in writing, software
  10. // distributed under the License is distributed on an "AS IS" BASIS,
  11. // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  12. // See the License for the specific language governing permissions and
  13. // limitations under the License.
  14. #include "soc/sdmmc_periph.h"
  15. const sdmmc_slot_info_t sdmmc_slot_info[SOC_SDMMC_NUM_SLOTS] = {
  16. {
  17. .width = 8,
  18. .card_detect = SDHOST_CARD_DETECT_N_1_IDX,
  19. .write_protect = SDHOST_CARD_WRITE_PRT_1_IDX,
  20. .card_int = SDHOST_CARD_INT_N_1_IDX,
  21. },
  22. {
  23. .width = 8,
  24. .card_detect = SDHOST_CARD_DETECT_N_2_IDX,
  25. .write_protect = SDHOST_CARD_WRITE_PRT_2_IDX,
  26. .card_int = SDHOST_CARD_INT_N_2_IDX,
  27. }
  28. };
  29. const sdmmc_slot_io_info_t sdmmc_slot_gpio_sig[SOC_SDMMC_NUM_SLOTS] = {
  30. {
  31. .clk = SDHOST_CCLK_OUT_1_IDX,
  32. .cmd = SDHOST_CCMD_OUT_1_IDX,
  33. .d0 = SDHOST_CDATA_OUT_10_IDX,
  34. .d1 = SDHOST_CDATA_OUT_11_IDX,
  35. .d2 = SDHOST_CDATA_OUT_12_IDX,
  36. .d3 = SDHOST_CDATA_OUT_13_IDX,
  37. .d4 = SDHOST_CDATA_OUT_14_IDX,
  38. .d5 = SDHOST_CDATA_OUT_15_IDX,
  39. .d6 = SDHOST_CDATA_OUT_16_IDX,
  40. .d7 = SDHOST_CDATA_OUT_17_IDX,
  41. },
  42. {
  43. .clk = SDHOST_CCLK_OUT_2_IDX,
  44. .cmd = SDHOST_CCMD_OUT_2_IDX,
  45. .d0 = SDHOST_CDATA_OUT_20_IDX,
  46. .d1 = SDHOST_CDATA_OUT_21_IDX,
  47. .d2 = SDHOST_CDATA_OUT_22_IDX,
  48. .d3 = SDHOST_CDATA_OUT_23_IDX,
  49. .d4 = SDHOST_CDATA_OUT_24_IDX,
  50. .d5 = SDHOST_CDATA_OUT_25_IDX,
  51. .d6 = SDHOST_CDATA_OUT_26_IDX,
  52. .d7 = SDHOST_CDATA_OUT_27_IDX,
  53. }
  54. };