add a way to disable FCS checking.

This commit is contained in:
Mariano Alvira 2010-03-11 15:18:29 -05:00
parent da7898557d
commit a61deb78f4
2 changed files with 11 additions and 0 deletions

View file

@ -46,6 +46,8 @@ static volatile uint8_t last_post = NO_POST;
#define safe_irq_disable(x) volatile uint32_t saved_irq; saved_irq = *INTENABLE; disable_irq(x)
#define irq_restore() *INTENABLE = saved_irq
volatile uint8_t fcs_mode = USE_FCS;
void maca_init(void) {
reset_maca();
radio_init();
@ -157,6 +159,7 @@ void post_receive(void) {
enable_irq(MACA);
*MACA_CONTROL = ( (1 << maca_ctrl_asap) |
( 4 << PRECOUNT) |
( fcs_mode << NOFC ) |
(1 << maca_ctrl_auto) |
(1 << maca_ctrl_prm) |
(maca_ctrl_seq_rx));