Advertisement
Guest User

Untitled

a guest
Jun 13th, 2020
60
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.50 KB | None | 0 0
  1. Here's the code with added printf statements:
  2.  
  3. DSTATUS disk_initialize(uint8_t drv) {
  4. uint8_t r;
  5.  
  6. printf("\n\n### drv=%d\n\n", drv);
  7. if (drv) return RES_NOTRDY;
  8.  
  9. r = spisdcard_init();
  10. spisdcard_deselect();
  11.  
  12. printf("\n\n### r=%d\n\n", r);
  13.  
  14. spisdcardstatus = r ? 0 : STA_NOINIT;
  15. printf("\n\nspisdcardstatus=%d\n\n", spisdcardstatus);
  16. return spisdcardstatus;
  17. }
  18.  
  19. And here's the output to the console:
  20.  
  21.  
  22. ### drv=0
  23.  
  24.  
  25.  
  26. ### r=1
  27.  
  28.  
  29.  
  30. spisdcardstatus=1
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement