summaryrefslogtreecommitdiff
path: root/usb_appl/usbconfig.h
diff options
context:
space:
mode:
Diffstat (limited to 'usb_appl/usbconfig.h')
-rw-r--r--usb_appl/usbconfig.h58
1 files changed, 29 insertions, 29 deletions
diff --git a/usb_appl/usbconfig.h b/usb_appl/usbconfig.h
index 0744d16..0d5e4af 100644
--- a/usb_appl/usbconfig.h
+++ b/usb_appl/usbconfig.h
@@ -183,18 +183,18 @@ 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
+/* Save timestamp of sof */
+
+#ifdef __ASSEMBLER__
+macro customSofHook
in YL, TCNT1L
sts usb_sof_time, YL
in YL, TCNT1H
sts usb_sof_time+1, 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
@@ -207,15 +207,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
@@ -361,9 +361,9 @@ endm
*/
#define USB_INTR_CFG MCUCR
#if defined(USB_COUNT_SOF) || defined(USB_SOF_HOOK)
-#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 */
@@ -371,22 +371,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__ */