mirror of
https://github.com/oliverschmidt/contiki.git
synced 2024-12-23 16:29:34 +00:00
implement tx_callback
This commit is contained in:
parent
556477e6a0
commit
097922e709
@ -137,6 +137,7 @@ extern volatile uint8_t fcs_mode;
|
||||
#define set_fcs_mode(x) fcs_mode = (x)
|
||||
|
||||
extern void maca_rx_callback(volatile packet_t *p) __attribute__((weak));
|
||||
extern void maca_tx_callback(volatile packet_t *p) __attribute__((weak));
|
||||
|
||||
/******************************************************************************/
|
||||
/* everything under this comment is messy, needs cleaning, and will */
|
||||
|
@ -2,7 +2,7 @@
|
||||
#include <stdio.h>
|
||||
|
||||
#ifndef DEBUG_MACA
|
||||
#define DEBUG_MACA 0
|
||||
#define DEBUG_MACA 1
|
||||
#endif
|
||||
#if (DEBUG_MACA == 0)
|
||||
#define PRINTF(...)
|
||||
@ -401,11 +401,12 @@ void maca_isr(void) {
|
||||
if(action_complete_irq()) {
|
||||
/* PRINTF("maca action complete %d\n\r", get_field(*MACA_CONTROL,SEQUENCE)); */
|
||||
if(last_post == TX_POST) {
|
||||
if(maca_tx_callback != 0) { maca_tx_callback(tx_head); }
|
||||
free_tx_head();
|
||||
last_post = NO_POST;
|
||||
}
|
||||
ResumeMACASync();
|
||||
*MACA_CLRIRQ = (1 << maca_irq_acpl);
|
||||
*MACA_CLRIRQ = (1 << maca_irq_acpl);
|
||||
}
|
||||
|
||||
decode_status();
|
||||
|
Loading…
Reference in New Issue
Block a user