stm32/subghz: Add STM32WL55 subghz radio interface to stm module.

This is the minimum C interface to allow a modem driver to be built in
Python.  Interface is simple, with the intention that the micropython-lib
driver is the main (only) consumer of it.

Signed-off-by: Angus Gratton <angus@redyak.com.au>
This commit is contained in:
Angus Gratton
2022-07-15 14:04:33 +10:00
committed by Damien George
parent 9e0f934cdf
commit 02620c2236
9 changed files with 236 additions and 4 deletions

View File

@@ -86,6 +86,7 @@
#include "servo.h"
#include "dac.h"
#include "can.h"
#include "subghz.h"
#if MICROPY_PY_THREAD
STATIC pyb_thread_t pyb_thread_main;
@@ -403,6 +404,9 @@ void stm32_main(uint32_t reset_mode) {
#if defined(STM32WB)
rfcore_init();
#endif
#if defined(STM32WL)
subghz_init();
#endif
#if MICROPY_HW_SDRAM_SIZE
sdram_init();
bool sdram_valid = true;
@@ -650,6 +654,9 @@ soft_reset_exit:
#if MICROPY_PY_BLUETOOTH
mp_bluetooth_deinit();
#endif
#if defined(STM32WL)
subghz_deinit();
#endif
#if MICROPY_PY_NETWORK
mod_network_deinit();
#endif