mirror of
https://github.com/Next-Flip/Momentum-Firmware.git
synced 2026-05-14 00:28:36 -07:00
Update ampd code
This commit is contained in:
@@ -55,6 +55,7 @@ typedef struct {
|
||||
uint8_t rolling_counter_mult;
|
||||
bool timestamp_file_names : 1;
|
||||
bool extended_frequency_i : 1;
|
||||
bool external_module_power_amp : 1;
|
||||
} FuriHalSubGhz;
|
||||
|
||||
volatile FuriHalSubGhz furi_hal_subghz = {
|
||||
@@ -63,6 +64,7 @@ volatile FuriHalSubGhz furi_hal_subghz = {
|
||||
.async_mirror_pin = NULL,
|
||||
.rolling_counter_mult = 1,
|
||||
.extended_frequency_i = false,
|
||||
.external_module_power_amp = false,
|
||||
};
|
||||
|
||||
uint8_t furi_hal_subghz_get_rolling_counter_mult(void) {
|
||||
@@ -77,6 +79,14 @@ void furi_hal_subghz_set_extended_frequency(bool state_i) {
|
||||
furi_hal_subghz.extended_frequency_i = state_i;
|
||||
}
|
||||
|
||||
bool furi_hal_subghz_get_ext_power_amp() {
|
||||
return furi_hal_subghz.external_module_power_amp;
|
||||
}
|
||||
|
||||
void furi_hal_subghz_set_ext_power_amp(bool enabled) {
|
||||
furi_hal_subghz.external_module_power_amp = enabled;
|
||||
}
|
||||
|
||||
void furi_hal_subghz_set_async_mirror_pin(const GpioPin* pin) {
|
||||
furi_hal_subghz.async_mirror_pin = pin;
|
||||
}
|
||||
|
||||
@@ -238,6 +238,16 @@ bool furi_hal_subghz_is_async_tx_complete();
|
||||
*/
|
||||
void furi_hal_subghz_stop_async_tx();
|
||||
|
||||
/** Get external amplifier power state
|
||||
* @return true if amplifier is enabled
|
||||
*/
|
||||
bool furi_hal_subghz_get_ext_power_amp();
|
||||
|
||||
/** Set external amplifier power state
|
||||
* @param enabled true to enable amplifier state, false to disable state
|
||||
*/
|
||||
void furi_hal_subghz_set_ext_power_amp(bool enabled);
|
||||
|
||||
// /** Initialize and switch to power save mode Used by internal API-HAL
|
||||
// * initialization routine Can be used to reinitialize device to safe state and
|
||||
// * send it to sleep
|
||||
|
||||
Reference in New Issue
Block a user