Commit Graph

494 Commits

Author SHA1 Message Date
Giacomo Ferretti
126a9efd09
NFC: change from int8_t to uint8_t (#2302)
Co-authored-by: gornekich <n.gorbadey@gmail.com>
Co-authored-by: あく <alleteam@gmail.com>
2023-01-27 15:21:52 +07:00
Giacomo Ferretti
eee5c35400
NFC: add MIFARE MINI support (#2307)
* NFC: add MIFARE MINI support
* Move new value to end of enum
* nfc: added missing unit test

Co-authored-by: gornekich <n.gorbadey@gmail.com>
Co-authored-by: あく <alleteam@gmail.com>
2023-01-27 12:51:47 +07:00
Emily Trau
4dc4d34d04
emv: parse track1&2 equivalent data (#2332)
* emv: parse track1&2 equivalent data
* emv: alternate expiry parser
* nfc: log EMV track1&2 data to trace output

Co-authored-by: gornekich <n.gorbadey@gmail.com>
Co-authored-by: あく <alleteam@gmail.com>
2023-01-27 12:10:08 +07:00
Krzysztof Zdulski
8fc834090d
nfc: Fix sector reads when one block is unreadable for MIFARE Classic (#2296)
* Fix sector reads when one block is unreadable
* Auth on the correct block instead of first
* Fix in sector reader as well
* Apply patch by @gornekich

Co-authored-by: gornekich <n.gorbadey@gmail.com>
Co-authored-by: あく <alleteam@gmail.com>
2023-01-27 12:00:25 +07:00
Krzysztof Haładyn (krzys_h)
5134f44c09
nfc: Fix crash when using debug PCAP trace (#2338) 2023-01-26 15:28:36 +07:00
Sergey Gavrilov
709fa633ff
ELF-loader: wait for notification to complete on app exit (#2335) 2023-01-25 12:15:01 +07:00
hedger
341610b8a1
[FL-3080] fbt: PVS support (#2286)
* fbt: added firmware_pvscheck & firmware_pvs targets for *nix
* fbt: pvs support on Windows
* fbt: additional fixes & docs for PVS support
* fbt: fixes for updater env configuration
* github: reworked pvs workflow
* vscode: added PVS shortcut
* pvs: added --ignore-ccache flag
* fbt: pvs: opening web browser if there are warnings
* fbt: pvs: added browser handler for mac
* github: fixed report path for PVS
* fbt: pvs: fixed report upload path
* removed intentional PVS warning
* fixed more PVS warnings
* fixed secplus_v1 PVS warning
* fbt: added PVSNOBROWSER flag
* github: setting PVSNOBROWSER for pvs runs
* fbt: less debug output

Co-authored-by: あく <alleteam@gmail.com>
2023-01-17 15:55:49 +03:00
Eric Betts
9e1a6a6d2e
relocate R_ARM_CALL (#2305) 2023-01-16 12:36:59 +03:00
Georgii Surkov
75e9de12b0
[FL-3078] Per protocol signal repeat count (#2293)
* Better Infrared protocol file structure
* Rename InfraredProtocolSpec to InfraredProtocolVariant
* Slightly better names
* Add repeat count field to protocol variant description
* Repeat the signal the appropriate number of times when brute-forcing
* Repeat the signal the appropriate number of times when sending via worker
* Better signal count logic in infrared_transmit
* Better variable names
* Convert some raw signals to messages in tv.ir

Co-authored-by: あく <alleteam@gmail.com>
2023-01-13 16:50:19 +03:00
yan0f
9740dd8c75
Fix typos in source code (#2258) 2023-01-07 01:06:50 +09:00
あく
41c43f4805
Various improvements: Toolbox, Updater and Unit Tests. (#2250)
* Toolbox: add seek to character stream method. UpdateUtils: reverse manifest iterator. UnitTests: more unit tests.
* Target: bump API version. Updater: delete empty folders from manifest before resource deployment.
* UnitTests: use manifest from unit_tests folder instead of global one
* Make PVS happy
* sector cache: allocate always
* Better PVS config for manifest.c
* PVS: Move exception outside of condition
* PVS: remove confusing condition

Co-authored-by: SG <who.just.the.doctor@gmail.com>
2023-01-06 16:31:17 +10:00
Georgii Surkov
95f8895b43
Add float_tools to SDK api (#2225) 2022-12-30 15:52:53 +03:00
Thomas Roth
26e5527a93
Mifare dictionary attack performance improvements. (#2173)
* NFC dictionary attack performance improvements.
* Remove unnecessary assignment
2022-12-29 14:20:01 +09:00
Skorpionm
ea054423b0
[FL-3074] SubGhz: CAME 12 bit encoder fix guard time (#2210)
* SubGhz: CAME encoder fix guard ime
* SubGhz: fix 2 encoder CAME

Co-authored-by: あく <alleteam@gmail.com>
2022-12-29 05:29:23 +09:00
Konstantin Volkov
27ee0f73f7
Fixing various typos in readme files #2208
Co-authored-by: Konstantin Volkov <k.volkov@flipperdevices.com>
2022-12-28 23:30:20 +09:00
Astra
ded7e727d0
[FL-3060] New MFC Bruteforce animation (#2190)
* Change the wording in the headers
* Add support for text in the progress bar
* New MFC key bruteforce screen
* Typo fix
* nfc: rename Flipper Dict to System Dict
* elements: fix types
* Display the correct key attack sector

Co-authored-by: gornekich <n.gorbadey@gmail.com>
Co-authored-by: Aleksandr Kutuzov <alleteam@gmail.com>
2022-12-27 18:14:03 +09:00
Skorpionm
1390f10a6f
[FL-3068] SubGhz: add Holtek_ht12x protocol (#2187)
* SubGhz: add Holtek_ht12x protocol
* SubGhz: add unit_test holtek_ht12x
* SubGhz: correct string formatting

Co-authored-by: あく <alleteam@gmail.com>
2022-12-27 17:29:21 +09:00
Georgii Surkov
8582670a34
[FL-2811] Fix PVS-Studio warnings (#2142)
Co-authored-by: あく <alleteam@gmail.com>
Co-authored-by: gornekich <n.gorbadey@gmail.com>
2022-12-26 21:13:30 +09:00
Skorpionm
797eab8924
SubGhz: fix Hormann HSM (#2158)
* SubGhz: fix Hormann HSM
* SubGhz: add check pattern hormann protocol

Co-authored-by: あく <alleteam@gmail.com>
2022-12-20 21:42:16 +09:00
gornekich
4cee550cc6
[FL-2809] Rework BLE key storage (#2154)
* bt: disconnect first on profile change
* bt keys: rework bt keys
* saved struct: add payload size getter to API
* bt: rework bt with new key storage API
* bt: add keys storage operation to bt API
* hid: save bt keys on sd card
* bt: add unit tests for key storage
* bt: working profile switch
* bt: cleanup
* bt hid: change keys storage path

Co-authored-by: あく <alleteam@gmail.com>
2022-12-20 21:32:24 +09:00
Astra
fa87216a1e
[FL-2970] Untangle NFC_APP_FOLDER from nfc_device (#2124)
* Untangle NFC_APP_FOLDER from nfc_device
* Make the folder an internal part of the nfc device struct
* Move the NFC folder definition to the nfc allocator
* Move the NFC folder definition to the allocator in the nfc magic FAP
* Replace furi_string_printf with furi_string_set for folder allocation and handle the cases when folder has no slashes
* Build and allocation fixes

Co-authored-by: あく <alleteam@gmail.com>
2022-12-20 04:57:48 +09:00
Skorpionm
b5e7bb3334
[FL-3043] SubGhz: add SMC5326, UNILARM protocol (#2138)
* SubGhz: add SMC5326 protocol
* SubGhz: add unit_test smc5326 protocol

Co-authored-by: あく <alleteam@gmail.com>
2022-12-16 05:25:43 +09:00
Adam Boeglin
1dc79fddf0
Added support for IDTECK cards (#2134) 2022-12-16 05:02:43 +09:00
Astra
7fb1af07b8
[FL- 3014] Untangle NFC from Unit Tests (#2106)
* Untangle NFC from Unit Tests
* nfc tests: add log error

Co-authored-by: Sergey Gavrilov <who.just.the.doctor@gmail.com>
Co-authored-by: gornekich <n.gorbadey@gmail.com>
Co-authored-by: あく <alleteam@gmail.com>
2022-12-10 22:02:34 +09:00
Shane Synan
5c3a5cd8f7
FuriHal, Power, UnitTests: battery charging voltage limit API (#2063) 2022-12-08 15:57:49 +09:00
Nikolay Minaylov
2daf39018b
[FL-3001] File browser base folder (#2091)
* File browser base folder
* Format sources
* FuriHal: bump api version

Co-authored-by: Aleksandr Kutuzov <alleteam@gmail.com>
2022-12-07 23:17:41 +09:00
gornekich
9a21dae29c
[FL-3008], [FL-2734], [FL-2766], [FL-2898] NFC bug fixes (#2098)
* nfc: rework mf classic update
* nfc: rename cache folder to .cache
* nfc: fix ATQA order bytes in nfc files
* file browser: add hide dot files option
* nfc: fix iso-14443-4 uid cards emulation
* nfc: fix unit tests

Co-authored-by: あく <alleteam@gmail.com>
2022-12-07 19:52:44 +09:00
Nikolay Minaylov
4070eeb1c9
USB HID: fix key name #2065
Co-authored-by: あく <alleteam@gmail.com>
2022-12-02 03:56:27 +09:00
Sergey Gavrilov
eb3a8734fb
Fix crash in iButton notifications routine (#2074)
* iButton: send notifications less strictly
* iButton: set notification callback earlier
2022-12-02 03:28:46 +09:00
Skorpionm
2a6a3a1bf7
[FL-2955], [FL-2953] SubGhz: fix RAW "Send never ends" (#1979)
* SubGhz: fix RAW "Send never ends"
* SubGhz: delete comments
* SubGhz: RAW file parsing speed increase
* SubGhz: fix level_duration_is_wait
* SubGhz: modification furi_hal_subghz_async_tx_refill
* SubGhz: furi_hal_subghz_stop_async_rx
* SubGhz: hal unit test and better async tx yield handling
* FuriHal: proper async tx end in subghz, vibro on power off
* FuriHal: variable naming in subghz
* SubGhz,FuriHal: extreme timings in subghz hal unit tests, remove memset in async tx buffer fill routine
* FuriHal: small refinements in subghz

Co-authored-by: あく <alleteam@gmail.com>
2022-11-30 20:41:23 +09:00
Sergey Gavrilov
297f185ef4
Blocking USB driver API (#2009)
* invalidate memmgt thread dict
* Core: rollback memmgt thread dict invalidation
* Dialogs: move api lock to toolbox
* HAL: blocking usb API
* HAL usb: fix api return data
* HAL usb: api optimization
* api lock: test results
* Fix build errors
* DAP Link: fix imports
* Crash when malloc in ISR
* Fix dap-link copypaste error
* Moar memory management crashes.
* Crash when malloc in IRQ, not ISR
* USB-UART: Blocking VCP mode switch

Co-authored-by: nminaylov <nm29719@gmail.com>
Co-authored-by: Aleksandr Kutuzov <alleteam@gmail.com>
2022-11-29 21:50:55 +09:00
Georgii Surkov
0261dc3075
[FL-2957] Unified Info API, App Error, Data Xchange (#1998)
* Update protobuf definitions
* Add Property subsystem entry point function
* Key-based system info and power info function stubs
* Remove unneeded functions
* Working power info
* Working system info
* Replace #defines with string literals
* Remove unneeded field
* Simplify system info formatting
* Refactor output callback handling
* Handle the last info element correctly
* Optimise power info, rename methods
* Add comments
* Add power debug
* Remove unneeded definitions
* Rename some files and functions
* Update protobuf definitions
* Implement App GetError and DataExchange APIs
* Send GetErrorReply with correct command_id
* Add RPC debug app stub
* Add more scenes
* Add warning, increase stack size
* Add receive data exchange scene
* Improve data exchange
* Add notifications
* Update application requirements
* Bump format version for property-based infos
* Correctly reset error text
* RCP: sync protobuf repo to latest release tag

Co-authored-by: Aleksandr Kutuzov <alleteam@gmail.com>
2022-11-29 18:08:08 +09:00
Georgii Surkov
c535ce9b76
[FL-2997] Improve file name filtering #2047
Co-authored-by: あく <alleteam@gmail.com>
2022-11-29 04:28:51 +09:00
Skorpionm
84f9af3e7e
SubGhz: fix duration pricenton protocol (#2054)
Co-authored-by: あく <alleteam@gmail.com>
2022-11-29 04:17:57 +09:00
Yukai Li
6b47bc1af4
Nfc: NTAG password auto capture (and other password-related changes) (#1843)
* nfc: MFUL minor cleanup
* nfc: Add mechanism to pass event data
* nfc: Add NTAG authentication event to emulation
* nfc: Rename enum member to align with existing convention
* nfc: Add function to determine whether MFUL is fully captured
* nfc: Fix emulation of incompletely-read password-protected MFUL
* nfc: Add reader password capture scene
* nfc: Set default MFUL password input to 0xFFFFFFFF
* nfc: Fix MFUL auth counter loading
* nfc: Be explicit about using manual auth method when using auto unlock
* nfc: Fill in MFUL has_auth when loading file
* nfc: Fix MFUL auth success usage, remove unused variable
* nfc: Display PWD and PACK in MFUL info if available
* nfc: Remove unnecessary include
* nfc: Add unlock options to loaded MFUL menu
* nfc: Move set default MFUL password. This way it can be edited if needed instead of reentered
* nfc: Fix unlock menu not maintaining selection index
* nfc: Move captured MFUL auth data from worker to device data
* nfc: Attempt to authenticate with default PWD when possible when reading NTAG
* nfc: Don't try to auth NTAG on read if we already authed
* nfc: Add title for all pages read but failed auth for NTAG auth
* nfc: Add faster auth callback patch
* lib: Remove scons submodule from index
* nfc: Revise MFUL unlock UI flow
* nfc: Disallow MFUL unlock with reader if card not read yet. Trying to read first results in either needing to make a new scene or badly jury rigging other scenes, so let's just not do that
* f7: Bump API symbols
* Format code

Co-authored-by: gornekich <n.gorbadey@gmail.com>
Co-authored-by: あく <alleteam@gmail.com>
2022-11-29 03:16:22 +09:00
Michael Huebler
1b3156521c
NFC: Accept non-parsed apps in Mifare DESFire. (#2041)
* NFC: Accept non-parsed apps in Mifare DESFire. Fixes #2040

Co-authored-by: gornekich <n.gorbadey@gmail.com>
Co-authored-by: あく <alleteam@gmail.com>
2022-11-29 02:14:13 +09:00
Sergey Gavrilov
c511c67e71
Core: thread allocation shortcut (#2007)
* Core: thread alloc+set shortcut
* Apps: use thread allocation shortcut
* Mark some service threads as services
* Init BT as soon as possible

Co-authored-by: あく <alleteam@gmail.com>
2022-11-23 21:49:17 +09:00
Skorpionm
00fcd9cfcd
[FL-2976] SubGhz: add protocol "Ansonic" (#2000)
* SubGhz: add protocol "Ansonic"
* SubGhz: fix encoder "Ansonic"
* SubGhz: add unit_test "Ansonic"
* SubGhz: fix flag
* SubGhz: protocol "Ansonic" fix timing

Co-authored-by: あく <alleteam@gmail.com>
2022-11-23 18:29:30 +09:00
Skorpionm
cf5b87f82e
SubGhz: add protocol Nice_Flo 20bit (#1983)
Co-authored-by: あく <alleteam@gmail.com>
2022-11-23 17:28:44 +09:00
Nikolay Minaylov
73441af9c6
BadUSB and Archive fixes (#2005)
* BsdUsb: fix empty lines handling
* Archive: folders and unknown files rename fix

Co-authored-by: あく <alleteam@gmail.com>
2022-11-12 20:55:42 +09:00
hedger
f9730bcafe
fbt: lint fixes (#2008)
* lint: exclude "lib" subfolder from naming checks; fbt: moved LINT_SOURCES from literal strings to Dir() nodes
* lint: also exclude hidden directories

Co-authored-by: あく <alleteam@gmail.com>
2022-11-12 19:03:22 +09:00
Astra
e7c4b40dbe
Force card types in extra actions (#1961)
* Mifare Classic forced read
* Add all the needed card types
* nfc: remove unused scene
* nfc: remove unused worker state
* nfc: fix read card type scene state usage
* nfc: move NfcReadMode to NfcDevData struct
* nfc: fix bank card reading and scene navigation
* nfc magic: fix magic deactifate function

Co-authored-by: gornekich <n.gorbadey@gmail.com>
Co-authored-by: あく <alleteam@gmail.com>
2022-11-11 01:29:57 +09:00
Astra
820afd2aec
NFC Unit tests part 1.1 (#1927)
* Mifare Classic 1/4K, 4/7b uid, NFC-A: NFC-A is not complete yet, as there are no 4b uid tests. Also, Mifare Classic tests don't cover the key cache yet.
* NFC unit tests require access to the NFC app
* Made nfc_device_save accept full path as an argument
* Move from cstrs to furi strings and fix logic
* nfc tests: fix memory leak
* nfc: add mf_classic_get_total_blocks() to API
* nfc tests: simplify nfc tests
* nfc: fix memory leak in shadow file saving
* nfc: fix set uid scene
* nfc: fix saving files
* nfc: fix preload nfc file path
* nfc: remove comments

Co-authored-by: Sergey Gavrilov <who.just.the.doctor@gmail.com>
Co-authored-by: gornekich <n.gorbadey@gmail.com>
Co-authored-by: あく <alleteam@gmail.com>
2022-11-11 01:20:35 +09:00
gornekich
3985b456c3
NFC: fix crash on MFC read (#1993)
* nfc: fix nfc_worker_stop logic
* nfc: fix stop order

Co-authored-by: あく <alleteam@gmail.com>
2022-11-10 03:12:55 +09:00
Samuel Stauffer
aa2ecbe80f
infrared: add Kaseikyo IR protocol (#1965)
* infrared: add Kaseikyo IR protocol

Add Kaseikyo IR protocol support. This protocol is also called the Panasonic protocol and is used by a number of manufacturers including Denon.

The protocol includes a vendor field and a number of fields that are vendor specific. To support the format of address+command used by flipper the vendor+genre1+genre2+id fields are encoded into the address while the data is used for the command.

There are older versions of the protocol that used a reverse bit order that are not supported.

Protocol information:
- https://github.com/Arduino-IRremote/Arduino-IRremote/blob/master/src/ir_Kaseikyo.hpp
- http://www.hifi-remote.com/johnsfine/DecodeIR.html#Kaseikyo
- https://www.denon.com/-/media/files/documentmaster/denonna/avr-x3700h_avc-x3700h_ir_code_v01_04062020.doc

* Format and add unit test to Kaseikyo IR codec.

Co-authored-by: Georgii Surkov <37121527+gsurkov@users.noreply.github.com>
2022-11-07 18:38:04 +04:00
あく
e8913f2e33
Code cleanup: srand, PVS warnings (#1974)
* Remove srand invocation

* PVS High priority fixes

* PVS High errors part 2

* Furi: heap tracing inheritance

* Furi add __builtin_unreachable to furi_thread_catch
2022-11-05 18:07:24 +03:00
gornekich
bf8fd71c00
NFC magic cards support (#1966)
* nfc magic: introduce nfc app to work with magic cards
* nfc: add nfc device functions to API
* nfc magic: add bacis scenes
* nfc magic: add wrong card and write confirm scenes
* nfc magic: introduce magic lib
* nfc magic: write magic lib
* nfc magic: add write commands to magic lib
* nfc magic: work on worker
* furi_hal_nfc: add bits data exchage method to API
* nfc magic: rework with new API
* nfc magic: add check and wipe scenes
* nfc magic: add icons, gui fixes
* nfc: format python src

Co-authored-by: あく <alleteam@gmail.com>
2022-11-04 16:01:44 +09:00
hedger
ebc2b66372
fbt fixes for mfbt pt2 (#1951)
* fbt: split sdk management code
* scripts: fixed import handling
* fbt: sdk: reformatted paths
* scrips: dist: bundling libs as a build artifact
* fbt: sdk: better path management
* typo fix
* fbt: sdk: minor path handling fixes
* toolchain: fixed windows toolchain download
* fbt: minor refactorin
* fbt: moved sdk management code to extapps.scons
* fbt: fixed sdk symbols header path; disabled -fstack-usage
* fbt: changed pathing for .py scripts
* fbt: changed SDK_HEADERS pathing; added libusb to SDK; added icon_i.h to SDK; added hw target to SDK meta
* fbt: added libusb headers to SDK
* picopass: include cleanup; api: added subghz/registry.h; api: added mbedtls to exported headers
* picopass: fixed formatting
* fbt: fixed COPRO_ASSETS_SCRIPT
* sdk: added basic infrared apis
* toolchain: added ufbt to list of legal fbtenv callers; updated error messages
* fbt: changed manifest collection & icon processing code
* fbt: simpler srcdir lookup
* toolchain: path management fixes; fbt: fixes for fap private libs paths
* scripts: toolchain: reworked download on Windows
* toolchain: v17
* scripts: added colorlog for logging
* Github: fix unit tests

Co-authored-by: あく <alleteam@gmail.com>
2022-11-03 00:15:40 +09:00
gornekich
93a6e17ce5
[FL-2933] Mf Classic initial write, update, detect reader (#1941)
* nfc: introduce nfc write
* nfc: add write logic
* nfc worker: add write state
* nfc: add mfc update logic
* nfc: add update success logic
* nfc: add custom card for detect reader
* nfc: update write logic
* nfc: add halt command, add notifications
* nfc: add write fail scene
* nfc: fixes and clean up
* nfc: fix navigation ad notifications
* nfc: fix detect reader nfc data setter

Co-authored-by: あく <alleteam@gmail.com>
2022-10-29 01:10:16 +09:00
Skorpionm
9cd0592aaf
SubGhz: add keeloq potocol JCM_Tech (#1939)
* SubGhz: add keeloq potocol  JCM_Tech
* SubGhz: add new metod decoder

Co-authored-by: あく <alleteam@gmail.com>
2022-10-28 23:31:41 +09:00
hedger
8b7a52b97b
fbt: fixed linter paths (#1930)
* fbt: fixed linter paths
* lint: changed file permissions

Co-authored-by: あく <alleteam@gmail.com>
2022-10-27 05:25:31 +09:00
Skorpionm
aff99a72e8
SubGhz: fix variable types and CC1101 GPIO initialization optimization (#1931)
* SubGhz: fix variable types
* SubGhz: CC1101 GPIO initialization optimization
* SubGhz: return back gpio init
* SubGhz: cleanup grammar in math and format doxygen comments

Co-authored-by: あく <alleteam@gmail.com>
2022-10-27 04:40:13 +09:00
Skorpionm
5c8df66b7c
[FL-2927] SubGhz: add RAW Read threshold rssi (#1911)
* SubGhz: add RAW Read threshold rssi
* SubGhz: update indicator RSSI
* SubGhz: fix record file

Co-authored-by: Aleksandr Kutuzov <alleteam@gmail.com>
2022-10-27 00:13:00 +09:00
Skorpionm
378bf05068
[FL-2934] WS: add protocol Acurite 592TXR (#1916)
* WS: add protocol Acurite 592TXR
* WS: fix decoder Acurite_592TXR
* SubGhz: proper types in math

Co-authored-by: Aleksandr Kutuzov <alleteam@gmail.com>
2022-10-26 23:56:54 +09:00
hedger
0adad32418
fbt fixes pt4 (#1899)
* fbt: fixed py scripts for gdb
* fbt: removed compiled dolphin assets from tracked files; resolved cached dependency issues by globally disabling deps cache; changed dependency tracking for dolphin assets
* fbt: fix for "resources" node lookup
* toolchain: bump to v.16 with scons + x64 win binaries
* fbt: using scons from toolchain
* vscode: fixed paths for 64-bit Windows toolchain
* fbt: added colors!
* fbt: moved import validator to ansi lib coloring
* fbt: moved COMSTR vars to tools
* fbt: custom action for fap dist
* fbt: added OPENOCD_ADAPTER_SERIAL configuration var for openocd operations
* fbt: added get_stlink target
* docs: details on libs for faps
* vscode: added DAP config for using Flipper as a debugger for a 2nd Flipper
* fbt: blind deps fix for sdk_origin
* fbt: sdk: moved deployment actions to pure python
* Github: disable disableLicenseExpirationCheck option for pvs

Co-authored-by: Aleksandr Kutuzov <alleteam@gmail.com>
2022-10-26 07:15:02 +09:00
Max Lapan
d8fbaba7a0
Move Oregon2 to Weather Station FAP (#1910)
* Init copy of oregon2 to weather station app
* WS decoder
* Reuse decoded data
* Delete old protocol
* Delete oregon2 unit test
* Decrement count of random test

Co-authored-by: Aleksandr Kutuzov <alleteam@gmail.com>
2022-10-23 00:50:26 +09:00
Skorpionm
c1bb10a694
[FL-2920] WS: add protocol Acurite-606TX, LaCrosse_TX141THBv2 (#1898)
* WS: add protocol Acurite-606TX
* WS: history, added display of the channel (if any) in the general list
* WS: added display of the button state if it is on the transmitter, and displaying the data that is in the signal
* WS: fix batt info
* WS: add protocol LaCrosse_TX141THBv2
* WS; fix syntax
* Furi: bump api_symbols version

Co-authored-by: あく <alleteam@gmail.com>
2022-10-21 02:26:28 +09:00
Sergey Gavrilov
42df7aa04a
Fix FuriString oplist (init move) (#1894)
* FuriString, Infrared: fix oplist and drop string_t.
* Elf loader: log size
* Comment fix
* API: furi_hal_console_init
2022-10-20 19:58:11 +09:00
Skorpionm
9a9abd59e9
[FL-2904, FL-2900, FL-2890] WS: add app WeatherStation (#1833)
* WeatherStation: start
* SubGhz: rename protocol magellen -> magellan
* WeatherStation: err Unresolved symbols: {'subghz_protocol_decoder_base_get_string'}
* WeatherStation: fix Unresolved symbols: {'subghz_protocol_decoder_base_get_string'}
* Subghz: add set protocol_items
* WeatherStation: adding your protocols
* WS: add Infactory protocol
* WS: add history
* WS: add setting
* WS: add lock
* WS: add hopper frequency
* WS: fix history
* WS fix string_t -> FuriString*
* WS: add images
* WS: history record update when receiving data from the sensor again
* WS: add receiver info, delete extra code
* WS: add protocol ThermoPRO_TX4
* [FL-2900] SubGhz: Move icons in Sub-GHz
* WS: add Notification
* [FL-2890] SubGhz: Rename *_user files in resources to _user.example
* WS: add about scene
* WS: removing redundant code
* WS: add  protocol Nexus-TH
* WS: add protocol GT_WT03
* WS: fix notification and rename "Weather Station" -> "Read Weather Station"
* SubGhz: partial unit tests fix
* SubGhz: fix unit_test
* SubGhz: remove dead code
* SubGhz: rename SubGhzPresetDefinition into SubGhzRadioPreset, cleanup subghz types.

Co-authored-by: Aleksandr Kutuzov <alleteam@gmail.com>
2022-10-20 02:27:26 +09:00
Skorpionm
68009c6230
[FL-2919] SubGhz: CAME Wrong number of bits in key (add protocol Airforce) (#1890)
Co-authored-by: あく <alleteam@gmail.com>
2022-10-18 23:24:53 +09:00
Georgii Surkov
02c27becb0
[FL-2912] Forced RAW receive option for Infrared CLI #1891
Co-authored-by: あく <alleteam@gmail.com>
2022-10-18 23:10:21 +09:00
gornekich
dfbe21e720
NFC fixes part 3 (#1885)
* nfc: fix read next key
* nfc: verify new line ending in user dictionary file
* nfc: fix cache save
* nfc: add unit test for dict load
* nfc: fix total key count in dictionary

Co-authored-by: あく <alleteam@gmail.com>
2022-10-18 02:10:41 +09:00
Astra
55f8beef9f
[FL-2876] MFC Improvements Part 2/2 (#1868)
* Remove keys incorrectly added by the key cache
* Improve responsiveness while checking for re-used keys and fix skipping keys when card is removed
* Actually check if the card is completely read
* Discard incorrect keys on a lower level
* nfc: clean up

Co-authored-by: gornekich <n.gorbadey@gmail.com>
2022-10-14 01:23:29 +09:00
Luke Williams
50dc2d7389
36-bit AWID (L11601 Lenel) (#1838)
* 36-bit AWID
* Rfid: correct vendor name AWIG -> AWID

Co-authored-by: Sergey Gavrilov <who.just.the.doctor@gmail.com>
Co-authored-by: あく <alleteam@gmail.com>
2022-10-13 01:31:54 +09:00
gornekich
2552278a3d
[FL-2883] NFC: bank card rework reading (#1858)
* nfc: remove bank card save option
* nfc: remove bank card save from nfc device
* nfc: remove unused function in emv
* nfc: try several times to start emv application
* nfc: add AID display fallback for bank cards

Co-authored-by: あく <alleteam@gmail.com>
2022-10-12 02:13:12 +09:00
Sergey Gavrilov
981f7ff8b0
Elf loader: do not load .ARM.* sections (#1850)
* Elf loader: do not load .ARM sections
* Fix section name
2022-10-09 00:51:51 +09:00
Sergey Gavrilov
37b5e58a60
More correct elf loader (#1839)
* ELF File: more robust section loader
* ELF File: faster and smaller preinit, init and fini arrays handling
* ELF File: load sections on preload stage
* ELF File: naming
* Furi: fix use after free in thread join

Co-authored-by: あく <alleteam@gmail.com>
2022-10-08 02:06:29 +09:00
Sergey Gavrilov
4000f0cac5
[FL-2870] Printf function attributes (#1841)
* Furi strings: printf attribute
* Logs: printf attribute
* Plugins: adapt
* Plugins: accommodate
* Unit tests: accommodate

Co-authored-by: あく <alleteam@gmail.com>
2022-10-07 22:35:15 +09:00
Sergey Gavrilov
38a82a1907
[FL-2839] Furi stream buffer (#1834)
* Core: stream buffer
* stream buffer: API and usage
* stream buffer: documentation
* stream buffer: more documentation
* Furi: fix spelling

Co-authored-by: Aleksandr Kutuzov <alleteam@gmail.com>
2022-10-07 21:27:11 +09:00
Astra
eaa3adf98a
[FL-2868] Remove string_push_uint64 (#1832)
* Remove string_pust_uint64
* Oops, furi strings now
* Remove dead code
* Remove unneeded import

Co-authored-by: あく <alleteam@gmail.com>
2022-10-07 03:51:30 +09:00
Astra
6dde5586af
[FL-2803] Mifare Classic read improvements Part 1 (#1822)
* Reuse found keys when reading a card
* Fix keys not being read if no newline at the end of the file
* Actually read all keys from the dictionary
* Support for furi_string
* Check only for re-used key after the current sector
* Declare the key attack function as static
* nfc: change logs, check worker state

Co-authored-by: gornekich <n.gorbadey@gmail.com>
Co-authored-by: あく <alleteam@gmail.com>
2022-10-07 02:07:56 +09:00
gornekich
5de2c32c81
[FL-2864] NFC update detect reader (#1820)
* nfc: update detect reader view
* nfc: make detect reader more interractive
* nfc: update icons
* nfc: fix detect reader gui
* nfc: fix gui, fix worker events
* nfc: fix notifications
* nfc: add nfc_worker NULL assert

Co-authored-by: あく <alleteam@gmail.com>
2022-10-07 01:58:17 +09:00
Georgii Surkov
61189c3c82
[FL-2847] FFF trailing space fix (#1811)
* Improve whitespace handlilng in FFF
* Add tests for odd fff user input
* Adjust formatting

Co-authored-by: あく <alleteam@gmail.com>
2022-10-06 23:18:20 +09:00
Nikolay Minaylov
a69e150e2f
[FL-2812] RFID: write fix for some protocols #1828
Co-authored-by: あく <alleteam@gmail.com>
2022-10-06 20:36:21 +09:00
Sergey Gavrilov
4bf29827f8
M*LIB: non-inlined strings, FuriString primitive (#1795)
* Quicksave 1
* Header stage complete
* Source stage complete
* Lint & merge fixes
* Includes
* Documentation step 1
* FBT: output free size considering BT STACK
* Documentation step 2
* py lint
* Fix music player plugin
* unit test stage 1: string allocator, mem, getters, setters, appends, compare, search.
* unit test: string equality
* unit test: string replace
* unit test: string start_with, end_with
* unit test: string trim
* unit test: utf-8
* Rename
* Revert fw_size changes
* Simplify CLI backspace handling
* Simplify CLI character insert
* Merge fixes
* Furi: correct filenaming and spelling
* Bt: remove furi string include

Co-authored-by: Aleksandr Kutuzov <alleteam@gmail.com>
2022-10-06 00:15:23 +09:00
hedger
f8b532f063
[FL-2831] Resources cleanup in updater (#1796)
* updater: remove files from existing resources Manifest file before deploying new resources
* toolbox: tar: single file extraction API

Co-authored-by: あく <alleteam@gmail.com>
2022-09-29 02:13:12 +09:00
Tom Samstag
e6e1e7fe15 Add formatting to DESfire data dump (#1784)
Co-authored-by: gornekich <n.gorbadey@gmail.com>
2022-09-28 02:02:18 +09:00
Shane Synan
9f501034c3
Power: Also ask charger if charge done (#1378)
* power: Also ask charger if charge done
* F7: bump API Symbols version
* Lib: remove double include in bq25896.c

Co-authored-by: あく <alleteam@gmail.com>
2022-09-27 00:34:59 +09:00
hedger
efb09380bd
[FL-2836] Fast flash programming mode (#1782)
* updater: lowered logging level for resources unpacking; hal: implemented fast flash write mode
* hal: reworked fast flash programming; clearing most error flags on flash init; changed some flash functions return type from bool to void; scripts: fixed malformed CRC values in update bundles in certain cases;
* hal: flash: larger critical section
* hal: flash: enabling fast write inside critical section
* api_symbols: bump minor version
2022-09-26 20:03:21 +09:00
David Coles
a6b98ccbbe
Preliminary Rust support (#1781)
* Add support for R_ARM_THM_MOVW_ABS_NC/THM_MOVT_ABS

These are sometimes emitted by the Rust LLVM compiler.

Ref: https://github.com/ARM-software/abi-aa/blob/main/aaelf32/aaelf32.rst#56relocation

* Discard LLVM bitcode from extension applications

LLVM-based compilers may include uncompressed bitcode in object files
to help with link-time optimization. However this can bloat binary sizes
from KB to MB.

* Expose alligned_malloc/free functions to applications

This is required to implement a global allocator in Rust.
2022-09-26 07:06:46 +10:00
Skorpionm
bc777b2eff
SubGhz: fix config menu (#1748)
* SubGhz: fix config menu
* SubGhz: fix gui Magellen protocol
* SubGhz: fix gui Transmit SubGhz
* SubGhz: keeloq, new gen manufacture code
* SubGhz: Update keeloq_mfcodes

Co-authored-by: あく <alleteam@gmail.com>
2022-09-25 23:34:52 +09:00
Sergey Gavrilov
e6d22ed147
ELF-Loader: C++ plugin support, loader overhaul. (#1744)
* fap-loader: load all code and data sections
* fap-loader: relocate all code and data sections
* fap-loader: remove old elf loader
* fap-loader: new jmp call relocation
* openocd: resume on detach
* fap-loader: trampoline for big jumps
* fap-loader: rename cache
* fap-loader: init_array support
* fap-loader: untangled flipper_application into separate entities
* fap-loader: fix debug
* fap-loader: optimize section container
* fap-loader: optimize key for section container
* fap-loader: disable debug log
* documentation
* F7: bump api symbols version
* Lib: cleanup elf_file.c

Co-authored-by: あく <alleteam@gmail.com>
2022-09-25 23:11:29 +09:00
Sergey Gavrilov
92e440c77d
Core: simplify record container (#1776)
Co-authored-by: あく <alleteam@gmail.com>
2022-09-25 20:48:57 +09:00
Andrea Sacchi
3846852f2b
NFC Fix Mifare Classic (#1769)
* Fix Mifare Classic key str to int conversion: Wrong cast lead to unexpected behavior converting key from str to int.
* Nfc: fix type cast in mf_classic_dict and add basic unit tests

Co-authored-by: Aleksandr Kutuzov <alleteam@gmail.com>
2022-09-23 02:35:28 +09:00
Max Lapan
3360f818a1
Subghz: Adding checks for get_upload functions (#1704)
* Adding checks for get_upload functions
  Almost in every protocol, function which generates upload might fail and return false.
  But we don't check this result, which might end up sending random memory contents to the air.
* Format sources and fix crash on ivalid bit count in chamberlain

Co-authored-by: あく <alleteam@gmail.com>
2022-09-20 14:29:10 +09:00
David
f5ff6438d1
NFC user dict list, delete, and de-duplication. (#1533)
* Add MFC user keys list
* Leakey submenu fix
* Set next target for Save/Delete success scenes
* Delete individual user keys
* Update count of total keys
* Fix memory leak
* Check for duplicate keys
* Remove a submodule that I never added?
* Swap and position icons
* Revamp according to design doc
* Rename icons to include size and replace keychain icon with smaller variant
* Fix typos
* Final fixes
* Fufill requested changes
* Cleanup comments
* Merge dev after SD app loading
* Fixing icon names
* Revert merge mistakes and API version
* Scene switching adjustments
* F7: add/change/remove some nfc icons in api_symbols.csv

Co-authored-by: あく <alleteam@gmail.com>
2022-09-20 01:43:53 +09:00
Astra
9f3b80e606
Add new card parsers (#1503)
* Add the "Two cities" parser
* Add plantain and plantain4k parsers
* Add new parsers to the supported list
* United card PoC
* Fix nfc device not sleeping
* Completely read the 4K troika variants
* Correct naming
* Update to reflect upstream changes
* Add support for MfUl info
* Fix parsers
* Card type detection fixes
* Remove debug info
* Fixes for the verification of cards
* nfc: fix verification for supported cards
* nfc: remove unused vars
* Improve card reading reliability and fix plantain
* plantain: change log level

Co-authored-by: gornekich <n.gorbadey@gmail.com>
2022-09-20 01:05:04 +09:00
Max Lapan
d003db0404
SubGhz: Oregon v2.1 decoder (#1678)
* Oregon v2.1 decoder
* Refactor FSM to switch
* Refactor headers
* Format strings
* Unit tests of oregon2
* Cleanups
* Add oregon2 raw data to random_test_raw.sub
* Adjust count of packets detected on random test
* Format sources

Co-authored-by: あく <alleteam@gmail.com>
2022-09-19 23:24:24 +09:00
Nikolay Minaylov
fb476c29e6
RFID: fix read info screen (#1723)
* RFID: fix read info screen
* Fix line break for long data string
* Protocol data redecoding before write

Co-authored-by: SG <who.just.the.doctor@gmail.com>
Co-authored-by: あく <alleteam@gmail.com>
2022-09-19 22:21:40 +09:00
hedger
ed385594a3
faploader: more subsystem headers in API table (#1742)
* faploader: more subsystem headers in API table; not counting header entries for SDK version change
* subghz: removed dead function
* Adjusted API version
* hal: removed furi_hal_power_get_system_voltage
* lib: mbedtls: additional flags for .fap linkage
* fbt: rebuilding assets when git commit id changes
* fbt: removed assets rebuild on git commit id change; added explicit dependency for SDK source on compiled assets parts; removed unneeded sdk regeneration runs
* fbt: changed stock plugins to EXTERNAL apps; restored building app as a PLUGIN as a part of main fw as well as a .fap; readme fixes
* fbt: restored certain apps to PLUGIN type
* fbt: app manifests: renamed version->fap_version, added extra fields
* fbt: fixed version processing after rename

Co-authored-by: あく <alleteam@gmail.com>
2022-09-19 21:39:00 +09:00
hedger
007a3d295e
[FL-2819] updater: fixed failing backups on /int with empty files in it #1735
Co-authored-by: あく <alleteam@gmail.com>
2022-09-15 22:55:55 +09:00
SG
b9a766d909 [FL-2627] Flipper applications: SDK, build and debug system (#1387)
* Added support for running applications from SD card (FAPs - Flipper Application Packages)
* Added plugin_dist target for fbt to build FAPs
* All apps of type FlipperAppType.EXTERNAL and FlipperAppType.PLUGIN are built as FAPs by default
* Updated VSCode configuration for new fbt features - re-deploy stock configuration to use them
* Added debugging support for FAPs with fbt debug & VSCode
* Added public firmware API with automated versioning

Co-authored-by: hedger <hedger@users.noreply.github.com>
Co-authored-by: SG <who.just.the.doctor@gmail.com>
Co-authored-by: あく <alleteam@gmail.com>
2022-09-15 02:21:03 +09:00
Skorpionm
e9ab581771
SubGhz: fix decoder kelooq (#1719)
* SubGhz: fix decoder kelooq

Co-authored-by: hedger <hedger@users.noreply.github.com>
2022-09-08 10:27:03 +03:00
あく
b62096fb91
[FL-2645, FL-2810] SubGhz: handle missing key in cryptostore. Lib: lower default display contrast. (#1717)
* SubGhz: skip file loading on key load fail

* Lib: update default display contrast

* Format sources

Co-authored-by: hedger <hedger@users.noreply.github.com>
2022-09-08 10:18:18 +03:00
あく
3a767c9c02
[FL-2794] Lib: update LFS to v2.5.0, lower update free page limit (#1706)
* Lib: update lfs to v2.5.0

* Storage: set minimum free pages for update on internal storage to 3

* Updater: lower min int free space limit

* lfs: disabled debug and trace logs by default

Co-authored-by: hedger <hedger@nanode.su>
2022-09-05 20:40:20 +03:00
VVX7
8d8481b17f
fix buffer overflow in mifar ul load (#1697)
Co-authored-by: gornekich <n.gorbadey@gmail.com>
2022-09-05 20:42:59 +09:00
gornekich
1853359d78
[FL-2759], [FL-2766] NFC collect params for mfkey32 attack (#1643)
* nfc: start nfc over rpc
* nfc: add detect reader state
* nfc: add reader analyzer
* nfc: rework reader analyzer
* reader_analyzer: print collected nonces to debug
* reader analyzer: add save on SD card
* reader_analyzer: separate mfkey related part to different file
* mfkey32: add logic for collecting parameters
* nfc: rework pcap with reader analyzer
* nfc: add logger for reader
* nfc: clean up
* nfc: add detect reader view
* nfc: add detect reader and mfkey nonces scenes
* nfc: add mfkey comlplete scene
* nfc: add new assets
* nfc: fix gui
* nfc: fix iso14443-4 UID emulation
* nfc: add no sd card notification
* nfc: fix grammar

Co-authored-by: あく <alleteam@gmail.com>
2022-09-03 21:25:36 +09:00
Skorpionm
a3932cfa6d
[FL-2787] SubGhz: add protocol Clemsa, fix decoder BETT (#1696)
* SubGhz: add protocol Clemsa
* SubGhz: fix decoder BETT protocol

Co-authored-by: あく <alleteam@gmail.com>
2022-09-03 15:19:01 +09:00
Sebastian Mauer
1d787e6da8
Add support for Keri tags (#1689)
Co-authored-by: SG <who.just.the.doctor@gmail.com>
2022-09-02 21:36:13 +10:00
Sebastian Mauer
10b0a611cf
Add support for Gallagher tags (#1680)
* Add Gallagher protocol
2022-09-02 21:15:34 +10:00