60
60
* Inclusion mode button:
61
61
* - Connect GPIO5 via switch to GND ('inclusion switch')
62
62
*
63
- * * Signing , RF69 radio and a separate SPI flash are not supported yet !
63
+ * Hardware SHA204 signing , RF69 radio and a separate SPI flash are not supported!
64
64
*
65
65
* Make sure to fill in your ssid and WiFi password below for ssid & pass.
66
66
*/
67
67
#define NO_PORTB_PINCHANGES
68
68
69
69
#include < SPI.h>
70
70
71
+ #include < MySigningNone.h>
72
+ #include < MySigningAtsha204Soft.h>
71
73
#include < MyTransportNRF24.h>
72
74
#include < EEPROM.h>
73
75
#include < MyHwESP8266.h>
@@ -87,25 +89,36 @@ const char *pass = "MyVerySecretPassword"; //
87
89
#define RADIO_CE_PIN 4 // radio chip enable
88
90
#define RADIO_SPI_SS_PIN 15 // radio SPI serial select
89
91
92
+ #ifdef WITH_LEDS_BLINKING
90
93
#define RADIO_ERROR_LED_PIN 7 // Error led pin
91
94
#define RADIO_RX_LED_PIN 8 // Receive led pin
92
95
#define RADIO_TX_LED_PIN 9 // the PCB, on board LED
96
+ #endif
93
97
94
98
95
99
// NRFRF24L01 radio driver (set low transmit power by default)
96
100
MyTransportNRF24 transport (RADIO_CE_PIN, RADIO_SPI_SS_PIN, RF24_PA_LEVEL_GW);
97
101
102
+ // Message signing driver (signer needed if MY_SIGNING_FEATURE is turned on in MyConfig.h)
103
+ #ifdef MY_SIGNING_FEATURE
104
+ MySigningNone signer;
105
+ // MySigningAtsha204Soft signer;
106
+ #endif
107
+
98
108
// Hardware profile
99
109
MyHwESP8266 hw;
100
110
101
111
// Construct MySensors library (signer needed if MY_SIGNING_FEATURE is turned on in MyConfig.h)
102
112
// To use LEDs blinking, uncomment WITH_LEDS_BLINKING in MyConfig.h
113
+ MySensor gw (transport, hw
114
+ #ifdef MY_SIGNING_FEATURE
115
+ , signer
116
+ #endif
103
117
#ifdef WITH_LEDS_BLINKING
104
- MySensor gw (transport, hw /* , signer*/ , RADIO_RX_LED_PIN, RADIO_TX_LED_PIN, RADIO_ERROR_LED_PIN);
105
- #else
106
- MySensor gw (transport, hw /* , signer*/ );
118
+ , RADIO_RX_LED_PIN, RADIO_TX_LED_PIN, RADIO_ERROR_LED_PIN
107
119
#endif
108
-
120
+ );
121
+
109
122
110
123
#define IP_PORT 5003 // The port you want to open
111
124
0 commit comments