USB Host Shield 2.0
Macros
max3421e.h File Reference

Go to the source code of this file.

Macros

#define SE0   0
 
#define SE1   1
 
#define FSHOST   2
 
#define LSHOST   3
 
#define rRCVFIFO   0x08
 
#define rSNDFIFO   0x10
 
#define rSUDFIFO   0x20
 
#define rRCVBC   0x30
 
#define rSNDBC   0x38
 
#define rUSBIRQ   0x68
 
#define bmVBUSIRQ   0x40
 
#define bmNOVBUSIRQ   0x20
 
#define bmOSCOKIRQ   0x01
 
#define rUSBIEN   0x70
 
#define bmVBUSIE   0x40
 
#define bmNOVBUSIE   0x20
 
#define bmOSCOKIE   0x01
 
#define rUSBCTL   0x78
 
#define bmCHIPRES   0x20
 
#define bmPWRDOWN   0x10
 
#define rCPUCTL   0x80
 
#define bmPUSLEWID1   0x80
 
#define bmPULSEWID0   0x40
 
#define bmIE   0x01
 
#define rPINCTL   0x88
 
#define bmFDUPSPI   0x10
 
#define bmINTLEVEL   0x08
 
#define bmPOSINT   0x04
 
#define bmGPXB   0x02
 
#define bmGPXA   0x01
 
#define GPX_OPERATE   0x00
 
#define GPX_VBDET   0x01
 
#define GPX_BUSACT   0x02
 
#define GPX_SOF   0x03
 
#define rREVISION   0x90
 
#define rIOPINS1   0xa0
 
#define bmGPOUT0   0x01
 
#define bmGPOUT1   0x02
 
#define bmGPOUT2   0x04
 
#define bmGPOUT3   0x08
 
#define bmGPIN0   0x10
 
#define bmGPIN1   0x20
 
#define bmGPIN2   0x40
 
#define bmGPIN3   0x80
 
#define rIOPINS2   0xa8
 
#define bmGPOUT4   0x01
 
#define bmGPOUT5   0x02
 
#define bmGPOUT6   0x04
 
#define bmGPOUT7   0x08
 
#define bmGPIN4   0x10
 
#define bmGPIN5   0x20
 
#define bmGPIN6   0x40
 
#define bmGPIN7   0x80
 
#define rGPINIRQ   0xb0
 
#define bmGPINIRQ0   0x01
 
#define bmGPINIRQ1   0x02
 
#define bmGPINIRQ2   0x04
 
#define bmGPINIRQ3   0x08
 
#define bmGPINIRQ4   0x10
 
#define bmGPINIRQ5   0x20
 
#define bmGPINIRQ6   0x40
 
#define bmGPINIRQ7   0x80
 
#define rGPINIEN   0xb8
 
#define bmGPINIEN0   0x01
 
#define bmGPINIEN1   0x02
 
#define bmGPINIEN2   0x04
 
#define bmGPINIEN3   0x08
 
#define bmGPINIEN4   0x10
 
#define bmGPINIEN5   0x20
 
#define bmGPINIEN6   0x40
 
#define bmGPINIEN7   0x80
 
#define rGPINPOL   0xc0
 
#define bmGPINPOL0   0x01
 
#define bmGPINPOL1   0x02
 
#define bmGPINPOL2   0x04
 
#define bmGPINPOL3   0x08
 
#define bmGPINPOL4   0x10
 
#define bmGPINPOL5   0x20
 
#define bmGPINPOL6   0x40
 
#define bmGPINPOL7   0x80
 
#define rHIRQ   0xc8
 
#define bmBUSEVENTIRQ   0x01
 
#define bmRWUIRQ   0x02
 
#define bmRCVDAVIRQ   0x04
 
#define bmSNDBAVIRQ   0x08
 
#define bmSUSDNIRQ   0x10
 
#define bmCONDETIRQ   0x20
 
#define bmFRAMEIRQ   0x40
 
#define bmHXFRDNIRQ   0x80
 
