57 #define _W5500_SPI_VDM_OP_ 0x00
58 #define _W5500_SPI_FDM_OP_LEN1_ 0x01
59 #define _W5500_SPI_FDM_OP_LEN2_ 0x02
60 #define _W5500_SPI_FDM_OP_LEN4_ 0x03
62 #if (_WIZCHIP_ == 5500)
83 spi_data[0] = (AddrSel & 0x00FF0000) >> 16;
84 spi_data[1] = (AddrSel & 0x0000FF00) >> 8;
85 spi_data[2] = (AddrSel & 0x000000FF) >> 0;
114 spi_data[0] = (AddrSel & 0x00FF0000) >> 16;
115 spi_data[1] = (AddrSel & 0x0000FF00) >> 8;
116 spi_data[2] = (AddrSel & 0x000000FF) >> 0;
140 for(i = 0; i < len; i++)
145 spi_data[0] = (AddrSel & 0x00FF0000) >> 16;
146 spi_data[1] = (AddrSel & 0x0000FF00) >> 8;
147 spi_data[2] = (AddrSel & 0x000000FF) >> 0;
171 for(i = 0; i < len; i++)
176 spi_data[0] = (AddrSel & 0x00FF0000) >> 16;
177 spi_data[1] = (AddrSel & 0x0000FF00) >> 8;
178 spi_data[2] = (AddrSel & 0x000000FF) >> 0;
190 uint16_t val=0,val1=0;
201 }
while (val != val1);
208 uint16_t val=0,val1=0;
219 }
while (val != val1);
223 void wiz_send_data(uint8_t sn, uint8_t *wizdata, uint16_t len)
226 uint32_t addrsel = 0;
240 void wiz_recv_data(uint8_t sn, uint8_t *wizdata, uint16_t len)
243 uint32_t addrsel = 0;
uint8_t(* _read_byte)(void)
void wiz_recv_ignore(uint8_t sn, uint16_t len)
It discard the received data in RX memory.
uint16_t getSn_RX_RSR(uint8_t sn)
Get Sn_RX_RSR register.
void(* _select)(void)
_WIZCHIP_ selected
void WIZCHIP_READ_BUF(uint32_t AddrSel, uint8_t *pBuf, uint16_t len)
It reads sequence data from registers.
void wiz_recv_data(uint8_t sn, uint8_t *wizdata, uint16_t len)
It copies data to your buffer from internal RX memory.
uint8_t WIZCHIP_READ(uint32_t AddrSel)
It reads 1 byte value from a register.
void wiz_send_data(uint8_t sn, uint8_t *wizdata, uint16_t len)
It copies data to internal TX memory.
uint16_t getSn_TX_FSR(uint8_t sn)
Get Sn_TX_FSR register.
void(* _read_burst)(uint8_t *pBuf, uint16_t len)
void(* _deselect)(void)
_WIZCHIP_ deselected
void(* _write_byte)(uint8_t wb)
#define WIZCHIP_CRITICAL_ENTER()
Enter a critical section.
#define WIZCHIP_OFFSET_INC(ADDR, N)
Increase offset address.
struct __WIZCHIP::_IF::@1 SPI
#define getSn_TX_WR(sn)
Get Sn_TX_WR register.
#define Sn_TX_FSR(sn)
Transmit free memory size register(R)
#define _W5500_SPI_WRITE_
#define _W5500_SPI_VDM_OP_
void WIZCHIP_WRITE_BUF(uint32_t AddrSel, uint8_t *pBuf, uint16_t len)
It writes sequence data to registers.
#define Sn_RX_RSR(sn)
Received data size register(R)
void WIZCHIP_WRITE(uint32_t AddrSel, uint8_t wb)
It writes 1 byte value to a register.
#define WIZCHIP_RXBUF_BLOCK(N)
#define setSn_TX_WR(sn, txwr)
Set Sn_TX_WR register.
#define WIZCHIP_CRITICAL_EXIT()
Exit a critical section.
void(* _write_burst)(uint8_t *pBuf, uint16_t len)
#define setSn_RX_RD(sn, rxrd)
Set Sn_RX_RD register.
#define WIZCHIP_TXBUF_BLOCK(N)
#define getSn_RX_RD(sn)
Get Sn_RX_RD register.