reorganize few global vars & fcts

This commit is contained in:
Philippe Teuwen 2020-11-05 23:05:52 +01:00
commit a8b92f48a7
7 changed files with 17 additions and 21 deletions

View file

@ -65,6 +65,9 @@
#include "spiffs.h"
#endif
int DBGLEVEL = DBG_ERROR;
uint8_t g_trigger = 0;
bool g_hf_field_active = false;
extern uint32_t _stack_start, _stack_end;
struct common_area common_area __attribute__((section(".commonarea")));
static int button_status = BUTTON_NO_CLICK;
@ -88,6 +91,12 @@ int tearoff_hook(void) {
}
}
void hf_field_off(void) {
FpgaWriteConfWord(FPGA_MAJOR_MODE_OFF);
LEDsoff();
g_hf_field_active = false;
}
void send_wtx(uint16_t wtx) {
if (allow_send_wtx) {
reply_ng(CMD_WTX, PM3_SUCCESS, (uint8_t *)&wtx, sizeof(wtx));