Header for SJA1000 CAN-Bus controller driver. More...
#include <stdint.h>
Go to the source code of this file.
Defines | |
#define | SJA1000_MODECTRL (*(volatile uint8_t*) (sja_base+0)) |
#define | RM_RR_Bit 0x01 |
#define | LOM_Bit 0x02 |
#define | STM_Bit 0x04 |
#define | AFM_Bit 0x08 |
#define | SM_Bit 0x10 |
#define | SJA1000_IEN (*(volatile uint8_t*) (sja_base+4)) |
#define | RIE_Bit 0x01 |
#define | TIE_Bit 0x02 |
#define | EIE_Bit 0x04 |
#define | DOIE_Bit 0x08 |
#define | WUIE_Bit 0x10 |
#define | EPIE_Bit 0x20 |
#define | ALIE_Bit 0x40 |
#define | BEIE_Bit 0x80 |
#define | SJA1000_CMD (*(volatile uint8_t*) (sja_base+1)) |
#define | TR_Bit 0x01 |
#define | AT_Bit 0x02 |
#define | RRB_Bit 0x04 |
#define | CDO_Bit 0x08 |
#define | SRR_Bit 0x10 |
#define | SJA1000_STATUS (*(volatile uint8_t*) (sja_base+2)) |
#define | RBS_Bit 0x01 |
#define | DOS_Bit 0x02 |
#define | TBS_Bit 0x04 |
#define | TCS_Bit 0x08 |
#define | RS_Bit 0x10 |
#define | TS_Bit 0x20 |
#define | ES_Bit 0x40 |
#define | BS_Bit 0x80 |
#define | SJA1000_INT (*(volatile uint8_t*) (sja_base+3)) |
#define | RI_Bit 0x01 |
#define | TI_Bit 0x02 |
#define | EI_Bit 0x04 |
#define | DOI_Bit 0x08 |
#define | WUI_Bit 0x10 |
#define | EPI_Bit 0x20 |
#define | ALI_Bit 0x40 |
#define | BEI_Bit 0x80 |
#define | SJA1000_BT0 (*(volatile uint8_t*) (sja_base+6)) |
#define | SJA1000_BT1 (*(volatile uint8_t*) (sja_base+7)) |
#define | SAM_Bit 0x80 |
#define | SJA1000_OUTCTRL (*(volatile uint8_t*) (sja_base+8)) |
#define | BiPhaseMode 0x00 |
#define | NormalMode 0x02 |
#define | ClkOutMode 0x03 |
#define | OCPOL1_Bit 0x20 |
#define | Tx1Float 0x00 |
#define | Tx1PullDn 0x40 |
#define | Tx1PullUp 0x80 |
#define | Tx1PshPull 0xC0 |
#define | OCPOLO_Bit 0x04 |
#define | Tx0Float 0x00 |
#define | Tx0PullDn 0x08 |
#define | Tx0PullUp 0x10 |
#define | Tx0PshPull 0x18 |
#define | SJA1000_AC0 (*(volatile uint8_t*) (sja_base+16)) |
#define | SJA1000_AC1 (*(volatile uint8_t*) (sja_base+17)) |
#define | SJA1000_AC2 (*(volatile uint8_t*) (sja_base+18)) |
#define | SJA1000_AC3 (*(volatile uint8_t*) (sja_base+19)) |
#define | SJA1000_AM0 (*(volatile uint8_t*) (sja_base+20)) |
#define | SJA1000_AM1 (*(volatile uint8_t*) (sja_base+21)) |
#define | SJA1000_AM2 (*(volatile uint8_t*) (sja_base+22)) |
#define | SJA1000_AM3 (*(volatile uint8_t*) (sja_base+23)) |
#define | SJA1000_RxFrameInfo (*(volatile uint8_t*) (sja_base+16)) |
#define | SJA1000_Rx1 (*(volatile uint8_t*) (sja_base+17)) |
#define | SJA1000_Rx2 (*(volatile uint8_t*) (sja_base+18)) |
#define | SJA1000_Rx3 (*(volatile uint8_t*) (sja_base+19)) |
#define | SJA1000_Rx4 (*(volatile uint8_t*) (sja_base+20)) |
#define | SJA1000_Rx5 (*(volatile uint8_t*) (sja_base+21)) |
#define | SJA1000_Rx6 (*(volatile uint8_t*) (sja_base+22)) |
#define | SJA1000_Rx7 (*(volatile uint8_t*) (sja_base+23)) |
#define | SJA1000_Rx8 (*(volatile uint8_t*) (sja_base+24)) |
#define | SJA1000_Rx9 (*(volatile uint8_t*) (sja_base+25)) |
#define | SJA1000_Rx10 (*(volatile uint8_t*) (sja_base+26)) |
#define | SJA1000_Rx11 (*(volatile uint8_t*) (sja_base+27)) |
#define | SJA1000_Rx12 (*(volatile uint8_t*) (sja_base+28)) |
#define | TestReg (*(volatile uint8_t*) (sja_base+9)) |
#define | SJA1000_TxFrameInfo (*(volatile uint8_t*) (sja_base+16)) |
#define | SJA1000_Tx1 (*(volatile uint8_t*) (sja_base+17)) |
#define | SJA1000_Tx2 (*(volatile uint8_t*) (sja_base+18)) |
#define | SJA1000_Tx3 (*(volatile uint8_t*) (sja_base+19)) |
#define | SJA1000_Tx4 (*(volatile uint8_t*) (sja_base+20)) |
#define | SJA1000_Tx5 (*(volatile uint8_t*) (sja_base+21)) |
#define | SJA1000_Tx6 (*(volatile uint8_t*) (sja_base+22)) |
#define | SJA1000_Tx7 (*(volatile uint8_t*) (sja_base+23)) |
#define | SJA1000_Tx8 (*(volatile uint8_t*) (sja_base+24)) |
#define | SJA1000_Tx9 (*(volatile uint8_t*) (sja_base+25)) |
#define | SJA1000_Tx10 (*(volatile uint8_t*) (sja_base+26)) |
#define | SJA1000_Tx11 (*(volatile uint8_t*) (sja_base+27)) |
#define | SJA1000_Tx12 (*(volatile uint8_t*) (sja_base+28)) |
#define | SJA1000_TxFrameInfoRd (*(volatile uint8_t*) (sja_base+96)) |
#define | SJA1000_TxRd1 (*(volatile uint8_t*) (sja_base+97)) |
#define | SJA1000_TxRd2 (*(volatile uint8_t*) (sja_base+98)) |
#define | SJA1000_TxRd3 (*(volatile uint8_t*) (sja_base+99)) |
#define | SJA1000_TxRd4 (*(volatile uint8_t*) (sja_base+100)) |
#define | SJA1000_TxRd5 (*(volatile uint8_t*) (sja_base+101)) |
#define | SJA1000_TxRd6 (*(volatile uint8_t*) (sja_base+102)) |
#define | SJA1000_TxRd7 (*(volatile uint8_t*) (sja_base+103)) |
#define | SJA1000_TxRd8 (*(volatile uint8_t*) (sja_base+104)) |
#define | SJA1000_TxRd9 (*(volatile uint8_t*) (sja_base+105)) |
#define | SJA1000_TxRd10 (*(volatile uint8_t*) (sja_base+106)) |
#define | SJA1000_TxRd11 (*(volatile uint8_t*) (sja_base+107)) |
#define | SJA1000_TxRd12 (*(volatile uint8_t*) (sja_base+108)) |
#define | SJA1000_ArbLostCap (*(volatile uint8_t*) (sja_base+11)) |
#define | SJA1000_ErrCodeCap (*(volatile uint8_t*) (sja_base+12)) |
#define | SJA1000_ErrWarnLimit (*(volatile uint8_t*) (sja_base+13)) |
#define | SJA1000_RxErrCount (*(volatile uint8_t*) (sja_base+14)) |
#define | SJA1000_TxErrCount (*(volatile uint8_t*) (sja_base+15)) |
#define | SJA1000_RxMsgCount (*(volatile uint8_t*) (sja_base+29)) |
#define | SJA1000_RxBufStartAdr (*(volatile uint8_t*) (sja_base+30)) |
#define | SJA1000_CLK_DIV (*(volatile uint8_t*) (sja_base+31)) |
#define | DivBy1 0x07 |
#define | DivBy2 0x00 |
#define | ClkOff_Bit 0x08 |
#define | RXINTEN_Bit 0x20 |
#define | CBP_Bit 0x40 |
#define | CANMode_Bit 0x80 |
#define | ClkOutMode 0x03 |
#define | OCPOL1_Bit 0x20 |
#define | Tx1Float 0x00 |
#define | Tx1PullDn 0x40 |
#define | Tx1PullUp 0x80 |
#define | Tx1PshPull 0xC0 |
#define | OCPOL0_Bit 0x04 |
#define | Tx0Float 0x00 |
#define | Tx0PullDn 0x08 |
#define | Presc_MB_16 0x00 |
#define | SJW_MB_16 0x00 |
#define | TSEG1_MB_16 0x04 |
#define | TSEG2_MB_16 0x10 |
#define | errCAN_INVALID_BAUD 7 |
#define | CAN_OK 0 |
#define | CAN_ERR 1 |
#define | CAN_INIT_SPEED_ERR 1 |
#define | CAN_NOT_INITIATED 1 |
#define | CAN_NOT_STARTED 1 |
#define | CAN_TXBUF_FULL 2 |
#define | CAN_RXBUF_EMPTY 2 |
#define | CAN_LOST_FRAME 0x01 |
#define | CAN_BUS_OFF 0x02 |
#define | CAN_29 0x80 |
#define | CAN_RTR 0x40 |
#define | ClrIntEnSJA 0x00 |
Variables | |
NUTDEVICE | devSJA1000 |
Device information structure. |
Header for SJA1000 CAN-Bus controller driver.
The SJA1000 controller is connected to the memory bus. It's base address and interrupt is set by NutRegisterDevice.
Have a look to our m-can board if you have questions.
Definition in file sja1000.h.