IEEE 802.15.4 subsystem
Sign in or create your account | Project List | Help
IEEE 802.15.4 subsystem Git Source Tree
Root/
Source at commit 07b1da29ec94c00d52cd7c16a667c537e48a65e8 created 10 years 7 months ago. By Werner Almesberger, tools/lib/: aggressive polling for wait_for_interrupt, if timeout_ms = -1 | |
---|---|
1 | /* |
2 | * include/misctxrx.h - Miscellaenous transceiver helper functions |
3 | * |
4 | * Written 2010-2011 by Werner Almesberger |
5 | * Copyright 2010-2011 Werner Almesberger |
6 | * |
7 | * This program is free software; you can redistribute it and/or modify |
8 | * it under the terms of the GNU General Public License as published by |
9 | * the Free Software Foundation; either version 2 of the License, or |
10 | * (at your option) any later version. |
11 | */ |
12 | |
13 | #ifndef MISCTXRX_H |
14 | #define MISCTXRX_H |
15 | |
16 | #include <stdint.h> |
17 | |
18 | #include "atrf.h" |
19 | |
20 | |
21 | void flush_interrupts(struct atrf_dsc *dsc); |
22 | |
23 | /* |
24 | * timeout_ms: |
25 | * > 0: time out after that many milliseconds |
26 | * == 0: wait forever |
27 | * < 0: wait forever and eliminate poll delays (for high-speed capture) |
28 | */ |
29 | |
30 | uint8_t wait_for_interrupt(struct atrf_dsc *dsc, uint8_t wait_for, |
31 | uint8_t ignore, int timeout_ms); |
32 | |
33 | int tx_power_dBm2step(struct atrf_dsc *dsc, double power); |
34 | double tx_power_step2dBm(struct atrf_dsc *dsc, int step); |
35 | |
36 | void set_power_step(struct atrf_dsc *dsc, int power, int crc); |
37 | void set_power_dBm(struct atrf_dsc *dsc, double power, int crc); |
38 | |
39 | #endif /* !MISCTXRX_H */ |
40 |