Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: AUDIO_DISCO_F746NG BSP_DISCO_F746NG EEPROM_DISCO_F746NG LCD_DISCO_F746NG QSPI_DISCO_F746NG SD_DISCO_F746NG SDRAM_DISCO_F746NG TS_DISCO_F746NG FATFileSystem mbed-rtos mbed
Fork of DISCO-F746NG_Monttory_Base by
USBHostKeyboard Class Reference
A class to communicate a USB keyboard. More...
#include <USBHostKeyboard.h>
Inherits IUSBEnumerator.
Public Member Functions | |
USBHostKeyboard () | |
Constructor. | |
bool | connect () |
Try to connect a keyboard device. | |
bool | connected () |
Check if a keyboard is connected. | |
void | attach (void(*ptr)(uint8_t key)) |
Attach a callback called when a keyboard event is received. | |
void | attach (void(*ptr)(uint8_t keyCode, uint8_t modifier)) |
Attach a callback called when a keyboard event is received. |
Detailed Description
A class to communicate a USB keyboard.
Definition at line 29 of file USBHostKeyboard.h.
Constructor & Destructor Documentation
USBHostKeyboard | ( | ) |
Constructor.
Definition at line 88 of file USBHostKeyboard.cpp.
Member Function Documentation
void attach | ( | void(*)(uint8_t key) | ptr ) |
Attach a callback called when a keyboard event is received.
- Parameters:
-
ptr function pointer
Definition at line 57 of file USBHostKeyboard.h.
void attach | ( | void(*)(uint8_t keyCode, uint8_t modifier) | ptr ) |
Attach a callback called when a keyboard event is received.
- Parameters:
-
ptr function pointer
Definition at line 69 of file USBHostKeyboard.h.
bool connect | ( | void | ) |
Try to connect a keyboard device.
- Returns:
- true if connection was successful
Definition at line 113 of file USBHostKeyboard.cpp.
bool connected | ( | ) |
Check if a keyboard is connected.
- Returns:
- true if a keyboard is connected
Definition at line 107 of file USBHostKeyboard.cpp.
Generated on Wed Jul 13 2022 18:23:14 by
