Added BVLC to dynamic datalink module. Thanks, Kim Taylor!
This commit is contained in:
@@ -31,6 +31,11 @@
|
|||||||
License.
|
License.
|
||||||
-------------------------------------------
|
-------------------------------------------
|
||||||
####COPYRIGHTEND####*/
|
####COPYRIGHTEND####*/
|
||||||
|
#include "ethernet.h"
|
||||||
|
#include "bip.h"
|
||||||
|
#include "bvlc.h"
|
||||||
|
#include "arcnet.h"
|
||||||
|
#include "dlmstp.h"
|
||||||
#include "datalink.h"
|
#include "datalink.h"
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
|
|
||||||
@@ -41,10 +46,10 @@
|
|||||||
|
|
||||||
/** Function template to Initialize the DataLink services at the given interface.
|
/** Function template to Initialize the DataLink services at the given interface.
|
||||||
* @ingroup DLTemplates
|
* @ingroup DLTemplates
|
||||||
*
|
*
|
||||||
* @note For Linux, ifname is eth0, ath0, arc0, ttyS0, and others.
|
* @note For Linux, ifname is eth0, ath0, arc0, ttyS0, and others.
|
||||||
For Windows, ifname is the COM port or dotted ip address of the interface.
|
For Windows, ifname is the COM port or dotted ip address of the interface.
|
||||||
|
|
||||||
* @param ifname [in] The named interface to use for the network layer.
|
* @param ifname [in] The named interface to use for the network layer.
|
||||||
* @return True if the interface is successfully initialized,
|
* @return True if the interface is successfully initialized,
|
||||||
* else False if the initialization fails.
|
* else False if the initialization fails.
|
||||||
@@ -95,6 +100,13 @@ void datalink_set(
|
|||||||
datalink_cleanup = bip_cleanup;
|
datalink_cleanup = bip_cleanup;
|
||||||
datalink_get_broadcast_address = bip_get_broadcast_address;
|
datalink_get_broadcast_address = bip_get_broadcast_address;
|
||||||
datalink_get_my_address = bip_get_my_address;
|
datalink_get_my_address = bip_get_my_address;
|
||||||
|
} else if (strcasecmp("bvlc", datalink_string) == 0) {
|
||||||
|
datalink_init = bip_init;
|
||||||
|
datalink_send_pdu = bvlc_send_pdu;
|
||||||
|
datalink_receive = bvlc_receive;
|
||||||
|
datalink_cleanup = bip_cleanup;
|
||||||
|
datalink_get_broadcast_address = bip_get_broadcast_address;
|
||||||
|
datalink_get_my_address = bip_get_my_address;
|
||||||
} else if (strcasecmp("ethernet", datalink_string) == 0) {
|
} else if (strcasecmp("ethernet", datalink_string) == 0) {
|
||||||
datalink_init = ethernet_init;
|
datalink_init = ethernet_init;
|
||||||
datalink_send_pdu = ethernet_send_pdu;
|
datalink_send_pdu = ethernet_send_pdu;
|
||||||
|
|||||||
Reference in New Issue
Block a user