Archived
1
0

Seems to be compiling now...finally after many months.

This commit is contained in:
Jacob Alexander 2011-09-07 18:04:06 -07:00
parent d1f1128f6a
commit 5226cdd252
2 changed files with 10 additions and 10 deletions

4
main.c
View File

@ -272,7 +272,7 @@ void keyPressDetection( uint8_t *keys, uint8_t *validKeys, uint8_t numberOfKeys,
for ( uint8_t key = 0; key < numberOfKeys + 1; key++ ) {
if ( keys[key] & (1 << 7) ) {
pint8( key );
print(" ");
//print(" ");
uint8_t modFound = 0;
// Determine if the key is a modifier
@ -402,7 +402,7 @@ int main( void )
keyPressDetection( keyDetectArray, &validKeys, KEYBOARD_SIZE, keyboard_MODMASK, keyboard_NUMMODS, keyboard_MAP );
keyPressDetection( keypadDetectArray, &validKeys, KEYPAD_SIZE, keypad_MODMASK, keypad_NUMMODS, keypad_MAP );
print(":\n");
//print(":\n");
// TODO undo potentially old keys
for ( uint8_t c = validKeys; c < 6; c++ )

View File

@ -94,7 +94,7 @@ static const uint8_t PROGMEM endpoint_config_table[] = {
// spec and relevant portions of any USB class specifications!
static uint8_t PROGMEM device_descriptor[] = {
static const uint8_t PROGMEM device_descriptor[] = {
18, // bLength
1, // bDescriptorType
0x00, 0x02, // bcdUSB
@ -112,7 +112,7 @@ static uint8_t PROGMEM device_descriptor[] = {
};
// Keyboard Protocol 1, HID 1.11 spec, Appendix B, page 59-60
static uint8_t PROGMEM keyboard_hid_report_desc[] = {
static const uint8_t PROGMEM keyboard_hid_report_desc[] = {
0x05, 0x01, // Usage Page (Generic Desktop),
0x09, 0x06, // Usage (Keyboard),
0xA1, 0x01, // Collection (Application),
@ -147,7 +147,7 @@ static uint8_t PROGMEM keyboard_hid_report_desc[] = {
0xc0 // End Collection
};
static uint8_t PROGMEM debug_hid_report_desc[] = {
static const uint8_t PROGMEM debug_hid_report_desc[] = {
0x06, 0x31, 0xFF, // Usage Page 0xFF31 (vendor defined)
0x09, 0x74, // Usage 0x74
0xA1, 0x53, // Collection 0x53
@ -163,7 +163,7 @@ static uint8_t PROGMEM debug_hid_report_desc[] = {
#define CONFIG1_DESC_SIZE (9+9+9+7+9+9+7)
#define KEYBOARD_HID_DESC_OFFSET (9+9)
#define DEBUG_HID_DESC_OFFSET (9+9+9+7+9)
static uint8_t PROGMEM config1_descriptor[CONFIG1_DESC_SIZE] = {
static const uint8_t PROGMEM config1_descriptor[CONFIG1_DESC_SIZE] = {
// configuration descriptor, USB spec 9.6.3, page 264-266, Table 9-10
9, // bLength;
2, // bDescriptorType;
@ -236,17 +236,17 @@ struct usb_string_descriptor_struct {
uint8_t bDescriptorType;
int16_t wString[];
};
static struct usb_string_descriptor_struct PROGMEM string0 = {
static const struct usb_string_descriptor_struct PROGMEM string0 = {
4,
3,
{0x0409}
};
static struct usb_string_descriptor_struct PROGMEM string1 = {
static const struct usb_string_descriptor_struct PROGMEM string1 = {
sizeof(STR_MANUFACTURER),
3,
STR_MANUFACTURER
};
static struct usb_string_descriptor_struct PROGMEM string2 = {
static const struct usb_string_descriptor_struct PROGMEM string2 = {
sizeof(STR_PRODUCT),
3,
STR_PRODUCT
@ -254,7 +254,7 @@ static struct usb_string_descriptor_struct PROGMEM string2 = {
// This table defines which descriptor data is sent for each specific
// request from the host (in wValue and wIndex).
static struct descriptor_list_struct {
static const struct descriptor_list_struct {
uint16_t wValue;
uint16_t wIndex;
const uint8_t *addr;