aboutsummaryrefslogtreecommitdiffstats
path: root/Demos/Host
diff options
context:
space:
mode:
authorDean Camera <dean@fourwalledcubicle.com>2010-07-21 16:19:32 +0000
committerDean Camera <dean@fourwalledcubicle.com>2010-07-21 16:19:32 +0000
commit6bda628718f67c04ed43e8328f55bdce5319c504 (patch)
treeefd08eefa90cef94440f880a70902f5803fb12a7 /Demos/Host
parent83e293a6ec98c7faad1b76dd312b31b86cbeecc1 (diff)
downloadlufa-6bda628718f67c04ed43e8328f55bdce5319c504.tar.gz
lufa-6bda628718f67c04ed43e8328f55bdce5319c504.tar.bz2
lufa-6bda628718f67c04ed43e8328f55bdce5319c504.zip
Update all demos, projects and bootloaders to indent all function parameters, one per line, for better readability.
Add missing const qualifiers to the demos.
Diffstat (limited to 'Demos/Host')
-rw-r--r--Demos/Host/ClassDriver/JoystickHostWithParser/JoystickHostWithParser.c5
-rw-r--r--Demos/Host/ClassDriver/JoystickHostWithParser/JoystickHostWithParser.h5
-rw-r--r--Demos/Host/ClassDriver/KeyboardHost/KeyboardHost.c3
-rw-r--r--Demos/Host/ClassDriver/KeyboardHost/KeyboardHost.h3
-rw-r--r--Demos/Host/ClassDriver/KeyboardHostWithParser/KeyboardHostWithParser.c5
-rw-r--r--Demos/Host/ClassDriver/KeyboardHostWithParser/KeyboardHostWithParser.h5
-rw-r--r--Demos/Host/ClassDriver/MIDIHost/MIDIHost.c3
-rw-r--r--Demos/Host/ClassDriver/MIDIHost/MIDIHost.h3
-rw-r--r--Demos/Host/ClassDriver/MassStorageHost/MassStorageHost.c3
-rw-r--r--Demos/Host/ClassDriver/MassStorageHost/MassStorageHost.h3
-rw-r--r--Demos/Host/ClassDriver/MouseHost/MouseHost.c3
-rw-r--r--Demos/Host/ClassDriver/MouseHost/MouseHost.h3
-rw-r--r--Demos/Host/ClassDriver/MouseHostWithParser/MouseHostWithParser.c5
-rw-r--r--Demos/Host/ClassDriver/MouseHostWithParser/MouseHostWithParser.h5
-rw-r--r--Demos/Host/ClassDriver/PrinterHost/PrinterHost.c3
-rw-r--r--Demos/Host/ClassDriver/PrinterHost/PrinterHost.h3
-rw-r--r--Demos/Host/ClassDriver/RNDISEthernetHost/RNDISEthernetHost.c3
-rw-r--r--Demos/Host/ClassDriver/RNDISEthernetHost/RNDISEthernetHost.h3
-rw-r--r--Demos/Host/ClassDriver/StillImageHost/StillImageHost.c3
-rw-r--r--Demos/Host/ClassDriver/StillImageHost/StillImageHost.h3
-rw-r--r--Demos/Host/ClassDriver/VirtualSerialHost/VirtualSerialHost.c3
-rw-r--r--Demos/Host/ClassDriver/VirtualSerialHost/VirtualSerialHost.h3
-rw-r--r--Demos/Host/Incomplete/BluetoothHost/BluetoothHost.c3
-rw-r--r--Demos/Host/Incomplete/BluetoothHost/BluetoothHost.h3
-rw-r--r--Demos/Host/Incomplete/BluetoothHost/Lib/BluetoothACLPackets.c7
-rw-r--r--Demos/Host/Incomplete/BluetoothHost/Lib/BluetoothHCICommands.c4
-rw-r--r--Demos/Host/Incomplete/BluetoothHost/Lib/BluetoothHCICommands.h3
-rw-r--r--Demos/Host/Incomplete/BluetoothHost/Lib/BluetoothStack.h10
-rw-r--r--Demos/Host/Incomplete/BluetoothHost/Lib/RFCOMM.c39
-rw-r--r--Demos/Host/Incomplete/BluetoothHost/Lib/RFCOMM.h39
-rw-r--r--Demos/Host/Incomplete/BluetoothHost/Lib/RFCOMMControl.c30
-rw-r--r--Demos/Host/Incomplete/BluetoothHost/Lib/RFCOMMControl.h30
-rw-r--r--Demos/Host/Incomplete/BluetoothHost/Lib/SDP.c43
-rw-r--r--Demos/Host/Incomplete/BluetoothHost/Lib/SDP.h63
-rw-r--r--Demos/Host/LowLevel/GenericHIDHost/GenericHIDHost.c14
-rw-r--r--Demos/Host/LowLevel/GenericHIDHost/GenericHIDHost.h8
-rw-r--r--Demos/Host/LowLevel/JoystickHostWithParser/HIDReport.c2
-rw-r--r--Demos/Host/LowLevel/JoystickHostWithParser/HIDReport.h2
-rw-r--r--Demos/Host/LowLevel/JoystickHostWithParser/JoystickHostWithParser.h3
-rw-r--r--Demos/Host/LowLevel/KeyboardHost/KeyboardHost.c3
-rw-r--r--Demos/Host/LowLevel/KeyboardHost/KeyboardHost.h3
-rw-r--r--Demos/Host/LowLevel/KeyboardHostWithParser/HIDReport.c2
-rw-r--r--Demos/Host/LowLevel/KeyboardHostWithParser/HIDReport.h2
-rw-r--r--Demos/Host/LowLevel/KeyboardHostWithParser/KeyboardHostWithParser.c3
-rw-r--r--Demos/Host/LowLevel/KeyboardHostWithParser/KeyboardHostWithParser.h3
-rw-r--r--Demos/Host/LowLevel/MIDIHost/MIDIHost.c3
-rw-r--r--Demos/Host/LowLevel/MIDIHost/MIDIHost.h3
-rw-r--r--Demos/Host/LowLevel/MassStorageHost/Lib/MassStoreCommands.c34
-rw-r--r--Demos/Host/LowLevel/MassStorageHost/Lib/MassStoreCommands.h37
-rw-r--r--Demos/Host/LowLevel/MassStorageHost/MassStorageHost.c6
-rw-r--r--Demos/Host/LowLevel/MassStorageHost/MassStorageHost.h6
-rw-r--r--Demos/Host/LowLevel/MouseHost/MouseHost.c3
-rw-r--r--Demos/Host/LowLevel/MouseHost/MouseHost.h3
-rw-r--r--Demos/Host/LowLevel/MouseHostWithParser/HIDReport.c2
-rw-r--r--Demos/Host/LowLevel/MouseHostWithParser/HIDReport.h2
-rw-r--r--Demos/Host/LowLevel/MouseHostWithParser/MouseHostWithParser.c3
-rw-r--r--Demos/Host/LowLevel/MouseHostWithParser/MouseHostWithParser.h3
-rw-r--r--Demos/Host/LowLevel/PrinterHost/Lib/PrinterCommands.c6
-rw-r--r--Demos/Host/LowLevel/PrinterHost/Lib/PrinterCommands.h8
-rw-r--r--Demos/Host/LowLevel/PrinterHost/PrinterHost.c5
-rw-r--r--Demos/Host/LowLevel/PrinterHost/PrinterHost.h5
-rw-r--r--Demos/Host/LowLevel/RNDISEthernetHost/Lib/RNDISCommands.c17
-rw-r--r--Demos/Host/LowLevel/RNDISEthernetHost/Lib/RNDISCommands.h17
-rw-r--r--Demos/Host/LowLevel/RNDISEthernetHost/RNDISEthernetHost.c3
-rw-r--r--Demos/Host/LowLevel/RNDISEthernetHost/RNDISEthernetHost.h3
-rw-r--r--Demos/Host/LowLevel/StillImageHost/Lib/StillImageCommands.c6
-rw-r--r--Demos/Host/LowLevel/StillImageHost/Lib/StillImageCommands.h6
-rw-r--r--Demos/Host/LowLevel/StillImageHost/StillImageHost.c9
-rw-r--r--Demos/Host/LowLevel/StillImageHost/StillImageHost.h9
-rw-r--r--Demos/Host/LowLevel/VirtualSerialHost/VirtualSerialHost.c3
-rw-r--r--Demos/Host/LowLevel/VirtualSerialHost/VirtualSerialHost.h3
71 files changed, 399 insertions, 203 deletions
diff --git a/Demos/Host/ClassDriver/JoystickHostWithParser/JoystickHostWithParser.c b/Demos/Host/ClassDriver/JoystickHostWithParser/JoystickHostWithParser.c
index 8f0b40533..f1b4cac7b 100644
--- a/Demos/Host/ClassDriver/JoystickHostWithParser/JoystickHostWithParser.c
+++ b/Demos/Host/ClassDriver/JoystickHostWithParser/JoystickHostWithParser.c
@@ -231,7 +231,8 @@ void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
/** Event handler for the USB_DeviceEnumerationFailed event. This indicates that a problem occurred while
* enumerating an attached USB device.
*/
-void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode)
+void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode)
{
printf_P(PSTR(ESC_FG_RED "Dev Enum Error\r\n"
" -- Error Code %d\r\n"
@@ -250,7 +251,7 @@ void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8
*
* \return Boolean true if the item should be stored into the HID report structure, false if it should be discarded
*/
-bool CALLBACK_HIDParser_FilterHIDReportItem(HID_ReportItem_t* CurrentItem)
+bool CALLBACK_HIDParser_FilterHIDReportItem(HID_ReportItem_t* const CurrentItem)
{
bool IsJoystick = false;
diff --git a/Demos/Host/ClassDriver/JoystickHostWithParser/JoystickHostWithParser.h b/Demos/Host/ClassDriver/JoystickHostWithParser/JoystickHostWithParser.h
index da667e632..1cebb924c 100644
--- a/Demos/Host/ClassDriver/JoystickHostWithParser/JoystickHostWithParser.h
+++ b/Demos/Host/ClassDriver/JoystickHostWithParser/JoystickHostWithParser.h
@@ -85,9 +85,10 @@
void EVENT_USB_Host_HostError(const uint8_t ErrorCode);
void EVENT_USB_Host_DeviceAttached(void);
void EVENT_USB_Host_DeviceUnattached(void);
- void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode);
+ void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode);
void EVENT_USB_Host_DeviceEnumerationComplete(void);
- bool CALLBACK_HIDParser_FilterHIDReportItem(HID_ReportItem_t* CurrentItem);
+ bool CALLBACK_HIDParser_FilterHIDReportItem(HID_ReportItem_t* const CurrentItem);
#endif
diff --git a/Demos/Host/ClassDriver/KeyboardHost/KeyboardHost.c b/Demos/Host/ClassDriver/KeyboardHost/KeyboardHost.c
index 8ae7d8312..8bdf2b6ec 100644
--- a/Demos/Host/ClassDriver/KeyboardHost/KeyboardHost.c
+++ b/Demos/Host/ClassDriver/KeyboardHost/KeyboardHost.c
@@ -211,7 +211,8 @@ void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
/** Event handler for the USB_DeviceEnumerationFailed event. This indicates that a problem occurred while
* enumerating an attached USB device.
*/
-void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode)
+void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode)
{
printf_P(PSTR(ESC_FG_RED "Dev Enum Error\r\n"
" -- Error Code %d\r\n"
diff --git a/Demos/Host/ClassDriver/KeyboardHost/KeyboardHost.h b/Demos/Host/ClassDriver/KeyboardHost/KeyboardHost.h
index 948ff6a99..fd6b83882 100644
--- a/Demos/Host/ClassDriver/KeyboardHost/KeyboardHost.h
+++ b/Demos/Host/ClassDriver/KeyboardHost/KeyboardHost.h
@@ -70,7 +70,8 @@
void EVENT_USB_Host_HostError(const uint8_t ErrorCode);
void EVENT_USB_Host_DeviceAttached(void);
void EVENT_USB_Host_DeviceUnattached(void);
- void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode);
+ void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode);
void EVENT_USB_Host_DeviceEnumerationComplete(void);
#endif
diff --git a/Demos/Host/ClassDriver/KeyboardHostWithParser/KeyboardHostWithParser.c b/Demos/Host/ClassDriver/KeyboardHostWithParser/KeyboardHostWithParser.c
index dedf12fc4..9d28e7136 100644
--- a/Demos/Host/ClassDriver/KeyboardHostWithParser/KeyboardHostWithParser.c
+++ b/Demos/Host/ClassDriver/KeyboardHostWithParser/KeyboardHostWithParser.c
@@ -237,7 +237,8 @@ void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
/** Event handler for the USB_DeviceEnumerationFailed event. This indicates that a problem occurred while
* enumerating an attached USB device.
*/
-void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode)
+void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode)
{
printf_P(PSTR(ESC_FG_RED "Dev Enum Error\r\n"
" -- Error Code %d\r\n"
@@ -256,7 +257,7 @@ void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8
*
* \return Boolean true if the item should be stored into the HID report structure, false if it should be discarded
*/
-bool CALLBACK_HIDParser_FilterHIDReportItem(HID_ReportItem_t* CurrentItem)
+bool CALLBACK_HIDParser_FilterHIDReportItem(HID_ReportItem_t* const CurrentItem)
{
/* Check the attributes of the current item - see if we are interested in it or not;
* only store KEYBOARD usage page items into the Processed HID Report structure to
diff --git a/Demos/Host/ClassDriver/KeyboardHostWithParser/KeyboardHostWithParser.h b/Demos/Host/ClassDriver/KeyboardHostWithParser/KeyboardHostWithParser.h
index 8a0aeffd6..5ecfdf458 100644
--- a/Demos/Host/ClassDriver/KeyboardHostWithParser/KeyboardHostWithParser.h
+++ b/Demos/Host/ClassDriver/KeyboardHostWithParser/KeyboardHostWithParser.h
@@ -73,9 +73,10 @@
void EVENT_USB_Host_HostError(const uint8_t ErrorCode);
void EVENT_USB_Host_DeviceAttached(void);
void EVENT_USB_Host_DeviceUnattached(void);
- void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode);
+ void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode);
void EVENT_USB_Host_DeviceEnumerationComplete(void);
- bool CALLBACK_HIDParser_FilterHIDReportItem(HID_ReportItem_t* CurrentItem);
+ bool CALLBACK_HIDParser_FilterHIDReportItem(HID_ReportItem_t* const CurrentItem);
#endif
diff --git a/Demos/Host/ClassDriver/MIDIHost/MIDIHost.c b/Demos/Host/ClassDriver/MIDIHost/MIDIHost.c
index 108c807c6..faaebdd7c 100644
--- a/Demos/Host/ClassDriver/MIDIHost/MIDIHost.c
+++ b/Demos/Host/ClassDriver/MIDIHost/MIDIHost.c
@@ -252,7 +252,8 @@ void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
/** Event handler for the USB_DeviceEnumerationFailed event. This indicates that a problem occurred while
* enumerating an attached USB device.
*/
-void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode)
+void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode)
{
printf_P(PSTR(ESC_FG_RED "Dev Enum Error\r\n"
" -- Error Code %d\r\n"
diff --git a/Demos/Host/ClassDriver/MIDIHost/MIDIHost.h b/Demos/Host/ClassDriver/MIDIHost/MIDIHost.h
index f33ecb750..84e7680f3 100644
--- a/Demos/Host/ClassDriver/MIDIHost/MIDIHost.h
+++ b/Demos/Host/ClassDriver/MIDIHost/MIDIHost.h
@@ -73,7 +73,8 @@
void EVENT_USB_Host_HostError(const uint8_t ErrorCode);
void EVENT_USB_Host_DeviceAttached(void);
void EVENT_USB_Host_DeviceUnattached(void);
- void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode);
+ void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode);
void EVENT_USB_Host_DeviceEnumerationComplete(void);
#endif
diff --git a/Demos/Host/ClassDriver/MassStorageHost/MassStorageHost.c b/Demos/Host/ClassDriver/MassStorageHost/MassStorageHost.c
index 697da3420..40cf2a48d 100644
--- a/Demos/Host/ClassDriver/MassStorageHost/MassStorageHost.c
+++ b/Demos/Host/ClassDriver/MassStorageHost/MassStorageHost.c
@@ -289,7 +289,8 @@ void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
/** Event handler for the USB_DeviceEnumerationFailed event. This indicates that a problem occurred while
* enumerating an attached USB device.
*/
-void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode)
+void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode)
{
printf_P(PSTR(ESC_FG_RED "Dev Enum Error\r\n"
" -- Error Code %d\r\n"
diff --git a/Demos/Host/ClassDriver/MassStorageHost/MassStorageHost.h b/Demos/Host/ClassDriver/MassStorageHost/MassStorageHost.h
index 0cd989781..b99471205 100644
--- a/Demos/Host/ClassDriver/MassStorageHost/MassStorageHost.h
+++ b/Demos/Host/ClassDriver/MassStorageHost/MassStorageHost.h
@@ -74,7 +74,8 @@
void EVENT_USB_Host_HostError(const uint8_t ErrorCode);
void EVENT_USB_Host_DeviceAttached(void);
void EVENT_USB_Host_DeviceUnattached(void);
- void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode);
+ void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode);
void EVENT_USB_Host_DeviceEnumerationComplete(void);
#endif
diff --git a/Demos/Host/ClassDriver/MouseHost/MouseHost.c b/Demos/Host/ClassDriver/MouseHost/MouseHost.c
index 6edceb08d..a03381cc6 100644
--- a/Demos/Host/ClassDriver/MouseHost/MouseHost.c
+++ b/Demos/Host/ClassDriver/MouseHost/MouseHost.c
@@ -207,7 +207,8 @@ void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
/** Event handler for the USB_DeviceEnumerationFailed event. This indicates that a problem occurred while
* enumerating an attached USB device.
*/
-void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode)
+void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode)
{
printf_P(PSTR(ESC_FG_RED "Dev Enum Error\r\n"
" -- Error Code %d\r\n"
diff --git a/Demos/Host/ClassDriver/MouseHost/MouseHost.h b/Demos/Host/ClassDriver/MouseHost/MouseHost.h
index ccbaa8213..7664580cb 100644
--- a/Demos/Host/ClassDriver/MouseHost/MouseHost.h
+++ b/Demos/Host/ClassDriver/MouseHost/MouseHost.h
@@ -70,7 +70,8 @@
void EVENT_USB_Host_HostError(const uint8_t ErrorCode);
void EVENT_USB_Host_DeviceAttached(void);
void EVENT_USB_Host_DeviceUnattached(void);
- void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode);
+ void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode);
void EVENT_USB_Host_DeviceEnumerationComplete(void);
#endif
diff --git a/Demos/Host/ClassDriver/MouseHostWithParser/MouseHostWithParser.c b/Demos/Host/ClassDriver/MouseHostWithParser/MouseHostWithParser.c
index ef7835e54..111bed48e 100644
--- a/Demos/Host/ClassDriver/MouseHostWithParser/MouseHostWithParser.c
+++ b/Demos/Host/ClassDriver/MouseHostWithParser/MouseHostWithParser.c
@@ -240,7 +240,8 @@ void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
/** Event handler for the USB_DeviceEnumerationFailed event. This indicates that a problem occurred while
* enumerating an attached USB device.
*/
-void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode)
+void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode)
{
printf_P(PSTR(ESC_FG_RED "Dev Enum Error\r\n"
" -- Error Code %d\r\n"
@@ -259,7 +260,7 @@ void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8
*
* \return Boolean true if the item should be stored into the HID report structure, false if it should be discarded
*/
-bool CALLBACK_HIDParser_FilterHIDReportItem(HID_ReportItem_t* CurrentItem)
+bool CALLBACK_HIDParser_FilterHIDReportItem(HID_ReportItem_t* const CurrentItem)
{
bool IsMouse = false;
diff --git a/Demos/Host/ClassDriver/MouseHostWithParser/MouseHostWithParser.h b/Demos/Host/ClassDriver/MouseHostWithParser/MouseHostWithParser.h
index 342dff79a..3b26cead5 100644
--- a/Demos/Host/ClassDriver/MouseHostWithParser/MouseHostWithParser.h
+++ b/Demos/Host/ClassDriver/MouseHostWithParser/MouseHostWithParser.h
@@ -88,9 +88,10 @@
void EVENT_USB_Host_HostError(const uint8_t ErrorCode);
void EVENT_USB_Host_DeviceAttached(void);
void EVENT_USB_Host_DeviceUnattached(void);
- void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode);
+ void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode);
void EVENT_USB_Host_DeviceEnumerationComplete(void);
- bool CALLBACK_HIDParser_FilterHIDReportItem(HID_ReportItem_t* CurrentItem);
+ bool CALLBACK_HIDParser_FilterHIDReportItem(HID_ReportItem_t* const CurrentItem);
#endif
diff --git a/Demos/Host/ClassDriver/PrinterHost/PrinterHost.c b/Demos/Host/ClassDriver/PrinterHost/PrinterHost.c
index 9d5ca08d9..e0d9726b6 100644
--- a/Demos/Host/ClassDriver/PrinterHost/PrinterHost.c
+++ b/Demos/Host/ClassDriver/PrinterHost/PrinterHost.c
@@ -211,7 +211,8 @@ void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
/** Event handler for the USB_DeviceEnumerationFailed event. This indicates that a problem occurred while
* enumerating an attached USB device.
*/
-void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode)
+void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode)
{
printf_P(PSTR(ESC_FG_RED "Dev Enum Error\r\n"
" -- Error Code %d\r\n"
diff --git a/Demos/Host/ClassDriver/PrinterHost/PrinterHost.h b/Demos/Host/ClassDriver/PrinterHost/PrinterHost.h
index a4880577e..a2b90a69d 100644
--- a/Demos/Host/ClassDriver/PrinterHost/PrinterHost.h
+++ b/Demos/Host/ClassDriver/PrinterHost/PrinterHost.h
@@ -73,7 +73,8 @@
void EVENT_USB_Host_HostError(const uint8_t ErrorCode);
void EVENT_USB_Host_DeviceAttached(void);
void EVENT_USB_Host_DeviceUnattached(void);
- void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode);
+ void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode);
void EVENT_USB_Host_DeviceEnumerationComplete(void);
#endif
diff --git a/Demos/Host/ClassDriver/RNDISEthernetHost/RNDISEthernetHost.c b/Demos/Host/ClassDriver/RNDISEthernetHost/RNDISEthernetHost.c
index 589faebca..b793db928 100644
--- a/Demos/Host/ClassDriver/RNDISEthernetHost/RNDISEthernetHost.c
+++ b/Demos/Host/ClassDriver/RNDISEthernetHost/RNDISEthernetHost.c
@@ -236,7 +236,8 @@ void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
/** Event handler for the USB_DeviceEnumerationFailed event. This indicates that a problem occurred while
* enumerating an attached USB device.
*/
-void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode)
+void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode)
{
printf_P(PSTR(ESC_FG_RED "Dev Enum Error\r\n"
" -- Error Code %d\r\n"
diff --git a/Demos/Host/ClassDriver/RNDISEthernetHost/RNDISEthernetHost.h b/Demos/Host/ClassDriver/RNDISEthernetHost/RNDISEthernetHost.h
index 06f5ec2f0..f3c04f593 100644
--- a/Demos/Host/ClassDriver/RNDISEthernetHost/RNDISEthernetHost.h
+++ b/Demos/Host/ClassDriver/RNDISEthernetHost/RNDISEthernetHost.h
@@ -74,7 +74,8 @@
void EVENT_USB_Host_HostError(const uint8_t ErrorCode);
void EVENT_USB_Host_DeviceAttached(void);
void EVENT_USB_Host_DeviceUnattached(void);
- void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode);
+ void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode);
void EVENT_USB_Host_DeviceEnumerationComplete(void);
#endif
diff --git a/Demos/Host/ClassDriver/StillImageHost/StillImageHost.c b/Demos/Host/ClassDriver/StillImageHost/StillImageHost.c
index 8f91d81f1..152639fef 100644
--- a/Demos/Host/ClassDriver/StillImageHost/StillImageHost.c
+++ b/Demos/Host/ClassDriver/StillImageHost/StillImageHost.c
@@ -205,7 +205,8 @@ void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
/** Event handler for the USB_DeviceEnumerationFailed event. This indicates that a problem occurred while
* enumerating an attached USB device.
*/
-void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode)
+void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode)
{
printf_P(PSTR(ESC_FG_RED "Dev Enum Error\r\n"
" -- Error Code %d\r\n"
diff --git a/Demos/Host/ClassDriver/StillImageHost/StillImageHost.h b/Demos/Host/ClassDriver/StillImageHost/StillImageHost.h
index 5c163ef54..1b776596b 100644
--- a/Demos/Host/ClassDriver/StillImageHost/StillImageHost.h
+++ b/Demos/Host/ClassDriver/StillImageHost/StillImageHost.h
@@ -70,7 +70,8 @@
void EVENT_USB_Host_HostError(const uint8_t ErrorCode);
void EVENT_USB_Host_DeviceAttached(void);
void EVENT_USB_Host_DeviceUnattached(void);
- void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode);
+ void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode);
void EVENT_USB_Host_DeviceEnumerationComplete(void);
#endif
diff --git a/Demos/Host/ClassDriver/VirtualSerialHost/VirtualSerialHost.c b/Demos/Host/ClassDriver/VirtualSerialHost/VirtualSerialHost.c
index e6403ecdf..543e09825 100644
--- a/Demos/Host/ClassDriver/VirtualSerialHost/VirtualSerialHost.c
+++ b/Demos/Host/ClassDriver/VirtualSerialHost/VirtualSerialHost.c
@@ -182,7 +182,8 @@ void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
/** Event handler for the USB_DeviceEnumerationFailed event. This indicates that a problem occurred while
* enumerating an attached USB device.
*/
-void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode)
+void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode)
{
printf_P(PSTR(ESC_FG_RED "Dev Enum Error\r\n"
" -- Error Code %d\r\n"
diff --git a/Demos/Host/ClassDriver/VirtualSerialHost/VirtualSerialHost.h b/Demos/Host/ClassDriver/VirtualSerialHost/VirtualSerialHost.h
index bd5cd6ad6..ed4ffcef7 100644
--- a/Demos/Host/ClassDriver/VirtualSerialHost/VirtualSerialHost.h
+++ b/Demos/Host/ClassDriver/VirtualSerialHost/VirtualSerialHost.h
@@ -70,7 +70,8 @@
void EVENT_USB_Host_HostError(const uint8_t ErrorCode);
void EVENT_USB_Host_DeviceAttached(void);
void EVENT_USB_Host_DeviceUnattached(void);
- void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode);
+ void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode);
void EVENT_USB_Host_DeviceEnumerationComplete(void);
#endif
diff --git a/Demos/Host/Incomplete/BluetoothHost/BluetoothHost.c b/Demos/Host/Incomplete/BluetoothHost/BluetoothHost.c
index 55c399778..8301e85bd 100644
--- a/Demos/Host/Incomplete/BluetoothHost/BluetoothHost.c
+++ b/Demos/Host/Incomplete/BluetoothHost/BluetoothHost.c
@@ -123,7 +123,8 @@ void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
/** Event handler for the USB_DeviceEnumerationFailed event. This indicates that a problem occurred while
* enumerating an attached USB device.
*/
-void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode)
+void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode)
{
printf_P(PSTR(ESC_FG_RED "Dev Enum Error\r\n"
" -- Error Code %d\r\n"
diff --git a/Demos/Host/Incomplete/BluetoothHost/BluetoothHost.h b/Demos/Host/Incomplete/BluetoothHost/BluetoothHost.h
index e0de59ae2..0814845a0 100644
--- a/Demos/Host/Incomplete/BluetoothHost/BluetoothHost.h
+++ b/Demos/Host/Incomplete/BluetoothHost/BluetoothHost.h
@@ -79,7 +79,8 @@
void EVENT_USB_Host_DeviceUnattached(void);
void EVENT_USB_Host_DeviceEnumerationComplete(void);
void EVENT_USB_Host_HostError(const uint8_t ErrorCode);
- void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode);
+ void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode);
/* Function Prototypes: */
void SetupHardware(void);
diff --git a/Demos/Host/Incomplete/BluetoothHost/Lib/BluetoothACLPackets.c b/Demos/Host/Incomplete/BluetoothHost/Lib/BluetoothACLPackets.c
index 68a02d48b..939b2ae5f 100644
--- a/Demos/Host/Incomplete/BluetoothHost/Lib/BluetoothACLPackets.c
+++ b/Demos/Host/Incomplete/BluetoothHost/Lib/BluetoothACLPackets.c
@@ -211,7 +211,8 @@ static void Bluetooth_ProcessIncomingACLPackets(void)
*
* \return Pointer to the matching channel information structure in the channel table if found, NULL otherwise
*/
-Bluetooth_Channel_t* Bluetooth_GetChannelData(const uint16_t SearchValue, const uint8_t SearchKey)
+Bluetooth_Channel_t* Bluetooth_GetChannelData(const uint16_t SearchValue,
+ const uint8_t SearchKey)
{
for (uint8_t i = 0; i < BLUETOOTH_MAX_OPEN_CHANNELS; i++)
{
@@ -253,7 +254,9 @@ Bluetooth_Channel_t* Bluetooth_GetChannelData(const uint16_t SearchValue, const
*
* \return A value from the \ref BT_SendPacket_ErrorCodes_t enum
*/
-uint8_t Bluetooth_SendPacket(void* Data, const uint16_t DataLen, Bluetooth_Channel_t* const ACLChannel)
+uint8_t Bluetooth_SendPacket(void* Data,
+ const uint16_t DataLen,
+ Bluetooth_Channel_t* const ACLChannel)
{
BT_ACL_Header_t ACLPacketHeader;
BT_DataPacket_Header_t DataHeader;
diff --git a/Demos/Host/Incomplete/BluetoothHost/Lib/BluetoothHCICommands.c b/Demos/Host/Incomplete/BluetoothHost/Lib/BluetoothHCICommands.c
index 0db17a263..7f6f8b78d 100644
--- a/Demos/Host/Incomplete/BluetoothHost/Lib/BluetoothHCICommands.c
+++ b/Demos/Host/Incomplete/BluetoothHost/Lib/BluetoothHCICommands.c
@@ -374,7 +374,9 @@ void Bluetooth_HCITask(void)
*
* \return A value from the USB_Host_SendControlErrorCodes_t enum.
*/
-static uint8_t Bluetooth_SendHCICommand(const BT_HCICommand_Header_t* const HCICommandHeader, const void* Parameters, const uint16_t ParameterLength)
+static uint8_t Bluetooth_SendHCICommand(const BT_HCICommand_Header_t* const HCICommandHeader,
+ const void* Parameters,
+ const uint16_t ParameterLength)
{
/* Need to reserve the amount of bytes given in the header for the complete payload */
uint8_t CommandBuffer[sizeof(BT_HCICommand_Header_t) + HCICommandHeader->ParameterLength];
diff --git a/Demos/Host/Incomplete/BluetoothHost/Lib/BluetoothHCICommands.h b/Demos/Host/Incomplete/BluetoothHost/Lib/BluetoothHCICommands.h
index 5a556e114..9476446f6 100644
--- a/Demos/Host/Incomplete/BluetoothHost/Lib/BluetoothHCICommands.h
+++ b/Demos/Host/Incomplete/BluetoothHost/Lib/BluetoothHCICommands.h
@@ -204,7 +204,8 @@
void Bluetooth_HCITask(void);
#if defined(INCLUDE_FROM_BLUETOOTHHCICOMMANDS_C)
- static uint8_t Bluetooth_SendHCICommand(const BT_HCICommand_Header_t* const HCICommandHeader, const void* Parameters,
+ static uint8_t Bluetooth_SendHCICommand(const BT_HCICommand_Header_t* const HCICommandHeader,
+ const void* Parameters,
const uint16_t ParameterLength);
#endif
diff --git a/Demos/Host/Incomplete/BluetoothHost/Lib/BluetoothStack.h b/Demos/Host/Incomplete/BluetoothHost/Lib/BluetoothStack.h
index f47bf1e0a..6f1ea6742 100644
--- a/Demos/Host/Incomplete/BluetoothHost/Lib/BluetoothStack.h
+++ b/Demos/Host/Incomplete/BluetoothHost/Lib/BluetoothStack.h
@@ -155,13 +155,17 @@
void Bluetooth_ConnectionComplete(void);
void Bluetooth_DisconnectionComplete(void);
bool Bluetooth_ChannelConnectionRequest(const uint16_t PSM);
- void Bluetooth_PacketReceived(void* Data, uint16_t DataLen, Bluetooth_Channel_t* const ACLChannel);
+ void Bluetooth_PacketReceived(void* Data, uint16_t DataLen,
+ Bluetooth_Channel_t* const ACLChannel);
void Bluetooth_ChannelOpened(Bluetooth_Channel_t* const ACLChannel);
- Bluetooth_Channel_t* Bluetooth_GetChannelData(const uint16_t SearchValue, const uint8_t SearchKey);
+ Bluetooth_Channel_t* Bluetooth_GetChannelData(const uint16_t SearchValue,
+ const uint8_t SearchKey);
Bluetooth_Channel_t* Bluetooth_OpenChannel(const uint16_t PSM);
void Bluetooth_CloseChannel(Bluetooth_Channel_t* const ACLChannel);
- uint8_t Bluetooth_SendPacket(void* Data, uint16_t DataLen, Bluetooth_Channel_t* const ACLChannel);
+ uint8_t Bluetooth_SendPacket(void* Data,
+ uint16_t DataLen,
+ Bluetooth_Channel_t* const ACLChannel);
/* External Variables: */
extern Bluetooth_Device_t Bluetooth_DeviceConfiguration;
diff --git a/Demos/Host/Incomplete/BluetoothHost/Lib/RFCOMM.c b/Demos/Host/Incomplete/BluetoothHost/Lib/RFCOMM.c
index d091676aa..f74002a07 100644
--- a/Demos/Host/Incomplete/BluetoothHost/Lib/RFCOMM.c
+++ b/Demos/Host/Incomplete/BluetoothHost/Lib/RFCOMM.c
@@ -118,7 +118,8 @@ void RFCOMM_ServiceChannels(Bluetooth_Channel_t* const ACLChannel)
* \param[in] Data Incoming packet data containing the RFCOMM packet
* \param[in] ACLChannel ACL channel the request was issued to by the remote device
*/
-void RFCOMM_ProcessPacket(void* Data, Bluetooth_Channel_t* const ACLChannel)
+void RFCOMM_ProcessPacket(void* Data,
+ Bluetooth_Channel_t* const ACLChannel)
{
const RFCOMM_Header_t* FrameHeader = (const RFCOMM_Header_t*)Data;
const uint8_t* FrameData = (const uint8_t*)Data + sizeof(RFCOMM_Header_t);
@@ -154,7 +155,8 @@ void RFCOMM_ProcessPacket(void* Data, Bluetooth_Channel_t* const ACLChannel)
* \param[in] RFCOMMChannel RFCOMM logical channel whose local terminal signals have changed
* \param[in] ACLChannel ACL channel which has been opened to carry RFCOMM traffic between devices
*/
-void RFCOMM_SendChannelSignals(const RFCOMM_Channel_t* const RFCOMMChannel, Bluetooth_Channel_t* const ACLChannel)
+void RFCOMM_SendChannelSignals(const RFCOMM_Channel_t* const RFCOMMChannel,
+ Bluetooth_Channel_t* const ACLChannel)
{
BT_RFCOMM_DEBUG(1, ">> MSC Command");
BT_RFCOMM_DEBUG(2, "-- DLCI 0x%02X", RFCOMMChannel->DLCI);
@@ -184,7 +186,9 @@ void RFCOMM_SendChannelSignals(const RFCOMM_Channel_t* const RFCOMMChannel, Blue
* \param[in] RFCOMMChannel RFCOMM logical channel which is to be transmitted to
* \param[in] ACLChannel ACL channel which has been opened to carry RFCOMM traffic between devices
*/
-void RFCOMM_SendData(const uint16_t DataLen, const uint8_t* Data, const RFCOMM_Channel_t* const RFCOMMChannel,
+void RFCOMM_SendData(const uint16_t DataLen,
+ const uint8_t* Data,
+ const RFCOMM_Channel_t* const RFCOMMChannel,
Bluetooth_Channel_t* const ACLChannel)
{
if (RFCOMMChannel->State != RFCOMM_Channel_Open)
@@ -263,8 +267,12 @@ uint16_t RFCOMM_GetVariableFieldValue(const uint8_t** BufferPos)
return (((uint16_t)SecondOctet << 7) | FirstOctet >> 1);
}
-void RFCOMM_SendFrame(const uint8_t DLCI, const bool CommandResponse, const uint8_t Control, const uint16_t DataLen,
- const void* Data, Bluetooth_Channel_t* const ACLChannel)
+void RFCOMM_SendFrame(const uint8_t DLCI,
+ const bool CommandResponse,
+ const uint8_t Control,
+ const uint16_t DataLen,
+ const void* Data,
+ Bluetooth_Channel_t* const ACLChannel)
{
struct
{
@@ -304,7 +312,8 @@ void RFCOMM_SendFrame(const uint8_t DLCI, const bool CommandResponse, const uint
Bluetooth_SendPacket(&ResponsePacket, sizeof(ResponsePacket), ACLChannel);
}
-static uint8_t RFCOMM_GetFCSValue(const void* FrameStart, uint8_t Length)
+static uint8_t RFCOMM_GetFCSValue(const void* FrameStart,
+ uint8_t Length)
{
uint8_t FCS = 0xFF;
@@ -315,13 +324,15 @@ static uint8_t RFCOMM_GetFCSValue(const void* FrameStart, uint8_t Length)
return ~FCS;
}
-static void RFCOMM_ProcessDM(const RFCOMM_Address_t* const FrameAddress, Bluetooth_Channel_t* const ACLChannel)
+static void RFCOMM_ProcessDM(const RFCOMM_Address_t* const FrameAddress,
+ Bluetooth_Channel_t* const ACLChannel)
{
BT_RFCOMM_DEBUG(1, "<< DM Received");
BT_RFCOMM_DEBUG(2, "-- DLCI 0x%02X", FrameAddress->DLCI);
}
-static void RFCOMM_ProcessDISC(const RFCOMM_Address_t* const FrameAddress, Bluetooth_Channel_t* const ACLChannel)
+static void RFCOMM_ProcessDISC(const RFCOMM_Address_t* const FrameAddress,
+ Bluetooth_Channel_t* const ACLChannel)
{
BT_RFCOMM_DEBUG(1, "<< DISC Received");
BT_RFCOMM_DEBUG(2, "-- DLCI 0x%02X", FrameAddress->DLCI);
@@ -336,7 +347,8 @@ static void RFCOMM_ProcessDISC(const RFCOMM_Address_t* const FrameAddress, Bluet
RFCOMM_SendFrame(FrameAddress->DLCI, true, (RFCOMM_Frame_UA | FRAME_POLL_FINAL), 0, NULL, ACLChannel);
}
-static void RFCOMM_ProcessSABM(const RFCOMM_Address_t* const FrameAddress, Bluetooth_Channel_t* const ACLChannel)
+static void RFCOMM_ProcessSABM(const RFCOMM_Address_t* const FrameAddress,
+ Bluetooth_Channel_t* const ACLChannel)
{
BT_RFCOMM_DEBUG(1, "<< SABM Received");
BT_RFCOMM_DEBUG(2, "-- DLCI 0x%02X", FrameAddress->DLCI);
@@ -375,14 +387,17 @@ static void RFCOMM_ProcessSABM(const RFCOMM_Address_t* const FrameAddress, Bluet
}
}
-static void RFCOMM_ProcessUA(const RFCOMM_Address_t* const FrameAddress, Bluetooth_Channel_t* const ACLChannel)
+static void RFCOMM_ProcessUA(const RFCOMM_Address_t* const FrameAddress,
+ Bluetooth_Channel_t* const ACLChannel)
{
BT_RFCOMM_DEBUG(1, "<< UA Received");
BT_RFCOMM_DEBUG(2, "-- DLCI 0x%02X", FrameAddress->DLCI);
}
-static void RFCOMM_ProcessUIH(const RFCOMM_Address_t* const FrameAddress, const uint16_t FrameLength,
- const uint8_t* FrameData, Bluetooth_Channel_t* const ACLChannel)
+static void RFCOMM_ProcessUIH(const RFCOMM_Address_t* const FrameAddress,
+ const uint16_t FrameLength,
+ const uint8_t* FrameData,
+ Bluetooth_Channel_t* const ACLChannel)
{
if (FrameAddress->DLCI == RFCOMM_CONTROL_DLCI)
{
diff --git a/Demos/Host/Incomplete/BluetoothHost/Lib/RFCOMM.h b/Demos/Host/Incomplete/BluetoothHost/Lib/RFCOMM.h
index 5d22e3825..7b74f4fab 100644
--- a/Demos/Host/Incomplete/BluetoothHost/Lib/RFCOMM.h
+++ b/Demos/Host/Incomplete/BluetoothHost/Lib/RFCOMM.h
@@ -102,33 +102,48 @@
/* Function Prototypes: */
void RFCOMM_Initialize(void);
void RFCOMM_ServiceChannels(Bluetooth_Channel_t* const ACLChannel);
- void RFCOMM_ProcessPacket(void* Data, Bluetooth_Channel_t* const ACLChannel);
+ void RFCOMM_ProcessPacket(void* Data,
+ Bluetooth_Channel_t* const ACLChannel);
void RFCOMM_SendChannelSignals(const RFCOMM_Channel_t* const RFCOMMChannel,
Bluetooth_Channel_t* const ACLChannel);
- void RFCOMM_SendData(const uint16_t DataLen, const uint8_t* Data,
+ void RFCOMM_SendData(const uint16_t DataLen,
+ const uint8_t* Data,
const RFCOMM_Channel_t* const RFCOMMChannel,
Bluetooth_Channel_t* const ACLChannel);
void RFCOMM_ChannelOpened(RFCOMM_Channel_t* const RFCOMMChannel);
- void RFCOMM_DataReceived(RFCOMM_Channel_t* const RFCOMMChannel, uint16_t DataLen, const uint8_t* Data);
+ void RFCOMM_DataReceived(RFCOMM_Channel_t* const RFCOMMChannel,
+ uint16_t DataLen,
+ const uint8_t* Data);
void RFCOMM_ChannelSignalsReceived(RFCOMM_Channel_t* const RFCOMMChannel);
RFCOMM_Channel_t* RFCOMM_GetFreeChannelEntry(const uint8_t DLCI);
RFCOMM_Channel_t* RFCOMM_GetChannelData(const uint8_t DLCI);
uint16_t RFCOMM_GetVariableFieldValue(const uint8_t** BufferPos);
- void RFCOMM_SendFrame(const uint8_t DLCI, const bool CommandResponse, const uint8_t Control,
- const uint16_t DataLen, const void* Data, Bluetooth_Channel_t* const ACLChannel);
+ void RFCOMM_SendFrame(const uint8_t DLCI,
+ const bool CommandResponse,
+ const uint8_t Control,
+ const uint16_t DataLen,
+ const void* Data,
+ Bluetooth_Channel_t* const ACLChannel);
#if defined(INCLUDE_FROM_RFCOMM_C)
- static uint8_t RFCOMM_GetFCSValue(const void* FrameStart, uint8_t Length);
+ static uint8_t RFCOMM_GetFCSValue(const void* FrameStart,
+ uint8_t Length);
- static void RFCOMM_ProcessDM(const RFCOMM_Address_t* const FrameAddress, Bluetooth_Channel_t* const ACLChannel);
- static void RFCOMM_ProcessDISC(const RFCOMM_Address_t* const FrameAddress, Bluetooth_Channel_t* const ACLChannel);
- static void RFCOMM_ProcessSABM(const RFCOMM_Address_t* const FrameAddress, Bluetooth_Channel_t* const ACLChannel);
- static void RFCOMM_ProcessUA(const RFCOMM_Address_t* const FrameAddress, Bluetooth_Channel_t* const ACLChannel);
- static void RFCOMM_ProcessUIH(const RFCOMM_Address_t* const FrameAddress, const uint16_t FrameLength,
- const uint8_t* FrameData, Bluetooth_Channel_t* const ACLChannel);
+ static void RFCOMM_ProcessDM(const RFCOMM_Address_t* const FrameAddress,
+ Bluetooth_Channel_t* const ACLChannel);
+ static void RFCOMM_ProcessDISC(const RFCOMM_Address_t* const FrameAddress,
+ Bluetooth_Channel_t* const ACLChannel);
+ static void RFCOMM_ProcessSABM(const RFCOMM_Address_t* const FrameAddress,
+ Bluetooth_Channel_t* const ACLChannel);
+ static void RFCOMM_ProcessUA(const RFCOMM_Address_t* const FrameAddress,
+ Bluetooth_Channel_t* const ACLChannel);
+ static void RFCOMM_ProcessUIH(const RFCOMM_Address_t* const FrameAddress,
+ const uint16_t FrameLength,
+ const uint8_t* FrameData,
+ Bluetooth_Channel_t* const ACLChannel);
#endif
#endif
diff --git a/Demos/Host/Incomplete/BluetoothHost/Lib/RFCOMMControl.c b/Demos/Host/Incomplete/BluetoothHost/Lib/RFCOMMControl.c
index 0f829eab5..5bd884572 100644
--- a/Demos/Host/Incomplete/BluetoothHost/Lib/RFCOMMControl.c
+++ b/Demos/Host/Incomplete/BluetoothHost/Lib/RFCOMMControl.c
@@ -38,7 +38,8 @@
#define INCLUDE_FROM_RFCOMM_CONTROL_C
#include "RFCOMMControl.h"
-void RFCOMM_ProcessControlCommand(const uint8_t* Command, Bluetooth_Channel_t* const ACLChannel)
+void RFCOMM_ProcessControlCommand(const uint8_t* Command,
+ Bluetooth_Channel_t* const ACLChannel)
{
const RFCOMM_Command_t* CommandHeader = (const RFCOMM_Command_t*)Command;
const uint8_t* CommandData = (const uint8_t*)Command + sizeof(RFCOMM_Command_t);
@@ -73,8 +74,10 @@ void RFCOMM_ProcessControlCommand(const uint8_t* Command, Bluetooth_Channel_t* c
}
}
-static void RFCOMM_ProcessTestCommand(const RFCOMM_Command_t* const CommandHeader, const uint8_t CommandDataLen,
- const uint8_t* CommandData, Bluetooth_Channel_t* const ACLChannel)
+static void RFCOMM_ProcessTestCommand(const RFCOMM_Command_t* const CommandHeader,
+ const uint8_t CommandDataLen,
+ const uint8_t* CommandData,
+ Bluetooth_Channel_t* const ACLChannel)
{
const uint8_t* Params = (const uint8_t*)CommandData;
@@ -98,20 +101,24 @@ static void RFCOMM_ProcessTestCommand(const RFCOMM_Command_t* const CommandHeade
RFCOMM_SendFrame(RFCOMM_CONTROL_DLCI, false, RFCOMM_Frame_UIH, sizeof(TestResponse), &TestResponse, ACLChannel);
}
-static void RFCOMM_ProcessFCECommand(const RFCOMM_Command_t* const CommandHeader, const uint8_t* CommandData,
+static void RFCOMM_ProcessFCECommand(const RFCOMM_Command_t* const CommandHeader,
+ const uint8_t* CommandData,
Bluetooth_Channel_t* const ACLChannel)
{
BT_RFCOMM_DEBUG(1, "<< FCE Command");
}
-static void RFCOMM_ProcessFCDCommand(const RFCOMM_Command_t* const CommandHeader, const uint8_t* CommandData,
+static void RFCOMM_ProcessFCDCommand(const RFCOMM_Command_t* const CommandHeader,
+ const uint8_t* CommandData,
Bluetooth_Channel_t* const ACLChannel)
{
BT_RFCOMM_DEBUG(1, "<< FCD Command");
}
-static void RFCOMM_ProcessMSCCommand(const RFCOMM_Command_t* const CommandHeader, const uint8_t CommandDataLen,
- const uint8_t* CommandData, Bluetooth_Channel_t* const ACLChannel)
+static void RFCOMM_ProcessMSCCommand(const RFCOMM_Command_t* const CommandHeader,
+ const uint8_t CommandDataLen,
+ const uint8_t* CommandData,
+ Bluetooth_Channel_t* const ACLChannel)
{
const RFCOMM_MSC_Parameters_t* Params = (const RFCOMM_MSC_Parameters_t*)CommandData;
@@ -168,19 +175,22 @@ static void RFCOMM_ProcessMSCCommand(const RFCOMM_Command_t* const CommandHeader
}
}
-static void RFCOMM_ProcessRPNCommand(const RFCOMM_Command_t* const CommandHeader, const uint8_t* CommandData,
+static void RFCOMM_ProcessRPNCommand(const RFCOMM_Command_t* const CommandHeader,
+ const uint8_t* CommandData,
Bluetooth_Channel_t* const ACLChannel)
{
BT_RFCOMM_DEBUG(1, "<< RPN Command");
}
-static void RFCOMM_ProcessRLSCommand(const RFCOMM_Command_t* const CommandHeader, const uint8_t* CommandData,
+static void RFCOMM_ProcessRLSCommand(const RFCOMM_Command_t* const CommandHeader,
+ const uint8_t* CommandData,
Bluetooth_Channel_t* const ACLChannel)
{
BT_RFCOMM_DEBUG(1, "<< RLS Command");
}
-static void RFCOMM_ProcessDPNCommand(const RFCOMM_Command_t* const CommandHeader, const uint8_t* CommandData,
+static void RFCOMM_ProcessDPNCommand(const RFCOMM_Command_t* const CommandHeader,
+ const uint8_t* CommandData,
Bluetooth_Channel_t* const ACLChannel)
{
const RFCOMM_DPN_Parameters_t* Params = (const RFCOMM_DPN_Parameters_t*)CommandData;
diff --git a/Demos/Host/Incomplete/BluetoothHost/Lib/RFCOMMControl.h b/Demos/Host/Incomplete/BluetoothHost/Lib/RFCOMMControl.h
index d47715f80..b527bfa7c 100644
--- a/Demos/Host/Incomplete/BluetoothHost/Lib/RFCOMMControl.h
+++ b/Demos/Host/Incomplete/BluetoothHost/Lib/RFCOMMControl.h
@@ -115,22 +115,32 @@
} RFCOMM_MSC_Parameters_t;
/* Function Prototypes: */
- void RFCOMM_ProcessControlCommand(const uint8_t* Command, Bluetooth_Channel_t* const Channel);
+ void RFCOMM_ProcessControlCommand(const uint8_t* Command,
+ Bluetooth_Channel_t* const Channel);
#if defined(INCLUDE_FROM_RFCOMM_CONTROL_C)
- static void RFCOMM_ProcessTestCommand(const RFCOMM_Command_t* const CommandHeader, const uint8_t CommandDataLen,
- const uint8_t* CommandData, Bluetooth_Channel_t* const ACLChannel);
- static void RFCOMM_ProcessFCECommand(const RFCOMM_Command_t* const CommandHeader, const uint8_t* CommandData,
+ static void RFCOMM_ProcessTestCommand(const RFCOMM_Command_t* const CommandHeader,
+ const uint8_t CommandDataLen,
+ const uint8_t* CommandData,
+ Bluetooth_Channel_t* const ACLChannel);
+ static void RFCOMM_ProcessFCECommand(const RFCOMM_Command_t* const CommandHeader,
+ const uint8_t* CommandData,
Bluetooth_Channel_t* const ACLChannel);
- static void RFCOMM_ProcessFCDCommand(const RFCOMM_Command_t* const CommandHeader, const uint8_t* CommandData,
+ static void RFCOMM_ProcessFCDCommand(const RFCOMM_Command_t* const CommandHeader,
+ const uint8_t* CommandData,
Bluetooth_Channel_t* const ACLChannel);
- static void RFCOMM_ProcessMSCCommand(const RFCOMM_Command_t* const CommandHeader, const uint8_t CommandDataLen,
- const uint8_t* CommandData, Bluetooth_Channel_t* const ACLChannel);
- static void RFCOMM_ProcessRPNCommand(const RFCOMM_Command_t* const CommandHeader, const uint8_t* CommandData,
+ static void RFCOMM_ProcessMSCCommand(const RFCOMM_Command_t* const CommandHeader,
+ const uint8_t CommandDataLen,
+ const uint8_t* CommandData,
Bluetooth_Channel_t* const ACLChannel);
- static void RFCOMM_ProcessRLSCommand(const RFCOMM_Command_t* const CommandHeader, const uint8_t* CommandData,
+ static void RFCOMM_ProcessRPNCommand(const RFCOMM_Command_t* const CommandHeader,
+ const uint8_t* CommandData,
Bluetooth_Channel_t* const ACLChannel);
- static void RFCOMM_ProcessDPNCommand(const RFCOMM_Command_t* const CommandHeader, const uint8_t* CommandData,
+ static void RFCOMM_ProcessRLSCommand(const RFCOMM_Command_t* const CommandHeader,
+ const uint8_t* CommandData,
+ Bluetooth_Channel_t* const ACLChannel);
+ static void RFCOMM_ProcessDPNCommand(const RFCOMM_Command_t* const CommandHeader,
+ const uint8_t* CommandData,
Bluetooth_Channel_t* const ACLChannel);
#endif
diff --git a/Demos/Host/Incomplete/BluetoothHost/Lib/SDP.c b/Demos/Host/Incomplete/BluetoothHost/Lib/SDP.c
index eb501f709..e0522f994 100644
--- a/Demos/Host/Incomplete/BluetoothHost/Lib/SDP.c
+++ b/Demos/Host/Incomplete/BluetoothHost/Lib/SDP.c
@@ -88,7 +88,8 @@ void SDP_ProcessPacket(void* Data, Bluetooth_Channel_t* const Channel)
* \param[in] SDPHeader Pointer to the start of the issued SDP request
* \param[in] Channel Pointer to the Bluetooth channel structure the request was issued to
*/
-static void SDP_ProcessServiceSearch(const SDP_PDUHeader_t* const SDPHeader, Bluetooth_Channel_t* const Channel)
+static void SDP_ProcessServiceSearch(const SDP_PDUHeader_t* const SDPHeader,
+ Bluetooth_Channel_t* const Channel)
{
const void* CurrentParameter = ((const void*)SDPHeader + sizeof(SDP_PDUHeader_t));
@@ -169,7 +170,8 @@ static void SDP_ProcessServiceSearch(const SDP_PDUHeader_t* const SDPHeader, Blu
* \param[in] SDPHeader Pointer to the start of the issued SDP request
* \param[in] Channel Pointer to the Bluetooth channel structure the request was issued to
*/
-static void SDP_ProcessServiceAttribute(const SDP_PDUHeader_t* const SDPHeader, Bluetooth_Channel_t* const Channel)
+static void SDP_ProcessServiceAttribute(const SDP_PDUHeader_t* const SDPHeader,
+ Bluetooth_Channel_t* const Channel)
{
const void* CurrentParameter = ((const void*)SDPHeader + sizeof(SDP_PDUHeader_t));
@@ -259,7 +261,8 @@ static void SDP_ProcessServiceAttribute(const SDP_PDUHeader_t* const SDPHeader,
* \param[in] SDPHeader Pointer to the start of the issued SDP request
* \param[in] Channel Pointer to the Bluetooth channel structure the request was issued to
*/
-static void SDP_ProcessServiceSearchAttribute(const SDP_PDUHeader_t* const SDPHeader, Bluetooth_Channel_t* const Channel)
+static void SDP_ProcessServiceSearchAttribute(const SDP_PDUHeader_t* const SDPHeader,
+ Bluetooth_Channel_t* const Channel)
{
const void* CurrentParameter = ((const void*)SDPHeader + sizeof(SDP_PDUHeader_t));
@@ -348,8 +351,10 @@ static void SDP_ProcessServiceSearchAttribute(const SDP_PDUHeader_t* const SDPHe
*
* \return Number of bytes added to the output buffer
*/
-static uint16_t SDP_AddListedAttributesToResponse(const ServiceAttributeTable_t* AttributeTable, uint16_t AttributeList[][2],
- const uint8_t TotalAttributes, void** const BufferPos)
+static uint16_t SDP_AddListedAttributesToResponse(const ServiceAttributeTable_t* AttributeTable,
+ uint16_t AttributeList[][2],
+ const uint8_t TotalAttributes,
+ void** const BufferPos)
{
uint16_t TotalResponseSize;
@@ -396,7 +401,9 @@ static uint16_t SDP_AddListedAttributesToResponse(const ServiceAttributeTable_t*
*
* \return Number of bytes added to the response buffer
*/
-static uint16_t SDP_AddAttributeToResponse(const uint16_t AttributeID, const void* AttributeValue, void** ResponseBuffer)
+static uint16_t SDP_AddAttributeToResponse(const uint16_t AttributeID,
+ const void* AttributeValue,
+ void** ResponseBuffer)
{
/* Retrieve the size of the attribute value from its container header */
uint8_t AttributeHeaderLength;
@@ -424,7 +431,8 @@ static uint16_t SDP_AddAttributeToResponse(const uint16_t AttributeID, const voi
*
* \return Pointer to the start of the Attribute's value if found within the table, NULL otherwise
*/
-static void* SDP_GetAttributeValue(const ServiceAttributeTable_t* AttributeTable, const uint16_t AttributeID)
+static void* SDP_GetAttributeValue(const ServiceAttributeTable_t* AttributeTable,
+ const uint16_t AttributeID)
{
void* CurrTableItemData;
@@ -449,7 +457,8 @@ static void* SDP_GetAttributeValue(const ServiceAttributeTable_t* AttributeTable
*
* \return True if all the UUIDs given in the UUID list appear in the given attribute table, false otherwise
*/
-static bool SDP_SearchServiceTable(uint8_t UUIDList[][UUID_SIZE_BYTES], const uint8_t TotalUUIDs,
+static bool SDP_SearchServiceTable(uint8_t UUIDList[][UUID_SIZE_BYTES],
+ const uint8_t TotalUUIDs,
const ServiceAttributeTable_t* CurrAttributeTable)
{
const void* CurrAttribute;
@@ -481,8 +490,10 @@ static bool SDP_SearchServiceTable(uint8_t UUIDList[][UUID_SIZE_BYTES], const ui
*
* \return True if all the UUIDs given in the UUID list appear in the given attribute table, false otherwise
*/
-static void SDP_CheckUUIDMatch(uint8_t UUIDList[][UUID_SIZE_BYTES], const uint8_t TotalUUIDs,
- uint16_t* const UUIDMatchFlags, const void* CurrAttribute)
+static void SDP_CheckUUIDMatch(uint8_t UUIDList[][UUID_SIZE_BYTES],
+ const uint8_t TotalUUIDs,
+ uint16_t* const UUIDMatchFlags,
+ const void* CurrAttribute)
{
uint8_t CurrAttributeType = (pgm_read_byte(CurrAttribute) & ~0x07);
@@ -536,7 +547,8 @@ static void SDP_CheckUUIDMatch(uint8_t UUIDList[][UUID_SIZE_BYTES], const uint8_
*
* \return Total number of Attribute ranges stored in the Data Element Sequence
*/
-static uint8_t SDP_GetAttributeList(uint16_t AttributeList[][2], const void** const CurrentParameter)
+static uint8_t SDP_GetAttributeList(uint16_t AttributeList[][2],
+ const void** const CurrentParameter)
{
uint8_t ElementHeaderSize;
uint8_t TotalAttributes = 0;
@@ -578,7 +590,8 @@ static uint8_t SDP_GetAttributeList(uint16_t AttributeList[][2], const void** co
*
* \return Total number of UUIDs stored in the Data Element Sequence
*/
-static uint8_t SDP_GetUUIDList(uint8_t UUIDList[][UUID_SIZE_BYTES], const void** const CurrentParameter)
+static uint8_t SDP_GetUUIDList(uint8_t UUIDList[][UUID_SIZE_BYTES],
+ const void** const CurrentParameter)
{
uint8_t ElementHeaderSize;
uint8_t TotalUUIDs = 0;
@@ -629,7 +642,8 @@ static uint8_t SDP_GetUUIDList(uint8_t UUIDList[][UUID_SIZE_BYTES], const void**
*
* \return Size in bytes of the entire attribute container, including the header
*/
-static uint32_t SDP_GetLocalAttributeContainerSize(const void* const AttributeData, uint8_t* const HeaderSize)
+static uint32_t SDP_GetLocalAttributeContainerSize(const void* const AttributeData,
+ uint8_t* const HeaderSize)
{
/* Fetch the size of the Data Element structure from the header */
uint8_t SizeIndex = (pgm_read_byte(AttributeData) & 0x07);
@@ -668,7 +682,8 @@ static uint32_t SDP_GetLocalAttributeContainerSize(const void* const AttributeDa
*
* \return Size in bytes of the Data Element container's contents, minus the header
*/
-static uint32_t SDP_GetDataElementSize(const void** const DataElementHeader, uint8_t* const ElementHeaderSize)
+static uint32_t SDP_GetDataElementSize(const void** const DataElementHeader,
+ uint8_t* const ElementHeaderSize)
{
/* Fetch the size of the Data Element structure from the header, increment the current buffer pos */
uint8_t SizeIndex = (SDP_ReadData8(DataElementHeader) & 0x07);
diff --git a/Demos/Host/Incomplete/BluetoothHost/Lib/SDP.h b/Demos/Host/Incomplete/BluetoothHost/Lib/SDP.h
index 548f3d557..2df8c225d 100644
--- a/Demos/Host/Incomplete/BluetoothHost/Lib/SDP.h
+++ b/Demos/Host/Incomplete/BluetoothHost/Lib/SDP.h
@@ -110,7 +110,8 @@
* \param[in, out] BufferPos Current position in the buffer where the data is to be written to
* \param[in] Data Data to write to the buffer
*/
- static inline void SDP_WriteData8(void** BufferPos, uint8_t Data)
+ static inline void SDP_WriteData8(void** BufferPos,
+ const uint8_t Data)
{
*((uint8_t*)*BufferPos) = Data;
*BufferPos += sizeof(uint8_t);
@@ -121,7 +122,8 @@
* \param[in, out] BufferPos Current position in the buffer where the data is to be written to
* \param[in] Data Data to write to the buffer
*/
- static inline void SDP_WriteData16(void** BufferPos, uint16_t Data)
+ static inline void SDP_WriteData16(void** BufferPos,
+ const uint16_t Data)
{
*((uint16_t*)*BufferPos) = SwapEndian_16(Data);
*BufferPos += sizeof(uint16_t);
@@ -132,7 +134,8 @@
* \param[in, out] BufferPos Current position in the buffer where the data is to be written to
* \param[in] Data Data to write to the buffer
*/
- static inline void SDP_WriteData32(void** BufferPos, uint32_t Data)
+ static inline void SDP_WriteData32(void** BufferPos,
+ const uint32_t Data)
{
*((uint32_t*)*BufferPos) = SwapEndian_32(Data);
*BufferPos += sizeof(uint32_t);
@@ -203,28 +206,44 @@
}
/* Function Prototypes: */
- void SDP_ProcessPacket(void* Data, Bluetooth_Channel_t* const Channel);
+ void SDP_ProcessPacket(void* Data,
+ Bluetooth_Channel_t* const Channel);
#if defined(INCLUDE_FROM_SERVICEDISCOVERYPROTOCOL_C)
- static void SDP_ProcessServiceSearch(const SDP_PDUHeader_t* const SDPHeader, Bluetooth_Channel_t* const Channel);
- static void SDP_ProcessServiceAttribute(const SDP_PDUHeader_t* const SDPHeader, Bluetooth_Channel_t* const Channel);
- static void SDP_ProcessServiceSearchAttribute(const SDP_PDUHeader_t* const SDPHeader, Bluetooth_Channel_t* const Channel);
-
- static uint16_t SDP_AddListedAttributesToResponse(const ServiceAttributeTable_t* AttributeTable, uint16_t AttributeList[][2],
- const uint8_t TotalAttributes, void** const BufferPos);
- static uint16_t SDP_AddAttributeToResponse(const uint16_t AttributeID, const void* AttributeValue, void** ResponseBuffer);
- static void* SDP_GetAttributeValue(const ServiceAttributeTable_t* AttributeTable, const uint16_t AttributeID);
-
- static bool SDP_SearchServiceTable(uint8_t UUIDList[][UUID_SIZE_BYTES], const uint8_t TotalUUIDs,
+ static void SDP_ProcessServiceSearch(const SDP_PDUHeader_t* const SDPHeader,
+ Bluetooth_Channel_t* const Channel);
+ static void SDP_ProcessServiceAttribute(const SDP_PDUHeader_t* const SDPHeader,
+ Bluetooth_Channel_t* const Channel);
+ static void SDP_ProcessServiceSearchAttribute(const SDP_PDUHeader_t* const SDPHeader,
+ Bluetooth_Channel_t* const Channel);
+
+ static uint16_t SDP_AddListedAttributesToResponse(const ServiceAttributeTable_t* AttributeTable,
+ uint16_t AttributeList[][2],
+ const uint8_t TotalAttributes,
+ void** const BufferPos);
+ static uint16_t SDP_AddAttributeToResponse(const uint16_t AttributeID,
+ const void* AttributeValue,
+ void** ResponseBuffer);
+ static void* SDP_GetAttributeValue(const ServiceAttributeTable_t* AttributeTable,
+ const uint16_t AttributeID);
+
+ static bool SDP_SearchServiceTable(uint8_t UUIDList[][UUID_SIZE_BYTES],
+ const uint8_t TotalUUIDs,
const ServiceAttributeTable_t* CurrAttributeTable);
- static void SDP_CheckUUIDMatch(uint8_t UUIDList[][UUID_SIZE_BYTES], const uint8_t TotalUUIDs,
- uint16_t* const UUIDMatchFlags, const void* CurrAttribute);
-
- static uint8_t SDP_GetAttributeList(uint16_t AttributeList[][2], const void** const CurrentParameter);
- static uint8_t SDP_GetUUIDList(uint8_t UUIDList[][UUID_SIZE_BYTES], const void** const CurrentParameter);
-
- static uint32_t SDP_GetLocalAttributeContainerSize(const void* const AttributeData, uint8_t* const HeaderSize);
- static uint32_t SDP_GetDataElementSize(const void** const AttributeHeader, uint8_t* const ElementHeaderSize);
+ static void SDP_CheckUUIDMatch(uint8_t UUIDList[][UUID_SIZE_BYTES],
+ const uint8_t TotalUUIDs,
+ uint16_t* const UUIDMatchFlags,
+ const void* CurrAttribute);
+
+ static uint8_t SDP_GetAttributeList(uint16_t AttributeList[][2],
+ const void** const CurrentParameter);
+ static uint8_t SDP_GetUUIDList(uint8_t UUIDList[][UUID_SIZE_BYTES],
+ const void** const CurrentParameter);
+
+ static uint32_t SDP_GetLocalAttributeContainerSize(const void* const AttributeData,
+ uint8_t* const HeaderSize);
+ static uint32_t SDP_GetDataElementSize(const void** const AttributeHeader,
+ uint8_t* const ElementHeaderSize);
#endif
#endif
diff --git a/Demos/Host/LowLevel/GenericHIDHost/GenericHIDHost.c b/Demos/Host/LowLevel/GenericHIDHost/GenericHIDHost.c
index f477ac276..66a5b8e7e 100644
--- a/Demos/Host/LowLevel/GenericHIDHost/GenericHIDHost.c
+++ b/Demos/Host/LowLevel/GenericHIDHost/GenericHIDHost.c
@@ -112,7 +112,8 @@ void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
/** Event handler for the USB_DeviceEnumerationFailed event. This indicates that a problem occurred while
* enumerating an attached USB device.
*/
-void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode)
+void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode)
{
printf_P(PSTR(ESC_FG_RED "Dev Enum Error\r\n"
" -- Error Code %d\r\n"
@@ -165,11 +166,14 @@ void ReadNextReport(void)
/** Writes a report to the attached device.
*
* \param[in] ReportOUTData Buffer containing the report to send to the device
- * \param[in] ReportIndex Index of the report in the device (zero if the device does not use multiple reports)
- * \param[in] ReportType Type of report to send, either REPORT_TYPE_OUT or REPORT_TYPE_FEATURE
- * \param[in] ReportLength Length of the report to send
+ * \param[in] ReportIndex Index of the report in the device (zero if the device does not use multiple reports)
+ * \param[in] ReportType Type of report to send, either REPORT_TYPE_OUT or REPORT_TYPE_FEATURE
+ * \param[in] ReportLength Length of the report to send
*/
-void WriteNextReport(uint8_t* ReportOUTData, uint8_t ReportIndex, uint8_t ReportType, uint16_t ReportLength)
+void WriteNextReport(uint8_t* ReportOUTData,
+ const uint8_t ReportIndex,
+ const uint8_t ReportType,
+ uint16_t ReportLength)
{
/* Select the HID data OUT pipe */
Pipe_SelectPipe(HID_DATA_OUT_PIPE);
diff --git a/Demos/Host/LowLevel/GenericHIDHost/GenericHIDHost.h b/Demos/Host/LowLevel/GenericHIDHost/GenericHIDHost.h
index 8d0674eee..89ac01958 100644
--- a/Demos/Host/LowLevel/GenericHIDHost/GenericHIDHost.h
+++ b/Demos/Host/LowLevel/GenericHIDHost/GenericHIDHost.h
@@ -90,10 +90,14 @@
void EVENT_USB_Host_HostError(const uint8_t ErrorCode);
void EVENT_USB_Host_DeviceAttached(void);
void EVENT_USB_Host_DeviceUnattached(void);
- void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode);
+ void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode);
void EVENT_USB_Host_DeviceEnumerationComplete(void);
void ReadNextReport(void);
- void WriteNextReport(uint8_t* ReportOUTData, uint8_t ReportIndex, uint8_t ReportType, uint16_t ReportLength);
+ void WriteNextReport(uint8_t* ReportOUTData,
+ const uint8_t ReportIndex,
+ const uint8_t ReportType,
+ uint16_t ReportLength);
#endif
diff --git a/Demos/Host/LowLevel/JoystickHostWithParser/HIDReport.c b/Demos/Host/LowLevel/JoystickHostWithParser/HIDReport.c
index cc7c98bfc..bda99bdd0 100644
--- a/Demos/Host/LowLevel/JoystickHostWithParser/HIDReport.c
+++ b/Demos/Host/LowLevel/JoystickHostWithParser/HIDReport.c
@@ -79,7 +79,7 @@ uint8_t GetHIDReportData(void)
*
* \return Boolean true if the item should be stored into the HID report structure, false if it should be discarded
*/
-bool CALLBACK_HIDParser_FilterHIDReportItem(HID_ReportItem_t* CurrentItem)
+bool CALLBACK_HIDParser_FilterHIDReportItem(HID_ReportItem_t* const CurrentItem)
{
bool IsJoystick = false;
diff --git a/Demos/Host/LowLevel/JoystickHostWithParser/HIDReport.h b/Demos/Host/LowLevel/JoystickHostWithParser/HIDReport.h
index 3ffc051e8..da73ff823 100644
--- a/Demos/Host/LowLevel/JoystickHostWithParser/HIDReport.h
+++ b/Demos/Host/LowLevel/JoystickHostWithParser/HIDReport.h
@@ -89,6 +89,6 @@
/* Function Prototypes: */
uint8_t GetHIDReportData(void);
- bool CALLBACK_HIDParser_FilterHIDReportItem(HID_ReportItem_t* CurrentItem);
+ bool CALLBACK_HIDParser_FilterHIDReportItem(HID_ReportItem_t* const CurrentItem);
#endif
diff --git a/Demos/Host/LowLevel/JoystickHostWithParser/JoystickHostWithParser.h b/Demos/Host/LowLevel/JoystickHostWithParser/JoystickHostWithParser.h
index cf6369b9b..95a0a639e 100644
--- a/Demos/Host/LowLevel/JoystickHostWithParser/JoystickHostWithParser.h
+++ b/Demos/Host/LowLevel/JoystickHostWithParser/JoystickHostWithParser.h
@@ -76,7 +76,8 @@
void EVENT_USB_Host_HostError(const uint8_t ErrorCode);
void EVENT_USB_Host_DeviceAttached(void);
void EVENT_USB_Host_DeviceUnattached(void);
- void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode);
+ void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode);
void EVENT_USB_Host_DeviceEnumerationComplete(void);
void ProcessJoystickReport(uint8_t* JoystickReport);
diff --git a/Demos/Host/LowLevel/KeyboardHost/KeyboardHost.c b/Demos/Host/LowLevel/KeyboardHost/KeyboardHost.c
index debbf7651..d98c26557 100644
--- a/Demos/Host/LowLevel/KeyboardHost/KeyboardHost.c
+++ b/Demos/Host/LowLevel/KeyboardHost/KeyboardHost.c
@@ -112,7 +112,8 @@ void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
/** Event handler for the USB_DeviceEnumerationFailed event. This indicates that a problem occurred while
* enumerating an attached USB device.
*/
-void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode)
+void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode)
{
printf_P(PSTR(ESC_FG_RED "Dev Enum Error\r\n"
" -- Error Code %d\r\n"
diff --git a/Demos/Host/LowLevel/KeyboardHost/KeyboardHost.h b/Demos/Host/LowLevel/KeyboardHost/KeyboardHost.h
index dc09f84c9..91a2be534 100644
--- a/Demos/Host/LowLevel/KeyboardHost/KeyboardHost.h
+++ b/Demos/Host/LowLevel/KeyboardHost/KeyboardHost.h
@@ -87,7 +87,8 @@
void EVENT_USB_Host_HostError(const uint8_t ErrorCode);
void EVENT_USB_Host_DeviceAttached(void);
void EVENT_USB_Host_DeviceUnattached(void);
- void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode);
+ void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode);
void EVENT_USB_Host_DeviceEnumerationComplete(void);
void ReadNextReport(void);
diff --git a/Demos/Host/LowLevel/KeyboardHostWithParser/HIDReport.c b/Demos/Host/LowLevel/KeyboardHostWithParser/HIDReport.c
index eb8ec59a8..6b4df377d 100644
--- a/Demos/Host/LowLevel/KeyboardHostWithParser/HIDReport.c
+++ b/Demos/Host/LowLevel/KeyboardHostWithParser/HIDReport.c
@@ -79,7 +79,7 @@ uint8_t GetHIDReportData(void)
*
* \return Boolean true if the item should be stored into the HID report structure, false if it should be discarded
*/
-bool CALLBACK_HIDParser_FilterHIDReportItem(HID_ReportItem_t* CurrentItem)
+bool CALLBACK_HIDParser_FilterHIDReportItem(HID_ReportItem_t* const CurrentItem)
{
/* Check the attributes of the current item - see if we are interested in it or not;
* only store KEYBOARD usage page items into the Processed HID Report structure to
diff --git a/Demos/Host/LowLevel/KeyboardHostWithParser/HIDReport.h b/Demos/Host/LowLevel/KeyboardHostWithParser/HIDReport.h
index 428b91a2b..09cace965 100644
--- a/Demos/Host/LowLevel/KeyboardHostWithParser/HIDReport.h
+++ b/Demos/Host/LowLevel/KeyboardHostWithParser/HIDReport.h
@@ -77,6 +77,6 @@
/* Function Prototypes: */
uint8_t GetHIDReportData(void);
- bool CALLBACK_HIDParser_FilterHIDReportItem(HID_ReportItem_t* CurrentItem);
+ bool CALLBACK_HIDParser_FilterHIDReportItem(HID_ReportItem_t* const CurrentItem);
#endif
diff --git a/Demos/Host/LowLevel/KeyboardHostWithParser/KeyboardHostWithParser.c b/Demos/Host/LowLevel/KeyboardHostWithParser/KeyboardHostWithParser.c
index 301f6de3e..666879c98 100644
--- a/Demos/Host/LowLevel/KeyboardHostWithParser/KeyboardHostWithParser.c
+++ b/Demos/Host/LowLevel/KeyboardHostWithParser/KeyboardHostWithParser.c
@@ -112,7 +112,8 @@ void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
/** Event handler for the USB_DeviceEnumerationFailed event. This indicates that a problem occurred while
* enumerating an attached USB device.
*/
-void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode)
+void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode)
{
printf_P(PSTR(ESC_FG_RED "Dev Enum Error\r\n"
" -- Error Code %d\r\n"
diff --git a/Demos/Host/LowLevel/KeyboardHostWithParser/KeyboardHostWithParser.h b/Demos/Host/LowLevel/KeyboardHostWithParser/KeyboardHostWithParser.h
index 500b7cb2c..76b3b49a9 100644
--- a/Demos/Host/LowLevel/KeyboardHostWithParser/KeyboardHostWithParser.h
+++ b/Demos/Host/LowLevel/KeyboardHostWithParser/KeyboardHostWithParser.h
@@ -71,7 +71,8 @@
void EVENT_USB_Host_HostError(const uint8_t ErrorCode);
void EVENT_USB_Host_DeviceAttached(void);
void EVENT_USB_Host_DeviceUnattached(void);
- void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode);
+ void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode);
void EVENT_USB_Host_DeviceEnumerationComplete(void);
void ProcessKeyboardReport(uint8_t* KeyboardReport);
diff --git a/Demos/Host/LowLevel/MIDIHost/MIDIHost.c b/Demos/Host/LowLevel/MIDIHost/MIDIHost.c
index 9c8190286..f518550b5 100644
--- a/Demos/Host/LowLevel/MIDIHost/MIDIHost.c
+++ b/Demos/Host/LowLevel/MIDIHost/MIDIHost.c
@@ -114,7 +114,8 @@ void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
/** Event handler for the USB_DeviceEnumerationFailed event. This indicates that a problem occurred while
* enumerating an attached USB device.
*/
-void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode)
+void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode)
{
printf_P(PSTR(ESC_FG_RED "Dev Enum Error\r\n"
" -- Error Code %d\r\n"
diff --git a/Demos/Host/LowLevel/MIDIHost/MIDIHost.h b/Demos/Host/LowLevel/MIDIHost/MIDIHost.h
index 1338f6516..ecae67c8d 100644
--- a/Demos/Host/LowLevel/MIDIHost/MIDIHost.h
+++ b/Demos/Host/LowLevel/MIDIHost/MIDIHost.h
@@ -108,7 +108,8 @@
void EVENT_USB_Host_HostError(const uint8_t ErrorCode);
void EVENT_USB_Host_DeviceAttached(void);
void EVENT_USB_Host_DeviceUnattached(void);
- void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode);
+ void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode);
void EVENT_USB_Host_DeviceEnumerationComplete(void);
#endif
diff --git a/Demos/Host/LowLevel/MassStorageHost/Lib/MassStoreCommands.c b/Demos/Host/LowLevel/MassStorageHost/Lib/MassStoreCommands.c
index 129c50af8..b94bbcac7 100644
--- a/Demos/Host/LowLevel/MassStorageHost/Lib/MassStoreCommands.c
+++ b/Demos/Host/LowLevel/MassStorageHost/Lib/MassStoreCommands.c
@@ -63,7 +63,8 @@ static uint32_t MassStore_Tag = 1;
*
* \return A value from the Pipe_Stream_RW_ErrorCodes_t enum
*/
-static uint8_t MassStore_SendCommand(CommandBlockWrapper_t* SCSICommandBlock, void* BufferPtr)
+static uint8_t MassStore_SendCommand(CommandBlockWrapper_t* const SCSICommandBlock,
+ void* BufferPtr)
{
uint8_t ErrorCode = PIPE_RWSTREAM_NoError;
@@ -178,7 +179,8 @@ static uint8_t MassStore_WaitForDataReceived(void)
*
* \return A value from the Pipe_Stream_RW_ErrorCodes_t enum
*/
-static uint8_t MassStore_SendReceiveData(CommandBlockWrapper_t* SCSICommandBlock, void* BufferPtr)
+static uint8_t MassStore_SendReceiveData(CommandBlockWrapper_t* const SCSICommandBlock,
+ void* BufferPtr)
{
uint8_t ErrorCode = PIPE_RWSTREAM_NoError;
uint16_t BytesRem = SCSICommandBlock->DataTransferLength;
@@ -233,7 +235,7 @@ static uint8_t MassStore_SendReceiveData(CommandBlockWrapper_t* SCSICommandBlock
*
* \return A value from the Pipe_Stream_RW_ErrorCodes_t enum, or MASS_STORE_SCSI_COMMAND_FAILED if the SCSI command fails
*/
-static uint8_t MassStore_GetReturnedStatus(CommandStatusWrapper_t* SCSICommandStatus)
+static uint8_t MassStore_GetReturnedStatus(CommandStatusWrapper_t* const SCSICommandStatus)
{
uint8_t ErrorCode = PIPE_RWSTREAM_NoError;
@@ -334,7 +336,8 @@ uint8_t MassStore_GetMaxLUN(uint8_t* const MaxLUNIndex)
*
* \return A value from the Pipe_Stream_RW_ErrorCodes_t enum, or MASS_STORE_SCSI_COMMAND_FAILED if the SCSI command fails
*/
-uint8_t MassStore_Inquiry(const uint8_t LUNIndex, SCSI_Inquiry_Response_t* const InquiryPtr)
+uint8_t MassStore_Inquiry(const uint8_t LUNIndex,
+ SCSI_Inquiry_Response_t* const InquiryPtr)
{
uint8_t ErrorCode = PIPE_RWSTREAM_NoError;
@@ -384,7 +387,8 @@ uint8_t MassStore_Inquiry(const uint8_t LUNIndex, SCSI_Inquiry_Response_t* const
*
* \return A value from the Pipe_Stream_RW_ErrorCodes_t enum, or MASS_STORE_SCSI_COMMAND_FAILED if the SCSI command fails
*/
-uint8_t MassStore_RequestSense(const uint8_t LUNIndex, SCSI_Request_Sense_Response_t* const SensePtr)
+uint8_t MassStore_RequestSense(const uint8_t LUNIndex,
+ SCSI_Request_Sense_Response_t* const SensePtr)
{
uint8_t ErrorCode = PIPE_RWSTREAM_NoError;
@@ -437,8 +441,11 @@ uint8_t MassStore_RequestSense(const uint8_t LUNIndex, SCSI_Request_Sense_Respon
*
* \return A value from the Pipe_Stream_RW_ErrorCodes_t enum, or MASS_STORE_SCSI_COMMAND_FAILED if the SCSI command fails
*/
-uint8_t MassStore_ReadDeviceBlock(const uint8_t LUNIndex, const uint32_t BlockAddress,
- const uint8_t Blocks, const uint16_t BlockSize, void* BufferPtr)
+uint8_t MassStore_ReadDeviceBlock(const uint8_t LUNIndex,
+ const uint32_t BlockAddress,
+ const uint8_t Blocks,
+ const uint16_t BlockSize,
+ void* BufferPtr)
{
uint8_t ErrorCode = PIPE_RWSTREAM_NoError;
@@ -495,8 +502,11 @@ uint8_t MassStore_ReadDeviceBlock(const uint8_t LUNIndex, const uint32_t BlockAd
*
* \return A value from the Pipe_Stream_RW_ErrorCodes_t enum, or MASS_STORE_SCSI_COMMAND_FAILED if the SCSI command fails
*/
-uint8_t MassStore_WriteDeviceBlock(const uint8_t LUNIndex, const uint32_t BlockAddress,
- const uint8_t Blocks, const uint16_t BlockSize, void* BufferPtr)
+uint8_t MassStore_WriteDeviceBlock(const uint8_t LUNIndex,
+ const uint32_t BlockAddress,
+ const uint8_t Blocks,
+ const uint16_t BlockSize,
+ void* BufferPtr)
{
uint8_t ErrorCode = PIPE_RWSTREAM_NoError;
@@ -599,7 +609,8 @@ uint8_t MassStore_TestUnitReady(const uint8_t LUNIndex)
*
* \return A value from the Pipe_Stream_RW_ErrorCodes_t enum, or MASS_STORE_SCSI_COMMAND_FAILED if the SCSI command fails
*/
-uint8_t MassStore_ReadCapacity(const uint8_t LUNIndex, SCSI_Capacity_t* const CapacityPtr)
+uint8_t MassStore_ReadCapacity(const uint8_t LUNIndex,
+ SCSI_Capacity_t* const CapacityPtr)
{
uint8_t ErrorCode = PIPE_RWSTREAM_NoError;
@@ -658,7 +669,8 @@ uint8_t MassStore_ReadCapacity(const uint8_t LUNIndex, SCSI_Capacity_t* const Ca
*
* \return A value from the Pipe_Stream_RW_ErrorCodes_t enum, or MASS_STORE_SCSI_COMMAND_FAILED if the SCSI command fails
*/
-uint8_t MassStore_PreventAllowMediumRemoval(const uint8_t LUNIndex, const bool PreventRemoval)
+uint8_t MassStore_PreventAllowMediumRemoval(const uint8_t LUNIndex,
+ const bool PreventRemoval)
{
uint8_t ErrorCode = PIPE_RWSTREAM_NoError;
diff --git a/Demos/Host/LowLevel/MassStorageHost/Lib/MassStoreCommands.h b/Demos/Host/LowLevel/MassStorageHost/Lib/MassStoreCommands.h
index aa349946c..5c1e80b51 100644
--- a/Demos/Host/LowLevel/MassStorageHost/Lib/MassStoreCommands.h
+++ b/Demos/Host/LowLevel/MassStorageHost/Lib/MassStoreCommands.h
@@ -185,25 +185,34 @@
/* Function Prototypes: */
#if defined(INCLUDE_FROM_MASSSTORE_COMMANDS_C)
- static uint8_t MassStore_SendCommand(CommandBlockWrapper_t* SCSICommandBlock, void* BufferPtr);
+ static uint8_t MassStore_SendCommand(CommandBlockWrapper_t* const SCSICommandBlock,
+ void* BufferPtr);
static uint8_t MassStore_WaitForDataReceived(void);
- static uint8_t MassStore_SendReceiveData(CommandBlockWrapper_t* SCSICommandBlock, void* BufferPtr) ATTR_NON_NULL_PTR_ARG(1);
- static uint8_t MassStore_GetReturnedStatus(CommandStatusWrapper_t* SCSICommandStatus) ATTR_NON_NULL_PTR_ARG(1);
+ static uint8_t MassStore_SendReceiveData(CommandBlockWrapper_t* const SCSICommandBlock,
+ void* BufferPtr) ATTR_NON_NULL_PTR_ARG(1);
+ static uint8_t MassStore_GetReturnedStatus(CommandStatusWrapper_t* const SCSICommandStatus) ATTR_NON_NULL_PTR_ARG(1);
#endif
uint8_t MassStore_MassStorageReset(void);
uint8_t MassStore_GetMaxLUN(uint8_t* const MaxLUNIndex);
- uint8_t MassStore_RequestSense(const uint8_t LUNIndex, SCSI_Request_Sense_Response_t* const SensePtr)
- ATTR_NON_NULL_PTR_ARG(2);
- uint8_t MassStore_Inquiry(const uint8_t LUNIndex, SCSI_Inquiry_Response_t* const InquiryPtr)
- ATTR_NON_NULL_PTR_ARG(2);
- uint8_t MassStore_ReadDeviceBlock(const uint8_t LUNIndex, const uint32_t BlockAddress,
- const uint8_t Blocks, const uint16_t BlockSize, void* BufferPtr) ATTR_NON_NULL_PTR_ARG(5);
- uint8_t MassStore_WriteDeviceBlock(const uint8_t LUNIndex, const uint32_t BlockAddress,
- const uint8_t Blocks, const uint16_t BlockSize, void* BufferPtr) ATTR_NON_NULL_PTR_ARG(5);
- uint8_t MassStore_ReadCapacity(const uint8_t LUNIndex, SCSI_Capacity_t* const CapacityPtr)
- ATTR_NON_NULL_PTR_ARG(2);
+ uint8_t MassStore_RequestSense(const uint8_t LUNIndex,
+ SCSI_Request_Sense_Response_t* const SensePtr) ATTR_NON_NULL_PTR_ARG(2);
+ uint8_t MassStore_Inquiry(const uint8_t LUNIndex,
+ SCSI_Inquiry_Response_t* const InquiryPtr) ATTR_NON_NULL_PTR_ARG(2);
+ uint8_t MassStore_ReadDeviceBlock(const uint8_t LUNIndex,
+ const uint32_t BlockAddress,
+ const uint8_t Blocks,
+ const uint16_t BlockSize,
+ void* BufferPtr) ATTR_NON_NULL_PTR_ARG(5);
+ uint8_t MassStore_WriteDeviceBlock(const uint8_t LUNIndex,
+ const uint32_t BlockAddress,
+ const uint8_t Blocks,
+ const uint16_t BlockSize,
+ void* BufferPtr) ATTR_NON_NULL_PTR_ARG(5);
+ uint8_t MassStore_ReadCapacity(const uint8_t LUNIndex,
+ SCSI_Capacity_t* const CapacityPtr) ATTR_NON_NULL_PTR_ARG(2);
uint8_t MassStore_TestUnitReady(const uint8_t LUNIndex);
- uint8_t MassStore_PreventAllowMediumRemoval(const uint8_t LUNIndex, const bool PreventRemoval);
+ uint8_t MassStore_PreventAllowMediumRemoval(const uint8_t LUNIndex,
+ const bool PreventRemoval);
#endif
diff --git a/Demos/Host/LowLevel/MassStorageHost/MassStorageHost.c b/Demos/Host/LowLevel/MassStorageHost/MassStorageHost.c
index 2739fc99a..985aeeb08 100644
--- a/Demos/Host/LowLevel/MassStorageHost/MassStorageHost.c
+++ b/Demos/Host/LowLevel/MassStorageHost/MassStorageHost.c
@@ -117,7 +117,8 @@ void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
/** Event handler for the USB_DeviceEnumerationFailed event. This indicates that a problem occurred while
* enumerating an attached USB device.
*/
-void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode)
+void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode)
{
printf_P(PSTR(ESC_FG_RED "Dev Enum Error\r\n"
" -- Error Code %d\r\n"
@@ -373,7 +374,8 @@ void MassStorage_Task(void)
* \param[in] CommandString ASCII string located in PROGMEM space indicating what operation failed
* \param[in] ErrorCode Error code of the function which failed to complete successfully
*/
-void ShowDiskReadError(char* CommandString, uint8_t ErrorCode)
+void ShowDiskReadError(char* CommandString,
+ const uint8_t ErrorCode)
{
if (ErrorCode == MASS_STORE_SCSI_COMMAND_FAILED)
{
diff --git a/Demos/Host/LowLevel/MassStorageHost/MassStorageHost.h b/Demos/Host/LowLevel/MassStorageHost/MassStorageHost.h
index 14d8d9734..7aabe9f7d 100644
--- a/Demos/Host/LowLevel/MassStorageHost/MassStorageHost.h
+++ b/Demos/Host/LowLevel/MassStorageHost/MassStorageHost.h
@@ -80,9 +80,11 @@
void EVENT_USB_Host_HostError(const uint8_t ErrorCode);
void EVENT_USB_Host_DeviceAttached(void);
void EVENT_USB_Host_DeviceUnattached(void);
- void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode);
+ void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode);
void EVENT_USB_Host_DeviceEnumerationComplete(void);
- void ShowDiskReadError(char* CommandString, uint8_t ErrorCode);
+ void ShowDiskReadError(char* CommandString,
+ const uint8_t ErrorCode);
#endif
diff --git a/Demos/Host/LowLevel/MouseHost/MouseHost.c b/Demos/Host/LowLevel/MouseHost/MouseHost.c
index 6e7b284df..bf20bca52 100644
--- a/Demos/Host/LowLevel/MouseHost/MouseHost.c
+++ b/Demos/Host/LowLevel/MouseHost/MouseHost.c
@@ -112,7 +112,8 @@ void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
/** Event handler for the USB_DeviceEnumerationFailed event. This indicates that a problem occurred while
* enumerating an attached USB device.
*/
-void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode)
+void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode)
{
printf_P(PSTR(ESC_FG_RED "Dev Enum Error\r\n"
" -- Error Code %d\r\n"
diff --git a/Demos/Host/LowLevel/MouseHost/MouseHost.h b/Demos/Host/LowLevel/MouseHost/MouseHost.h
index f196dadcb..b9c5aeda1 100644
--- a/Demos/Host/LowLevel/MouseHost/MouseHost.h
+++ b/Demos/Host/LowLevel/MouseHost/MouseHost.h
@@ -87,7 +87,8 @@
void EVENT_USB_Host_HostError(const uint8_t ErrorCode);
void EVENT_USB_Host_DeviceAttached(void);
void EVENT_USB_Host_DeviceUnattached(void);
- void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode);
+ void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode);
void EVENT_USB_Host_DeviceEnumerationComplete(void);
void ReadNextReport(void);
diff --git a/Demos/Host/LowLevel/MouseHostWithParser/HIDReport.c b/Demos/Host/LowLevel/MouseHostWithParser/HIDReport.c
index f551f2f4c..327ae45ec 100644
--- a/Demos/Host/LowLevel/MouseHostWithParser/HIDReport.c
+++ b/Demos/Host/LowLevel/MouseHostWithParser/HIDReport.c
@@ -79,7 +79,7 @@ uint8_t GetHIDReportData(void)
*
* \return Boolean true if the item should be stored into the HID report structure, false if it should be discarded
*/
-bool CALLBACK_HIDParser_FilterHIDReportItem(HID_ReportItem_t* CurrentItem)
+bool CALLBACK_HIDParser_FilterHIDReportItem(HID_ReportItem_t* const CurrentItem)
{
bool IsMouse = false;
diff --git a/Demos/Host/LowLevel/MouseHostWithParser/HIDReport.h b/Demos/Host/LowLevel/MouseHostWithParser/HIDReport.h
index 684c74319..bd12a39c1 100644
--- a/Demos/Host/LowLevel/MouseHostWithParser/HIDReport.h
+++ b/Demos/Host/LowLevel/MouseHostWithParser/HIDReport.h
@@ -92,6 +92,6 @@
/* Function Prototypes: */
uint8_t GetHIDReportData(void);
- bool CALLBACK_HIDParser_FilterHIDReportItem(HID_ReportItem_t* CurrentItem);
+ bool CALLBACK_HIDParser_FilterHIDReportItem(HID_ReportItem_t* const CurrentItem);
#endif
diff --git a/Demos/Host/LowLevel/MouseHostWithParser/MouseHostWithParser.c b/Demos/Host/LowLevel/MouseHostWithParser/MouseHostWithParser.c
index efe1421a2..1b9c12aa9 100644
--- a/Demos/Host/LowLevel/MouseHostWithParser/MouseHostWithParser.c
+++ b/Demos/Host/LowLevel/MouseHostWithParser/MouseHostWithParser.c
@@ -112,7 +112,8 @@ void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
/** Event handler for the USB_DeviceEnumerationFailed event. This indicates that a problem occurred while
* enumerating an attached USB device.
*/
-void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode)
+void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode)
{
printf_P(PSTR(ESC_FG_RED "Dev Enum Error\r\n"
" -- Error Code %d\r\n"
diff --git a/Demos/Host/LowLevel/MouseHostWithParser/MouseHostWithParser.h b/Demos/Host/LowLevel/MouseHostWithParser/MouseHostWithParser.h
index 2c11f110c..3a80c8e60 100644
--- a/Demos/Host/LowLevel/MouseHostWithParser/MouseHostWithParser.h
+++ b/Demos/Host/LowLevel/MouseHostWithParser/MouseHostWithParser.h
@@ -76,7 +76,8 @@
void EVENT_USB_Host_HostError(const uint8_t ErrorCode);
void EVENT_USB_Host_DeviceAttached(void);
void EVENT_USB_Host_DeviceUnattached(void);
- void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode);
+ void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode);
void EVENT_USB_Host_DeviceEnumerationComplete(void);
void ProcessMouseReport(uint8_t* MouseReport);
diff --git a/Demos/Host/LowLevel/PrinterHost/Lib/PrinterCommands.c b/Demos/Host/LowLevel/PrinterHost/Lib/PrinterCommands.c
index 5f3effa7b..024895991 100644
--- a/Demos/Host/LowLevel/PrinterHost/Lib/PrinterCommands.c
+++ b/Demos/Host/LowLevel/PrinterHost/Lib/PrinterCommands.c
@@ -44,7 +44,8 @@
*
* \return A value from the Pipe_Stream_RW_ErrorCodes_t enum
*/
-uint8_t Printer_SendData(const void* const PrinterCommands, const uint16_t CommandSize)
+uint8_t Printer_SendData(const void* const PrinterCommands,
+ const uint16_t CommandSize)
{
uint8_t ErrorCode;
@@ -74,7 +75,8 @@ uint8_t Printer_SendData(const void* const PrinterCommands, const uint16_t Comma
*
* \return A value from the USB_Host_SendControlErrorCodes_t enum
*/
-uint8_t Printer_GetDeviceID(char* DeviceIDString, const uint16_t BufferSize)
+uint8_t Printer_GetDeviceID(char* DeviceIDString,
+ const uint16_t BufferSize)
{
uint8_t ErrorCode = HOST_SENDCONTROL_Successful;
uint16_t DeviceIDStringLength = 0;
diff --git a/Demos/Host/LowLevel/PrinterHost/Lib/PrinterCommands.h b/Demos/Host/LowLevel/PrinterHost/Lib/PrinterCommands.h
index cbc54564c..8c3bd3316 100644
--- a/Demos/Host/LowLevel/PrinterHost/Lib/PrinterCommands.h
+++ b/Demos/Host/LowLevel/PrinterHost/Lib/PrinterCommands.h
@@ -59,9 +59,11 @@
#define PRINTER_DATA_OUT_PIPE 2
/* Function Prototypes: */
- uint8_t Printer_SendData(const void* const PrinterCommands, const uint16_t CommandSize);
- uint8_t Printer_GetDeviceID(char* DeviceIDString, const uint16_t BufferSize);
- uint8_t Printer_GetPortStatus(uint8_t* PortStatus);
+ uint8_t Printer_SendData(const void* const PrinterCommands,
+ const uint16_t CommandSize);
+ uint8_t Printer_GetDeviceID(char* DeviceIDString,
+ const uint16_t BufferSize);
+ uint8_t Printer_GetPortStatus(uint8_t* const PortStatus);
uint8_t Printer_SoftReset(void);
#endif
diff --git a/Demos/Host/LowLevel/PrinterHost/PrinterHost.c b/Demos/Host/LowLevel/PrinterHost/PrinterHost.c
index b6f3efae3..f12c95ef9 100644
--- a/Demos/Host/LowLevel/PrinterHost/PrinterHost.c
+++ b/Demos/Host/LowLevel/PrinterHost/PrinterHost.c
@@ -98,7 +98,7 @@ void EVENT_USB_Host_DeviceEnumerationComplete(void)
}
/** Event handler for the USB_HostError event. This indicates that a hardware error occurred while in host mode. */
-void EVENT_USB_Host_HostError(uint8_t ErrorCode)
+void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
{
USB_ShutDown();
@@ -112,7 +112,8 @@ void EVENT_USB_Host_HostError(uint8_t ErrorCode)
/** Event handler for the USB_DeviceEnumerationFailed event. This indicates that a problem occurred while
* enumerating an attached USB device.
*/
-void EVENT_USB_Host_DeviceEnumerationFailed(uint8_t ErrorCode, uint8_t SubErrorCode)
+void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode)
{
printf_P(PSTR(ESC_FG_RED "Dev Enum Error\r\n"
" -- Error Code %d\r\n"
diff --git a/Demos/Host/LowLevel/PrinterHost/PrinterHost.h b/Demos/Host/LowLevel/PrinterHost/PrinterHost.h
index 99bbd4a66..78583f0e4 100644
--- a/Demos/Host/LowLevel/PrinterHost/PrinterHost.h
+++ b/Demos/Host/LowLevel/PrinterHost/PrinterHost.h
@@ -74,8 +74,9 @@
void EVENT_USB_Host_DeviceAttached(void);
void EVENT_USB_Host_DeviceUnattached(void);
void EVENT_USB_Host_DeviceEnumerationComplete(void);
- void EVENT_USB_Host_HostError(uint8_t ErrorCode);
- void EVENT_USB_Host_DeviceEnumerationFailed(uint8_t ErrorCode, uint8_t SubErrorCode);
+ void EVENT_USB_Host_HostError(const uint8_t ErrorCode);
+ void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode);
void SetupHardware(void);
diff --git a/Demos/Host/LowLevel/RNDISEthernetHost/Lib/RNDISCommands.c b/Demos/Host/LowLevel/RNDISEthernetHost/Lib/RNDISCommands.c
index 5200372e9..cd142ef55 100644
--- a/Demos/Host/LowLevel/RNDISEthernetHost/Lib/RNDISCommands.c
+++ b/Demos/Host/LowLevel/RNDISEthernetHost/Lib/RNDISCommands.c
@@ -47,7 +47,8 @@ uint32_t RequestID = 0;
*
* \return A value from the USB_Host_SendControlErrorCodes_t enum
*/
-uint8_t RNDIS_SendEncapsulatedCommand(void* const Buffer, const uint16_t Length)
+uint8_t RNDIS_SendEncapsulatedCommand(void* const Buffer,
+ const uint16_t Length)
{
USB_ControlRequest = (USB_Request_Header_t)
{
@@ -71,7 +72,8 @@ uint8_t RNDIS_SendEncapsulatedCommand(void* const Buffer, const uint16_t Length)
*
* \return A value from the USB_Host_SendControlErrorCodes_t enum
*/
-uint8_t RNDIS_GetEncapsulatedResponse(void* const Buffer, const uint16_t Length)
+uint8_t RNDIS_GetEncapsulatedResponse(void* const Buffer,
+ const uint16_t Length)
{
USB_ControlRequest = (USB_Request_Header_t)
{
@@ -128,7 +130,8 @@ uint8_t RNDIS_SendKeepAlive(void)
* \return A value from the USB_Host_SendControlErrorCodes_t enum or RNDIS_COMMAND_FAILED if the device returned a
* logical command failure
*/
-uint8_t RNDIS_InitializeDevice(const uint16_t HostMaxPacketSize, uint16_t* const DeviceMaxPacketSize)
+uint8_t RNDIS_InitializeDevice(const uint16_t HostMaxPacketSize,
+ uint16_t* const DeviceMaxPacketSize)
{
uint8_t ErrorCode;
@@ -172,7 +175,9 @@ uint8_t RNDIS_InitializeDevice(const uint16_t HostMaxPacketSize, uint16_t* const
* \return A value from the USB_Host_SendControlErrorCodes_t enum or RNDIS_COMMAND_FAILED if the device returned a
* logical command failure
*/
-uint8_t RNDIS_SetRNDISProperty(const uint32_t Oid, void* Buffer, const uint16_t Length)
+uint8_t RNDIS_SetRNDISProperty(const uint32_t Oid,
+ void* Buffer,
+ const uint16_t Length)
{
uint8_t ErrorCode;
@@ -222,7 +227,9 @@ uint8_t RNDIS_SetRNDISProperty(const uint32_t Oid, void* Buffer, const uint16_t
* \return A value from the USB_Host_SendControlErrorCodes_t enum or RNDIS_COMMAND_FAILED if the device returned a
* logical command failure
*/
-uint8_t RNDIS_QueryRNDISProperty(const uint32_t Oid, void* Buffer, const uint16_t MaxLength)
+uint8_t RNDIS_QueryRNDISProperty(const uint32_t Oid,
+ void* Buffer,
+ const uint16_t MaxLength)
{
uint8_t ErrorCode;
diff --git a/Demos/Host/LowLevel/RNDISEthernetHost/Lib/RNDISCommands.h b/Demos/Host/LowLevel/RNDISEthernetHost/Lib/RNDISCommands.h
index a2f15c5a7..960d53823 100644
--- a/Demos/Host/LowLevel/RNDISEthernetHost/Lib/RNDISCommands.h
+++ b/Demos/Host/LowLevel/RNDISEthernetHost/Lib/RNDISCommands.h
@@ -200,13 +200,20 @@
#define RNDIS_COMMAND_FAILED 0xC0
/* Function Prototypes: */
- uint8_t RNDIS_SendEncapsulatedCommand(void* const Buffer, const uint16_t Length);
- uint8_t RNDIS_GetEncapsulatedResponse(void* const Buffer, const uint16_t Length);
+ uint8_t RNDIS_SendEncapsulatedCommand(void* const Buffer,
+ const uint16_t Length);
+ uint8_t RNDIS_GetEncapsulatedResponse(void* const Buffer,
+ const uint16_t Length);
uint8_t RNDIS_SendKeepAlive(void);
- uint8_t RNDIS_InitializeDevice(const uint16_t HostMaxPacketSize, uint16_t* const DeviceMaxPacketSize);
- uint8_t RNDIS_SetRNDISProperty(const uint32_t Oid, void* Buffer, const uint16_t Length);
- uint8_t RNDIS_QueryRNDISProperty(const uint32_t Oid, void* Buffer, const uint16_t MaxLength);
+ uint8_t RNDIS_InitializeDevice(const uint16_t HostMaxPacketSize,
+ uint16_t* const DeviceMaxPacketSize);
+ uint8_t RNDIS_SetRNDISProperty(const uint32_t Oid,
+ void* Buffer,
+ const uint16_t Length);
+ uint8_t RNDIS_QueryRNDISProperty(const uint32_t Oid,
+ void* Buffer,
+ const uint16_t MaxLength);
uint8_t RNDIS_GetPacketLength(uint16_t* const PacketLength);
#endif
diff --git a/Demos/Host/LowLevel/RNDISEthernetHost/RNDISEthernetHost.c b/Demos/Host/LowLevel/RNDISEthernetHost/RNDISEthernetHost.c
index 1d18f11e6..1da5b4dbf 100644
--- a/Demos/Host/LowLevel/RNDISEthernetHost/RNDISEthernetHost.c
+++ b/Demos/Host/LowLevel/RNDISEthernetHost/RNDISEthernetHost.c
@@ -112,7 +112,8 @@ void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
/** Event handler for the USB_DeviceEnumerationFailed event. This indicates that a problem occurred while
* enumerating an attached USB device.
*/
-void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode)
+void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode)
{
printf_P(PSTR(ESC_FG_RED "Dev Enum Error\r\n"
" -- Error Code %d\r\n"
diff --git a/Demos/Host/LowLevel/RNDISEthernetHost/RNDISEthernetHost.h b/Demos/Host/LowLevel/RNDISEthernetHost/RNDISEthernetHost.h
index 46b47f95c..08187f9fa 100644
--- a/Demos/Host/LowLevel/RNDISEthernetHost/RNDISEthernetHost.h
+++ b/Demos/Host/LowLevel/RNDISEthernetHost/RNDISEthernetHost.h
@@ -91,7 +91,8 @@
void EVENT_USB_Host_HostError(const uint8_t ErrorCode);
void EVENT_USB_Host_DeviceAttached(void);
void EVENT_USB_Host_DeviceUnattached(void);
- void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode);
+ void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode);
void EVENT_USB_Host_DeviceEnumerationComplete(void);
#endif
diff --git a/Demos/Host/LowLevel/StillImageHost/Lib/StillImageCommands.c b/Demos/Host/LowLevel/StillImageHost/Lib/StillImageCommands.c
index 530450988..a99a95680 100644
--- a/Demos/Host/LowLevel/StillImageHost/Lib/StillImageCommands.c
+++ b/Demos/Host/LowLevel/StillImageHost/Lib/StillImageCommands.c
@@ -198,7 +198,8 @@ uint8_t SImage_ReceiveBlockHeader(void)
*
* \return A value from the Pipe_Stream_RW_ErrorCodes_t enum
*/
-uint8_t SImage_SendData(void* const Buffer, const uint16_t Bytes)
+uint8_t SImage_SendData(void* const Buffer,
+ const uint16_t Bytes)
{
uint8_t ErrorCode;
@@ -225,7 +226,8 @@ uint8_t SImage_SendData(void* const Buffer, const uint16_t Bytes)
*
* \return A value from the Pipe_Stream_RW_ErrorCodes_t enum
*/
-uint8_t SImage_ReadData(void* const Buffer, const uint16_t Bytes)
+uint8_t SImage_ReadData(void* const Buffer,
+ const uint16_t Bytes)
{
uint8_t ErrorCode;
diff --git a/Demos/Host/LowLevel/StillImageHost/Lib/StillImageCommands.h b/Demos/Host/LowLevel/StillImageHost/Lib/StillImageCommands.h
index a57ddaf2c..c91a80122 100644
--- a/Demos/Host/LowLevel/StillImageHost/Lib/StillImageCommands.h
+++ b/Demos/Host/LowLevel/StillImageHost/Lib/StillImageCommands.h
@@ -108,8 +108,10 @@
void SImage_SendBlockHeader(void);
uint8_t SImage_ReceiveBlockHeader(void);
uint8_t SImage_ReceiveEventHeader(void);
- uint8_t SImage_SendData(void* const Buffer, const uint16_t Bytes);
- uint8_t SImage_ReadData(void* const Buffer, const uint16_t Bytes);
+ uint8_t SImage_SendData(void* const Buffer,
+ const uint16_t Bytes);
+ uint8_t SImage_ReadData(void* const Buffer,
+ const uint16_t Bytes);
bool SImage_IsEventReceived(void);
#endif
diff --git a/Demos/Host/LowLevel/StillImageHost/StillImageHost.c b/Demos/Host/LowLevel/StillImageHost/StillImageHost.c
index 686eb5ff4..73f0c2c76 100644
--- a/Demos/Host/LowLevel/StillImageHost/StillImageHost.c
+++ b/Demos/Host/LowLevel/StillImageHost/StillImageHost.c
@@ -113,7 +113,8 @@ void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
/** Event handler for the USB_DeviceEnumerationFailed event. This indicates that a problem occurred while
* enumerating an attached USB device.
*/
-void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode)
+void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode)
{
printf_P(PSTR(ESC_FG_RED "Dev Enum Error\r\n"
" -- Error Code %d\r\n"
@@ -339,7 +340,8 @@ void StillImage_Task(void)
* \param[in] UnicodeString Pointer to a Unicode encoded input string
* \param[out] Buffer Pointer to a buffer where the converted ASCII string should be stored
*/
-void UnicodeToASCII(uint8_t* UnicodeString, char* Buffer)
+void UnicodeToASCII(uint8_t* UnicodeString,
+ char* Buffer)
{
/* Get the number of characters in the string, skip to the start of the string data */
uint8_t CharactersRemaining = *(UnicodeString++);
@@ -363,7 +365,8 @@ void UnicodeToASCII(uint8_t* UnicodeString, char* Buffer)
* \param[in] ErrorCode Error code of the function which failed to complete successfully
* \param[in] ResponseCodeError Indicates if the error is due to a command failed indication from the device, or a communication failure
*/
-void ShowCommandError(uint8_t ErrorCode, bool ResponseCodeError)
+void ShowCommandError(uint8_t ErrorCode,
+ bool ResponseCodeError)
{
char* FailureType = ((ResponseCodeError) ? PSTR("Response Code != OK") : PSTR("Transaction Fail"));
diff --git a/Demos/Host/LowLevel/StillImageHost/StillImageHost.h b/Demos/Host/LowLevel/StillImageHost/StillImageHost.h
index d7b893ee2..61e5eb5b5 100644
--- a/Demos/Host/LowLevel/StillImageHost/StillImageHost.h
+++ b/Demos/Host/LowLevel/StillImageHost/StillImageHost.h
@@ -76,10 +76,13 @@
void EVENT_USB_Host_HostError(const uint8_t ErrorCode);
void EVENT_USB_Host_DeviceAttached(void);
void EVENT_USB_Host_DeviceUnattached(void);
- void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode);
+ void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode);
void EVENT_USB_Host_DeviceEnumerationComplete(void);
- void UnicodeToASCII(uint8_t* restrict UnicodeString, char* restrict Buffer);
- void ShowCommandError(uint8_t ErrorCode, bool ResponseCodeError);
+ void UnicodeToASCII(uint8_t* UnicodeString,
+ char* Buffer);
+ void ShowCommandError(uint8_t ErrorCode,
+ bool ResponseCodeError);
#endif
diff --git a/Demos/Host/LowLevel/VirtualSerialHost/VirtualSerialHost.c b/Demos/Host/LowLevel/VirtualSerialHost/VirtualSerialHost.c
index 8bec8e562..4c250cd48 100644
--- a/Demos/Host/LowLevel/VirtualSerialHost/VirtualSerialHost.c
+++ b/Demos/Host/LowLevel/VirtualSerialHost/VirtualSerialHost.c
@@ -112,7 +112,8 @@ void EVENT_USB_Host_HostError(const uint8_t ErrorCode)
/** Event handler for the USB_DeviceEnumerationFailed event. This indicates that a problem occurred while
* enumerating an attached USB device.
*/
-void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode)
+void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode)
{
printf_P(PSTR(ESC_FG_RED "Dev Enum Error\r\n"
" -- Error Code %d\r\n"
diff --git a/Demos/Host/LowLevel/VirtualSerialHost/VirtualSerialHost.h b/Demos/Host/LowLevel/VirtualSerialHost/VirtualSerialHost.h
index 4227b5383..cf785e320 100644
--- a/Demos/Host/LowLevel/VirtualSerialHost/VirtualSerialHost.h
+++ b/Demos/Host/LowLevel/VirtualSerialHost/VirtualSerialHost.h
@@ -81,7 +81,8 @@
void EVENT_USB_Host_HostError(const uint8_t ErrorCode);
void EVENT_USB_Host_DeviceAttached(void);
void EVENT_USB_Host_DeviceUnattached(void);
- void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode);
+ void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode,
+ const uint8_t SubErrorCode);
void EVENT_USB_Host_DeviceEnumerationComplete(void);
#endif