From 6bda628718f67c04ed43e8328f55bdce5319c504 Mon Sep 17 00:00:00 2001 From: Dean Camera Date: Wed, 21 Jul 2010 16:19:32 +0000 Subject: Update all demos, projects and bootloaders to indent all function parameters, one per line, for better readability. Add missing const qualifiers to the demos. --- Demos/Host/LowLevel/GenericHIDHost/GenericHIDHost.c | 14 +++++++++----- Demos/Host/LowLevel/GenericHIDHost/GenericHIDHost.h | 8 ++++++-- 2 files changed, 15 insertions(+), 7 deletions(-) (limited to 'Demos/Host/LowLevel/GenericHIDHost') 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 -- cgit v1.2.3