aboutsummaryrefslogtreecommitdiffstats
path: root/libmaple/usb/usb.c
diff options
context:
space:
mode:
Diffstat (limited to 'libmaple/usb/usb.c')
-rw-r--r--libmaple/usb/usb.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/libmaple/usb/usb.c b/libmaple/usb/usb.c
index 881c7f9..23cde00 100644
--- a/libmaple/usb/usb.c
+++ b/libmaple/usb/usb.c
@@ -459,6 +459,14 @@ uint8 usbGetRTS() {
return ((line_dtr_rts & CONTROL_LINE_RTS) != 0);
}
+uint8 usbIsConfigured() {
+ return (bDeviceState == CONFIGURED);
+}
+
+uint8 usbIsConnected() {
+ return (bDeviceState != UNCONNECTED);
+}
+
uint16 usbGetPending() {
return countTx;
}