RadioLib
Universal wireless communication library for Arduino
STM32WLx_Module.h
1 /*
2 
3 Copyright (c) 2022 STMicroelectronics
4 
5 This file is licensed under the MIT License: https://opensource.org/licenses/MIT
6 */
7 
8 #if !defined(_RADIOLIB_STM32WLX_MODULE_H)
9 #define _RADIOLIB_STM32WLX_MODULE_H
10 
11 #include "../../TypeDef.h"
12 
13 #if !defined(RADIOLIB_EXCLUDE_STM32WLX)
14 
15 #include "../../Module.h"
16 
26 class STM32WLx_Module : public Module {
27  // Note: We cannot easily override any methods here, since most calls
28  // are non-virtual and made through a Module*, so they would not be
29  // calling any overridden methods. This means this class works by
30  // overriding some of the callbacks in its constructor.
31 
32  public:
34 
35 #if !defined(RADIOLIB_GODMODE)
36  private:
37 #endif
38 
39  // Replacement callbacks to handle virtual pins. These are static,
40  // since they replace global functions that cannot take any this
41  // pointer for context.
42  static void virtualPinMode(uint32_t dwPin, uint32_t dwMode);
43  static void virtualDigitalWrite(uint32_t dwPin, uint32_t dwVal);
44  static int virtualDigitalRead(uint32_t ulPin);
45 };
46 
47 #endif // !defined(RADIOLIB_EXCLUDE_STM32WLX)
48 
49 #endif // _RADIOLIB_STM32WLX_MODULE_H
Implements all common low-level methods to control the wireless module. Every module class contains o...
Definition: Module.h:28
Definition: STM32WLx_Module.h:26