mirror of https://github.com/ARMmbed/mbed-os.git
USBHOST: fix call back
parent
1577037b4b
commit
48434cfd64
|
@ -94,7 +94,7 @@ void USBDeviceConnected::init(uint8_t hub_, uint8_t port_, bool lowSpeed_) {
|
|||
|
||||
void USBDeviceConnected::disconnect() {
|
||||
for(int i = 0; i < MAX_INTF; i++) {
|
||||
intf[i].detach.call();
|
||||
if (intf[i].detach) intf[i].detach.call();
|
||||
}
|
||||
init();
|
||||
}
|
||||
|
|
|
@ -104,7 +104,8 @@ public:
|
|||
* Call the handler associted to the end of a transfer
|
||||
*/
|
||||
inline void call() {
|
||||
rx.call();
|
||||
if (rx)
|
||||
rx.call();
|
||||
};
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue