USB HID descriptor redefined error

Status
Not open for further replies.

wjfong

Newbie level 3
Joined
Jun 26, 2010
Messages
3
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Location
malaysia
Activity points
1,296
good day, i've generated a new usbdsc.c file with the hid terminal. but when i compile it, i keep on getting errors:

redefined: hid_input_report_bytes
redefined: hid_output_report_bytes
redefined: hid_feature_report_bytes
redefined: num_endpoints
redefined: hid_input_report_bytes
redefined: hid_input_report_bytes
...
...
...

how can i fix this problem?? thanks
 

Usually, this happens when you change types between the c and h files. Look for extern declarations of these variables. Changing from signed to unsigned is enough to trigger these errors.

Or else, it also means that somewhere, the same vars are defined with different value. If you only need these in one file, use static declarations.
 

Status
Not open for further replies.

Similar threads

Cookies are required to use this site. You must accept them to continue using the site. Learn more…