mirror of
https://github.com/Next-Flip/Momentum-Firmware.git
synced 2026-05-24 05:34:45 -07:00
fmt updates and build update
This commit is contained in:
@@ -61,7 +61,6 @@ static void draw_callback(Canvas* canvas, void* ctx) {
|
|||||||
default:
|
default:
|
||||||
canvas_draw_str(canvas, 3, 55, "Backlight: AUTO");
|
canvas_draw_str(canvas, 3, 55, "Backlight: AUTO");
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static void input_callback(InputEvent* input_event, void* ctx) {
|
static void input_callback(InputEvent* input_event, void* ctx) {
|
||||||
@@ -125,17 +124,16 @@ int32_t zeitraffer_app(void* p) {
|
|||||||
if(event.input.type == InputTypeShort) { // Короткие нажатия
|
if(event.input.type == InputTypeShort) { // Короткие нажатия
|
||||||
|
|
||||||
if(event.input.key == InputKeyBack) {
|
if(event.input.key == InputKeyBack) {
|
||||||
if(furi_timer_is_running(timer)) { // Если таймер запущен - нефиг мацать кнопки!
|
if(furi_timer_is_running(
|
||||||
|
timer)) { // Если таймер запущен - нефиг мацать кнопки!
|
||||||
notification_message(notifications, &sequence_error);
|
notification_message(notifications, &sequence_error);
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
WorkCount = Count;
|
WorkCount = Count;
|
||||||
WorkTime = 3;
|
WorkTime = 3;
|
||||||
if(Count == 0) {
|
if(Count == 0) {
|
||||||
InfiniteShot = true;
|
InfiniteShot = true;
|
||||||
WorkCount = 1;
|
WorkCount = 1;
|
||||||
}
|
} else
|
||||||
else
|
|
||||||
InfiniteShot = false;
|
InfiniteShot = false;
|
||||||
|
|
||||||
notification_message(notifications, &sequence_success);
|
notification_message(notifications, &sequence_success);
|
||||||
@@ -144,8 +142,7 @@ int32_t zeitraffer_app(void* p) {
|
|||||||
if(event.input.key == InputKeyRight) {
|
if(event.input.key == InputKeyRight) {
|
||||||
if(furi_timer_is_running(timer)) {
|
if(furi_timer_is_running(timer)) {
|
||||||
notification_message(notifications, &sequence_error);
|
notification_message(notifications, &sequence_error);
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
Count++;
|
Count++;
|
||||||
notification_message(notifications, &sequence_click);
|
notification_message(notifications, &sequence_click);
|
||||||
}
|
}
|
||||||
@@ -153,8 +150,7 @@ int32_t zeitraffer_app(void* p) {
|
|||||||
if(event.input.key == InputKeyLeft) {
|
if(event.input.key == InputKeyLeft) {
|
||||||
if(furi_timer_is_running(timer)) {
|
if(furi_timer_is_running(timer)) {
|
||||||
notification_message(notifications, &sequence_error);
|
notification_message(notifications, &sequence_error);
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
Count--;
|
Count--;
|
||||||
notification_message(notifications, &sequence_click);
|
notification_message(notifications, &sequence_click);
|
||||||
}
|
}
|
||||||
@@ -162,8 +158,7 @@ int32_t zeitraffer_app(void* p) {
|
|||||||
if(event.input.key == InputKeyUp) {
|
if(event.input.key == InputKeyUp) {
|
||||||
if(furi_timer_is_running(timer)) {
|
if(furi_timer_is_running(timer)) {
|
||||||
notification_message(notifications, &sequence_error);
|
notification_message(notifications, &sequence_error);
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
Time++;
|
Time++;
|
||||||
notification_message(notifications, &sequence_click);
|
notification_message(notifications, &sequence_click);
|
||||||
}
|
}
|
||||||
@@ -171,32 +166,26 @@ int32_t zeitraffer_app(void* p) {
|
|||||||
if(event.input.key == InputKeyDown) {
|
if(event.input.key == InputKeyDown) {
|
||||||
if(furi_timer_is_running(timer)) {
|
if(furi_timer_is_running(timer)) {
|
||||||
notification_message(notifications, &sequence_error);
|
notification_message(notifications, &sequence_error);
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
Time--;
|
Time--;
|
||||||
notification_message(notifications, &sequence_click);
|
notification_message(notifications, &sequence_click);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if(event.input.key == InputKeyOk) {
|
if(event.input.key == InputKeyOk) {
|
||||||
|
|
||||||
if(furi_timer_is_running(timer)) {
|
if(furi_timer_is_running(timer)) {
|
||||||
notification_message(notifications, &sequence_click);
|
notification_message(notifications, &sequence_click);
|
||||||
furi_timer_stop(timer);
|
furi_timer_stop(timer);
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
furi_timer_start(timer, 1000);
|
furi_timer_start(timer, 1000);
|
||||||
|
|
||||||
if (WorkCount == 0)
|
if(WorkCount == 0) WorkCount = Count;
|
||||||
WorkCount = Count;
|
|
||||||
|
|
||||||
if (WorkTime == 0)
|
if(WorkTime == 0) WorkTime = 3;
|
||||||
WorkTime = 3;
|
|
||||||
|
|
||||||
if(Count == 0) {
|
if(Count == 0) {
|
||||||
InfiniteShot = true;
|
InfiniteShot = true;
|
||||||
WorkCount = 1;
|
WorkCount = 1;
|
||||||
}
|
} else
|
||||||
else
|
|
||||||
InfiniteShot = false;
|
InfiniteShot = false;
|
||||||
|
|
||||||
if(Count == -1) {
|
if(Count == -1) {
|
||||||
@@ -205,8 +194,7 @@ int32_t zeitraffer_app(void* p) {
|
|||||||
Bulb = true;
|
Bulb = true;
|
||||||
WorkCount = 1;
|
WorkCount = 1;
|
||||||
WorkTime = Time;
|
WorkTime = Time;
|
||||||
}
|
} else
|
||||||
else
|
|
||||||
Bulb = false;
|
Bulb = false;
|
||||||
|
|
||||||
notification_message(notifications, &sequence_success);
|
notification_message(notifications, &sequence_success);
|
||||||
@@ -218,12 +206,12 @@ int32_t zeitraffer_app(void* p) {
|
|||||||
if(event.input.key == InputKeyBack) {
|
if(event.input.key == InputKeyBack) {
|
||||||
if(furi_timer_is_running(timer)) { // А если работает таймер - не выходим :D
|
if(furi_timer_is_running(timer)) { // А если работает таймер - не выходим :D
|
||||||
notification_message(notifications, &sequence_error);
|
notification_message(notifications, &sequence_error);
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
notification_message(notifications, &sequence_click);
|
notification_message(notifications, &sequence_click);
|
||||||
gpio_item_set_all_pins(false);
|
gpio_item_set_all_pins(false);
|
||||||
furi_timer_stop(timer);
|
furi_timer_stop(timer);
|
||||||
notification_message(notifications, &sequence_display_backlight_enforce_auto);
|
notification_message(
|
||||||
|
notifications, &sequence_display_backlight_enforce_auto);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -232,39 +220,34 @@ int32_t zeitraffer_app(void* p) {
|
|||||||
Backlight++;
|
Backlight++;
|
||||||
if(Backlight > 2) Backlight = 0;
|
if(Backlight > 2) Backlight = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if(event.input.type == InputTypeRepeat) { // Зажатые кнопки
|
if(event.input.type == InputTypeRepeat) { // Зажатые кнопки
|
||||||
if(event.input.key == InputKeyRight) {
|
if(event.input.key == InputKeyRight) {
|
||||||
if(furi_timer_is_running(timer)) {
|
if(furi_timer_is_running(timer)) {
|
||||||
notification_message(notifications, &sequence_error);
|
notification_message(notifications, &sequence_error);
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
Count = Count + 10;
|
Count = Count + 10;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if(event.input.key == InputKeyLeft) {
|
if(event.input.key == InputKeyLeft) {
|
||||||
if(furi_timer_is_running(timer)) {
|
if(furi_timer_is_running(timer)) {
|
||||||
notification_message(notifications, &sequence_error);
|
notification_message(notifications, &sequence_error);
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
Count = Count - 10;
|
Count = Count - 10;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if(event.input.key == InputKeyUp) {
|
if(event.input.key == InputKeyUp) {
|
||||||
if(furi_timer_is_running(timer)) {
|
if(furi_timer_is_running(timer)) {
|
||||||
notification_message(notifications, &sequence_error);
|
notification_message(notifications, &sequence_error);
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
Time = Time + 10;
|
Time = Time + 10;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if(event.input.key == InputKeyDown) {
|
if(event.input.key == InputKeyDown) {
|
||||||
if(furi_timer_is_running(timer)) {
|
if(furi_timer_is_running(timer)) {
|
||||||
notification_message(notifications, &sequence_error);
|
notification_message(notifications, &sequence_error);
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
Time = Time - 10;
|
Time = Time - 10;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -273,15 +256,14 @@ int32_t zeitraffer_app(void* p) {
|
|||||||
|
|
||||||
// Наше событие — это сработавший таймер
|
// Наше событие — это сработавший таймер
|
||||||
else if(event.type == EventTypeTick) {
|
else if(event.type == EventTypeTick) {
|
||||||
|
|
||||||
WorkTime--;
|
WorkTime--;
|
||||||
|
|
||||||
if(WorkTime < 1) { // фоткаем
|
if(WorkTime < 1) { // фоткаем
|
||||||
notification_message(notifications, &sequence_blink_white_100);
|
notification_message(notifications, &sequence_blink_white_100);
|
||||||
if(Bulb) {
|
if(Bulb) {
|
||||||
gpio_item_set_all_pins(false); WorkCount = 0;
|
gpio_item_set_all_pins(false);
|
||||||
}
|
WorkCount = 0;
|
||||||
else {
|
} else {
|
||||||
WorkCount--;
|
WorkCount--;
|
||||||
view_port_update(view_port);
|
view_port_update(view_port);
|
||||||
notification_message(notifications, &sequence_click);
|
notification_message(notifications, &sequence_click);
|
||||||
@@ -299,8 +281,7 @@ int32_t zeitraffer_app(void* p) {
|
|||||||
WorkTime = Time;
|
WorkTime = Time;
|
||||||
view_port_update(view_port);
|
view_port_update(view_port);
|
||||||
}
|
}
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
// Отправляем нотификацию мигания синим светодиодом
|
// Отправляем нотификацию мигания синим светодиодом
|
||||||
notification_message(notifications, &sequence_blink_blue_100);
|
notification_message(notifications, &sequence_blink_blue_100);
|
||||||
}
|
}
|
||||||
@@ -323,10 +304,10 @@ int32_t zeitraffer_app(void* p) {
|
|||||||
default:
|
default:
|
||||||
notification_message(notifications, &sequence_display_backlight_enforce_auto);
|
notification_message(notifications, &sequence_display_backlight_enforce_auto);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
if(Time < 1) Time = 1; // Не даём открутить таймер меньше единицы
|
if(Time < 1) Time = 1; // Не даём открутить таймер меньше единицы
|
||||||
if (Count < -1) Count = 0; // А тут даём, бо 0 кадров это бесконечная съёмка, а -1 кадров - BULB
|
if(Count < -1)
|
||||||
|
Count = 0; // А тут даём, бо 0 кадров это бесконечная съёмка, а -1 кадров - BULB
|
||||||
}
|
}
|
||||||
|
|
||||||
// Очищаем таймер
|
// Очищаем таймер
|
||||||
|
|||||||
@@ -60,7 +60,15 @@ const WifiMarauderItem items[NUM_MENU_ITEMS] = {
|
|||||||
{"Sniff",
|
{"Sniff",
|
||||||
{"beacon", "deauth", "esp", "pmkid", "probe", "pwn", "raw", "bt", "skim"},
|
{"beacon", "deauth", "esp", "pmkid", "probe", "pwn", "raw", "bt", "skim"},
|
||||||
9,
|
9,
|
||||||
{"sniffbeacon", "sniffdeauth", "sniffesp", "sniffpmkid", "sniffprobe", "sniffpwn", "sniffraw", "sniffbt", "sniffskim"},
|
{"sniffbeacon",
|
||||||
|
"sniffdeauth",
|
||||||
|
"sniffesp",
|
||||||
|
"sniffpmkid",
|
||||||
|
"sniffprobe",
|
||||||
|
"sniffpwn",
|
||||||
|
"sniffraw",
|
||||||
|
"sniffbt",
|
||||||
|
"sniffskim"},
|
||||||
NO_ARGS,
|
NO_ARGS,
|
||||||
FOCUS_CONSOLE_END,
|
FOCUS_CONSOLE_END,
|
||||||
SHOW_STOPSCAN_TIP},
|
SHOW_STOPSCAN_TIP},
|
||||||
|
|||||||
@@ -1,3 +1,4 @@
|
|||||||
|
rm -rf RM*-*-*.tgz RM*-*-*.zip .sconsign.dblite dist build assets/resources/apps
|
||||||
git pull
|
git pull
|
||||||
./fbt updater_package
|
./fbt updater_package
|
||||||
DATE_VAR=`date +%m%d`
|
DATE_VAR=`date +%m%d`
|
||||||
|
|||||||
Reference in New Issue
Block a user