#define rHIEN   0xd0
 
#define bmBUSEVENTIE   0x01
 
#define bmRWUIE   0x02
 
#define bmRCVDAVIE   0x04
 
#define bmSNDBAVIE   0x08
 
#define bmSUSDNIE   0x10
 
#define bmCONDETIE   0x20
 
#define bmFRAMEIE   0x40
 
#define bmHXFRDNIE   0x80
 
#define rMODE   0xd8
 
#define bmHOST   0x01
 
#define bmLOWSPEED   0x02
 
#define bmHUBPRE   0x04
 
#define bmSOFKAENAB   0x08
 
#define bmSEPIRQ   0x10
 
#define bmDELAYISO   0x20
 
#define bmDMPULLDN   0x40
 
#define bmDPPULLDN   0x80
 
#define rPERADDR   0xe0
 
#define rHCTL   0xe8
 
#define bmBUSRST   0x01
 
#define bmFRMRST   0x02
 
#define bmSAMPLEBUS   0x04
 
#define bmSIGRSM   0x08
 
#define bmRCVTOG0   0x10
 
#define bmRCVTOG1   0x20
 
#define bmSNDTOG0   0x40
 
#define bmSNDTOG1   0x80
 
#define rHXFR   0xf0
 
#define tokSETUP   0x10
 
#define tokIN   0x00
 
#define tokOUT   0x20
 
#define tokINHS   0x80
 
#define tokOUTHS   0xA0
 
#define tokISOIN   0x40
 
#define tokISOOUT   0x60
 
#define rHRSL   0xf8
 
#define bmRCVTOGRD   0x10
 
#define bmSNDTOGRD   0x20
 
#define bmKSTATUS   0x40
 
#define bmJSTATUS   0x80
 
#define bmSE0   0x00
 
#define bmSE1   0xc0
 
#define hrSUCCESS   0x00
 
#define hrBUSY   0x01
 
#define hrBADREQ   0x02
 
#define hrUNDEF   0x03
 
#define hrNAK   0x04
 
#define hrSTALL   0x05
 
#define hrTOGERR   0x06
 
#define hrWRONGPID   0x07
 
#define hrBADBC   0x08
 
#define hrPIDERR   0x09
 
#define hrPKTERR   0x0A
 
#define hrCRCERR   0x0B
 
#define hrKERR   0x0C
 
#define hrJERR   0x0D
 
#define hrTIMEOUT   0x0E
 
#define hrBABBLE   0x0F
 
#define MODE_FS_HOST   (bmDPPULLDN|bmDMPULLDN|bmHOST|bmSOFKAENAB)
 
#define MODE_LS_HOST   (bmDPPULLDN|bmDMPULLDN|bmHOST|bmLOWSPEED|bmSOFKAENAB)
 

Macro Definition Documentation

◆ SE0

#define SE0   0

Definition at line 35 of file max3421e.h.

◆ SE1

#define SE1   1

Definition at line 36 of file max3421e.h.

◆ FSHOST

#define FSHOST   2

Definition at line 37 of file max3421e.h.

◆ LSHOST

#define LSHOST   3

Definition at line 38 of file max3421e.h.

◆ rRCVFIFO

#define rRCVFIFO   0x08

Definition at line 44 of file max3421e.h.

◆ rSNDFIFO

#define rSNDFIFO   0x10

Definition at line 45 of file max3421e.h.

◆ rSUDFIFO

#define rSUDFIFO   0x20

Definition at line 46 of file max3421e.h.

◆ rRCVBC

#define rRCVBC   0x30

Definition at line 47 of file max3421e.h.

◆ rSNDBC

#define rSNDBC   0x38

Definition at line 48 of file max3421e.h.

◆ rUSBIRQ

#define rUSBIRQ   0x68

Definition at line 50 of file max3421e.h.

◆ bmVBUSIRQ

#define bmVBUSIRQ   0x40

Definition at line 52 of file max3421e.h.

◆ bmNOVBUSIRQ

#define bmNOVBUSIRQ   0x20

