Skip to content

Commit

Permalink
Merge remote-tracking branch 'mntm/dev' into merge/iso15-mode
Browse files Browse the repository at this point in the history
  • Loading branch information
Willy-JL committed Nov 27, 2024
2 parents f14dd3f + 1163b58 commit 9baae2c
Show file tree
Hide file tree
Showing 336 changed files with 30,700 additions and 10,386 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ Many apps included in Momentum are modified (some lots more than others). This i
- Removing/tweaking icons and/or their usages to **support our Asset Packs system**
- Removing duplicate keyboard implementations to **use our extended system keyboard**
- With our system keyboard also **support our CLI command `input keyboard`** to type with PC keyboard
- Tweak UART/SPI usage to **support our GPIO Pins mapping settings**
- **Moving location of save files** to a more appropriate location or changing how they are saved
- **Changing application display names** to fit our naming scheme
- **Changing how some menus work/look** or adding **new exclusive menus and features**
Expand Down
2 changes: 1 addition & 1 deletion avr_isp/.gitsubtree
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
https://github.com/xMasterX/all-the-plugins dev base_pack/avr_isp_programmer 4558d74c9da36abc851edd96a95d18f7d5511a75
https://github.com/xMasterX/all-the-plugins dev base_pack/avr_isp_programmer 17bec3e26b8250c59acebd4fa52b6b08f68152d7
https://github.com/flipperdevices/flipperzero-good-faps dev avr_isp_programmer b791dea234f855155027bb46215dc60f3ddeb243
1 change: 1 addition & 0 deletions avr_isp/helpers/avr_isp_worker.c
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ static const CdcCallbacks cdc_cb = {
vcp_state_callback,
vcp_on_cdc_control_line,
vcp_on_line_config,
NULL,
};

