mirror of
https://github.com/DarkFlippers/unleashed-firmware
synced 2024-11-27 23:10:22 +00:00
22e1ecb642
* Hal lfrfid: add read timer pulse and period config fns * New debug application for lfrfid subsystem * New lfrfid: app, fix naming * App lfrfid: assets * Container view module * App ibutton: remove unused header * App lfrfid scenes * App notification, add yield to blocking operations, add speaker volume control * App lfrfid: reading key scene * Assets: placeholder icon * App lfrfid: reworked container view module * App lfrfid: new scenes * App lfrfid: write scene * App lfrfid: write hid * App lfrfid: emulate scene * App lfrfid: save name scene * App lfrfid: add missing file
29 lines
No EOL
795 B
C++
29 lines
No EOL
795 B
C++
#pragma once
|
|
#include <api-hal.h>
|
|
#include "key-info.h"
|
|
#include "encoder-generic.h"
|
|
#include "encoder-emmarine.h"
|
|
#include "encoder-hid-h10301.h"
|
|
#include "encoder-indala-40134.h"
|
|
#include "pulse-joiner.h"
|
|
#include <map>
|
|
|
|
class RfidTimerEmulator {
|
|
public:
|
|
RfidTimerEmulator();
|
|
~RfidTimerEmulator();
|
|
void start(LfrfidKeyType type, const uint8_t* data, uint8_t data_size);
|
|
void stop();
|
|
|
|
private:
|
|
EncoderGeneric* current_encoder = nullptr;
|
|
|
|
std::map<LfrfidKeyType, EncoderGeneric*> encoders = {
|
|
{LfrfidKeyType::KeyEM4100, new EncoderEM()},
|
|
{LfrfidKeyType::KeyH10301, new EncoderHID_H10301()},
|
|
{LfrfidKeyType::KeyI40134, new EncoderIndala_40134()},
|
|
};
|
|
|
|
PulseJoiner pulse_joiner;
|
|
static void timer_update_callback(void* _hw, void* ctx);
|
|
}; |