diff options
Diffstat (limited to 'apps/recorder/radio.c')
| -rw-r--r-- | apps/recorder/radio.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/apps/recorder/radio.c b/apps/recorder/radio.c index 0459ff3..ab0c1eb 100644 --- a/apps/recorder/radio.c +++ b/apps/recorder/radio.c @@ -74,6 +74,18 @@ void radio_stop(void) } +bool radio_hardware_present(void) +{ + int val; + + fmradio_set(2, 0x140885); /* 5kHz, 7.2MHz crystal, test mode 1 */ + val = fmradio_read(0); + if(val == 0x140885) + return true; + else + return false; +} + void radio_set_frequency(int freq) { /* We add the standard Intermediate Frequency 10.7MHz before calculating |