Definition at line 53 of file max3421e.h.

◆ bmOSCOKIRQ

#define bmOSCOKIRQ   0x01

Definition at line 54 of file max3421e.h.

◆ rUSBIEN

#define rUSBIEN   0x70

Definition at line 56 of file max3421e.h.

◆ bmVBUSIE

#define bmVBUSIE   0x40

Definition at line 58 of file max3421e.h.

◆ bmNOVBUSIE

#define bmNOVBUSIE   0x20

Definition at line 59 of file max3421e.h.

◆ bmOSCOKIE

#define bmOSCOKIE   0x01

Definition at line 60 of file max3421e.h.

◆ rUSBCTL

#define rUSBCTL   0x78

Definition at line 62 of file max3421e.h.

◆ bmCHIPRES

#define bmCHIPRES   0x20

Definition at line 64 of file max3421e.h.

◆ bmPWRDOWN

#define bmPWRDOWN   0x10

Definition at line 65 of file max3421e.h.

◆ rCPUCTL

#define rCPUCTL   0x80

Definition at line 67 of file max3421e.h.

◆ bmPUSLEWID1

#define bmPUSLEWID1   0x80

Definition at line 69 of file max3421e.h.

◆ bmPULSEWID0

#define bmPULSEWID0   0x40

Definition at line 70 of file max3421e.h.

◆ bmIE

#define bmIE   0x01

Definition at line 71 of file max3421e.h.

◆ rPINCTL

#define rPINCTL   0x88

Definition at line 73 of file max3421e.h.

◆ bmFDUPSPI

#define bmFDUPSPI   0x10

Definition at line 75 of file max3421e.h.

◆ bmINTLEVEL

#define bmINTLEVEL   0x08

Definition at line 76 of file max3421e.h.

◆ bmPOSINT

#define bmPOSINT   0x04

Definition at line 77 of file max3421e.h.

◆ bmGPXB

#define bmGPXB   0x02

Definition at line 78 of file max3421e.h.

◆ bmGPXA

#define bmGPXA   0x01

Definition at line 79 of file max3421e.h.

◆ GPX_OPERATE

#define GPX_OPERATE   0x00

Definition at line 81 of file max3421e.h.

◆ GPX_VBDET

#define GPX_VBDET   0x01

Definition at line 82 of file max3421e.h.

◆ GPX_BUSACT

#define GPX_BUSACT   0x02

Definition at line 83 of file max3421e.h.

◆ GPX_SOF

#define GPX_SOF   0x03

Definition at line 84 of file max3421e.h.

◆ rREVISION

#define rREVISION   0x90

Definition at line 86 of file max3421e.h.

◆ rIOPINS1

#define rIOPINS1   0xa0

Definition at line 88 of file max3421e.h.

◆ bmGPOUT0

#define bmGPOUT0   0x01

Definition at line 91 of file max3421e.h.

◆ bmGPOUT1

#define bmGPOUT1   0x02

Definition at line 92 of file max3421e.h.

◆ bmGPOUT2

#define bmGPOUT2   0x04

Definition at line 93 of file max3421e.h.

◆ bmGPOUT3

#define bmGPOUT3   0x08

Definition at line 94 of file max3421e.h.

◆ bmGPIN0

#define bmGPIN0   0x10

Definition at line 95 of file max3421e.h.

◆ bmGPIN1

#define bmGPIN1   0x20

Definition at line 96 of file max3421e.h.

◆ bmGPIN2

#define bmGPIN2   0x40

Definition at line 97 of file max3421e.h.

◆ bmGPIN3

#define bmGPIN3   0x80

Definition at line 98 of file max3421e.h.

◆ rIOPINS2

#define rIOPINS2   0xa8

Definition at line 100 of file max3421e.h.

◆ bmGPOUT4

#define bmGPOUT4   0x01

Definition at line 102 of file max3421e.h.

◆ bmGPOUT5

#define bmGPOUT5   0x02

Definition at line 103 of file max3421e.h.

◆ bmGPOUT6

