@@ -144,23 +144,23 @@ void app_main(void) {
144
144
uint8_t magic = esp_rtcmem_read (0 );
145
145
uint8_t inv_magic = esp_rtcmem_read (1 );
146
146
147
- if (false) {
148
- //Grab level of int pin of touchpad. If high, this was a
149
- //scheduled wakeup because of a deep sleep timeout. If low,
150
- //the user used the touchpad.
151
- //yes, this is v1 specific. Please add v0.x support yourself.
152
- gpio_config_t io_conf = {
153
- .mode = GPIO_MODE_INPUT ,
154
- .pin_bit_mask = 1LL << PIN_NUM_MPR121_INT ,
155
- .pull_down_en = 0 ,
156
- .pull_up_en = 1 ,
157
- };
158
- gpio_config (& io_conf );
159
- if (gpio_get_level (PIN_NUM_MPR121_INT )== 1 ) {
160
- printf ("Touch int is high. Starting bpp.\n" );
161
- do_bpp_bgnd ();
162
- }
163
- }
147
+ #ifdef CONFIG_SHA_BPP_ENABLE
148
+ //Grab level of int pin of touchpad. If high, this was a
149
+ //scheduled wakeup because of a deep sleep timeout. If low,
150
+ //the user used the touchpad.
151
+ //yes, this is v1 specific. Please add v0.x support yourself.
152
+ gpio_config_t io_conf = {
153
+ .mode = GPIO_MODE_INPUT ,
154
+ .pin_bit_mask = 1LL << PIN_NUM_MPR121_INT ,
155
+ .pull_down_en = 0 ,
156
+ .pull_up_en = 1 ,
157
+ };
158
+ gpio_config (& io_conf );
159
+ if (gpio_get_level (PIN_NUM_MPR121_INT )== 1 ) {
160
+ printf ("Touch int is high. Starting bpp.\n" );
161
+ do_bpp_bgnd ();
162
+ }
163
+ #endif
164
164
165
165
if (magic == (uint8_t )~inv_magic ) {
166
166
printf ("Magic checked out!\n" );
0 commit comments