Add rn42_lined(): connection status(GPIO2)
This commit is contained in:
parent
3e7875455e
commit
4b2b32a14b
|
@ -86,6 +86,11 @@ void rn42_cts_lo(void)
|
||||||
PORTD &= ~(1<<5);
|
PORTD &= ~(1<<5);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool rn42_linked(void)
|
||||||
|
{
|
||||||
|
return PINF&(1<<6);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
static uint8_t keyboard_leds(void) { return 0; }
|
static uint8_t keyboard_leds(void) { return 0; }
|
||||||
|
|
||||||
|
|
|
@ -14,5 +14,6 @@ void rn42_disconnect(void);
|
||||||
bool rn42_rts(void);
|
bool rn42_rts(void);
|
||||||
void rn42_cts_hi(void);
|
void rn42_cts_hi(void);
|
||||||
void rn42_cts_lo(void);
|
void rn42_cts_lo(void);
|
||||||
|
bool rn42_linked(void);
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -162,8 +162,10 @@ bool command_extra(uint8_t code)
|
||||||
xprintf("protocol: %s\n", (host_get_driver() == &rn42_driver) ? "RN-42" : "LUFA");
|
xprintf("protocol: %s\n", (host_get_driver() == &rn42_driver) ? "RN-42" : "LUFA");
|
||||||
xprintf("force_usb: %X\n", force_usb);
|
xprintf("force_usb: %X\n", force_usb);
|
||||||
xprintf("rn42_autoconnecting(): %X\n", rn42_autoconnecting());
|
xprintf("rn42_autoconnecting(): %X\n", rn42_autoconnecting());
|
||||||
|
xprintf("rn42_linked(): %X\n", rn42_linked());
|
||||||
xprintf("rn42_rts(): %X\n", rn42_rts());
|
xprintf("rn42_rts(): %X\n", rn42_rts());
|
||||||
xprintf("config_mode: %X\n", config_mode);
|
xprintf("config_mode: %X\n", config_mode);
|
||||||
|
xprintf("VBUS: %X\n", USBSTA&(1<<VBUS));
|
||||||
return true;
|
return true;
|
||||||
case KC_B:
|
case KC_B:
|
||||||
// battery monitor
|
// battery monitor
|
||||||
|
|
Loading…
Reference in New Issue