LSA_VOID EPS_APP_INSTALL_DRV_OPEN (PSI_LD_RUNS_ON_TYPE ldRunsOnType)
The user application has to implement this function.
The following has to be done in this function:
- Install hardware drivers
The following hardware drivers are available:
- Npcap driver (Windows)
- PnDevDriver (CP1625 Host)
- SOC1 driver (CP1625 Host)
- AFPACKET driver (Linux Native)
In order to install a driver, call the install function eps_xxx_drv_install.
Parameters
ldRunsOnType: Input. This parameter was passed to EPS at eps_open.
EPS passes this parameter back to the application. In this way, the application can install different drivers only when necessary.
Interaction between EPS and PN Driver
At the startup of PN Driver, PN Driver calls EPS at SERV_CP_startup.
EPS performs a callback to PN Driver by calling
EPS_APP_INSTALL_DRV_OPEN().
After the call of EPS_APP_INSTALL_DRV_OPEN(), EPS uses the installed PN
Device Drivers in order to access Ethernet adapters. Each registered PN
Device Driver is asked by EPS whether the Ethernet adapter at the given
PCI location/MAC address can be opened or not. The first driver that
supports the adapter is used, i. e. the order in which the drivers are
installed does matter. See section PN Device Driver for more information
regarding PN Device Driver.
Example
"eps_winpcapdrv" and CustomDriverXYZ are installed within
EPS_APP_INSTALL_DRV_OPEN. Both can open the Ethernet adapter with the
MAC address <mac_address>. EPS asks "eps_winpcapdrv" to open the
board. If it succeeds, eps_winpcapdrv is used and CustomDriverXYZ is not
asked to open the board.
Using another EPS driver
If you want to use another driver provided by EPS, replace the call of
the eps_XXX_install() function by another driver listed in the
description of EPS_APP_INSTALL_DRV_OPEN().
Using a custom driver
If you want to use a custom driver that is not included in PN Driver
delivery, this driver has to be implemented and registered in
EPS_APP_INSTALL_DRV_OPEN() using the eps_XXX_install() functions. See
section PN Device Driver for more
detailed information.