mirror of
https://github.com/DarkFlippers/unleashed-firmware.git
synced 2026-10-15 12:39:54 +00:00
Add Manually now asks whether to enter a card as FC/ID or as hex. FC/ID takes the numbers printed on the card, one number input per field, and lays them out in the protocol data itself: EM4100, HID H10301, ioProx XSF, AWID and Pyramid 26-bit, and Gallagher. Parity and checksums are added by the firmware encoders as for hex-entered data. Formats whose scrambling and checksums are not exported by the protocol library go straight to hex as before. HID H10302, H10304, H10306, AMAG S10401 and Corporate 1000 35-bit are read on top of the firmware's Generic HIDProx protocol, whose data is the raw 44-bit field. The read and saved-card screens add a line for every format the frame fits by length and parity; a 37-bit frame fits more than one, so the second and later readings are prefixed "or". Layouts follow the Proxmark3 wiegand_formats.c reference except S10401, whose even parity covers bits 1-17 rather than 18: of 42 badges exported from a live access system, all 42 pass that and only the 13 with bit 18 clear pass Proxmark3's. Casi-Rusco C10106 badges transmit a plain EM4100 frame at RF/32, so the app reads the badge id out of those 40 bits - a 19-bit credential beginning with 15, then a 19-bit card field, less 66606 when its top bit is set. The frame carries no parity, so the line is shown as the alternative reading and the credential range keeps it off almost all other EM4100 cards. The Generic HIDProx render now gives the frame length alone. Its "Data:" line repeated the hex every caller already prints, and read the frame one nibble at a time from offsets that assumed a full first nibble, so a frame whose length is not a multiple of four lost bits after its first digit. A unit test covers every size header. A number input whose range excludes 0 opened on an empty field that could not be confirmed, because 0 is drawn as empty and the starting value was only clamped when it was not 0. It is now clamped unconditionally, so the field is only ever empty when 0 is in range, and an empty field reads back as 0 and is range-checked like any other value. Co-authored-by: matthewb-worthe <135917560+matthewb-worthe@users.noreply.github.com> Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Structure
app-scened-template- C++ app librarybit_lib- library for working with bits/bytes directlyble_profile- BLE Profiles source codecmsis_core- CMSIS Core package, contain cortex-m core headerscxxheaderparser- C++ headers parser, used by SDK bundlerdatetime- DateTime librarydigital_signal- Digital signal library: used by NFC for software implemented protocolsdrivers- Various flipper driversfatfs- FatFS file system driverflipper_application- Flipper application library, used for FAPsflipper_format- Flipper File Format libraryFreeRTOS-glue- Extra glue to hold together FreeRTOS kernel and flipper firmwareFreeRTOS-Kernel- FreeRTOS kernel source codeheatshrink- Heatshrink compression libraryibutton- ibutton library, used by iButton applicationinfrared- Infrared library, used by Infrared applicationlfrfid- LF-RFID library, used by LF RFID applicationlibusb_stm32- LibUSB for STM32 series MCUmbedtls- MbedTLS cryptography librarymicrotar- MicroTAR librarymjs- MJs, javascript engine librarymlib- M-Lib C containers librarymusic_worker- MusicWorker library for playing midi and RTTTL filesnanopb- NanoPB library, protobuf implementation for MCUnfc- NFC library, used by NFC applicationone_wire- OneWire library, used by iButton applicationprint- Tiny printf implementationdigital_signal- Digital Signal library used by NFC for software implemented protocolspulse_reader- Pulse Reader library used by NFC for software implemented protocolsstm32wb_cmsis- STM32WB series CMSIS headers, extends CMSIS Corestm32wb_copro- STM32WB Copro library: contains WPAN and radio co-processor firmwarestm32wb_hal- STM32WB HAL library, extends STM32WB CMSIS and provides HALsubghz- Subghz library, used by SubGhz applicationtoolbox- Toolbox library, contains various things that is used by Flipper firmwareu8g2- u8g2 graphics library, used by GUI subsystemupdate_util- update utilities library, used by updater