Socket APIs
|
WIZCHIP Config Header File. More...
Go to the source code of this file.
Functions | |
void | wizchip_cris_enter (void) |
Default function to enable interrupt. More... | |
void | wizchip_cris_exit (void) |
Default function to disable interrupt. More... | |
void | wizchip_cs_select (void) |
Default function to select chip. More... | |
void | wizchip_cs_deselect (void) |
Default function to deselect chip. More... | |
iodata_t | wizchip_bus_readdata (uint32_t AddrSel) |
Default function to read in direct or indirect interface. More... | |
void | wizchip_bus_writedata (uint32_t AddrSel, iodata_t wb) |
Default function to write in direct or indirect interface. More... | |
uint8_t | wizchip_spi_readbyte (void) |
Default function to read in SPI interface. More... | |
void | wizchip_spi_writebyte (uint8_t wb) |
Default function to write in SPI interface. More... | |
void | wizchip_spi_readburst (uint8_t *pBuf, uint16_t len) |
Default function to burst read in SPI interface. More... | |
void | wizchip_spi_writeburst (uint8_t *pBuf, uint16_t len) |
Default function to burst write in SPI interface. More... | |
void | reg_wizchip_cris_cbfunc (void(*cris_en)(void), void(*cris_ex)(void)) |
Registers call back function for critical section of I/O functions such as WIZCHIP_READ, WIZCHIP_WRITE, WIZCHIP_READ_BUF and WIZCHIP_WRITE_BUF. More... | |
void | reg_wizchip_cs_cbfunc (void(*cs_sel)(void), void(*cs_desel)(void)) |
Registers call back function for WIZCHIP select & deselect. More... | |
void | reg_wizchip_bus_cbfunc (iodata_t(*bus_rb)(uint32_t addr), void(*bus_wb)(uint32_t addr, iodata_t wb)) |
Registers call back function for bus interface. More... | |
void | reg_wizchip_spi_cbfunc (uint8_t(*spi_rb)(void), void(*spi_wb)(uint8_t wb)) |
Registers call back function for SPI interface. More... | |
void | reg_wizchip_spiburst_cbfunc (void(*spi_rb)(uint8_t *pBuf, uint16_t len), void(*spi_wb)(uint8_t *pBuf, uint16_t len)) |
Registers call back function for SPI interface. More... | |
int8_t | ctlwizchip (ctlwizchip_type cwtype, void *arg) |
Controls to the WIZCHIP. More... | |
int8_t | ctlnetwork (ctlnetwork_type cntype, void *arg) |
Controls to network. More... | |
void | wizchip_sw_reset (void) |
Reset WIZCHIP by softly. More... | |
int8_t | wizchip_init (uint8_t *txsize, uint8_t *rxsize) |
Initializes WIZCHIP with socket buffer size. More... | |
void | wizchip_clrinterrupt (intr_kind intr) |
Clear Interrupt of WIZCHIP. More... | |
intr_kind | wizchip_getinterrupt (void) |
Get Interrupt of WIZCHIP. More... | |
void | wizchip_setinterruptmask (intr_kind intr) |
Mask or Unmask Interrupt of WIZCHIP. More... | |
intr_kind | wizchip_getinterruptmask (void) |
Get Interrupt mask of WIZCHIP. More... | |
int8_t | wizphy_getphylink (void) |
get the link status of phy in WIZCHIP. No use in W5100 More... | |
int8_t | wizphy_getphypmode (void) |
get the power mode of PHY in WIZCHIP. No use in W5100 More... | |
void | wizphy_reset (void) |
Reset phy. Vailid only in W5500. More... | |
void | wizphy_setphyconf (wiz_PhyConf *phyconf) |
Set the phy information for WIZCHIP without power mode. More... | |
void | wizphy_getphyconf (wiz_PhyConf *phyconf) |
Get phy configuration information. More... | |
void | wizphy_getphystat (wiz_PhyConf *phyconf) |
Get phy status. More... | |
int8_t | wizphy_setphypmode (uint8_t pmode) |
set the power mode of phy inside WIZCHIP. Refer to PHYCFGR in W5500, PHYSTATUS in W5200 More... | |
void | wizchip_setnetinfo (wiz_NetInfo *pnetinfo) |
Set the network information for WIZCHIP. More... | |
void | wizchip_getnetinfo (wiz_NetInfo *pnetinfo) |
Get the network information for WIZCHIP. More... | |
int8_t | wizchip_setnetmode (netmode_type netmode) |
Set the network mode such WOL, PPPoE, Ping Block, and etc. More... | |
netmode_type | wizchip_getnetmode (void) |
Get the network mode such WOL, PPPoE, Ping Block, and etc. More... | |
void | wizchip_settimeout (wiz_NetTimeout *nettime) |
Set retry time value(RTR) and retry count(RCR). More... | |
void | wizchip_gettimeout (wiz_NetTimeout *nettime) |
Get retry time value(RTR) and retry count(RCR). More... | |
Variables | |
_WIZCHIP | WIZCHIP |
Detailed Description
WIZCHIP Config Header File.
- Version
- 1.0.1
- Date
- 2013/10/21
- Revision history
- <2015/02/05> Notice The version history is not updated after this point. Download the latest version directly from GitHub. Please visit the our GitHub repository for ioLibrary. >> https://github.com/Wiznet/ioLibrary_Driver <2014/05/01> V1.0.1 Refer to M20140501
- Explicit type casting in wizchip_bus_readdata() & wizchip_bus_writedata()
Definition in file wizchip_conf.c.
Function Documentation
void wizchip_cris_enter | ( | void | ) |
Default function to enable interrupt.
uint32_t type converts into ptrdiff_t first. And then recoverting it into uint8_t* For remove the warning when pointer type size is not 32bit. If ptrdiff_t doesn't support in your complier, You should must replace ptrdiff_t into your suitable pointer type. <2013/10/21> 1st Release
- Author
- MidnightCow
- Copyright
Copyright (c) 2013, WIZnet Co., LTD. All rights reserved.
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
- Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
- Neither the name of the <ORGANIZATION> nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- Note
- This function help not to access wrong address. If you do not describe this function or register any functions, null function is called.
Definition at line 67 of file wizchip_conf.c.
Referenced by reg_wizchip_cris_cbfunc().
void wizchip_cris_exit | ( | void | ) |
Default function to disable interrupt.
- Note
- This function help not to access wrong address. If you do not describe this function or register any functions, null function is called.
Definition at line 75 of file wizchip_conf.c.
Referenced by reg_wizchip_cris_cbfunc().
void wizchip_cs_select | ( | void | ) |
Default function to select chip.
- Note
- This function help not to access wrong address. If you do not describe this function or register any functions, null function is called.
Definition at line 83 of file wizchip_conf.c.
Referenced by reg_wizchip_cs_cbfunc().
void wizchip_cs_deselect | ( | void | ) |
Default function to deselect chip.
- Note
- This function help not to access wrong address. If you do not describe this function or register any functions, null function is called.
Definition at line 91 of file wizchip_conf.c.
Referenced by reg_wizchip_cs_cbfunc().
iodata_t wizchip_bus_readdata | ( | uint32_t | AddrSel | ) |
Default function to read in direct or indirect interface.
- Note
- This function help not to access wrong address. If you do not describe this function or register any functions, null function is called.
Definition at line 100 of file wizchip_conf.c.
Referenced by reg_wizchip_bus_cbfunc().
void wizchip_bus_writedata | ( | uint32_t | AddrSel, |
iodata_t | wb | ||
) |
Default function to write in direct or indirect interface.
- Note
- This function help not to access wrong address. If you do not describe this function or register any functions, null function is called.
Definition at line 109 of file wizchip_conf.c.
Referenced by reg_wizchip_bus_cbfunc().
uint8_t wizchip_spi_readbyte | ( | void | ) |
Default function to read in SPI interface.
- Note
- This function help not to access wrong address. If you do not describe this function or register any functions, null function is called.
Definition at line 117 of file wizchip_conf.c.
Referenced by reg_wizchip_spi_cbfunc().
void wizchip_spi_writebyte | ( | uint8_t | wb | ) |
Default function to write in SPI interface.
- Note
- This function help not to access wrong address. If you do not describe this function or register any functions, null function is called.
Definition at line 125 of file wizchip_conf.c.
Referenced by reg_wizchip_spi_cbfunc().
void wizchip_spi_readburst | ( | uint8_t * | pBuf, |
uint16_t | len | ||
) |
Default function to burst read in SPI interface.
- Note
- This function help not to access wrong address. If you do not describe this function or register any functions, null function is called.
Definition at line 133 of file wizchip_conf.c.
Referenced by reg_wizchip_spiburst_cbfunc().
void wizchip_spi_writeburst | ( | uint8_t * | pBuf, |
uint16_t | len | ||
) |
Default function to burst write in SPI interface.
- Note
- This function help not to access wrong address. If you do not describe this function or register any functions, null function is called.
Definition at line 141 of file wizchip_conf.c.
Referenced by reg_wizchip_spiburst_cbfunc().
void reg_wizchip_cris_cbfunc | ( | void(*)(void) | cris_en, |
void(*)(void) | cris_ex | ||
) |
Registers call back function for critical section of I/O functions such as WIZCHIP_READ, WIZCHIP_WRITE, WIZCHIP_READ_BUF and WIZCHIP_WRITE_BUF.
- Parameters
-
cris_en : callback function for critical section enter. cris_ex : callback function for critical section exit.
- Todo:
- Describe WIZCHIP_CRITICAL_ENTER and WIZCHIP_CRITICAL_EXIT marco or register your functions.
- Note
- If you do not describe or register, default functions(wizchip_cris_enter & wizchip_cris_exit) is called.
Definition at line 186 of file wizchip_conf.c.
References __WIZCHIP::_CRIS::_enter, __WIZCHIP::_CRIS::_exit, __WIZCHIP::CRIS, wizchip_cris_enter(), and wizchip_cris_exit().
void reg_wizchip_cs_cbfunc | ( | void(*)(void) | cs_sel, |
void(*)(void) | cs_desel | ||
) |
Registers call back function for WIZCHIP select & deselect.
- Parameters
-
cs_sel : callback function for WIZCHIP select cs_desel : callback fucntion for WIZCHIP deselect
- Todo:
- Describe wizchip_cs_select and wizchip_cs_deselect function or register your functions.
- Note
- If you do not describe or register, null function is called.
Definition at line 200 of file wizchip_conf.c.
References __WIZCHIP::_CS::_deselect, __WIZCHIP::_CS::_select, __WIZCHIP::CS, wizchip_cs_deselect(), and wizchip_cs_select().
void reg_wizchip_bus_cbfunc | ( | iodata_t(*)(uint32_t addr) | bus_rb, |
void(*)(uint32_t addr, iodata_t wb) | bus_wb | ||
) |
Registers call back function for bus interface.
- Parameters
-
bus_rb : callback function to read byte data using system bus bus_wb : callback function to write byte data using system bus
- Todo:
- Describe wizchip_bus_readbyte and wizchip_bus_writebyte function or register your functions.
- Note
- If you do not describe or register, null function is called.
Definition at line 216 of file wizchip_conf.c.
References __WIZCHIP::_IF::_read_data, _WIZCHIP_IO_MODE_BUS_, __WIZCHIP::_IF::_write_data, __WIZCHIP::_IF::BUS, __WIZCHIP::IF, __WIZCHIP::if_mode, wizchip_bus_readdata(), and wizchip_bus_writedata().
void reg_wizchip_spi_cbfunc | ( | uint8_t(*)(void) | spi_rb, |
void(*)(uint8_t wb) | spi_wb | ||
) |
Registers call back function for SPI interface.
- Parameters
-
spi_rb : callback function to read byte using SPI spi_wb : callback function to write byte using SPI
- Todo:
- Describe wizchip_spi_readbyte and wizchip_spi_writebyte function or register your functions.
- Note
- If you do not describe or register, null function is called.
Definition at line 244 of file wizchip_conf.c.
References __WIZCHIP::_IF::_read_byte, _WIZCHIP_IO_MODE_SPI_, __WIZCHIP::_IF::_write_byte, __WIZCHIP::IF, __WIZCHIP::if_mode, __WIZCHIP::_IF::SPI, wizchip_spi_readbyte(), and wizchip_spi_writebyte().
void reg_wizchip_spiburst_cbfunc | ( | void(*)(uint8_t *pBuf, uint16_t len) | spi_rb, |
void(*)(uint8_t *pBuf, uint16_t len) | spi_wb | ||
) |
Registers call back function for SPI interface.
- Parameters
-
spi_rb : callback function to burst read using SPI spi_wb : callback function to burst write using SPI
- Todo:
- Describe wizchip_spi_readbyte and wizchip_spi_writebyte function or register your functions.
- Note
- If you do not describe or register, null function is called.
Definition at line 261 of file wizchip_conf.c.
References __WIZCHIP::_IF::_read_burst, _WIZCHIP_IO_MODE_SPI_, __WIZCHIP::_IF::_write_burst, __WIZCHIP::IF, __WIZCHIP::if_mode, __WIZCHIP::_IF::SPI, wizchip_spi_readburst(), and wizchip_spi_writeburst().
int8_t wizphy_getphylink | ( | void | ) |
get the link status of phy in WIZCHIP. No use in W5100
Definition at line 575 of file wizchip_conf.c.
References getPHYCFGR, getPHYSTATUS, PHY_LINK_OFF, PHY_LINK_ON, PHYCFGR_LNK_ON, and PHYSTATUS_LINK.
Referenced by ctlwizchip().
int8_t wizphy_getphypmode | ( | void | ) |
get the power mode of PHY in WIZCHIP. No use in W5100
Definition at line 596 of file wizchip_conf.c.
References getPHYCFGR, getPHYSTATUS, PHY_POWER_DOWN, PHY_POWER_NORM, PHYCFGR_OPMDC_PDOWN, and PHYSTATUS_POWERDOWN.
Referenced by ctlwizchip().
void wizphy_reset | ( | void | ) |
Reset phy. Vailid only in W5500.
Definition at line 617 of file wizchip_conf.c.
References getPHYCFGR, PHYCFGR_RST, and setPHYCFGR.
Referenced by ctlwizchip(), wizphy_setphyconf(), and wizphy_setphypmode().
Variable Documentation
_WIZCHIP WIZCHIP |
\ref _WIZCHIP instance
Definition at line 165 of file wizchip_conf.c.
Generated on Wed May 4 2016 16:43:59 for Socket APIs by 1.8.9.1