[FL-580] Prepare BLE for certification (#376)
* api-hal-bt: separate bt init to core init and app start * bt: add continuous TX and RX tests * bt: finish rx test on Back button click * api-hal-bt: check core 2 started, same f4 and f5 implementation * bt: refactoring, move hopping test logic to main thread Co-authored-by: あく <alleteam@gmail.com>
This commit is contained in:
@@ -1,6 +1,8 @@
|
||||
#pragma once
|
||||
|
||||
#include "bt.h"
|
||||
#include "bt_views.h"
|
||||
#include "bt_types.h"
|
||||
|
||||
#include <furi.h>
|
||||
#include <api-hal.h>
|
||||
@@ -9,11 +11,17 @@
|
||||
|
||||
#include <gui/gui.h>
|
||||
#include <gui/view_port.h>
|
||||
#include <gui/view.h>
|
||||
#include <gui/view_dispatcher.h>
|
||||
|
||||
#include <menu/menu.h>
|
||||
#include <menu/menu_item.h>
|
||||
|
||||
typedef struct {
|
||||
struct Bt {
|
||||
osMessageQueueId_t message_queue;
|
||||
BtState state;
|
||||
osTimerId_t update_status_timer;
|
||||
osTimerId_t hopping_mode_timer;
|
||||
Cli* cli;
|
||||
Gui* gui;
|
||||
ValueMutex* menu;
|
||||
@@ -22,12 +30,27 @@ typedef struct {
|
||||
// Menu
|
||||
Icon* menu_icon;
|
||||
MenuItem* menu_item;
|
||||
} Bt;
|
||||
View* view_test_tone_tx;
|
||||
View* view_test_packet_tx;
|
||||
View* view_test_tone_rx;
|
||||
View* view_start_app;
|
||||
ViewDispatcher* view_dispatcher;
|
||||
};
|
||||
|
||||
Bt* bt_alloc();
|
||||
|
||||
void bt_draw_statusbar_callback(Canvas* canvas, void* context);
|
||||
|
||||
BtTestChannel bt_switch_channel(InputKey key, BtTestChannel inst_chan);
|
||||
|
||||
void bt_cli_info(string_t args, void* context);
|
||||
|
||||
void bt_draw_statusbar_callback(Canvas* canvas, void* context);
|
||||
|
||||
void bt_menu_test_tone_tx(void* context);
|
||||
|
||||
void bt_menu_test_packet_tx(void* context);
|
||||
|
||||
void bt_menu_test_tone_rx(void* context);
|
||||
|
||||
void bt_menu_start_app(void* context);
|
||||
|
Reference in New Issue
Block a user