Closed Blobadoodle closed 2 years ago
Confirmed. Quite a few APIs appear to have changed since firmware 0.67.x, including an overhaul of how strings are done apparently.
I tried to build the apps myself but found that a few won't compile at all with the new firmware due to the change from struct string_t *
to FuriString *
. I've been working my way through some of the apps, hoping to contribute a PR, but at least the flipfrid app is full of strings and i'm getting tangled up.
A few notes:
#include <m-string.h>
should be substituted for #include <furi.h>
string_t MyString; string_init(MyString);
is now FuriString* MyString; MyString = furi_string_alloc();
string_set_str(MyString, "Value");
is now furi_string_set(MyString, "Value");
string_clear(MyString);
is now furi_string_free(MyString);
furi_
appended to them (ie, string_size
is now furi_string_size
), the ones I found are string_get_cstr
, string_push_back
, string_cmp_str
, string_printf
, string_right
, string_search
, string_cat_printf
, string_size
and string_reset
.string_equal_str_p(MyString, OtherString);
is now furi_string_equal(MyString, OtherString);
string_starts_with_str_p(MyString, "Value");
is now furi_string_starts_with(MyString, "Value");
string_init_set_str(MyString, OtherString);
is now MyString = furi_string_alloc_set(OtherString);
string_init_vprintf(MyString, Format, Args);
is now MyString = furi_string_alloc_vprintf(Format, Args);
STRING_OPLIST
is now FURI_STRING_OPLIST
string_cmp_str
appears to have become both furi_string_cmp
and furi_string_cmp_str
, i'm not sure what the difference is or if i'm reading things wrongI found the above through reading the diff from the PR that introduced the FuriString stuff: https://github.com/flipperdevices/flipperzero-firmware/pull/1795/files
Hope this helps? ^^;
I had some time today, so I picked this up again and finished patching using mostly regular expressions. There was a second breaking change between 0.67.x and 0.69.x: the with_view_model
macro had changed to be more memory-efficient. The signature changed from with_view_model(MyView, (MyModel * model) {some_code; return true;});
to with_view_model(MyView, MyModel * model, {some_code}, true);
I've attached the compilation output (haven't tested yet if they actually work) and the patch that can be applied to this repo after recursively cloning it.
Hope this helped!
I've tried the faps you've attatched but for some reason they still don't work?, they all still show the same error.
I'm going to try compiling them myself but I'm not sure if that will make a difference.
@Blobadoodle I managed to get them loaded on my flipper zero and it turns out I'd been building against the dev
branch the whole time (I forgot how to switch branches..)
Here's a built and tested set of apps for 0.69.1:
The patch I provided in my last message works, I just built the apps against the wrong branch.
Just tested your build and all the apps work fine now.
Thanks!
@Blobadoodle No problem! :)
I've also attached an updated build of the flipfrid.fap (RFID Fuzzer) app, because I found it was crashing. Turns out there were some changes needed to be pulled in from the upstream for that app (https://github.com/DarkFlippers/unleashed-firmware). I'm not sure how @vmeurisse is doing the upstreaming work so I'll leave that.
And the full bundle for completeness' sake. 0.69.1 Apps.zip
And the full bundle for completeness' sake. 0.69.1 Apps.zip
This problem is happening again with this build and the latest firmware.
I am using release firmware 0.69.1 (3ab17e59) and none of the apps launch anymore. They all simply show the message: