1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00
RIOT/cpu/native/include/nativenet.h

34 lines
860 B
C
Raw Normal View History

2013-08-15 19:39:29 +02:00
#ifndef NATIVENET_H
#define NATIVENET_H
2013-08-08 11:08:33 +02:00
#include <net/ethernet.h>
#define RX_BUF_SIZE (10)
#define TRANSCEIVER_BUFFER_SIZE (3)
#ifndef NATIVE_MAX_DATA_LENGTH
/* TODO: set this properly: */
#define NATIVE_MAX_DATA_LENGTH (ETHER_MAX_LEN - (ETHER_HDR_LEN+2))
#else
#warning be careful not to exceed (ETHER_MAX_LEN) with NATIVE_MAX_DATA_LENGTH
#endif /* NATIVE_MAX_DATA_LENGTH */
void nativenet_init(int transceiver_pid);
void nativenet_powerdown();
void nativenet_set_monitor(uint8_t mode);
uint8_t nativenet_send(radio_packet_t *packet);
2013-08-21 19:22:32 +02:00
radio_address_t nativenet_set_address(radio_address_t address);
radio_address_t nativenet_get_address();
2013-08-08 11:08:33 +02:00
int16_t nativenet_set_channel(uint8_t channel);
int16_t nativenet_get_channel();
uint16_t nativenet_set_pan(uint16_t pan);
uint16_t nativenet_get_pan();
void nativenet_switch_to_rx();
2013-08-15 19:39:29 +02:00
#endif /* NATIVENET_H */