/* VCP callbacks */
Expand Down
2 changes: 1 addition & 1 deletion esp_flasher/application.fam
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
App(
appid="esp_flasher",
name="[ESP] ESP Flasher",
fap_version=(1, 6),
fap_version=(1, 7),
apptype=FlipperAppType.EXTERNAL,
entry_point="esp_flasher_app",
requires=["gui"],
Expand Down
Binary file not shown.
8 changes: 4 additions & 4 deletions esp_flasher/scenes/esp_flasher_scene_browse.c
Original file line number Diff line number Diff line change
Expand Up @@ -180,9 +180,9 @@ static void esp_flasher_scene_browse_callback(void* context, uint32_t index) {
#define STR_APP_A "FirmwareA(" TOSTRING(ESP_ADDR_APP_A) ")"
#define STR_APP_B "FirmwareB(" TOSTRING(ESP_ADDR_APP_B) ")"
#define STR_CUSTOM "Custom"
#define STR_FLASH_S3 "[>] FLASH - slow (S3)"
#define STR_FLASH_S3 "[>] FLASH - slow (0x0)"
#define STR_FLASH "[>] FLASH - slow"
#define STR_FLASH_TURBO_S3 "[>] FLASH - fast (S3)"
#define STR_FLASH_TURBO_S3 "[>] FLASH - fast (0x0)"
#define STR_FLASH_TURBO "[>] FLASH - fast"
static void _refresh_submenu(EspFlasherApp* app) {
Submenu* submenu = app->submenu;
Expand All @@ -192,8 +192,8 @@ static void _refresh_submenu(EspFlasherApp* app) {
submenu_set_header(submenu, "Browse for files to flash");
submenu_add_item(
submenu,
app->selected_flash_options[SelectedFlashS3Mode] ? "[x] Using ESP32-S3" :
"[ ] Select if using S3",
app->selected_flash_options[SelectedFlashS3Mode] ? "[x] Using S3, C3 or C6" :
"[ ] Select for S3, C3, C6",
SubmenuIndexS3Mode,
esp_flasher_scene_browse_callback,
app);
Expand Down
34 changes: 17 additions & 17 deletions esp_flasher/scenes/esp_flasher_scene_quick.c
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ enum QuickState {
QuickStart,
QuickS2Boot,
QuickS2Boot_Marauder,
QuickS2Boot_Blackmagic,
QuickS2Boot_Flipperhttp,
QuickS2Boot_Blackmagic,
QuickWROOMBoot,
QuickWROOMBoot_Marauder,
QuickWROOMBoot_Wardriver,
Expand All @@ -29,8 +29,8 @@ enum QuickState {
QuickWROOM_Wardriver,
QuickS2,
QuickS2_Marauder,
QuickS2_Blackmagic,
QuickS2_Flipperhttp,
QuickS2_Blackmagic,
QuickS3,
QuickS3_Marauder,
QuickS3_Wardriver,
Expand Down Expand Up @@ -91,11 +91,11 @@ void esp_flasher_scene_quick_on_enter(void* context) {
submenu, "Other ESP32-S3", QuickS3, esp_flasher_scene_quick_submenu_callback, app);
break;
case QuickS2Boot_Marauder:
case QuickS2Boot_Blackmagic:
case QuickS2Boot_Flipperhttp:
case QuickS2Boot_Blackmagic:
case QuickS2_Marauder:
case QuickS2_Blackmagic:
case QuickS2_Flipperhttp:
case QuickS2_Blackmagic:
submenu_set_header(submenu, "Choose Firmware:");
submenu_add_item(
submenu,
Expand All @@ -105,14 +105,14 @@ void esp_flasher_scene_quick_on_enter(void* context) {
app);
submenu_add_item(
submenu,
"Black Magic (FZ debugger)",
state > QuickS2 ? QuickS2_Blackmagic : QuickS2Boot_Blackmagic,
"FlipperHTTP (web access)",
state > QuickS2 ? QuickS2_Flipperhttp : QuickS2Boot_Flipperhttp,
esp_flasher_scene_quick_submenu_callback,
app);
submenu_add_item(
submenu,
"FlipperHTTP (web access)",
state > QuickS2 ? QuickS2_Flipperhttp : QuickS2Boot_Flipperhttp,
"Black Magic (FZ debugger)",
state > QuickS2 ? QuickS2_Blackmagic : QuickS2Boot_Blackmagic,
esp_flasher_scene_quick_submenu_callback,
app);
break;
Expand Down Expand Up @@ -199,15 +199,6 @@ bool esp_flasher_scene_quick_on_event(void* context, SceneManagerEvent event) {
firm = APP_DATA_PATH("assets/marauder/s2/esp32_marauder.flipper.bin");
break;

case QuickS2Boot_Blackmagic:
enter_bootloader = true;
/* fallthrough */
case QuickS2_Blackmagic:
boot = APP_DATA_PATH("assets/blackmagic/s2/bootloader.bin");
part = APP_DATA_PATH("assets/blackmagic/s2/partition-table.bin");
firm = APP_DATA_PATH("assets/blackmagic/s2/blackmagic.bin");
break;

case QuickS2Boot_Flipperhttp:
enter_bootloader = true;
/* fallthrough */
Expand All @@ -217,6 +208,15 @@ bool esp_flasher_scene_quick_on_event(void* context, SceneManagerEvent event) {
firm = APP_DATA_PATH("assets/flipperhttp/s2/flipper_http_firmware_a.bin");
break;

case QuickS2Boot_Blackmagic:
enter_bootloader = true;
/* fallthrough */
case QuickS2_Blackmagic:
boot = APP_DATA_PATH("assets/blackmagic/s2/bootloader.bin");
part = APP_DATA_PATH("assets/blackmagic/s2/partition-table.bin");
firm = APP_DATA_PATH("assets/blackmagic/s2/blackmagic.bin");
break;

case QuickWROOMBoot_Marauder:
enter_bootloader = true;
/* fallthrough */
Expand Down
Binary file removed flip_library/.DS_Store
Binary file not shown.
19 changes: 18 additions & 1 deletion flip_library/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,20 @@
## v1.3
Refactored by Derek Jamison:
- Improved progress display.
- Added connectivity check on startup.
- Added Wikipedia API.

## v1.2
- Improved memory allocation.
- Added in Dog Facts.
- Added in Random Quotes.

## v1.1
- Update for app catalog.

## v1.0
- Initial Release.

## v1.2
- Improved memory allocation.
- Added in Dog Facts.
Expand All @@ -7,4 +24,4 @@
- Update for app catalog.

## v1.0
- Initial Release.
- Initial Release.
9 changes: 7 additions & 2 deletions flip_library/README.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
The **FlipLibrary** app for Flipper Zero is a versatile and user-friendly application that offers a combination of useful features to enhance your Flipper Zero experience.

The app includes a **dictionary**, **random facts**, and additional functionalities, all accessible directly from your Flipper Zero device. It is designed for easy navigation and quick access to information, making it a handy companion for on-the-go learning and entertainment.
The app includes a **dictionary**, **random facts**, and additional functionalities, all accessible directly from your Flipper Zero device. It is designed for easy navigation and quick access to information, making it a handy companion for on-the-go learning and entertainment. Big shout out to [Derek Jamison](https://github.com/jamisonderek) for his contributions.

FlipLibrary uses the FlipperHTTP flash for the WiFi Devboard, first introduced in the WebCrawler app: https://github.com/jblanked/WebCrawler-FlipperZero/tree/main/assets/FlipperHTTP


## Requirements
- WiFi Dev Board or Raspberry Pi Pico W for Flipper Zero with FlipperHTTP Flash: https://github.com/jblanked/FlipperHTTP
- WiFi Developer Board or Raspberry Pi Pico W with FlipperHTTP Flash: https://github.com/jblanked/FlipperHTTP
- WiFi Access Point


Expand Down Expand Up @@ -34,3 +34,8 @@ The app automatically allocates necessary resources and initializes settings. If
- Visit **Random Facts** to read interesting trivia.
- Configure **WiFi settings** if network-related features are required in the future.
- Check the **About** section to learn more about the app.

# Known Bugs

1. **Screen Delay**: Occasionally, the Defition or Random Facts screen may get stuck on "Loading".
- Update to version 1.3 or higher.
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
#ifndef FLIP_LIBRARY_I_H
#define FLIP_LIBRARY_I_H
#include "alloc/flip_library_alloc.h"

// Function to allocate resources for the FlipLibraryApp
static FlipLibraryApp* flip_library_app_alloc() {
FlipLibraryApp* flip_library_app_alloc() {
FlipLibraryApp* app = (FlipLibraryApp*)malloc(sizeof(FlipLibraryApp));

Gui* gui = furi_record_open(RECORD_GUI);
Expand All @@ -15,7 +14,7 @@ static FlipLibraryApp* flip_library_app_alloc() {
// Allocate the text input buffer
app->uart_text_input_buffer_size_ssid = 64;
app->uart_text_input_buffer_size_password = 64;
app->uart_text_input_buffer_size_dictionary = 64;
app->uart_text_input_buffer_size_query = 64;
if(!easy_flipper_set_buffer(
&app->uart_text_input_buffer_ssid, app->uart_text_input_buffer_size_ssid)) {
return NULL;
Expand All @@ -34,67 +33,51 @@ static FlipLibraryApp* flip_library_app_alloc() {
return NULL;
}
if(!easy_flipper_set_buffer(
&app->uart_text_input_buffer_dictionary, app->uart_text_input_buffer_size_dictionary)) {
&app->uart_text_input_buffer_query, app->uart_text_input_buffer_size_query)) {
return NULL;
}
if(!easy_flipper_set_buffer(
&app->uart_text_input_temp_buffer_dictionary,
app->uart_text_input_buffer_size_dictionary)) {
&app->uart_text_input_temp_buffer_query, app->uart_text_input_buffer_size_query)) {
return NULL;
}

// Allocate ViewDispatcher
if(!easy_flipper_set_view_dispatcher(&app->view_dispatcher, gui, app)) {
return NULL;
}
view_dispatcher_set_custom_event_callback(
app->view_dispatcher, flip_library_custom_event_callback);

// Main view
if(!easy_flipper_set_view(
&app->view_random_facts,
FlipLibraryViewRandomFactsRun,
view_draw_callback_random_facts,
&app->view_loader,
FlipLibraryViewLoader,
flip_library_loader_draw_callback,
NULL,
callback_to_random_facts,
&app->view_dispatcher,
app)) {
return NULL;
}
if(!easy_flipper_set_view(
&app->view_dictionary,
FlipLibraryViewDictionaryRun,
view_draw_callback_dictionary_run,
NULL,
callback_to_submenu,
&app->view_dispatcher,
app)) {
return NULL;
}
flip_library_loader_init(app->view_loader);

// Widget
if(!easy_flipper_set_widget(
&app->widget,
&app->widget_about,
FlipLibraryViewAbout,
"FlipLibrary v1.2\n-----\nDictionary, random facts, and\nmore.\n-----\nwww.github.com/jblanked",
"FlipLibrary v1.3\n-----\nDictionary, random facts, and\nmore.\n-----\nwww.github.com/jblanked",
callback_to_submenu,
&app->view_dispatcher)) {
return NULL;
}
if(!easy_flipper_set_widget(
&app->widget_random_fact,
FlipLibraryViewRandomFactWidget,
&app->widget_result,
FlipLibraryViewWidgetResult,
"Error, try again.",
callback_to_random_facts,
&app->view_dispatcher)) {
return NULL;
}
if(!easy_flipper_set_widget(
&app->widget_dictionary,
FlipLibraryViewDictionaryWidget,
"Error, try again.",
callback_to_submenu,
&app->view_dispatcher)) {
return NULL;
}

// Text Input
if(!easy_flipper_set_uart_text_input(
Expand Down Expand Up @@ -122,12 +105,12 @@ static FlipLibraryApp* flip_library_app_alloc() {
return NULL;
}
if(!easy_flipper_set_uart_text_input(
&app->uart_text_input_dictionary,
FlipLibraryViewDictionaryTextInput,
"Enter a word",
app->uart_text_input_temp_buffer_dictionary,
app->uart_text_input_buffer_size_dictionary,
text_updated_dictionary,
&app->uart_text_input_query,
FlipLibraryViewTextInputQuery,
"Enter Query",
app->uart_text_input_temp_buffer_query,
app->uart_text_input_buffer_size_query,
text_updated_query,
callback_to_submenu,
&app->view_dispatcher,
app)) {
Expand Down Expand Up @@ -156,7 +139,7 @@ static FlipLibraryApp* flip_library_app_alloc() {
if(!easy_flipper_set_submenu(
&app->submenu_main,
FlipLibraryViewSubmenuMain,
"FlipLibrary v1.2",
"FlipLibrary v1.3",
callback_exit_app,
&app->view_dispatcher)) {
return NULL;
Expand All @@ -176,6 +159,12 @@ static FlipLibraryApp* flip_library_app_alloc() {
FlipLibrarySubmenuIndexRandomFacts,
callback_submenu_choices,
app);
submenu_add_item(
app->submenu_main,
"Wikipedia",
FlipLibrarySubmenuIndexRandomFactsWiki,
callback_submenu_choices,
app);
submenu_add_item(
app->submenu_main,
"Dictionary",
Expand Down Expand Up @@ -219,9 +208,10 @@ static FlipLibraryApp* flip_library_app_alloc() {
app->uart_text_input_buffer_password,
app->uart_text_input_buffer_size_password)) {
// Update variable items
if(app->variable_item_ssid)
if(app->variable_item_ssid) {
variable_item_set_current_value_text(
app->variable_item_ssid, app->uart_text_input_buffer_ssid);
}
// dont show password

// Copy items into their temp buffers with safety checks
Expand Down Expand Up @@ -251,5 +241,3 @@ static FlipLibraryApp* flip_library_app_alloc() {

return app;
}

#endif // FLIP_LIBRARY_I_H
10 changes: 10 additions & 0 deletions flip_library/alloc/flip_library_alloc.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
#ifndef FLIP_LIBRARY_I_H
#define FLIP_LIBRARY_I_H

#include <flip_library.h>
#include <callback/flip_library_callback.h>

// Function to allocate resources for the FlipLibraryApp
FlipLibraryApp* flip_library_app_alloc();

#endif // FLIP_LIBRARY_I_H
Loading

0 comments on commit 9baae2c

Please sign in to comment.