mirror of
https://github.com/felis/USB_Host_Shield_2.0.git
synced 2024-03-22 11:31:26 +01:00
Print error code in ADK code
Also added space between message and error code
This commit is contained in:
parent
9f855fca16
commit
3b429e633b
3 changed files with 10 additions and 10 deletions
8
adk.cpp
8
adk.cpp
|
@ -234,25 +234,25 @@ uint8_t ADK::Init(uint8_t parent, uint8_t port, bool lowspeed) {
|
|||
/* diagnostic messages */
|
||||
FailGetDevDescr:
|
||||
#ifdef DEBUG_USB_HOST
|
||||
NotifyFailGetDevDescr();
|
||||
NotifyFailGetDevDescr(rcode);
|
||||
goto Fail;
|
||||
#endif
|
||||
|
||||
FailSetDevTblEntry:
|
||||
#ifdef DEBUG_USB_HOST
|
||||
NotifyFailSetDevTblEntry();
|
||||
NotifyFailSetDevTblEntry(rcode);
|
||||
goto Fail;
|
||||
#endif
|
||||
|
||||
FailGetConfDescr:
|
||||
#ifdef DEBUG_USB_HOST
|
||||
NotifyFailGetConfDescr();
|
||||
NotifyFailGetConfDescr(rcode);
|
||||
goto Fail;
|
||||
#endif
|
||||
|
||||
FailSetConfDescr:
|
||||
#ifdef DEBUG_USB_HOST
|
||||
NotifyFailSetConfDescr();
|
||||
NotifyFailSetConfDescr(rcode);
|
||||
goto Fail;
|
||||
#endif
|
||||
|
||||
|
|
11
message.cpp
11
message.cpp
|
@ -65,18 +65,18 @@ void E_Notify(double d, int lvl) {
|
|||
|
||||
#ifdef DEBUG_USB_HOST
|
||||
void NotifyFailGetDevDescr(void) {
|
||||
Notify(PSTR("\r\ngetDevDescr"), 0x80);
|
||||
Notify(PSTR("\r\ngetDevDescr "), 0x80);
|
||||
}
|
||||
|
||||
void NotifyFailSetDevTblEntry(void) {
|
||||
Notify(PSTR("\r\nsetDevTblEn"), 0x80);
|
||||
Notify(PSTR("\r\nsetDevTblEn "), 0x80);
|
||||
}
|
||||
void NotifyFailGetConfDescr(void) {
|
||||
Notify(PSTR("\r\ngetConf"), 0x80);
|
||||
Notify(PSTR("\r\ngetConf "), 0x80);
|
||||
}
|
||||
|
||||
void NotifyFailSetConfDescr(void) {
|
||||
Notify(PSTR("\r\nsetConf"), 0x80);
|
||||
Notify(PSTR("\r\nsetConf "), 0x80);
|
||||
}
|
||||
|
||||
void NotifyFailGetDevDescr(uint8_t reason) {
|
||||
|
@ -95,12 +95,11 @@ void NotifyFailGetConfDescr(uint8_t reason) {
|
|||
NotifyFail(reason);
|
||||
}
|
||||
|
||||
/* Will we need this in the future?
|
||||
void NotifyFailSetConfDescr(uint8_t reason) {
|
||||
NotifyFailSetConfDescr();
|
||||
NotifyFail(reason);
|
||||
}
|
||||
*/
|
||||
|
||||
void NotifyFailUnknownDevice(uint16_t VID, uint16_t PID) {
|
||||
Notify(PSTR("\r\nUnknown Device Connected - VID: "), 0x80);
|
||||
D_PrintHex<uint16_t > (VID, 0x80);
|
||||
|
|
|
@ -43,6 +43,7 @@ void E_Notifyc(char c, int lvl);
|
|||
void NotifyFailGetDevDescr(uint8_t reason);
|
||||
void NotifyFailSetDevTblEntry(uint8_t reason);
|
||||
void NotifyFailGetConfDescr(uint8_t reason);
|
||||
void NotifyFailSetConfDescr(uint8_t reason);
|
||||
void NotifyFailGetDevDescr(void);
|
||||
void NotifyFailSetDevTblEntry(void);
|
||||
void NotifyFailGetConfDescr(void);
|
||||
|
|
Loading…
Reference in a new issue