make style + cleanup
This commit is contained in:
@@ -171,7 +171,7 @@ void em4x50_setup_sim(void) {
|
|||||||
|
|
||||||
// calculate signal properties (mean amplitudes) from measured data:
|
// calculate signal properties (mean amplitudes) from measured data:
|
||||||
// 32 amplitudes (maximum values) -> mean amplitude value -> gHigh -> gLow
|
// 32 amplitudes (maximum values) -> mean amplitude value -> gHigh -> gLow
|
||||||
bool get_signalproperties(void) {
|
static bool get_signalproperties(void) {
|
||||||
|
|
||||||
bool signal_found = false;
|
bool signal_found = false;
|
||||||
int no_periods = 32, pct = 75, noise = 140;
|
int no_periods = 32, pct = 75, noise = 140;
|
||||||
@@ -444,7 +444,7 @@ static int find_double_listen_window(bool bcommand) {
|
|||||||
|
|
||||||
// function is used to check wether a tag on the proxmark is an
|
// function is used to check wether a tag on the proxmark is an
|
||||||
// EM4x50 tag or not -> speed up "lf search" process
|
// EM4x50 tag or not -> speed up "lf search" process
|
||||||
bool find_em4x50_tag(void) {
|
static bool find_em4x50_tag(void) {
|
||||||
return find_single_listen_window();
|
return find_single_listen_window();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -600,7 +600,7 @@ static int get_word_from_bitstream(uint32_t *data) {
|
|||||||
|
|
||||||
// simple login to EM4x50,
|
// simple login to EM4x50,
|
||||||
// used in operations that require authentication
|
// used in operations that require authentication
|
||||||
static bool login(uint32_t password) {
|
static int login(uint32_t password) {
|
||||||
if (request_receive_mode() == PM3_SUCCESS) {
|
if (request_receive_mode() == PM3_SUCCESS) {
|
||||||
|
|
||||||
// send login command
|
// send login command
|
||||||
@@ -1107,7 +1107,6 @@ void em4x50_writepwd(em4x50_data_t *etd) {
|
|||||||
// send bit in receive mode by counting carrier cycles
|
// send bit in receive mode by counting carrier cycles
|
||||||
static void em4x50_sim_send_bit(uint8_t bit) {
|
static void em4x50_sim_send_bit(uint8_t bit) {
|
||||||
|
|
||||||
//uint16_t timeout = EM4X50_T_TAG_FULL_PERIOD;
|
|
||||||
uint16_t timeout = EM4X50_T_SIMULATION_TIMEOUT_READ;
|
uint16_t timeout = EM4X50_T_SIMULATION_TIMEOUT_READ;
|
||||||
|
|
||||||
for (int t = 0; t < EM4X50_T_TAG_FULL_PERIOD; t++) {
|
for (int t = 0; t < EM4X50_T_TAG_FULL_PERIOD; t++) {
|
||||||
@@ -1277,7 +1276,6 @@ static bool em4x50_sim_read_byte(uint8_t *byte, bool paritycheck) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// read complete word in simulation mode
|
// read complete word in simulation mode
|
||||||
|
|||||||
@@ -14,8 +14,6 @@
|
|||||||
#include "../include/em4x50.h"
|
#include "../include/em4x50.h"
|
||||||
|
|
||||||
void em4x50_setup_read(void);
|
void em4x50_setup_read(void);
|
||||||
bool get_signalproperties(void);
|
|
||||||
bool find_em4x50_tag(void);
|
|
||||||
int standard_read(int *now, uint32_t *words);
|
int standard_read(int *now, uint32_t *words);
|
||||||
|
|
||||||
void em4x50_setup_sim(void);
|
void em4x50_setup_sim(void);
|
||||||
|
|||||||
Reference in New Issue
Block a user