#define bmGPOUT6   0x04

Definition at line 104 of file max3421e.h.

◆ bmGPOUT7

#define bmGPOUT7   0x08

Definition at line 105 of file max3421e.h.

◆ bmGPIN4

#define bmGPIN4   0x10

Definition at line 106 of file max3421e.h.

◆ bmGPIN5

#define bmGPIN5   0x20

Definition at line 107 of file max3421e.h.

◆ bmGPIN6

#define bmGPIN6   0x40

Definition at line 108 of file max3421e.h.

◆ bmGPIN7

#define bmGPIN7   0x80

Definition at line 109 of file max3421e.h.

◆ rGPINIRQ

#define rGPINIRQ   0xb0

Definition at line 111 of file max3421e.h.

◆ bmGPINIRQ0

#define bmGPINIRQ0   0x01

Definition at line 113 of file max3421e.h.

◆ bmGPINIRQ1

#define bmGPINIRQ1   0x02

Definition at line 114 of file max3421e.h.

◆ bmGPINIRQ2

#define bmGPINIRQ2   0x04

Definition at line 115 of file max3421e.h.

◆ bmGPINIRQ3

#define bmGPINIRQ3   0x08

Definition at line 116 of file max3421e.h.

◆ bmGPINIRQ4

#define bmGPINIRQ4   0x10

Definition at line 117 of file max3421e.h.

◆ bmGPINIRQ5

#define bmGPINIRQ5   0x20

Definition at line 118 of file max3421e.h.

◆ bmGPINIRQ6

#define bmGPINIRQ6   0x40

Definition at line 119 of file max3421e.h.

◆ bmGPINIRQ7

#define bmGPINIRQ7   0x80

Definition at line 120 of file max3421e.h.

◆ rGPINIEN

#define rGPINIEN   0xb8

Definition at line 122 of file max3421e.h.

◆ bmGPINIEN0

#define bmGPINIEN0   0x01

Definition at line 124 of file max3421e.h.

◆ bmGPINIEN1

#define bmGPINIEN1   0x02

Definition at line 125 of file max3421e.h.

◆ bmGPINIEN2

#define bmGPINIEN2   0x04

Definition at line 126 of file max3421e.h.

◆ bmGPINIEN3

#define bmGPINIEN3   0x08

Definition at line 127 of file max3421e.h.

◆ bmGPINIEN4

#define bmGPINIEN4   0x10

Definition at line 128 of file max3421e.h.

◆ bmGPINIEN5

#define bmGPINIEN5   0x20

Definition at line 129 of file max3421e.h.

◆ bmGPINIEN6

#define bmGPINIEN6   0x40

Definition at line 130 of file max3421e.h.

◆ bmGPINIEN7

#define bmGPINIEN7   0x80

Definition at line 131 of file max3421e.h.

◆ rGPINPOL

#define rGPINPOL   0xc0

Definition at line 133 of file max3421e.h.

◆ bmGPINPOL0

#define bmGPINPOL0   0x01

Definition at line 135 of file max3421e.h.

◆ bmGPINPOL1

#define bmGPINPOL1   0x02

Definition at line 136 of file max3421e.h.

◆ bmGPINPOL2

#define bmGPINPOL2   0x04

Definition at line 137 of file max3421e.h.

◆ bmGPINPOL3

#define bmGPINPOL3   0x08

Definition at line 138 of file max3421e.h.

◆ bmGPINPOL4

#define bmGPINPOL4   0x10

Definition at line 139 of file max3421e.h.

◆ bmGPINPOL5

#define bmGPINPOL5   0x20

Definition at line 140 of file max3421e.h.

◆ bmGPINPOL6

#define bmGPINPOL6   0x40

Definition at line 141 of file max3421e.h.

◆ bmGPINPOL7

#define bmGPINPOL7   0x80

Definition at line 142 of file max3421e.h.

◆ rHIRQ

#define rHIRQ   0xc8

Definition at line 144 of file max3421e.h.

◆ bmBUSEVENTIRQ

