Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/dev' into release-candidate
Browse files Browse the repository at this point in the history
  • Loading branch information
skotopes committed Dec 23, 2022
2 parents 8bc7723 + dff73df commit 6ff3f82
Show file tree
Hide file tree
Showing 10 changed files with 505 additions and 2 deletions.
3 changes: 3 additions & 0 deletions .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,9 @@

/applications/debug/unit_tests/ @skotopes @DrZlo13 @hedger @nminaylov @gornekich @Astrrra @gsurkov @Skorpionm

# Assets
/assets/resources/infrared/ @skotopes @DrZlo13 @hedger @gsurkov

# Documentation
/documentation/ @skotopes @DrZlo13 @hedger @drunkbatya
/scripts/toolchain/ @skotopes @DrZlo13 @hedger @drunkbatya
Expand Down
1 change: 0 additions & 1 deletion applications/main/ibutton/scenes/ibutton_scene_read.c
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,6 @@ bool ibutton_scene_read_on_event(void* context, SceneManagerEvent event) {

if(success) {
ibutton_notification_message(ibutton, iButtonNotificationMessageSuccess);
ibutton_notification_message(ibutton, iButtonNotificationMessageGreenOn);
scene_manager_next_scene(scene_manager, iButtonSceneReadSuccess);
DOLPHIN_DEED(DolphinDeedIbuttonReadSuccess);
}
Expand Down
2 changes: 2 additions & 0 deletions applications/main/ibutton/scenes/ibutton_scene_read_success.c
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,8 @@ void ibutton_scene_read_success_on_enter(void* context) {
dialog_ex_set_context(dialog_ex, ibutton);

view_dispatcher_switch_to_view(ibutton->view_dispatcher, iButtonViewDialogEx);

ibutton_notification_message(ibutton, iButtonNotificationMessageGreenOn);
}

bool ibutton_scene_read_success_on_event(void* context, SceneManagerEvent event) {
Expand Down
3 changes: 2 additions & 1 deletion applications/main/subghz/views/receiver.c
Original file line number Diff line number Diff line change
Expand Up @@ -309,7 +309,8 @@ bool subghz_view_receiver_input(InputEvent* event, void* context) {
subghz_receiver->view,
SubGhzViewReceiverModel * model,
{
if(model->idx != model->history_item - 1) model->idx++;
if((model->history_item != 0) && (model->idx != model->history_item - 1))
model->idx++;
},
true);
} else if(event->key == InputKeyLeft && event->type == InputTypeShort) {
Expand Down
43 changes: 43 additions & 0 deletions assets/resources/infrared/assets/audio.ir
Original file line number Diff line number Diff line change
Expand Up @@ -242,3 +242,46 @@ type: raw
frequency: 38000
duty_cycle: 0.330000
data: 4639 4406 586 418 585 393 559 447 557 447 557 1477 532 1477 532 472 532 472 532 1476 533 1476 532 1476 532 1476 532 473 555 449 555 449 555 449 555 4455 554 450 554 450 554 450 554 450 554 1455 554 450 554 450 554 450 554 1455 554 1455 553 1455 553 450 554 450 554 1455 554 1455 554 1455 554 450 554 450 554 450 554 1455 554 55454 4557 4458 555 449 555 449 555 450 554 450 554 1455 554 1455 553 450 554 450 554 1455 554 1455 554 1454 554 1455 554 450 554 450 554 450 555 450 554 4455 553 450 554 450 554 450 554 450 554 1455 554 450 554 450 554 450 554 1455 554 1455 554 1455 553 450 554 450 554 1455 554 1455 553 1455 554 450 554 450 554 450 554 1455 554
#
# Model: Edifier R1850DB
name: Power
type: parsed
protocol: NECext
address: 10 E7 00 00
command: 46 B9 00 00
#
name: Play
type: parsed
protocol: NECext
address: 10 E7 00 00
command: 5E A1 00 00
#
name: Vol_up
type: parsed
protocol: NECext
address: 10 E7 00 00
command: 05 FA 00 00
#
name: Vol_dn
type: parsed
protocol: NECext
address: 10 E7 00 00
command: 49 B6 00 00
#
name: Next
type: parsed
protocol: NECext
address: 10 E7 00 00
command: 02 FD 00 00
#
name: Prev
type: parsed
protocol: NECext
address: 10 E7 00 00
command: 1E E1 00 00
#
name: Mute
type: parsed
protocol: NECext
address: 10 E7 00 00
command: 41 BE 00 00
19 changes: 19 additions & 0 deletions assets/resources/infrared/assets/tv.ir
Original file line number Diff line number Diff line change
Expand Up @@ -1656,3 +1656,22 @@ type: parsed
protocol: RC5
address: 01 00 00 00
command: 21 00 00 00
#
# Model: VIZIO
name: Mute
type: parsed
protocol: NEC
address: 04 00 00 00
command: 09 00 00 00
#
name: Vol_up
type: parsed
protocol: NEC
address: 04 00 00 00
command: 02 00 00 00
#
name: Vol_dn
type: parsed
protocol: NEC
address: 04 00 00 00
command: 03 00 00 00
92 changes: 92 additions & 0 deletions documentation/file_formats/BadUsbScriptFormat.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,92 @@
# Command syntax
BadUsb app uses extended Duckyscript syntax. It is compatible with classic USB Rubber Ducky 1.0 scripts, but provides some additional commands and features, such as custom USB ID, ALT+Numpad input method, SYSRQ command and more fuctional keys.
# Script file format
BadUsb app can execute only text scrips from .txt files, no compilation is required. Both `\n` and `\r\n` line endings are supported. Empty lines are allowed. You can use spaces ore tabs for line indentation.
# Command set
## Comment line
Just a single comment line. All text after REM command will be ignored by interpreter
|Command|Parameters|Notes|
|-|-|-|
|REM|Comment text||

## Delay
Pause script execution by defined time
|Command|Parameters|Notes|
|-|-|-|
|DELAY|Delay value in ms|Single delay|
|DEFAULT_DELAY|Delay value in ms|Add delay before every next command|
|DEFAULTDELAY|Delay value in ms|Same as DEFAULT_DELAY|

## Special keys
|Command|Notes|
|-|-|
|DOWNARROW / DOWN||
|LEFTARROW / LEFT||
|RIGHTARROW / RIGHT||
|UPARROW / UP||
|ENTER||
|DELETE||
|BACKSPACE||
|END||
|HOME||
|ESCAPE / ESC||
|INSERT||
|PAGEUP||
|PAGEDOWN||
|CAPSLOCK||
|NUMLOCK||
|SCROLLLOCK||
|PRINTSCREEN||
|BREAK|Pause/Break key|
|PAUSE|Pause/Break key|
|SPACE||
|TAB||
|MENU|Context menu key|
|APP|Same as MENU|
|Fx|F1-F12 keys|

## Modifier keys
Can be combined with special key command or single character
|Command|Notes|
|-|-|
|CONTROL / CTRL||
|SHIFT||
|ALT||
|WINDOWS / GUI||
|CTRL-ALT|CTRL+ALT|
|CTRL-SHIFT|CTRL+SHIFT|
|ALT-SHIFT|ALT+SHIFT|
|ALT-GUI|ALT+WIN|
|GUI-SHIFT|WIN+SHIFT|
## String
|Command|Parameters|Notes|
|-|-|-|
|STRING|Text string|Print text string|
## Repeat
|Command|Parameters|Notes|
|-|-|-|
|REPEAT|Number of additional repeats|Repeat previous command|
## ALT+Numpad input
On Windows and some Linux systems you can print character by pressing ALT key and entering its code on numpad
|Command|Parameters|Notes|
|-|-|-|
|ALTCHAR|Character code|Print single character|
|ALTSTRING|Text string|Print text string using ALT+Numpad method|
|ALTCODE|Text string|Same as ALTSTRING, presents in some Duckyscript implementations|
## SysRq
Send [SysRq command](https://en.wikipedia.org/wiki/Magic_SysRq_key)
|Command|Parameters|Notes|
|-|-|-|
|SYSRQ|Single character||
## USB device ID
You can set custom ID of Flipper USB HID device. ID command should be in the **first line** of script, it is executed before script run.

|Command|Parameters|Notes|
|-|-|-|
|ID|VID:PID Manufacturer:Product||

Example:
`ID 1234:abcd Flipper Devices:Flipper Zero`

VID and PID are hex codes and are mandatory, Manufacturer and Product are text strings and are optional.

47 changes: 47 additions & 0 deletions documentation/file_formats/LfRfidFileFormat.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
# LF RFID key file format

## Example
```
Filetype: Flipper RFID key
Version: 1
Key type: EM4100
Data: 01 23 45 67 89
```
## Description

Filename extension: `.rfid`

The file stores single RFID key of type defined by `Key type` parameter

### Version history

1. Initial version.

### Format fields

|Name|Description|
|-|-|
|Key type|Key protocol type|
|Data|Key data (HEX values)|

### Supported key types

|Type|Full name|
|-|-|
|EM4100|EM-Micro EM4100|
|H10301|HID H10301|
|Idteck|IDTECK|
|Indala26|Motorola Indala26|
|IOProxXSF|Kantech IOProxXSF|
|AWID|AWID|
|FDX-A|FECAVA FDX-A|
|FDX-B|ISO FDX-B|
|HIDProx|Generic HIDProx|
|HIDExt|Generic HIDExt|
|Pyramid|Farpointe Pyramid|
|Viking|Viking|
|Jablotron|Jablotron|
|Paradox|Paradox|
|PAC/Stanley|PAC/Stanley|
|Keri|Keri|
|Gallagher|Gallagher|
Loading

0 comments on commit 6ff3f82

Please sign in to comment.