From afc8f9ff30b9c026bd8b5b678748e6b23913d867 Mon Sep 17 00:00:00 2001 From: Andreas Auras Date: Wed, 10 Feb 2010 12:55:37 +0100 Subject: More modifications for public use of project --- usb_boot/usbconfig.h | 60 ++++++++++++++++++++++++++-------------------------- 1 file changed, 30 insertions(+), 30 deletions(-) (limited to 'usb_boot/usbconfig.h') diff --git a/usb_boot/usbconfig.h b/usb_boot/usbconfig.h index e9899b7..70f76f1 100644 --- a/usb_boot/usbconfig.h +++ b/usb_boot/usbconfig.h @@ -183,17 +183,17 @@ section at the end of this file). * Please note that Start Of Frame detection works only if D- is wired to the * interrupt, not D+. THIS IS DIFFERENT THAN MOST EXAMPLES! */ - -/* Save timestamp of sof */ -#ifdef __ASSEMBLER__ -macro customSofHook - ldi YL, 0 +/* Save timestamp of sof */ + +#ifdef __ASSEMBLER__ +macro customSofHook + ldi YL, 0 out TCNT1H, YL out TCNT1L, YL endm #endif - + #define USB_CFG_CHECK_DATA_TOGGLING 1 /* define this macro to 1 if you want to filter out duplicate data packets * sent by the host. Duplicates occur only as a consequence of communication @@ -206,15 +206,15 @@ endm /* define this macro to 1 if you want the function usbMeasureFrameLength() * compiled in. This function can be used to calibrate the AVR's RC oscillator. */ -#define USB_USE_FAST_CRC 1 -/* The assembler module has two implementations for the CRC algorithm. One is - * faster, the other is smaller. This CRC routine is only used for transmitted - * messages where timing is not critical. The faster routine needs 31 cycles - * per byte while the smaller one needs 61 to 69 cycles. The faster routine - * may be worth the 32 bytes bigger code size if you transmit lots of data and - * run the AVR close to its limit. - */ - +#define USB_USE_FAST_CRC 1 +/* The assembler module has two implementations for the CRC algorithm. One is + * faster, the other is smaller. This CRC routine is only used for transmitted + * messages where timing is not critical. The faster routine needs 31 cycles + * per byte while the smaller one needs 61 to 69 cycles. The faster routine + * may be worth the 32 bytes bigger code size if you transmit lots of data and + * run the AVR close to its limit. + */ + /* -------------------------- Device Description --------------------------- */ #define USB_CFG_VENDOR_ID 0xc0, 0x16 @@ -360,9 +360,9 @@ endm */ #define USB_INTR_CFG MCUCR #if defined(USB_COUNT_SOF) || defined(USB_SOF_HOOK) || 1 -#define USB_INTR_CFG_SET ((1 << ISC11)) +#define USB_INTR_CFG_SET ((1 << ISC11)) #else -#define USB_INTR_CFG_SET ((1 << ISC10) | (1 << ISC11)) +#define USB_INTR_CFG_SET ((1 << ISC10) | (1 << ISC11)) #endif /* #define USB_INTR_CFG_CLR 0 */ /* #define USB_INTR_ENABLE GIMSK */ @@ -370,22 +370,22 @@ endm /* #define USB_INTR_PENDING GIFR */ #define USB_INTR_PENDING_BIT INTF1 #define USB_INTR_VECTOR SIG_INTERRUPT1 - - -/* This is a new macro that is executed and the beginning of the usb irq handler. - * This needs a patch in the corresponding clock dependend assembler file of VUSB!!! - * It is save to use register YH here - */ -/*#define USB_START_IRQ_HOOK customTriggerHook*/ - - + + +/* This is a new macro that is executed and the beginning of the usb irq handler. + * This needs a patch in the corresponding clock dependend assembler file of VUSB!!! + * It is save to use register YH here + */ +/*#define USB_START_IRQ_HOOK customTriggerHook*/ + + /* Reinstall edge level interrupt triggering (after sleep) */ #ifdef __ASSEMBLER__ -macro customTriggerHook - in YH, USB_INTR_CFG +macro customTriggerHook + in YH, USB_INTR_CFG ori YH, USB_INTR_CFG_SET out USB_INTR_CFG, YH -endm +endm #endif - + #endif /* __usbconfig_h_included__ */ -- cgit v1.2.3