Send on select (#1557)

* fixed bug not fully displaying rx packet
* added sending selected packet
* setting packet count to 100 as 1 is too aggressive for speed > 2
* setting limit to 50 as 50 does not bog down UI at speed 5.
* fix tx channel getting out of sync with freq
This commit is contained in:
Netro
2023-11-06 05:16:01 -05:00
committed by GitHub
parent 2b7962fa7c
commit adabbfbef1
6 changed files with 54 additions and 16 deletions

View File

@@ -55,9 +55,17 @@ class BLELoggerTx {
namespace ui {
struct BLETxPacket {
char macAddress[13];
char advertisementData[63];
char packetCount[11];
uint32_t packet_count;
};
class BLETxView : public View {
public:
BLETxView(NavigationView& nav);
BLETxView(NavigationView& nav, BLETxPacket packet);
~BLETxView();
void set_parent_rect(const Rect new_parent_rect) override;
@@ -74,13 +82,6 @@ class BLETxView : public View {
std::string title() const override { return "BLE TX"; };
struct BLETxPacket {
char macAddress[13];
char advertisementData[63];
char packetCount[11];
uint32_t packet_count;
};
private:
void on_data(uint32_t value, bool is_data);
void on_tx_progress(const bool done);
@@ -112,6 +113,7 @@ class BLETxView : public View {
uint32_t num_packets{0};
uint32_t current_packet{0};
bool random_mac = false;
bool file_override = false;
enum PKT_TYPE {
INVALID_TYPE,