A version of the USBMSD_SD library that doesn't try to connect in the constructor. I made this change to support an operation mode where USB MSD can be enabled later in program operation without hanging.

Dependents:   Rocket

Fork of USBMSD_SD by Greg Steiert

Revision:
4:46888c9d5cd7
Parent:
3:cce1e689c548
diff -r cce1e689c548 -r 46888c9d5cd7 USBMSD_SD.cpp
--- a/USBMSD_SD.cpp	Wed Nov 16 18:24:52 2016 +0000
+++ b/USBMSD_SD.cpp	Sun Jun 11 04:05:51 2017 +0000
@@ -1,6 +1,8 @@
 /* mbed Microcontroller Library
  * Copyright (c) 2006-2012 ARM Limited
  *
+ * Modified by Dan Julio 5/2017 - do not "connect" during instantiation
+ *
  * Permission is hereby granted, free of charge, to any person obtaining a copy
  * of this software and associated documentation files (the "Software"), to deal
  * in the Software without restriction, including without limitation the rights
@@ -126,7 +128,9 @@
     //no init
     _status = 0x01;
     
-    connect();
+    // Modified by Dan Julio 5/2017 to prevent this object from blocking
+    // until manually connected by user code
+    //connect();
 }
 
 #define R1_IDLE_STATE           (1 << 0)