Six public API functions had no callers anywhere in the firmware: splash_prev, splash_set_active, splash_current_name, splash_count, ble_is_connected, imu_set_rotation, power_is_usb_connected, power_usb_changed. Trimming them lets power.cpp drop the VBUS state machine (cached_usb, usb_changed_flag, last_vbus_ms, enableVbusVoltageMeasure). usage_rate_reset becomes file-static since the only caller is in usage_rate.cpp itself. Montserrat font flags in platformio.ini were enabled but never referenced.
26 lines
588 B
C
26 lines
588 B
C
#pragma once
|
|
#include <stdint.h>
|
|
|
|
enum ble_state_t {
|
|
BLE_STATE_INIT,
|
|
BLE_STATE_ADVERTISING,
|
|
BLE_STATE_CONNECTED,
|
|
BLE_STATE_DISCONNECTED,
|
|
};
|
|
|
|
void ble_init(void);
|
|
void ble_tick(void);
|
|
ble_state_t ble_get_state(void);
|
|
const char* ble_get_device_name(void);
|
|
const char* ble_get_mac_address(void);
|
|
void ble_clear_bonds(void);
|
|
bool ble_has_data(void);
|
|
const char* ble_get_data(void);
|
|
void ble_send_ack(void);
|
|
void ble_send_nack(void);
|
|
void ble_request_refresh(void);
|
|
|
|
// BLE HID keyboard
|
|
void ble_keyboard_press(uint8_t key, uint8_t modifier);
|
|
void ble_keyboard_release(void);
|