aboutsummaryrefslogtreecommitdiff
path: root/Projects/HIDReportViewer/HIDReportViewer.c
diff options
context:
space:
mode:
authorDean <Dean@d5102386-fcda-11dd-9fdb-3debd5008f28>2011-06-20 02:08:52 +0000
committerDean <Dean@d5102386-fcda-11dd-9fdb-3debd5008f28>2011-06-20 02:08:52 +0000
commit9151150e451400cec8bc71cb842fc8cff196c3ce (patch)
treec610c3301bc1f017eb5f24f05ead92f4cb25756e /Projects/HIDReportViewer/HIDReportViewer.c
parentd10298c1518f416884d8b3252827ef15a7381b15 (diff)
Make HIDReportViewer project show the IN, OUT and DATA report sizes as both bits and (rounded) bytes.
git-svn-id: http://lufa-lib.googlecode.com/svn/trunk@1815 d5102386-fcda-11dd-9fdb-3debd5008f28
Diffstat (limited to 'Projects/HIDReportViewer/HIDReportViewer.c')
-rw-r--r--Projects/HIDReportViewer/HIDReportViewer.c14
1 files changed, 10 insertions, 4 deletions
diff --git a/Projects/HIDReportViewer/HIDReportViewer.c b/Projects/HIDReportViewer/HIDReportViewer.c
index 58f9d5ea..1dfbd405 100644
--- a/Projects/HIDReportViewer/HIDReportViewer.c
+++ b/Projects/HIDReportViewer/HIDReportViewer.c
@@ -133,11 +133,17 @@ int main(void)
uint8_t ReportSizeFeatureBits = CurrReportIDInfo->ReportSizeBits[HID_REPORT_ITEM_Feature];
/* Print out the byte sizes of each report within the device */
- printf_P(PSTR(" + Report ID %" PRId8 " - In: %" PRId8 " bytes, Out: %" PRId8 " bytes, Feature: %" PRId8 " bytes\r\n"),
+ printf_P(PSTR(" + Report ID 0x%02" PRIX8 "\r\n"
+ " - Input Data: %" PRId8 " bits (%" PRId8 " bytes)\r\n"
+ " - Output Data: %" PRId8 " bits (%" PRId8 " bytes)\r\n"
+ " - Feature Data: %" PRId8 " bits (%" PRId8 " bytes)\r\n"),
CurrReportIDInfo->ReportID,
- ((ReportSizeInBits >> 3) + ((ReportSizeInBits & 0x07) != 0)),
- ((ReportSizeOutBits >> 3) + ((ReportSizeOutBits & 0x07) != 0)),
- ((ReportSizeFeatureBits >> 3) + ((ReportSizeFeatureBits & 0x07) != 0)));
+ ReportSizeInBits,
+ ((ReportSizeInBits >> 3) + ((ReportSizeInBits & 0x07) != 0)),
+ ReportSizeOutBits,
+ ((ReportSizeOutBits >> 3) + ((ReportSizeOutBits & 0x07) != 0)),
+ ReportSizeFeatureBits,
+ ((ReportSizeFeatureBits >> 3) + ((ReportSizeFeatureBits & 0x07) != 0)));
}
puts_P(PSTR("\r\nReport Items:\r\n"));