#define bmBUSEVENTIRQ   0x01

Definition at line 146 of file max3421e.h.

◆ bmRWUIRQ

#define bmRWUIRQ   0x02

Definition at line 147 of file max3421e.h.

◆ bmRCVDAVIRQ

#define bmRCVDAVIRQ   0x04

Definition at line 148 of file max3421e.h.

◆ bmSNDBAVIRQ

#define bmSNDBAVIRQ   0x08

Definition at line 149 of file max3421e.h.

◆ bmSUSDNIRQ

#define bmSUSDNIRQ   0x10

Definition at line 150 of file max3421e.h.

◆ bmCONDETIRQ

#define bmCONDETIRQ   0x20

Definition at line 151 of file max3421e.h.

◆ bmFRAMEIRQ

#define bmFRAMEIRQ   0x40

Definition at line 152 of file max3421e.h.

◆ bmHXFRDNIRQ

#define bmHXFRDNIRQ   0x80

Definition at line 153 of file max3421e.h.

◆ rHIEN

#define rHIEN   0xd0

Definition at line 155 of file max3421e.h.

◆ bmBUSEVENTIE

#define bmBUSEVENTIE   0x01

Definition at line 158 of file max3421e.h.

◆ bmRWUIE

#define bmRWUIE   0x02

Definition at line 159 of file max3421e.h.

◆ bmRCVDAVIE

#define bmRCVDAVIE   0x04

Definition at line 160 of file max3421e.h.

◆ bmSNDBAVIE

#define bmSNDBAVIE   0x08

Definition at line 161 of file max3421e.h.

◆ bmSUSDNIE

#define bmSUSDNIE   0x10

Definition at line 162 of file max3421e.h.

◆ bmCONDETIE

#define bmCONDETIE   0x20

Definition at line 163 of file max3421e.h.

◆ bmFRAMEIE

#define bmFRAMEIE   0x40

Definition at line 164 of file max3421e.h.

◆ bmHXFRDNIE

#define bmHXFRDNIE   0x80

Definition at line 165 of file max3421e.h.

◆ rMODE

#define rMODE   0xd8

Definition at line 167 of file max3421e.h.

◆ bmHOST

#define bmHOST   0x01

Definition at line 170 of file max3421e.h.

◆ bmLOWSPEED

#define bmLOWSPEED   0x02

Definition at line 171 of file max3421e.h.

◆ bmHUBPRE

#define bmHUBPRE   0x04

Definition at line 172 of file max3421e.h.

◆ bmSOFKAENAB

#define bmSOFKAENAB   0x08

Definition at line 173 of file max3421e.h.

◆ bmSEPIRQ

#define bmSEPIRQ   0x10

Definition at line 174 of file max3421e.h.

◆ bmDELAYISO

#define bmDELAYISO   0x20

Definition at line 175 of file max3421e.h.

◆ bmDMPULLDN

#define bmDMPULLDN   0x40

Definition at line 176 of file max3421e.h.

◆ bmDPPULLDN

#define bmDPPULLDN   0x80

Definition at line 177 of file max3421e.h.

◆ rPERADDR

#define rPERADDR   0xe0

Definition at line 179 of file max3421e.h.

◆ rHCTL

#define rHCTL   0xe8

Definition at line 181 of file max3421e.h.

◆ bmBUSRST

#define bmBUSRST   0x01

Definition at line 183 of file max3421e.h.

◆ bmFRMRST

#define bmFRMRST   0x02

Definition at line 184 of file max3421e.h.

◆ bmSAMPLEBUS

#define bmSAMPLEBUS   0x04

Definition at line 185 of file max3421e.h.

◆ bmSIGRSM

#define bmSIGRSM   0x08

Definition at line 186 of file max3421e.h.

◆ bmRCVTOG0

#define bmRCVTOG0   0x10

Definition at line 187 of file max3421e.h.

◆ bmRCVTOG1

#define bmRCVTOG1   0x20

Definition at line 188 of file max3421e.h.

