2021-08-29 13:05:15 +00:00
|
|
|
#include "subghz_test_static.h"
|
2023-07-06 15:15:03 +00:00
|
|
|
#include "../subghz_test_app_i.h"
|
|
|
|
#include "../helpers/subghz_test_frequency.h"
|
2023-06-30 14:03:36 +00:00
|
|
|
#include <lib/subghz/devices/cc1101_configs.h>
|
2021-04-15 08:47:52 +00:00
|
|
|
|
|
|
|
#include <math.h>
|
|
|
|
#include <furi.h>
|
2022-01-05 16:10:18 +00:00
|
|
|
#include <furi_hal.h>
|
2021-04-15 08:47:52 +00:00
|
|
|
#include <input/input.h>
|
2022-01-05 16:10:18 +00:00
|
|
|
#include <notification/notification_messages.h>
|
2023-07-06 15:15:03 +00:00
|
|
|
#include "../protocol/princeton_for_testing.h"
|
2021-04-15 08:47:52 +00:00
|
|
|
|
2021-11-12 13:04:35 +00:00
|
|
|
#define TAG "SubGhzTestStatic"
|
|
|
|
|
2021-09-28 00:05:40 +00:00
|
|
|
typedef enum {
|
2022-03-03 09:48:56 +00:00
|
|
|
SubGhzTestStaticStatusIDLE,
|
|
|
|
SubGhzTestStaticStatusTX,
|
|
|
|
} SubGhzTestStaticStatus;
|
2021-09-28 00:05:40 +00:00
|
|
|
|
2021-08-29 13:05:15 +00:00
|
|
|
static const uint32_t subghz_test_static_keys[] = {
|
[FL-1610] SubGhz: scene based application, PT save and replay (#630)
* SubGhz: scene based application
* SubGhz: encoder/decoder separation, DMA streaming, update app and cli.
* SubGhz: 2 stage async tx complete, minor cleanup
* SubGhz: 2 stage async tx complete, FIX state pin end transmit
* SubGhz: Pricenton, receive TE signal
* SubGhz: Pricenton, add save data, add load data
* SubGhz: Add Read scene, Fix pricenton save, load funtion
* SubGhz: Add Read, Receiver, SaveName scene
* SubGhz: Read and Save (pricenton)
* SubGhz: add Load scence
* SubGhz: Fix select file scene, add load scene, add transmitter view, add send tx pricenton
* SubGhz: Fix pricenton encoder, fix transmitter send
* SubGhz: modified Pricenton Encoder (added guard time at the beginning), modified CC1101 config, code refactoring
* SubGhz: Fix pricenton encoder defalut TE
* Archive: Fix path and name SubGhz
* Archive: Fix name app SubGhz
* GubGhz: Came: add Save, Load key
* GubGhz: GateTX: add Save, Load key
* GubGhz: NeroSketch: add Save, Load key
* Github: better linters triggers
* SubGhz: adding fast loading keys Archive -> Run in app
* GubGhz: KeeLog: add Save, Load key, key generation from the serial number of the meter and the button
* SubGhz: format sources and fix compilation
* FuriHal: add subghz configuration description for AGC section
* SubGhz: save only protocols that can be saved. Cleanup.
* Github: lint on pull requests
Co-authored-by: Aleksandr Kutuzov <alleteam@gmail.com>
2021-08-12 14:42:56 +00:00
|
|
|
0x0074BADE,
|
|
|
|
0x0074BADD,
|
|
|
|
0x0074BADB,
|
|
|
|
0x00E34A4E,
|
2021-04-15 08:47:52 +00:00
|
|
|
};
|
|
|
|
|
2022-03-03 09:48:56 +00:00
|
|
|
struct SubGhzTestStatic {
|
2021-04-15 08:47:52 +00:00
|
|
|
View* view;
|
2022-07-25 14:35:02 +00:00
|
|
|
SubGhzTestStaticStatus status_tx;
|
[FL-1610] SubGhz: scene based application, PT save and replay (#630)
* SubGhz: scene based application
* SubGhz: encoder/decoder separation, DMA streaming, update app and cli.
* SubGhz: 2 stage async tx complete, minor cleanup
* SubGhz: 2 stage async tx complete, FIX state pin end transmit
* SubGhz: Pricenton, receive TE signal
* SubGhz: Pricenton, add save data, add load data
* SubGhz: Add Read scene, Fix pricenton save, load funtion
* SubGhz: Add Read, Receiver, SaveName scene
* SubGhz: Read and Save (pricenton)
* SubGhz: add Load scence
* SubGhz: Fix select file scene, add load scene, add transmitter view, add send tx pricenton
* SubGhz: Fix pricenton encoder, fix transmitter send
* SubGhz: modified Pricenton Encoder (added guard time at the beginning), modified CC1101 config, code refactoring
* SubGhz: Fix pricenton encoder defalut TE
* Archive: Fix path and name SubGhz
* Archive: Fix name app SubGhz
* GubGhz: Came: add Save, Load key
* GubGhz: GateTX: add Save, Load key
* GubGhz: NeroSketch: add Save, Load key
* Github: better linters triggers
* SubGhz: adding fast loading keys Archive -> Run in app
* GubGhz: KeeLog: add Save, Load key, key generation from the serial number of the meter and the button
* SubGhz: format sources and fix compilation
* FuriHal: add subghz configuration description for AGC section
* SubGhz: save only protocols that can be saved. Cleanup.
* Github: lint on pull requests
Co-authored-by: Aleksandr Kutuzov <alleteam@gmail.com>
2021-08-12 14:42:56 +00:00
|
|
|
SubGhzEncoderPrinceton* encoder;
|
2022-03-03 09:48:56 +00:00
|
|
|
SubGhzTestStaticCallback callback;
|
2021-09-28 00:05:40 +00:00
|
|
|
void* context;
|
2021-04-15 08:47:52 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
typedef struct {
|
2021-04-19 16:46:00 +00:00
|
|
|
uint8_t frequency;
|
2021-04-15 08:47:52 +00:00
|
|
|
uint32_t real_frequency;
|
|
|
|
uint8_t button;
|
2022-03-03 09:48:56 +00:00
|
|
|
} SubGhzTestStaticModel;
|
2021-04-15 08:47:52 +00:00
|
|
|
|
2021-09-28 00:05:40 +00:00
|
|
|
void subghz_test_static_set_callback(
|
2022-03-03 09:48:56 +00:00
|
|
|
SubGhzTestStatic* subghz_test_static,
|
|
|
|
SubGhzTestStaticCallback callback,
|
2021-09-28 00:05:40 +00:00
|
|
|
void* context) {
|
|
|
|
furi_assert(subghz_test_static);
|
|
|
|
furi_assert(callback);
|
|
|
|
subghz_test_static->callback = callback;
|
|
|
|
subghz_test_static->context = context;
|
|
|
|
}
|
|
|
|
|
2022-03-03 09:48:56 +00:00
|
|
|
void subghz_test_static_draw(Canvas* canvas, SubGhzTestStaticModel* model) {
|
2021-04-15 08:47:52 +00:00
|
|
|
char buffer[64];
|
|
|
|
|
|
|
|
canvas_set_color(canvas, ColorBlack);
|
|
|
|
canvas_set_font(canvas, FontPrimary);
|
2021-07-04 16:01:16 +00:00
|
|
|
canvas_draw_str(canvas, 0, 8, "CC1101 Static");
|
2021-04-15 08:47:52 +00:00
|
|
|
|
|
|
|
canvas_set_font(canvas, FontSecondary);
|
|
|
|
// Frequency
|
|
|
|
snprintf(
|
|
|
|
buffer,
|
|
|
|
sizeof(buffer),
|
|
|
|
"Freq: %03ld.%03ld.%03ld Hz",
|
|
|
|
model->real_frequency / 1000000 % 1000,
|
|
|
|
model->real_frequency / 1000 % 1000,
|
|
|
|
model->real_frequency % 1000);
|
2021-07-04 16:01:16 +00:00
|
|
|
canvas_draw_str(canvas, 0, 20, buffer);
|
2021-04-15 08:47:52 +00:00
|
|
|
snprintf(buffer, sizeof(buffer), "Key: %d", model->button);
|
2021-07-04 16:01:16 +00:00
|
|
|
canvas_draw_str(canvas, 0, 31, buffer);
|
2021-04-15 08:47:52 +00:00
|
|
|
}
|
|
|
|
|
2021-08-29 13:05:15 +00:00
|
|
|
bool subghz_test_static_input(InputEvent* event, void* context) {
|
2021-04-15 08:47:52 +00:00
|
|
|
furi_assert(context);
|
2022-03-03 09:48:56 +00:00
|
|
|
SubGhzTestStatic* instance = context;
|
2021-04-15 08:47:52 +00:00
|
|
|
|
|
|
|
if(event->key == InputKeyBack) {
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
|
|
|
with_view_model(
|
2022-10-08 17:38:29 +00:00
|
|
|
instance->view,
|
|
|
|
SubGhzTestStaticModel * model,
|
|
|
|
{
|
2021-04-15 08:47:52 +00:00
|
|
|
if(event->type == InputTypeShort) {
|
|
|
|
if(event->key == InputKeyLeft) {
|
2021-04-19 16:46:00 +00:00
|
|
|
if(model->frequency > 0) model->frequency--;
|
2021-04-15 08:47:52 +00:00
|
|
|
} else if(event->key == InputKeyRight) {
|
2021-12-22 11:05:14 +00:00
|
|
|
if(model->frequency < subghz_frequencies_count_testing - 1) model->frequency++;
|
2021-04-15 08:47:52 +00:00
|
|
|
} else if(event->key == InputKeyDown) {
|
2021-04-19 16:46:00 +00:00
|
|
|
if(model->button > 0) model->button--;
|
2021-04-15 08:47:52 +00:00
|
|
|
} else if(event->key == InputKeyUp) {
|
2021-04-27 16:00:03 +00:00
|
|
|
if(model->button < 3) model->button++;
|
2021-04-15 08:47:52 +00:00
|
|
|
}
|
2021-04-19 16:46:00 +00:00
|
|
|
}
|
|
|
|
|
2021-12-22 11:05:14 +00:00
|
|
|
model->real_frequency = subghz_frequencies_testing[model->frequency];
|
2021-04-15 08:47:52 +00:00
|
|
|
|
|
|
|
if(event->key == InputKeyOk) {
|
2022-07-26 12:21:51 +00:00
|
|
|
NotificationApp* notification = furi_record_open(RECORD_NOTIFICATION);
|
2021-04-15 08:47:52 +00:00
|
|
|
if(event->type == InputTypePress) {
|
2021-08-29 13:05:15 +00:00
|
|
|
furi_hal_subghz_idle();
|
2021-12-22 11:05:14 +00:00
|
|
|
furi_hal_subghz_set_frequency_and_path(
|
|
|
|
subghz_frequencies_testing[model->frequency]);
|
2021-09-28 00:05:40 +00:00
|
|
|
if(!furi_hal_subghz_tx()) {
|
2022-03-03 09:48:56 +00:00
|
|
|
instance->callback(SubGhzTestStaticEventOnlyRx, instance->context);
|
2021-09-28 00:05:40 +00:00
|
|
|
} else {
|
|
|
|
notification_message_block(notification, &sequence_set_red_255);
|
2021-08-29 13:05:15 +00:00
|
|
|
|
2021-11-12 13:04:35 +00:00
|
|
|
FURI_LOG_I(TAG, "TX Start");
|
2021-08-29 13:05:15 +00:00
|
|
|
|
2022-03-03 09:48:56 +00:00
|
|
|
subghz_encoder_princeton_for_testing_set(
|
2021-12-13 12:21:37 +00:00
|
|
|
instance->encoder,
|
|
|
|
subghz_test_static_keys[model->button],
|
|
|
|
10000,
|
2021-12-22 11:05:14 +00:00
|
|
|
subghz_frequencies_testing[model->frequency]);
|
[FL-1610] SubGhz: scene based application, PT save and replay (#630)
* SubGhz: scene based application
* SubGhz: encoder/decoder separation, DMA streaming, update app and cli.
* SubGhz: 2 stage async tx complete, minor cleanup
* SubGhz: 2 stage async tx complete, FIX state pin end transmit
* SubGhz: Pricenton, receive TE signal
* SubGhz: Pricenton, add save data, add load data
* SubGhz: Add Read scene, Fix pricenton save, load funtion
* SubGhz: Add Read, Receiver, SaveName scene
* SubGhz: Read and Save (pricenton)
* SubGhz: add Load scence
* SubGhz: Fix select file scene, add load scene, add transmitter view, add send tx pricenton
* SubGhz: Fix pricenton encoder, fix transmitter send
* SubGhz: modified Pricenton Encoder (added guard time at the beginning), modified CC1101 config, code refactoring
* SubGhz: Fix pricenton encoder defalut TE
* Archive: Fix path and name SubGhz
* Archive: Fix name app SubGhz
* GubGhz: Came: add Save, Load key
* GubGhz: GateTX: add Save, Load key
* GubGhz: NeroSketch: add Save, Load key
* Github: better linters triggers
* SubGhz: adding fast loading keys Archive -> Run in app
* GubGhz: KeeLog: add Save, Load key, key generation from the serial number of the meter and the button
* SubGhz: format sources and fix compilation
* FuriHal: add subghz configuration description for AGC section
* SubGhz: save only protocols that can be saved. Cleanup.
* Github: lint on pull requests
Co-authored-by: Aleksandr Kutuzov <alleteam@gmail.com>
2021-08-12 14:42:56 +00:00
|
|
|
|
2021-09-28 00:05:40 +00:00
|
|
|
furi_hal_subghz_start_async_tx(
|
2022-03-03 09:48:56 +00:00
|
|
|
subghz_encoder_princeton_for_testing_yield, instance->encoder);
|
2022-07-25 14:35:02 +00:00
|
|
|
instance->status_tx = SubGhzTestStaticStatusTX;
|
2021-09-28 00:05:40 +00:00
|
|
|
}
|
|
|
|
} else if(event->type == InputTypeRelease) {
|
2022-07-25 14:35:02 +00:00
|
|
|
if(instance->status_tx == SubGhzTestStaticStatusTX) {
|
2021-11-12 13:04:35 +00:00
|
|
|
FURI_LOG_I(TAG, "TX Stop");
|
2022-03-30 15:23:40 +00:00
|
|
|
subghz_encoder_princeton_for_testing_stop(
|
2022-07-20 10:56:33 +00:00
|
|
|
instance->encoder, furi_get_tick());
|
2022-03-03 09:48:56 +00:00
|
|
|
subghz_encoder_princeton_for_testing_print_log(instance->encoder);
|
2021-09-28 00:05:40 +00:00
|
|
|
furi_hal_subghz_stop_async_tx();
|
|
|
|
notification_message(notification, &sequence_reset_red);
|
|
|
|
}
|
2022-07-25 14:35:02 +00:00
|
|
|
instance->status_tx = SubGhzTestStaticStatusIDLE;
|
2021-04-15 08:47:52 +00:00
|
|
|
}
|
2022-07-26 12:21:51 +00:00
|
|
|
furi_record_close(RECORD_NOTIFICATION);
|
2021-04-15 08:47:52 +00:00
|
|
|
}
|
2022-10-08 17:38:29 +00:00
|
|
|
},
|
|
|
|
true);
|
2021-04-15 08:47:52 +00:00
|
|
|
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
|
2021-08-29 13:05:15 +00:00
|
|
|
void subghz_test_static_enter(void* context) {
|
2021-04-15 08:47:52 +00:00
|
|
|
furi_assert(context);
|
2022-03-03 09:48:56 +00:00
|
|
|
SubGhzTestStatic* instance = context;
|
2021-04-15 08:47:52 +00:00
|
|
|
|
2021-08-08 18:03:25 +00:00
|
|
|
furi_hal_subghz_reset();
|
2023-06-30 14:03:36 +00:00
|
|
|
furi_hal_subghz_load_custom_preset(subghz_device_cc1101_preset_ook_650khz_async_regs);
|
2021-04-15 08:47:52 +00:00
|
|
|
|
2022-03-30 15:23:40 +00:00
|
|
|
furi_hal_gpio_init(&gpio_cc1101_g0, GpioModeOutputPushPull, GpioPullNo, GpioSpeedLow);
|
|
|
|
furi_hal_gpio_write(&gpio_cc1101_g0, false);
|
2022-07-25 14:35:02 +00:00
|
|
|
instance->status_tx = SubGhzTestStaticStatusIDLE;
|
2021-04-15 08:47:52 +00:00
|
|
|
|
|
|
|
with_view_model(
|
2022-10-08 17:38:29 +00:00
|
|
|
instance->view,
|
|
|
|
SubGhzTestStaticModel * model,
|
|
|
|
{
|
2021-12-22 11:05:14 +00:00
|
|
|
model->frequency = subghz_frequencies_433_92_testing;
|
|
|
|
model->real_frequency = subghz_frequencies_testing[model->frequency];
|
2021-04-15 08:47:52 +00:00
|
|
|
model->button = 0;
|
2022-10-08 17:38:29 +00:00
|
|
|
},
|
|
|
|
true);
|
2021-04-15 08:47:52 +00:00
|
|
|
}
|
|
|
|
|
2021-08-29 13:05:15 +00:00
|
|
|
void subghz_test_static_exit(void* context) {
|
2021-04-15 08:47:52 +00:00
|
|
|
furi_assert(context);
|
2021-08-08 18:03:25 +00:00
|
|
|
furi_hal_subghz_sleep();
|
2021-04-15 08:47:52 +00:00
|
|
|
}
|
|
|
|
|
2022-03-03 09:48:56 +00:00
|
|
|
SubGhzTestStatic* subghz_test_static_alloc() {
|
|
|
|
SubGhzTestStatic* instance = malloc(sizeof(SubGhzTestStatic));
|
2021-04-15 08:47:52 +00:00
|
|
|
|
|
|
|
// View allocation and configuration
|
[FL-1610] SubGhz: scene based application, PT save and replay (#630)
* SubGhz: scene based application
* SubGhz: encoder/decoder separation, DMA streaming, update app and cli.
* SubGhz: 2 stage async tx complete, minor cleanup
* SubGhz: 2 stage async tx complete, FIX state pin end transmit
* SubGhz: Pricenton, receive TE signal
* SubGhz: Pricenton, add save data, add load data
* SubGhz: Add Read scene, Fix pricenton save, load funtion
* SubGhz: Add Read, Receiver, SaveName scene
* SubGhz: Read and Save (pricenton)
* SubGhz: add Load scence
* SubGhz: Fix select file scene, add load scene, add transmitter view, add send tx pricenton
* SubGhz: Fix pricenton encoder, fix transmitter send
* SubGhz: modified Pricenton Encoder (added guard time at the beginning), modified CC1101 config, code refactoring
* SubGhz: Fix pricenton encoder defalut TE
* Archive: Fix path and name SubGhz
* Archive: Fix name app SubGhz
* GubGhz: Came: add Save, Load key
* GubGhz: GateTX: add Save, Load key
* GubGhz: NeroSketch: add Save, Load key
* Github: better linters triggers
* SubGhz: adding fast loading keys Archive -> Run in app
* GubGhz: KeeLog: add Save, Load key, key generation from the serial number of the meter and the button
* SubGhz: format sources and fix compilation
* FuriHal: add subghz configuration description for AGC section
* SubGhz: save only protocols that can be saved. Cleanup.
* Github: lint on pull requests
Co-authored-by: Aleksandr Kutuzov <alleteam@gmail.com>
2021-08-12 14:42:56 +00:00
|
|
|
instance->view = view_alloc();
|
2022-03-03 09:48:56 +00:00
|
|
|
view_allocate_model(instance->view, ViewModelTypeLocking, sizeof(SubGhzTestStaticModel));
|
[FL-1610] SubGhz: scene based application, PT save and replay (#630)
* SubGhz: scene based application
* SubGhz: encoder/decoder separation, DMA streaming, update app and cli.
* SubGhz: 2 stage async tx complete, minor cleanup
* SubGhz: 2 stage async tx complete, FIX state pin end transmit
* SubGhz: Pricenton, receive TE signal
* SubGhz: Pricenton, add save data, add load data
* SubGhz: Add Read scene, Fix pricenton save, load funtion
* SubGhz: Add Read, Receiver, SaveName scene
* SubGhz: Read and Save (pricenton)
* SubGhz: add Load scence
* SubGhz: Fix select file scene, add load scene, add transmitter view, add send tx pricenton
* SubGhz: Fix pricenton encoder, fix transmitter send
* SubGhz: modified Pricenton Encoder (added guard time at the beginning), modified CC1101 config, code refactoring
* SubGhz: Fix pricenton encoder defalut TE
* Archive: Fix path and name SubGhz
* Archive: Fix name app SubGhz
* GubGhz: Came: add Save, Load key
* GubGhz: GateTX: add Save, Load key
* GubGhz: NeroSketch: add Save, Load key
* Github: better linters triggers
* SubGhz: adding fast loading keys Archive -> Run in app
* GubGhz: KeeLog: add Save, Load key, key generation from the serial number of the meter and the button
* SubGhz: format sources and fix compilation
* FuriHal: add subghz configuration description for AGC section
* SubGhz: save only protocols that can be saved. Cleanup.
* Github: lint on pull requests
Co-authored-by: Aleksandr Kutuzov <alleteam@gmail.com>
2021-08-12 14:42:56 +00:00
|
|
|
view_set_context(instance->view, instance);
|
2021-08-29 13:05:15 +00:00
|
|
|
view_set_draw_callback(instance->view, (ViewDrawCallback)subghz_test_static_draw);
|
|
|
|
view_set_input_callback(instance->view, subghz_test_static_input);
|
|
|
|
view_set_enter_callback(instance->view, subghz_test_static_enter);
|
|
|
|
view_set_exit_callback(instance->view, subghz_test_static_exit);
|
[FL-1610] SubGhz: scene based application, PT save and replay (#630)
* SubGhz: scene based application
* SubGhz: encoder/decoder separation, DMA streaming, update app and cli.
* SubGhz: 2 stage async tx complete, minor cleanup
* SubGhz: 2 stage async tx complete, FIX state pin end transmit
* SubGhz: Pricenton, receive TE signal
* SubGhz: Pricenton, add save data, add load data
* SubGhz: Add Read scene, Fix pricenton save, load funtion
* SubGhz: Add Read, Receiver, SaveName scene
* SubGhz: Read and Save (pricenton)
* SubGhz: add Load scence
* SubGhz: Fix select file scene, add load scene, add transmitter view, add send tx pricenton
* SubGhz: Fix pricenton encoder, fix transmitter send
* SubGhz: modified Pricenton Encoder (added guard time at the beginning), modified CC1101 config, code refactoring
* SubGhz: Fix pricenton encoder defalut TE
* Archive: Fix path and name SubGhz
* Archive: Fix name app SubGhz
* GubGhz: Came: add Save, Load key
* GubGhz: GateTX: add Save, Load key
* GubGhz: NeroSketch: add Save, Load key
* Github: better linters triggers
* SubGhz: adding fast loading keys Archive -> Run in app
* GubGhz: KeeLog: add Save, Load key, key generation from the serial number of the meter and the button
* SubGhz: format sources and fix compilation
* FuriHal: add subghz configuration description for AGC section
* SubGhz: save only protocols that can be saved. Cleanup.
* Github: lint on pull requests
Co-authored-by: Aleksandr Kutuzov <alleteam@gmail.com>
2021-08-12 14:42:56 +00:00
|
|
|
|
2022-03-03 09:48:56 +00:00
|
|
|
instance->encoder = subghz_encoder_princeton_for_testing_alloc();
|
[FL-1610] SubGhz: scene based application, PT save and replay (#630)
* SubGhz: scene based application
* SubGhz: encoder/decoder separation, DMA streaming, update app and cli.
* SubGhz: 2 stage async tx complete, minor cleanup
* SubGhz: 2 stage async tx complete, FIX state pin end transmit
* SubGhz: Pricenton, receive TE signal
* SubGhz: Pricenton, add save data, add load data
* SubGhz: Add Read scene, Fix pricenton save, load funtion
* SubGhz: Add Read, Receiver, SaveName scene
* SubGhz: Read and Save (pricenton)
* SubGhz: add Load scence
* SubGhz: Fix select file scene, add load scene, add transmitter view, add send tx pricenton
* SubGhz: Fix pricenton encoder, fix transmitter send
* SubGhz: modified Pricenton Encoder (added guard time at the beginning), modified CC1101 config, code refactoring
* SubGhz: Fix pricenton encoder defalut TE
* Archive: Fix path and name SubGhz
* Archive: Fix name app SubGhz
* GubGhz: Came: add Save, Load key
* GubGhz: GateTX: add Save, Load key
* GubGhz: NeroSketch: add Save, Load key
* Github: better linters triggers
* SubGhz: adding fast loading keys Archive -> Run in app
* GubGhz: KeeLog: add Save, Load key, key generation from the serial number of the meter and the button
* SubGhz: format sources and fix compilation
* FuriHal: add subghz configuration description for AGC section
* SubGhz: save only protocols that can be saved. Cleanup.
* Github: lint on pull requests
Co-authored-by: Aleksandr Kutuzov <alleteam@gmail.com>
2021-08-12 14:42:56 +00:00
|
|
|
|
|
|
|
return instance;
|
2021-04-15 08:47:52 +00:00
|
|
|
}
|
|
|
|
|
2022-03-03 09:48:56 +00:00
|
|
|
void subghz_test_static_free(SubGhzTestStatic* instance) {
|
[FL-1610] SubGhz: scene based application, PT save and replay (#630)
* SubGhz: scene based application
* SubGhz: encoder/decoder separation, DMA streaming, update app and cli.
* SubGhz: 2 stage async tx complete, minor cleanup
* SubGhz: 2 stage async tx complete, FIX state pin end transmit
* SubGhz: Pricenton, receive TE signal
* SubGhz: Pricenton, add save data, add load data
* SubGhz: Add Read scene, Fix pricenton save, load funtion
* SubGhz: Add Read, Receiver, SaveName scene
* SubGhz: Read and Save (pricenton)
* SubGhz: add Load scence
* SubGhz: Fix select file scene, add load scene, add transmitter view, add send tx pricenton
* SubGhz: Fix pricenton encoder, fix transmitter send
* SubGhz: modified Pricenton Encoder (added guard time at the beginning), modified CC1101 config, code refactoring
* SubGhz: Fix pricenton encoder defalut TE
* Archive: Fix path and name SubGhz
* Archive: Fix name app SubGhz
* GubGhz: Came: add Save, Load key
* GubGhz: GateTX: add Save, Load key
* GubGhz: NeroSketch: add Save, Load key
* Github: better linters triggers
* SubGhz: adding fast loading keys Archive -> Run in app
* GubGhz: KeeLog: add Save, Load key, key generation from the serial number of the meter and the button
* SubGhz: format sources and fix compilation
* FuriHal: add subghz configuration description for AGC section
* SubGhz: save only protocols that can be saved. Cleanup.
* Github: lint on pull requests
Co-authored-by: Aleksandr Kutuzov <alleteam@gmail.com>
2021-08-12 14:42:56 +00:00
|
|
|
furi_assert(instance);
|
2022-03-03 09:48:56 +00:00
|
|
|
subghz_encoder_princeton_for_testing_free(instance->encoder);
|
[FL-1610] SubGhz: scene based application, PT save and replay (#630)
* SubGhz: scene based application
* SubGhz: encoder/decoder separation, DMA streaming, update app and cli.
* SubGhz: 2 stage async tx complete, minor cleanup
* SubGhz: 2 stage async tx complete, FIX state pin end transmit
* SubGhz: Pricenton, receive TE signal
* SubGhz: Pricenton, add save data, add load data
* SubGhz: Add Read scene, Fix pricenton save, load funtion
* SubGhz: Add Read, Receiver, SaveName scene
* SubGhz: Read and Save (pricenton)
* SubGhz: add Load scence
* SubGhz: Fix select file scene, add load scene, add transmitter view, add send tx pricenton
* SubGhz: Fix pricenton encoder, fix transmitter send
* SubGhz: modified Pricenton Encoder (added guard time at the beginning), modified CC1101 config, code refactoring
* SubGhz: Fix pricenton encoder defalut TE
* Archive: Fix path and name SubGhz
* Archive: Fix name app SubGhz
* GubGhz: Came: add Save, Load key
* GubGhz: GateTX: add Save, Load key
* GubGhz: NeroSketch: add Save, Load key
* Github: better linters triggers
* SubGhz: adding fast loading keys Archive -> Run in app
* GubGhz: KeeLog: add Save, Load key, key generation from the serial number of the meter and the button
* SubGhz: format sources and fix compilation
* FuriHal: add subghz configuration description for AGC section
* SubGhz: save only protocols that can be saved. Cleanup.
* Github: lint on pull requests
Co-authored-by: Aleksandr Kutuzov <alleteam@gmail.com>
2021-08-12 14:42:56 +00:00
|
|
|
view_free(instance->view);
|
|
|
|
free(instance);
|
2021-04-15 08:47:52 +00:00
|
|
|
}
|
|
|
|
|
2022-03-03 09:48:56 +00:00
|
|
|
View* subghz_test_static_get_view(SubGhzTestStatic* instance) {
|
[FL-1610] SubGhz: scene based application, PT save and replay (#630)
* SubGhz: scene based application
* SubGhz: encoder/decoder separation, DMA streaming, update app and cli.
* SubGhz: 2 stage async tx complete, minor cleanup
* SubGhz: 2 stage async tx complete, FIX state pin end transmit
* SubGhz: Pricenton, receive TE signal
* SubGhz: Pricenton, add save data, add load data
* SubGhz: Add Read scene, Fix pricenton save, load funtion
* SubGhz: Add Read, Receiver, SaveName scene
* SubGhz: Read and Save (pricenton)
* SubGhz: add Load scence
* SubGhz: Fix select file scene, add load scene, add transmitter view, add send tx pricenton
* SubGhz: Fix pricenton encoder, fix transmitter send
* SubGhz: modified Pricenton Encoder (added guard time at the beginning), modified CC1101 config, code refactoring
* SubGhz: Fix pricenton encoder defalut TE
* Archive: Fix path and name SubGhz
* Archive: Fix name app SubGhz
* GubGhz: Came: add Save, Load key
* GubGhz: GateTX: add Save, Load key
* GubGhz: NeroSketch: add Save, Load key
* Github: better linters triggers
* SubGhz: adding fast loading keys Archive -> Run in app
* GubGhz: KeeLog: add Save, Load key, key generation from the serial number of the meter and the button
* SubGhz: format sources and fix compilation
* FuriHal: add subghz configuration description for AGC section
* SubGhz: save only protocols that can be saved. Cleanup.
* Github: lint on pull requests
Co-authored-by: Aleksandr Kutuzov <alleteam@gmail.com>
2021-08-12 14:42:56 +00:00
|
|
|
furi_assert(instance);
|
|
|
|
return instance->view;
|
2022-02-18 19:53:46 +00:00
|
|
|
}
|