OSDN Git Service

FX2/FX2.h: USBIRQ
authorPawel Jewstafjew (w) <Pawel.Jewstafjew@gmail.com>
Tue, 11 Sep 2018 09:53:56 +0000 (10:53 +0100)
committerPawel Jewstafjew (w) <Pawel.Jewstafjew@gmail.com>
Tue, 11 Sep 2018 09:53:56 +0000 (10:53 +0100)
FX2/FX2.h

index 1c07f94..a9ccaaf 100644 (file)
--- a/FX2/FX2.h
+++ b/FX2/FX2.h
@@ -80,6 +80,8 @@ enum {
 
    INPKTEND_A       = 0xE648, // Force IN Packet End
    OUTPKTEND_A      = 0xE649, // Force OUT Packet End
+   USBIE_A          = 0xE65C, // USB Interrupt Enable
+   USBIRQ_A         = 0xE65D, // USB Interrupt Request
    INTSETUP_A       = 0xE668, // Interrupt 2 and 4 Setup
    PORTACFG_A       = 0xE670, // I/O PORTA Alternate Configuration Register
    PORTCCFG_A       = 0xE671, // I/O PORTC Alternate Configuration Register
@@ -207,6 +209,8 @@ X8(REVCTL);
 X8(GPIFHOLDAMOUNT);
 X8(INPKTEND);
 X8(OUTPKTEND);
+X8(USBIE);
+X8(USBIRQ);
 X8(INTSETUP);
 X8(PORTACFG);
 X8(PORTCCFG);
@@ -440,6 +444,15 @@ enum {
    REVCTL_DYN_OUT = 1<<1, // Disable Auto-Arming at the 0-1 transition of AUTOOUT
    REVCTL_ENH_PKT = 1<<0, // Enhanced Packet Handling
 
+// USBIE, USBIRQ // USB Interrupt
+   USBI_EP0ACK  = 1<<6, // EndPoint 0 Acknowledge
+   USBI_HSGRANT = 1<<5, // Grant High-Speed Access
+   USBI_URES    = 1<<4, // USB Reset
+   USBI_SUSP    = 1<<3, // Suspend
+   USBI_SUTOK   = 1<<2, // Setup Token
+   USBI_SOF     = 1<<1, // Start of Frame
+   USBI_SUDAV   = 1<<0, // SETUP Data Available 
+
 // PINFLAGSAB, PINFLAGSCD Slave FIFO FLAGA-FLAGD Pin Configuration
    PC_INDEX  =  0, // indexed
    PC_EP2_PF =  4, // EP2, Programmable Flag