◆ bmSNDTOG0

#define bmSNDTOG0   0x40

Definition at line 189 of file max3421e.h.

◆ bmSNDTOG1

#define bmSNDTOG1   0x80

Definition at line 190 of file max3421e.h.

◆ rHXFR

#define rHXFR   0xf0

Definition at line 192 of file max3421e.h.

◆ tokSETUP

#define tokSETUP   0x10

Definition at line 195 of file max3421e.h.

◆ tokIN

#define tokIN   0x00

Definition at line 196 of file max3421e.h.

◆ tokOUT

#define tokOUT   0x20

Definition at line 197 of file max3421e.h.

◆ tokINHS

#define tokINHS   0x80

Definition at line 198 of file max3421e.h.

◆ tokOUTHS

#define tokOUTHS   0xA0

Definition at line 199 of file max3421e.h.

◆ tokISOIN

#define tokISOIN   0x40

Definition at line 200 of file max3421e.h.

◆ tokISOOUT

#define tokISOOUT   0x60

Definition at line 201 of file max3421e.h.

◆ rHRSL

#define rHRSL   0xf8

Definition at line 203 of file max3421e.h.

◆ bmRCVTOGRD

#define bmRCVTOGRD   0x10

Definition at line 206 of file max3421e.h.

◆ bmSNDTOGRD

#define bmSNDTOGRD   0x20

Definition at line 207 of file max3421e.h.

◆ bmKSTATUS

#define bmKSTATUS   0x40

Definition at line 208 of file max3421e.h.

◆ bmJSTATUS

#define bmJSTATUS   0x80

Definition at line 209 of file max3421e.h.

◆ bmSE0

#define bmSE0   0x00

Definition at line 210 of file max3421e.h.

◆ bmSE1

#define bmSE1   0xc0

Definition at line 211 of file max3421e.h.

◆ hrSUCCESS

#define hrSUCCESS   0x00

Definition at line 214 of file max3421e.h.

◆ hrBUSY

#define hrBUSY   0x01

Definition at line 215 of file max3421e.h.

◆ hrBADREQ

#define hrBADREQ   0x02

Definition at line 216 of file max3421e.h.

◆ hrUNDEF

#define hrUNDEF   0x03

Definition at line 217 of file max3421e.h.

◆ hrNAK

#define hrNAK   0x04

Definition at line 218 of file max3421e.h.

◆ hrSTALL

#define hrSTALL   0x05

Definition at line 219 of file max3421e.h.

◆ hrTOGERR

#define hrTOGERR   0x06

Definition at line 220 of file max3421e.h.

◆ hrWRONGPID

#define hrWRONGPID   0x07

Definition at line 221 of file max3421e.h.

◆ hrBADBC

#define hrBADBC   0x08

Definition at line 222 of file max3421e.h.

◆ hrPIDERR

#define hrPIDERR   0x09

Definition at line 223 of file max3421e.h.

◆ hrPKTERR

#define hrPKTERR   0x0A

Definition at line 224 of file max3421e.h.

◆ hrCRCERR

#define hrCRCERR   0x0B

Definition at line 225 of file max3421e.h.

◆ hrKERR

#define hrKERR   0x0C

Definition at line 226 of file max3421e.h.

◆ hrJERR

#define hrJERR   0x0D

Definition at line 227 of file max3421e.h.

◆ hrTIMEOUT

#define hrTIMEOUT   0x0E

Definition at line 228 of file max3421e.h.

◆ hrBABBLE

#define hrBABBLE   0x0F

Definition at line 229 of file max3421e.h.

◆ MODE_FS_HOST

#define MODE_FS_HOST   (bmDPPULLDN|bmDMPULLDN|bmHOST|bmSOFKAENAB)

Definition at line 231 of file max3421e.h.

◆ MODE_LS_HOST

#define MODE_LS_HOST   (bmDPPULLDN|bmDMPULLDN|bmHOST|bmLOWSPEED|bmSOFKAENAB)

Definition at line 232 of file max3421e.h.