implement rx callback
This commit is contained in:
parent
8b73c61175
commit
ea2646e5ec
2 changed files with 17 additions and 12 deletions
|
@ -7,6 +7,12 @@
|
|||
|
||||
#define LED LED_GREEN
|
||||
|
||||
void maca_rx_callback(volatile packet_t *p)
|
||||
{
|
||||
(void)p; /* surpress unused warning */
|
||||
toggle_gpio0(LED);
|
||||
}
|
||||
|
||||
void main(void) {
|
||||
volatile packet_t *p;
|
||||
|
||||
|
@ -35,7 +41,6 @@ void main(void) {
|
|||
print_welcome("rftest-rx");
|
||||
while(1) {
|
||||
if((p = rx_packet())) {
|
||||
toggle_gpio0(LED);
|
||||
/* print and free the packet */
|
||||
printf("rftest-rx --- ");
|
||||
print_packet(p);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue