Renamed a config define to better match contiki's naming philosophy
This commit is contained in:
parent
2d0d54c380
commit
5240519dd9
6 changed files with 16 additions and 16 deletions
|
@ -98,7 +98,7 @@ uint8_t rf_error = 0;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/*---------------------------------------------------------------------------*/
|
/*---------------------------------------------------------------------------*/
|
||||||
#if !SHORTCUTS_CONF_NETSTACK
|
#if !NETSTACK_CONF_SHORTCUTS
|
||||||
PROCESS(cc2430_rf_process, "CC2430 RF driver");
|
PROCESS(cc2430_rf_process, "CC2430 RF driver");
|
||||||
#endif
|
#endif
|
||||||
/*---------------------------------------------------------------------------*/
|
/*---------------------------------------------------------------------------*/
|
||||||
|
@ -152,7 +152,7 @@ flush_rx()
|
||||||
cc2430_rf_command(ISFLUSHRX);
|
cc2430_rf_command(ISFLUSHRX);
|
||||||
cc2430_rf_command(ISFLUSHRX);
|
cc2430_rf_command(ISFLUSHRX);
|
||||||
|
|
||||||
#if !SHORTCUTS_CONF_NETSTACK
|
#if !NETSTACK_CONF_SHORTCUTS
|
||||||
IEN2 |= RFIE;
|
IEN2 |= RFIE;
|
||||||
#endif
|
#endif
|
||||||
#if CC2430_RFERR_INTERRUPT
|
#if CC2430_RFERR_INTERRUPT
|
||||||
|
@ -338,7 +338,7 @@ init(void)
|
||||||
RFIF &= ~(IRQ_FIFOP);
|
RFIF &= ~(IRQ_FIFOP);
|
||||||
|
|
||||||
S1CON &= ~(RFIF_0 | RFIF_1);
|
S1CON &= ~(RFIF_0 | RFIF_1);
|
||||||
#if !SHORTCUTS_CONF_NETSTACK
|
#if !NETSTACK_CONF_SHORTCUTS
|
||||||
IEN2 |= RFIE;
|
IEN2 |= RFIE;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -351,7 +351,7 @@ init(void)
|
||||||
RF_RX_LED_OFF();
|
RF_RX_LED_OFF();
|
||||||
rf_initialized = 1;
|
rf_initialized = 1;
|
||||||
|
|
||||||
#if !SHORTCUTS_CONF_NETSTACK
|
#if !NETSTACK_CONF_SHORTCUTS
|
||||||
process_start(&cc2430_rf_process, NULL);
|
process_start(&cc2430_rf_process, NULL);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -476,7 +476,7 @@ read(void *buf, unsigned short bufsize)
|
||||||
#endif /* CC2420_CONF_CHECKSUM */
|
#endif /* CC2420_CONF_CHECKSUM */
|
||||||
|
|
||||||
/* Don't interrupt us while emptying the FIFO */
|
/* Don't interrupt us while emptying the FIFO */
|
||||||
#if !SHORTCUTS_CONF_NETSTACK
|
#if !NETSTACK_CONF_SHORTCUTS
|
||||||
IEN2 &= ~RFIE;
|
IEN2 &= ~RFIE;
|
||||||
#endif
|
#endif
|
||||||
#if CC2430_RFERR_INTERRUPT
|
#if CC2430_RFERR_INTERRUPT
|
||||||
|
@ -576,7 +576,7 @@ read(void *buf, unsigned short bufsize)
|
||||||
|
|
||||||
RF_RX_LED_OFF();
|
RF_RX_LED_OFF();
|
||||||
|
|
||||||
#if !SHORTCUTS_CONF_NETSTACK
|
#if !NETSTACK_CONF_SHORTCUTS
|
||||||
IEN2 |= RFIE;
|
IEN2 |= RFIE;
|
||||||
#endif
|
#endif
|
||||||
#if CC2430_RFERR_INTERRUPT
|
#if CC2430_RFERR_INTERRUPT
|
||||||
|
@ -688,7 +688,7 @@ const struct radio_driver cc2430_rf_driver =
|
||||||
off,
|
off,
|
||||||
};
|
};
|
||||||
/*---------------------------------------------------------------------------*/
|
/*---------------------------------------------------------------------------*/
|
||||||
#if !SHORTCUTS_CONF_NETSTACK
|
#if !NETSTACK_CONF_SHORTCUTS
|
||||||
/*---------------------------------------------------------------------------*/
|
/*---------------------------------------------------------------------------*/
|
||||||
PROCESS_THREAD(cc2430_rf_process, ev, data)
|
PROCESS_THREAD(cc2430_rf_process, ev, data)
|
||||||
{
|
{
|
||||||
|
|
|
@ -77,7 +77,7 @@ int8_t cc2430_rf_channel_set(uint8_t channel);
|
||||||
uint8_t cc2430_rf_power_set(uint8_t new_power);
|
uint8_t cc2430_rf_power_set(uint8_t new_power);
|
||||||
void cc2430_rf_set_addr(unsigned pan, unsigned addr, const uint8_t *ieee_addr);
|
void cc2430_rf_set_addr(unsigned pan, unsigned addr, const uint8_t *ieee_addr);
|
||||||
|
|
||||||
#if !SHORTCUTS_CONF_NETSTACK
|
#if !NETSTACK_CONF_SHORTCUTS
|
||||||
extern void cc2430_rf_ISR( void ) __interrupt (RF_VECTOR);
|
extern void cc2430_rf_ISR( void ) __interrupt (RF_VECTOR);
|
||||||
#endif
|
#endif
|
||||||
#if CC2430_RFERR_INTERRUPT
|
#if CC2430_RFERR_INTERRUPT
|
||||||
|
|
|
@ -50,7 +50,7 @@ uint8_t rf_error = 0;
|
||||||
|
|
||||||
PROCESS_NAME(cc2430_rf_process);
|
PROCESS_NAME(cc2430_rf_process);
|
||||||
|
|
||||||
#if !SHORTCUTS_CONF_NETSTACK
|
#if !NETSTACK_CONF_SHORTCUTS
|
||||||
/*---------------------------------------------------------------------------*/
|
/*---------------------------------------------------------------------------*/
|
||||||
/**
|
/**
|
||||||
* RF interrupt service routine.
|
* RF interrupt service routine.
|
||||||
|
|
|
@ -69,9 +69,9 @@
|
||||||
* - process_post_synch() in tcpip_uipcall (we call the relevant pthread)
|
* - process_post_synch() in tcpip_uipcall (we call the relevant pthread)
|
||||||
* - mac_call_sent_callback() is replaced with sent() in various places
|
* - mac_call_sent_callback() is replaced with sent() in various places
|
||||||
*
|
*
|
||||||
* These are good things to do, we reduce stack usage, RAM size and code size
|
* These are good things to do, they reduce stack usage and prevent crashes
|
||||||
*/
|
*/
|
||||||
#define SHORTCUTS_CONF_NETSTACK 1
|
#define NETSTACK_CONF_SHORTCUTS 1
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Sensors
|
* Sensors
|
||||||
|
|
|
@ -82,15 +82,15 @@
|
||||||
* When set, the RF driver is no longer a contiki process and the RX ISR is
|
* When set, the RF driver is no longer a contiki process and the RX ISR is
|
||||||
* disabled. Instead of polling the radio process when data arrives, we
|
* disabled. Instead of polling the radio process when data arrives, we
|
||||||
* periodically check for data by directly invoking the driver from main()
|
* periodically check for data by directly invoking the driver from main()
|
||||||
|
*
|
||||||
* When set, this directive also configures the following bypasses:
|
* When set, this directive also configures the following bypasses:
|
||||||
* - process_post_synch() in tcpip_input() (we call packet_input())
|
* - process_post_synch() in tcpip_input() (we call packet_input())
|
||||||
* - process_post_synch() in tcpip_uipcall (we call the relevant pthread)
|
* - process_post_synch() in tcpip_uipcall (we call the relevant pthread)
|
||||||
* - mac_call_sent_callback() is replaced with sent() in various places
|
* - mac_call_sent_callback() is replaced with sent() in various places
|
||||||
*
|
*
|
||||||
* These are good things to do, we reduce stack usage, RAM size and code size
|
* These are good things to do, they reduce stack usage and prevent crashes
|
||||||
*/
|
*/
|
||||||
#define SHORTCUTS_CONF_NETSTACK 1
|
#define NETSTACK_CONF_SHORTCUTS 1
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Sensors
|
* Sensors
|
||||||
|
|
|
@ -32,7 +32,7 @@ PROCESS_NAME(viztool_process);
|
||||||
PROCESS_NAME(batmon_process);
|
PROCESS_NAME(batmon_process);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if SHORTCUTS_CONF_NETSTACK
|
#if NETSTACK_CONF_SHORTCUTS
|
||||||
static __data int len;
|
static __data int len;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -306,7 +306,7 @@ main(void)
|
||||||
#endif
|
#endif
|
||||||
r = process_run();
|
r = process_run();
|
||||||
} while(r > 0);
|
} while(r > 0);
|
||||||
#if SHORTCUTS_CONF_NETSTACK
|
#if NETSTACK_CONF_SHORTCUTS
|
||||||
len = NETSTACK_RADIO.pending_packet();
|
len = NETSTACK_RADIO.pending_packet();
|
||||||
if(len) {
|
if(len) {
|
||||||
packetbuf_clear();
|
packetbuf_clear();
|
||||||
|
|
Loading…
Reference in a new issue