mirror of
https://github.com/DarkFlippers/unleashed-firmware.git
synced 2025-12-13 13:09:49 +04:00
Compare commits
403 Commits
un1-d1c79a
...
un4-0f9ea9
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
a8b48771e4 | ||
|
|
1424878d65 | ||
|
|
a37b0d464c | ||
|
|
96502e21ae | ||
|
|
b5d6d60535 | ||
|
|
32e64fd29e | ||
|
|
8f9d81b972 | ||
|
|
23e0566273 | ||
|
|
4141483147 | ||
|
|
30e005d5c4 | ||
|
|
e3a2711eb3 | ||
|
|
8569641ce6 | ||
|
|
cafd06c71b | ||
|
|
06a7bda69b | ||
|
|
c43ce93936 | ||
|
|
2288855163 | ||
|
|
c0765c1114 | ||
|
|
683c6254da | ||
|
|
2ef515ef56 | ||
|
|
667be798fc | ||
|
|
0f9598099a | ||
|
|
0d6f729386 | ||
|
|
b452b6fd32 | ||
|
|
9403128a03 | ||
|
|
71589b28a7 | ||
|
|
8b0fa6d0b1 | ||
|
|
cf47da0ff4 | ||
|
|
d6b7fae7e4 | ||
|
|
110dc48b96 | ||
|
|
37c666ddf5 | ||
|
|
6ddca568b9 | ||
|
|
8993db56b8 | ||
|
|
3c1efda1db | ||
|
|
b62b7956a6 | ||
|
|
dce5af5c2e | ||
|
|
fbacdc5b7b | ||
|
|
8dba4f25ae | ||
|
|
43ef4046ed | ||
|
|
1e63f57bf7 | ||
|
|
649887fe0f | ||
|
|
be42c390f2 | ||
|
|
cbda5d996f | ||
|
|
de1ec97512 | ||
|
|
8af749c965 | ||
|
|
4d3f45e911 | ||
|
|
63fee41a1f | ||
|
|
f441fed68d | ||
|
|
6e0eeed773 | ||
|
|
6bf306200e | ||
|
|
e2faf31b45 | ||
|
|
85eb740559 | ||
|
|
cea14ae9c5 | ||
|
|
e9a11cfce0 | ||
|
|
87a14b96e1 | ||
|
|
bbd3f9cf71 | ||
|
|
230f09dddd | ||
|
|
24e744f1d1 | ||
|
|
0f9ea925d3 | ||
|
|
836de3df16 | ||
|
|
c92217a109 | ||
|
|
41c93431c8 | ||
|
|
f0ea8f3a84 | ||
|
|
4d8f294e7a | ||
|
|
f543753873 | ||
|
|
1fb1a68842 | ||
|
|
54fedb9bc8 | ||
|
|
8af9c00ddb | ||
|
|
5a22803bbc | ||
|
|
824f5ea027 | ||
|
|
76d38e832e | ||
|
|
aba20b6af8 | ||
|
|
226f8517f3 | ||
|
|
7df70d7c62 | ||
|
|
9176387b9f | ||
|
|
972c0dcb4a | ||
|
|
62e56e2618 | ||
|
|
f202d27206 | ||
|
|
bcfb12bf28 | ||
|
|
5883e134d4 | ||
|
|
f8b532f063 | ||
|
|
e25b424188 | ||
|
|
4241ad24a3 | ||
|
|
6bcc6f363b | ||
|
|
3dcd8a73f1 | ||
|
|
9ad7f7825d | ||
|
|
aa00606d22 | ||
|
|
9c62e1f6ac | ||
|
|
b934c41ed0 | ||
|
|
0ebb3f060e | ||
|
|
8f2bd3be57 | ||
|
|
cc02d57857 | ||
|
|
0c5f11f713 | ||
|
|
006d27ed93 | ||
|
|
746b732034 | ||
|
|
2ec9aeeefa | ||
|
|
8be08093e2 | ||
|
|
406247c5d8 | ||
|
|
22a87d5707 | ||
|
|
4271246d8a | ||
|
|
a3db6718c2 | ||
|
|
0f0473bee6 | ||
|
|
497be7ccb0 | ||
|
|
12a6290e91 | ||
|
|
e6e1e7fe15 | ||
|
|
cb14d23108 | ||
|
|
c4783664c0 | ||
|
|
91f3774246 | ||
|
|
1f8a034a71 | ||
|
|
8cc3e2f35a | ||
|
|
069dd29f08 | ||
|
|
91c06a2168 | ||
|
|
545c4349d6 | ||
|
|
a40e1a2be2 | ||
|
|
286300b35b | ||
|
|
633145495c | ||
|
|
a0bcbf731d | ||
|
|
60242cd7c4 | ||
|
|
3e9409a1a8 | ||
|
|
a9210b2849 | ||
|
|
a58807c57a | ||
|
|
5bb7cabea6 | ||
|
|
f201062819 | ||
|
|
9f501034c3 | ||
|
|
7bd0c8ff2c | ||
|
|
cdcf80ed05 | ||
|
|
3e3a167764 | ||
|
|
fa9602bd68 | ||
|
|
efb09380bd | ||
|
|
61fee8e269 | ||
|
|
5e30b14d90 | ||
|
|
c07e3a34dd | ||
|
|
be7e11e60f | ||
|
|
e96e414561 | ||
|
|
0c99cb52ec | ||
|
|
ad9e1ce4df | ||
|
|
22dc5190d1 | ||
|
|
f2fd97d9c5 | ||
|
|
08084d5763 | ||
|
|
add1ad6949 | ||
|
|
87654e60b8 | ||
|
|
6f92cd645e | ||
|
|
23f6ea2e05 | ||
|
|
a6b98ccbbe | ||
|
|
ba5f590dab | ||
|
|
f1048733d2 | ||
|
|
ea7f68fcab | ||
|
|
8013aacd94 | ||
|
|
be8f409098 | ||
|
|
97e6fe8f4e | ||
|
|
54757428e6 | ||
|
|
bd39d81324 | ||
|
|
2a2078d9b5 | ||
|
|
01ca588488 | ||
|
|
f86eada292 | ||
|
|
bc777b2eff | ||
|
|
6f91fa42f0 | ||
|
|
e6d22ed147 | ||
|
|
436f70b69b | ||
|
|
ec9ce0cad7 | ||
|
|
7e2008095e | ||
|
|
92e440c77d | ||
|
|
666821e9ce | ||
|
|
1bca477a43 | ||
|
|
41571ce9ad | ||
|
|
038d098c85 | ||
|
|
b03cc8ddc3 | ||
|
|
c8e3d9b040 | ||
|
|
aeb02500de | ||
|
|
eadd7801af | ||
|
|
6d2b0a3b6c | ||
|
|
8093721c24 | ||
|
|
32a7642761 | ||
|
|
e8bb45496d | ||
|
|
3846852f2b | ||
|
|
17d01f5c29 | ||
|
|
e6bcba6959 | ||
|
|
e13edc2f70 | ||
|
|
de6ff1d9c9 | ||
|
|
bea15134ba | ||
|
|
28a55bf576 | ||
|
|
e70121e20f | ||
|
|
432ff41d6a | ||
|
|
87393a086c | ||
|
|
6000d47a0f | ||
|
|
d986ef4104 | ||
|
|
f85dc1675d | ||
|
|
7c7ac07e6a | ||
|
|
ca02826cfd | ||
|
|
96ad7f3cef | ||
|
|
c213ff596a | ||
|
|
b2589698ff | ||
|
|
3360f818a1 | ||
|
|
066da4080b | ||
|
|
b2c118f267 | ||
|
|
a8db46124e | ||
|
|
672e27f258 | ||
|
|
e762a68265 | ||
|
|
8659becc9d | ||
|
|
82e1e8af6a | ||
|
|
a71d05a114 | ||
|
|
8d68bf62a5 | ||
|
|
2c85adb270 | ||
|
|
e2123c55bb | ||
|
|
f5ff6438d1 | ||
|
|
9f3b80e606 | ||
|
|
111656d2c1 | ||
|
|
2045a29d3f | ||
|
|
26e46f9267 | ||
|
|
d003db0404 | ||
|
|
5a31e35dc2 | ||
|
|
c7cd5721ed | ||
|
|
fb476c29e6 | ||
|
|
d80329b323 | ||
|
|
3d3c422751 | ||
|
|
ed385594a3 | ||
|
|
787df44c79 | ||
|
|
f0eedc3243 | ||
|
|
365d055dc5 | ||
|
|
650ba8a91f | ||
|
|
654d6dc6ec | ||
|
|
18b70ac6b5 | ||
|
|
51369d6219 | ||
|
|
181533df1b | ||
|
|
d85731636f | ||
|
|
6f66f87fab | ||
|
|
85d4dedb15 | ||
|
|
0a4cddb84c | ||
|
|
4e17230290 | ||
|
|
aa99ac53c7 | ||
|
|
875f70196b | ||
|
|
1e71d212fe | ||
|
|
269a6ce562 | ||
|
|
cd2014c51b | ||
|
|
08f80ab645 | ||
|
|
14bd8f2c49 | ||
|
|
8ce5fae626 | ||
|
|
087bf41392 | ||
|
|
d390381d5a | ||
|
|
c3e31663ef | ||
|
|
c28e4ea733 | ||
|
|
96a3da24c9 | ||
|
|
9d4b318357 | ||
|
|
ef5d0aa483 | ||
|
|
66487abaee | ||
|
|
d2bb1ef4d3 | ||
|
|
0e15090629 | ||
|
|
1413d7c937 | ||
|
|
d97a3ef161 | ||
|
|
870dfd188c | ||
|
|
71a6844a5f | ||
|
|
d67d5da034 | ||
|
|
c894948d4f | ||
|
|
e25148ce72 | ||
|
|
07301935b5 | ||
|
|
3a1705bcf9 | ||
|
|
df87b04fa9 | ||
|
|
75f5efce03 | ||
|
|
00585fa16a | ||
|
|
30aaae33be | ||
|
|
c0e7c2a929 | ||
|
|
286b4876ce | ||
|
|
10c2ae5a05 | ||
|
|
8915c0c66c | ||
|
|
ec7676182a | ||
|
|
e23dbb9f99 | ||
|
|
19d201085b | ||
|
|
17a4e03656 | ||
|
|
1fd9240481 | ||
|
|
fc9996377d | ||
|
|
7f4b586b13 | ||
|
|
72de4af6db | ||
|
|
5bbb13c5c9 | ||
|
|
3efb093125 | ||
|
|
60bce7b8d8 | ||
|
|
8b05bd1106 | ||
|
|
668b7857b4 | ||
|
|
8b3b5fa802 | ||
|
|
a6052be0f1 | ||
|
|
007a3d295e | ||
|
|
28beff1ab6 | ||
|
|
9c95562fad | ||
|
|
83e036da14 | ||
|
|
8fd4225939 | ||
|
|
a3234995db | ||
|
|
98312860a6 | ||
|
|
9dbcd43e66 | ||
|
|
ffce0aeec9 | ||
|
|
361a239d3e | ||
|
|
51ffdcd3bc | ||
|
|
d47fdce337 | ||
|
|
3fbaad1488 | ||
|
|
b9a766d909 | ||
|
|
1b8684eb53 | ||
|
|
7a2b5be137 | ||
|
|
873e1f114b | ||
|
|
abce958db9 | ||
|
|
d4c44d7500 | ||
|
|
444035d06a | ||
|
|
c8c75d5f14 | ||
|
|
1fda069579 | ||
|
|
fccb99d847 | ||
|
|
4a61a28f57 | ||
|
|
b00117e02c | ||
|
|
6b91c660d4 | ||
|
|
9c3406895c | ||
|
|
ee6b59ab9d | ||
|
|
bd594c7134 | ||
|
|
4417a37a2e | ||
|
|
1b6794ce7c | ||
|
|
c96bfba95a | ||
|
|
fe8ad22132 | ||
|
|
bcb5af1813 | ||
|
|
77be3db143 | ||
|
|
7a2a1d6007 | ||
|
|
1c00709ea6 | ||
|
|
9ad96f782e | ||
|
|
67955b6ab8 | ||
|
|
37ce143527 | ||
|
|
771e948cfc | ||
|
|
9dc337a02c | ||
|
|
3ea01f8413 | ||
|
|
5623842892 | ||
|
|
a8d37879cb | ||
|
|
bcaf898c57 | ||
|
|
248d222459 | ||
|
|
fd230b6d09 | ||
|
|
d55da415c2 | ||
|
|
f94517fdab | ||
|
|
177fabe50c | ||
|
|
7930f73a4e | ||
|
|
b0633af0b6 | ||
|
|
e0efb2bf37 | ||
|
|
239eca0543 | ||
|
|
de4e7b9dd9 | ||
|
|
8e986c58c3 | ||
|
|
bbe5c9cae1 | ||
|
|
a3193e3bbd | ||
|
|
f34dafeecc | ||
|
|
f4c2744f16 | ||
|
|
e66e7fabed | ||
|
|
30ed8c1598 | ||
|
|
c2eeadc41e | ||
|
|
a1f4b8065a | ||
|
|
bda69f7650 | ||
|
|
5e03086d7b | ||
|
|
8e9795eec0 | ||
|
|
9e4d7a0c9b | ||
|
|
0f6f9ad52e | ||
|
|
0cabefbc24 | ||
|
|
4ea5dc4b5a | ||
|
|
8abb9e8a2b | ||
|
|
a07ab6175f | ||
|
|
61e76bc85c | ||
|
|
b52c63f6da | ||
|
|
e9ab581771 | ||
|
|
b62096fb91 | ||
|
|
ff33bc6aea | ||
|
|
d65c7b5f4c | ||
|
|
563cf986d6 | ||
|
|
123bd6fc65 | ||
|
|
77b19ec0db | ||
|
|
7f464f8be4 | ||
|
|
23433ce161 | ||
|
|
7de9c957d2 | ||
|
|
18891ade89 | ||
|
|
4588f38ae9 | ||
|
|
015fcf239c | ||
|
|
251b747b00 | ||
|
|
8955388a60 | ||
|
|
7afb4d0f41 | ||
|
|
6decd6fc7d | ||
|
|
e9e0079e30 | ||
|
|
f28ecec835 | ||
|
|
b10727435a | ||
|
|
fe7d089593 | ||
|
|
380fe2633a | ||
|
|
58cc7c1814 | ||
|
|
7681e9a257 | ||
|
|
365d2977ef | ||
|
|
a8895d56ea | ||
|
|
7acd814970 | ||
|
|
2ad9aec802 | ||
|
|
f84d5e9b85 | ||
|
|
1a60093689 | ||
|
|
a8eb53af4e | ||
|
|
5cb074fc24 | ||
|
|
d9265164a3 | ||
|
|
b67dfb5821 | ||
|
|
4c2e38b51c | ||
|
|
d13b4e3bd5 | ||
|
|
91c7441fa8 | ||
|
|
b7922a2a49 | ||
|
|
f0937e91f1 | ||
|
|
ac08c92a35 | ||
|
|
b2ba7b5e59 | ||
|
|
9b89acfec0 | ||
|
|
7c1a48a377 | ||
|
|
c8ad361818 | ||
|
|
1a52e55a73 | ||
|
|
f6a071ed6b | ||
|
|
05b6f9a901 | ||
|
|
31e06da7e7 | ||
|
|
1bb1022d51 |
151
.clang-format
151
.clang-format
@@ -1,86 +1,191 @@
|
|||||||
|
---
|
||||||
|
Language: Cpp
|
||||||
AccessModifierOffset: -4
|
AccessModifierOffset: -4
|
||||||
AlignAfterOpenBracket: AlwaysBreak
|
AlignAfterOpenBracket: AlwaysBreak
|
||||||
AlignConsecutiveAssignments: false
|
AlignArrayOfStructures: None
|
||||||
AlignConsecutiveDeclarations: false
|
AlignConsecutiveMacros: None
|
||||||
|
AlignConsecutiveAssignments: None
|
||||||
|
AlignConsecutiveBitFields: None
|
||||||
|
AlignConsecutiveDeclarations: None
|
||||||
AlignEscapedNewlines: Left
|
AlignEscapedNewlines: Left
|
||||||
AlignOperands: true
|
AlignOperands: Align
|
||||||
AlignTrailingComments: false
|
AlignTrailingComments: false
|
||||||
|
AllowAllArgumentsOnNextLine: true
|
||||||
AllowAllParametersOfDeclarationOnNextLine: false
|
AllowAllParametersOfDeclarationOnNextLine: false
|
||||||
|
AllowShortEnumsOnASingleLine: true
|
||||||
AllowShortBlocksOnASingleLine: Never
|
AllowShortBlocksOnASingleLine: Never
|
||||||
AllowShortCaseLabelsOnASingleLine: false
|
AllowShortCaseLabelsOnASingleLine: false
|
||||||
AllowShortFunctionsOnASingleLine: None
|
AllowShortFunctionsOnASingleLine: None
|
||||||
AllowShortIfStatementsOnASingleLine: true
|
AllowShortLambdasOnASingleLine: All
|
||||||
|
AllowShortIfStatementsOnASingleLine: WithoutElse
|
||||||
AllowShortLoopsOnASingleLine: true
|
AllowShortLoopsOnASingleLine: true
|
||||||
AlwaysBreakAfterDefinitionReturnType: None
|
AlwaysBreakAfterDefinitionReturnType: None
|
||||||
AlwaysBreakAfterReturnType: None
|
AlwaysBreakAfterReturnType: None
|
||||||
AlwaysBreakBeforeMultilineStrings: false
|
AlwaysBreakBeforeMultilineStrings: false
|
||||||
AlwaysBreakTemplateDeclarations: false
|
AlwaysBreakTemplateDeclarations: Yes
|
||||||
|
AttributeMacros:
|
||||||
|
- __capability
|
||||||
BinPackArguments: false
|
BinPackArguments: false
|
||||||
BinPackParameters: false
|
BinPackParameters: false
|
||||||
|
BraceWrapping:
|
||||||
|
AfterCaseLabel: false
|
||||||
|
AfterClass: false
|
||||||
|
AfterControlStatement: Never
|
||||||
|
AfterEnum: false
|
||||||
|
AfterFunction: false
|
||||||
|
AfterNamespace: false
|
||||||
|
AfterObjCDeclaration: false
|
||||||
|
AfterStruct: false
|
||||||
|
AfterUnion: false
|
||||||
|
AfterExternBlock: false
|
||||||
|
BeforeCatch: false
|
||||||
|
BeforeElse: false
|
||||||
|
BeforeLambdaBody: false
|
||||||
|
BeforeWhile: false
|
||||||
|
IndentBraces: false
|
||||||
|
SplitEmptyFunction: true
|
||||||
|
SplitEmptyRecord: true
|
||||||
|
SplitEmptyNamespace: true
|
||||||
BreakBeforeBinaryOperators: None
|
BreakBeforeBinaryOperators: None
|
||||||
|
BreakBeforeConceptDeclarations: true
|
||||||
BreakBeforeBraces: Attach
|
BreakBeforeBraces: Attach
|
||||||
|
BreakBeforeInheritanceComma: false
|
||||||
|
BreakInheritanceList: BeforeColon
|
||||||
BreakBeforeTernaryOperators: false
|
BreakBeforeTernaryOperators: false
|
||||||
|
BreakConstructorInitializersBeforeComma: false
|
||||||
BreakConstructorInitializers: BeforeComma
|
BreakConstructorInitializers: BeforeComma
|
||||||
|
BreakAfterJavaFieldAnnotations: false
|
||||||
BreakStringLiterals: false
|
BreakStringLiterals: false
|
||||||
ColumnLimit: 99
|
ColumnLimit: 99
|
||||||
|
CommentPragmas: '^ IWYU pragma:'
|
||||||
|
QualifierAlignment: Leave
|
||||||
CompactNamespaces: false
|
CompactNamespaces: false
|
||||||
ConstructorInitializerAllOnOneLineOrOnePerLine: false
|
|
||||||
ConstructorInitializerIndentWidth: 4
|
ConstructorInitializerIndentWidth: 4
|
||||||
ContinuationIndentWidth: 4
|
ContinuationIndentWidth: 4
|
||||||
Cpp11BracedListStyle: true
|
Cpp11BracedListStyle: true
|
||||||
|
DeriveLineEnding: true
|
||||||
DerivePointerAlignment: false
|
DerivePointerAlignment: false
|
||||||
DisableFormat: false
|
DisableFormat: false
|
||||||
|
EmptyLineAfterAccessModifier: Never
|
||||||
|
EmptyLineBeforeAccessModifier: LogicalBlock
|
||||||
ExperimentalAutoDetectBinPacking: false
|
ExperimentalAutoDetectBinPacking: false
|
||||||
|
PackConstructorInitializers: BinPack
|
||||||
|
BasedOnStyle: ''
|
||||||
|
ConstructorInitializerAllOnOneLineOrOnePerLine: false
|
||||||
|
AllowAllConstructorInitializersOnNextLine: true
|
||||||
FixNamespaceComments: false
|
FixNamespaceComments: false
|
||||||
|
ForEachMacros:
|
||||||
IncludeBlocks: Preserve
|
- foreach
|
||||||
|
- Q_FOREACH
|
||||||
|
- BOOST_FOREACH
|
||||||
|
IfMacros:
|
||||||
|
- KJ_IF_MAYBE
|
||||||
|
IncludeBlocks: Preserve
|
||||||
IncludeCategories:
|
IncludeCategories:
|
||||||
- Regex: '.*'
|
- Regex: '.*'
|
||||||
Priority: 1
|
Priority: 1
|
||||||
|
SortPriority: 0
|
||||||
|
CaseSensitive: false
|
||||||
|
- Regex: '^(<|"(gtest|gmock|isl|json)/)'
|
||||||
|
Priority: 3
|
||||||
|
SortPriority: 0
|
||||||
|
CaseSensitive: false
|
||||||
|
- Regex: '.*'
|
||||||
|
Priority: 1
|
||||||
|
SortPriority: 0
|
||||||
|
CaseSensitive: false
|
||||||
IncludeIsMainRegex: '(Test)?$'
|
IncludeIsMainRegex: '(Test)?$'
|
||||||
|
IncludeIsMainSourceRegex: ''
|
||||||
|
IndentAccessModifiers: false
|
||||||
IndentCaseLabels: false
|
IndentCaseLabels: false
|
||||||
|
IndentCaseBlocks: false
|
||||||
|
IndentGotoLabels: true
|
||||||
IndentPPDirectives: None
|
IndentPPDirectives: None
|
||||||
IndentWidth: 4
|
IndentExternBlock: AfterExternBlock
|
||||||
|
IndentRequires: false
|
||||||
|
IndentWidth: 4
|
||||||
IndentWrappedFunctionNames: true
|
IndentWrappedFunctionNames: true
|
||||||
|
InsertTrailingCommas: None
|
||||||
JavaScriptQuotes: Leave
|
JavaScriptQuotes: Leave
|
||||||
JavaScriptWrapImports: true
|
JavaScriptWrapImports: true
|
||||||
KeepEmptyLinesAtTheStartOfBlocks: false
|
KeepEmptyLinesAtTheStartOfBlocks: false
|
||||||
|
LambdaBodyIndentation: Signature
|
||||||
MacroBlockBegin: ''
|
MacroBlockBegin: ''
|
||||||
MacroBlockEnd: ''
|
MacroBlockEnd: ''
|
||||||
MaxEmptyLinesToKeep: 1
|
MaxEmptyLinesToKeep: 1
|
||||||
NamespaceIndentation: None
|
NamespaceIndentation: None
|
||||||
ObjCBinPackProtocolList: Auto
|
ObjCBinPackProtocolList: Auto
|
||||||
ObjCBlockIndentWidth: 4
|
ObjCBlockIndentWidth: 4
|
||||||
|
ObjCBreakBeforeNestedBlockParam: true
|
||||||
ObjCSpaceAfterProperty: true
|
ObjCSpaceAfterProperty: true
|
||||||
ObjCSpaceBeforeProtocolList: true
|
ObjCSpaceBeforeProtocolList: true
|
||||||
|
|
||||||
# Taken from git's rules
|
|
||||||
PenaltyBreakAssignment: 10
|
PenaltyBreakAssignment: 10
|
||||||
PenaltyBreakBeforeFirstCallParameter: 30
|
PenaltyBreakBeforeFirstCallParameter: 30
|
||||||
PenaltyBreakComment: 10
|
PenaltyBreakComment: 10
|
||||||
PenaltyBreakFirstLessLess: 0
|
PenaltyBreakFirstLessLess: 0
|
||||||
|
PenaltyBreakOpenParenthesis: 0
|
||||||
PenaltyBreakString: 10
|
PenaltyBreakString: 10
|
||||||
|
PenaltyBreakTemplateDeclaration: 10
|
||||||
PenaltyExcessCharacter: 100
|
PenaltyExcessCharacter: 100
|
||||||
PenaltyReturnTypeOnItsOwnLine: 60
|
PenaltyReturnTypeOnItsOwnLine: 60
|
||||||
|
PenaltyIndentedWhitespace: 0
|
||||||
PointerAlignment: Left
|
PointerAlignment: Left
|
||||||
ReflowComments: false
|
PPIndentWidth: -1
|
||||||
SortIncludes: false
|
ReferenceAlignment: Pointer
|
||||||
|
ReflowComments: false
|
||||||
|
RemoveBracesLLVM: false
|
||||||
|
SeparateDefinitionBlocks: Leave
|
||||||
|
ShortNamespaceLines: 1
|
||||||
|
SortIncludes: Never
|
||||||
|
SortJavaStaticImport: Before
|
||||||
SortUsingDeclarations: false
|
SortUsingDeclarations: false
|
||||||
SpaceAfterCStyleCast: false
|
SpaceAfterCStyleCast: false
|
||||||
|
SpaceAfterLogicalNot: false
|
||||||
SpaceAfterTemplateKeyword: true
|
SpaceAfterTemplateKeyword: true
|
||||||
SpaceBeforeAssignmentOperators: true
|
SpaceBeforeAssignmentOperators: true
|
||||||
|
SpaceBeforeCaseColon: false
|
||||||
|
SpaceBeforeCpp11BracedList: false
|
||||||
SpaceBeforeCtorInitializerColon: true
|
SpaceBeforeCtorInitializerColon: true
|
||||||
SpaceBeforeInheritanceColon: true
|
SpaceBeforeInheritanceColon: true
|
||||||
SpaceBeforeParens: Never
|
SpaceBeforeParens: Never
|
||||||
|
SpaceBeforeParensOptions:
|
||||||
|
AfterControlStatements: false
|
||||||
|
AfterForeachMacros: false
|
||||||
|
AfterFunctionDefinitionName: false
|
||||||
|
AfterFunctionDeclarationName: false
|
||||||
|
AfterIfMacros: false
|
||||||
|
AfterOverloadedOperator: false
|
||||||
|
BeforeNonEmptyParentheses: false
|
||||||
|
SpaceAroundPointerQualifiers: Default
|
||||||
SpaceBeforeRangeBasedForLoopColon: true
|
SpaceBeforeRangeBasedForLoopColon: true
|
||||||
|
SpaceInEmptyBlock: false
|
||||||
SpaceInEmptyParentheses: false
|
SpaceInEmptyParentheses: false
|
||||||
SpacesBeforeTrailingComments: 1
|
SpacesBeforeTrailingComments: 1
|
||||||
SpacesInAngles: false
|
SpacesInAngles: Never
|
||||||
|
SpacesInConditionalStatement: false
|
||||||
SpacesInContainerLiterals: false
|
SpacesInContainerLiterals: false
|
||||||
SpacesInCStyleCastParentheses: false
|
SpacesInCStyleCastParentheses: false
|
||||||
|
SpacesInLineCommentPrefix:
|
||||||
|
Minimum: 1
|
||||||
|
Maximum: -1
|
||||||
SpacesInParentheses: false
|
SpacesInParentheses: false
|
||||||
SpacesInSquareBrackets: false
|
SpacesInSquareBrackets: false
|
||||||
Standard: Cpp03
|
SpaceBeforeSquareBrackets: false
|
||||||
TabWidth: 4
|
BitFieldColonSpacing: Both
|
||||||
UseTab: Never
|
Standard: c++03
|
||||||
|
StatementAttributeLikeMacros:
|
||||||
|
- Q_EMIT
|
||||||
|
StatementMacros:
|
||||||
|
- Q_UNUSED
|
||||||
|
- QT_REQUIRE_VERSION
|
||||||
|
TabWidth: 4
|
||||||
|
UseCRLF: false
|
||||||
|
UseTab: Never
|
||||||
|
WhitespaceSensitiveMacros:
|
||||||
|
- STRINGIZE
|
||||||
|
- PP_STRINGIZE
|
||||||
|
- BOOST_PP_STRINGIZE
|
||||||
|
- NS_SWIFT_NAME
|
||||||
|
- CF_SWIFT_NAME
|
||||||
|
...
|
||||||
|
|
||||||
|
|||||||
28
.drone.yml
28
.drone.yml
@@ -28,33 +28,6 @@ steps:
|
|||||||
FBT_TOOLS_CUSTOM_LINK:
|
FBT_TOOLS_CUSTOM_LINK:
|
||||||
from_secret: fbt_link
|
from_secret: fbt_link
|
||||||
|
|
||||||
- name: "Bundle resources"
|
|
||||||
image: kramos/alpine-zip
|
|
||||||
commands:
|
|
||||||
- mkdir sd-card
|
|
||||||
- mkdir -p sd-card/subghz/assets
|
|
||||||
- mkdir -p sd-card/nfc/assets
|
|
||||||
- mkdir -p sd-card/infrared/assets
|
|
||||||
- mkdir -p sd-card/unirf
|
|
||||||
- mkdir -p sd-card/rfidfuzzer
|
|
||||||
- mkdir -p sd-card/badusb/layouts
|
|
||||||
- cp assets/resources/badusb/layouts/* sd-card/badusb/layouts/
|
|
||||||
- cp assets/resources/subghz/assets/dangerous_settings sd-card/subghz/assets/dangerous_settings
|
|
||||||
- cp assets/resources/subghz/assets/setting_user sd-card/subghz/assets/setting_user
|
|
||||||
- cp assets/resources/subghz/assets/keeloq_mfcodes sd-card/subghz/assets/keeloq_mfcodes
|
|
||||||
- cp assets/resources/nfc/assets/mf_classic_dict.nfc sd-card/nfc/assets/mf_classic_dict.nfc
|
|
||||||
- cp assets/resources/infrared/assets/tv.ir sd-card/infrared/assets/tv.ir
|
|
||||||
- cp assets/resources/infrared/assets/ac.ir sd-card/infrared/assets/ac.ir
|
|
||||||
- cp assets/resources/infrared/assets/fans.ir sd-card/infrared/assets/fans.ir
|
|
||||||
- cp assets/resources/infrared/assets/projectors.ir sd-card/infrared/assets/projectors.ir
|
|
||||||
- cp assets/resources/infrared/assets/audio.ir sd-card/infrared/assets/audio.ir
|
|
||||||
- cp assets/resources/unirf/unirf_map_example.txt sd-card/unirf/unirf_map_example.txt
|
|
||||||
- cp assets/resources/rfidfuzzer/example_uids.txt sd-card/rfidfuzzer/example_uids.txt
|
|
||||||
- cp assets/resources/Manifest sd-card/Manifest
|
|
||||||
- zip -r artifacts-default/sd-card-${DRONE_TAG}.zip sd-card
|
|
||||||
- rm -rf sd-card
|
|
||||||
- ls -laS artifacts-default
|
|
||||||
|
|
||||||
- name: "Bundle self-update packages"
|
- name: "Bundle self-update packages"
|
||||||
image: kramos/alpine-zip
|
image: kramos/alpine-zip
|
||||||
commands:
|
commands:
|
||||||
@@ -91,7 +64,6 @@ steps:
|
|||||||
files:
|
files:
|
||||||
- artifacts-default/*.tgz
|
- artifacts-default/*.tgz
|
||||||
- artifacts-default/*.zip
|
- artifacts-default/*.zip
|
||||||
- artifacts-default/flipper-z-f7-full-${DRONE_TAG}.dfu
|
|
||||||
title: ${DRONE_TAG}
|
title: ${DRONE_TAG}
|
||||||
note: CHANGELOG.md
|
note: CHANGELOG.md
|
||||||
checksum:
|
checksum:
|
||||||
|
|||||||
1
.github/CODEOWNERS
vendored
Normal file
1
.github/CODEOWNERS
vendored
Normal file
@@ -0,0 +1 @@
|
|||||||
|
* @xMasterX
|
||||||
3
.gitmodules
vendored
3
.gitmodules
vendored
@@ -28,3 +28,6 @@
|
|||||||
[submodule "lib/mbedtls"]
|
[submodule "lib/mbedtls"]
|
||||||
path = lib/mbedtls
|
path = lib/mbedtls
|
||||||
url = https://github.com/Mbed-TLS/mbedtls.git
|
url = https://github.com/Mbed-TLS/mbedtls.git
|
||||||
|
[submodule "lib/cxxheaderparser"]
|
||||||
|
path = lib/cxxheaderparser
|
||||||
|
url = https://github.com/robotpy/cxxheaderparser.git
|
||||||
|
|||||||
20
.vscode/example/launch.json
vendored
20
.vscode/example/launch.json
vendored
@@ -9,6 +9,10 @@
|
|||||||
"type": "command",
|
"type": "command",
|
||||||
"command": "shellCommand.execute",
|
"command": "shellCommand.execute",
|
||||||
"args": {
|
"args": {
|
||||||
|
"useSingleResult": true,
|
||||||
|
"env": {
|
||||||
|
"PATH": "${workspaceFolder};${env:PATH}"
|
||||||
|
},
|
||||||
"command": "./fbt get_blackmagic",
|
"command": "./fbt get_blackmagic",
|
||||||
"description": "Get Blackmagic device",
|
"description": "Get Blackmagic device",
|
||||||
}
|
}
|
||||||
@@ -24,14 +28,18 @@
|
|||||||
"servertype": "openocd",
|
"servertype": "openocd",
|
||||||
"device": "stlink",
|
"device": "stlink",
|
||||||
"svdFile": "./debug/STM32WB55_CM4.svd",
|
"svdFile": "./debug/STM32WB55_CM4.svd",
|
||||||
|
// If you're debugging early in the boot process, before OS scheduler is running,
|
||||||
|
// you have to comment out the following line.
|
||||||
"rtos": "FreeRTOS",
|
"rtos": "FreeRTOS",
|
||||||
"configFiles": [
|
"configFiles": [
|
||||||
"interface/stlink.cfg",
|
"interface/stlink.cfg",
|
||||||
"./debug/stm32wbx.cfg",
|
"./debug/stm32wbx.cfg",
|
||||||
],
|
],
|
||||||
"postAttachCommands": [
|
"postAttachCommands": [
|
||||||
// "attach 1",
|
// "compare-sections",
|
||||||
"compare-sections",
|
"source debug/flipperapps.py",
|
||||||
|
// "source debug/FreeRTOS/FreeRTOS.py",
|
||||||
|
// "svd_load debug/STM32WB55_CM4.svd"
|
||||||
]
|
]
|
||||||
// "showDevDebugOutput": "raw",
|
// "showDevDebugOutput": "raw",
|
||||||
},
|
},
|
||||||
@@ -50,7 +58,8 @@
|
|||||||
"attach 1",
|
"attach 1",
|
||||||
"set confirm off",
|
"set confirm off",
|
||||||
"set mem inaccessible-by-default off",
|
"set mem inaccessible-by-default off",
|
||||||
"compare-sections",
|
"source debug/flipperapps.py",
|
||||||
|
// "compare-sections",
|
||||||
]
|
]
|
||||||
// "showDevDebugOutput": "raw",
|
// "showDevDebugOutput": "raw",
|
||||||
},
|
},
|
||||||
@@ -65,6 +74,9 @@
|
|||||||
"device": "STM32WB55RG",
|
"device": "STM32WB55RG",
|
||||||
"svdFile": "./debug/STM32WB55_CM4.svd",
|
"svdFile": "./debug/STM32WB55_CM4.svd",
|
||||||
"rtos": "FreeRTOS",
|
"rtos": "FreeRTOS",
|
||||||
|
"postAttachCommands": [
|
||||||
|
"source debug/flipperapps.py",
|
||||||
|
]
|
||||||
// "showDevDebugOutput": "raw",
|
// "showDevDebugOutput": "raw",
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -73,7 +85,7 @@
|
|||||||
"request": "launch",
|
"request": "launch",
|
||||||
"program": "./lib/scons/scripts/scons.py",
|
"program": "./lib/scons/scripts/scons.py",
|
||||||
"args": [
|
"args": [
|
||||||
"sdk"
|
"plugin_dist"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|||||||
5
.vscode/example/settings.json
vendored
5
.vscode/example/settings.json
vendored
@@ -12,6 +12,9 @@
|
|||||||
"cortex-debug.openocdPath.windows": "${workspaceFolder}/toolchain/i686-windows/openocd/bin/openocd.exe",
|
"cortex-debug.openocdPath.windows": "${workspaceFolder}/toolchain/i686-windows/openocd/bin/openocd.exe",
|
||||||
"cortex-debug.openocdPath.linux": "${workspaceFolder}/toolchain/x86_64-linux/openocd/bin/openocd",
|
"cortex-debug.openocdPath.linux": "${workspaceFolder}/toolchain/x86_64-linux/openocd/bin/openocd",
|
||||||
"cortex-debug.openocdPath.osx": "${workspaceFolder}/toolchain/x86_64-darwin/openocd/bin/openocd",
|
"cortex-debug.openocdPath.osx": "${workspaceFolder}/toolchain/x86_64-darwin/openocd/bin/openocd",
|
||||||
|
"cortex-debug.gdbPath.windows": "${workspaceFolder}/toolchain/i686-windows/bin/arm-none-eabi-gdb-py.bat",
|
||||||
|
"cortex-debug.gdbPath.linux": "${workspaceFolder}/toolchain/x86_64-linux/bin/arm-none-eabi-gdb-py",
|
||||||
|
"cortex-debug.gdbPath.osx": "${workspaceFolder}/toolchain/x86_64-darwin/bin/arm-none-eabi-gdb-py",
|
||||||
"editor.formatOnSave": true,
|
"editor.formatOnSave": true,
|
||||||
"files.associations": {
|
"files.associations": {
|
||||||
"*.scons": "python",
|
"*.scons": "python",
|
||||||
@@ -19,4 +22,4 @@
|
|||||||
"SConstruct": "python",
|
"SConstruct": "python",
|
||||||
"*.fam": "python",
|
"*.fam": "python",
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
30
.vscode/example/tasks.json
vendored
30
.vscode/example/tasks.json
vendored
@@ -93,11 +93,41 @@
|
|||||||
"type": "shell",
|
"type": "shell",
|
||||||
"command": "./fbt FIRMWARE_APP_SET=unit_tests FORCE=1 flash_usb"
|
"command": "./fbt FIRMWARE_APP_SET=unit_tests FORCE=1 flash_usb"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"label": "[Debug] Flash (USB, with resources)",
|
||||||
|
"group": "build",
|
||||||
|
"type": "shell",
|
||||||
|
"command": "./fbt FORCE=1 flash_usb_full"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"label": "[Release] Flash (USB, with resources)",
|
"label": "[Release] Flash (USB, with resources)",
|
||||||
"group": "build",
|
"group": "build",
|
||||||
"type": "shell",
|
"type": "shell",
|
||||||
"command": "./fbt COMPACT=1 DEBUG=0 FORCE=1 flash_usb_full"
|
"command": "./fbt COMPACT=1 DEBUG=0 FORCE=1 flash_usb_full"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"label": "[Debug] Build FAPs",
|
||||||
|
"group": "build",
|
||||||
|
"type": "shell",
|
||||||
|
"command": "./fbt plugin_dist"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "[Release] Build FAPs",
|
||||||
|
"group": "build",
|
||||||
|
"type": "shell",
|
||||||
|
"command": "./fbt COMPACT=1 DEBUG=0 plugin_dist"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "[Debug] Launch App on Flipper",
|
||||||
|
"group": "build",
|
||||||
|
"type": "shell",
|
||||||
|
"command": "./fbt launch_app APPSRC=${relativeFileDirname}"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "[Release] Launch App on Flipper",
|
||||||
|
"group": "build",
|
||||||
|
"type": "shell",
|
||||||
|
"command": "./fbt COMPACT=1 DEBUG=0 launch_app APPSRC=${relativeFileDirname}"
|
||||||
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
17
CHANGELOG.md
17
CHANGELOG.md
@@ -1,14 +1,15 @@
|
|||||||
### New changes
|
### New changes
|
||||||
* Set poweroff button timer to 2sec
|
* Plugins: RFID Fuzzer - ability to change time delay (between cards), useful for slow readers, you can adjust it on the go
|
||||||
* Debug apps (USB Mouse, UART Echo) now included in release build
|
|
||||||
* OFW: Toolchain update
|
|
||||||
|
|
||||||
**Note: To avoid issues prefer installing using web updater or by self update package, all needed assets will be installed**
|
#### [🎲 Download extra apps pack](https://download-directory.github.io/?url=https://github.com/UberGuidoZ/Flipper/tree/main/Applications/Unleashed)
|
||||||
|
|
||||||
Self-update package (update from microSD) - `flipper-z-f7-update-(version).zip` or `.tgz` for iOS mobile app
|
[-> How to install firmware](https://github.com/Eng1n33r/flipperzero-firmware/blob/dev/documentation/HowToInstall.md)
|
||||||
|
|
||||||
DFU for update using qFlipper - `flipper-z-f7-full-(version).dfu`
|
[-> Download qFlipper 1.2.0 (allows .tgz installation) (official link)](https://update.flipperzero.one/builds/qFlipper/1.2.0/)
|
||||||
|
|
||||||
If using DFU update method, download this archive and unpack it to your microSD, replacing all files except files you have edited manually -
|
**Note: To avoid issues with .dfu, prefer installing using .tgz with qFlipper, web updater or by self update package, all needed assets will be installed**
|
||||||
`sd-card-(version).zip`
|
|
||||||
|
Self-update package (update from microSD) - `flipper-z-f7-update-(version).zip` or download `.tgz` for iOS mobile app / qFlipper
|
||||||
|
|
||||||
|
Update using qFlipper (1.2.0) is now possible with `.tgz` update package! Also you can use Web Updater or self-update package.
|
||||||
|
|
||||||
|
|||||||
48
ReadMe.md
48
ReadMe.md
@@ -7,7 +7,7 @@
|
|||||||
### Welcome to Flipper Zero Unleashed Firmware repo!
|
### Welcome to Flipper Zero Unleashed Firmware repo!
|
||||||
Our goal is to make any features possible in this device without any limitations!
|
Our goal is to make any features possible in this device without any limitations!
|
||||||
|
|
||||||
Please help us implement emulation for all subghz dynamic (rolling code) protocols and static code brute-force plugin!
|
Please help us implement emulation for all subghz dynamic (rolling code) protocols!
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
|
|
||||||
@@ -16,7 +16,7 @@ Please help us implement emulation for all subghz dynamic (rolling code) protoco
|
|||||||
<br>
|
<br>
|
||||||
Our Discord Community:
|
Our Discord Community:
|
||||||
<br>
|
<br>
|
||||||
<a href="https://discord.gg/58D6E8BtTU"><img src="https://discordapp.com/api/guilds/937479784148115456/widget.png?style=banner4" alt="Unofficial Discord Community"></a>
|
<a href="https://discord.gg/flipperzero-unofficial"><img src="https://discordapp.com/api/guilds/937479784148115456/widget.png?style=banner4" alt="Unofficial Discord Community"></a>
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
<br>
|
<br>
|
||||||
@@ -27,6 +27,8 @@ Our Discord Community:
|
|||||||
* SubGHz frequecy range can be extended in settings file (Warning: It can damage flipper's hardware)
|
* SubGHz frequecy range can be extended in settings file (Warning: It can damage flipper's hardware)
|
||||||
* Many rolling code protocols now have the ability to save & send captured signals
|
* Many rolling code protocols now have the ability to save & send captured signals
|
||||||
* FAAC SLH (Spa) & BFT Mitto (secure with seed) manual creation
|
* FAAC SLH (Spa) & BFT Mitto (secure with seed) manual creation
|
||||||
|
* Sub-GHz static code brute-force plugin
|
||||||
|
* LFRFID Fuzzer plugin
|
||||||
* Custom community plugins and games added
|
* Custom community plugins and games added
|
||||||
* Extra SubGHz frequencies + extra Mifare Classic keys
|
* Extra SubGHz frequencies + extra Mifare Classic keys
|
||||||
* Picopass/iClass plugin included in releases
|
* Picopass/iClass plugin included in releases
|
||||||
@@ -34,9 +36,12 @@ Our Discord Community:
|
|||||||
* Universal remote for Projectors, Fans, A/Cs and Audio(soundbars, etc.)
|
* Universal remote for Projectors, Fans, A/Cs and Audio(soundbars, etc.)
|
||||||
* BadUSB keyboard layouts
|
* BadUSB keyboard layouts
|
||||||
* Customizable Flipper name
|
* Customizable Flipper name
|
||||||
|
* SubGHz -> Press OK in frequency analyzer to use detected frequency in Read modes
|
||||||
|
* SubGHz -> Long press OK button in SubGHz Frequency analyzer to switch to Read menu
|
||||||
* Other small fixes and changes throughout
|
* Other small fixes and changes throughout
|
||||||
|
* See other changes in changelog and in readme below
|
||||||
|
|
||||||
See changelog in releases for latest updates!
|
Also check changelog in releases for latest updates!
|
||||||
|
|
||||||
### Current modified and new SubGHz protocols list:
|
### Current modified and new SubGHz protocols list:
|
||||||
- HCS101
|
- HCS101
|
||||||
@@ -47,7 +52,7 @@ See changelog in releases for latest updates!
|
|||||||
- Keeloq [Not ALL systems supported yet!]
|
- Keeloq [Not ALL systems supported yet!]
|
||||||
- Nice Flor S
|
- Nice Flor S
|
||||||
- Security+ v1 & v2
|
- Security+ v1 & v2
|
||||||
- Star Line
|
- Star Line (saving only)
|
||||||
|
|
||||||
## Support us so we can buy equipment and develop new features
|
## Support us so we can buy equipment and develop new features
|
||||||
* ETH/BSC/ERC20-Tokens: `0xFebF1bBc8229418FF2408C07AF6Afa49152fEc6a`
|
* ETH/BSC/ERC20-Tokens: `0xFebF1bBc8229418FF2408C07AF6Afa49152fEc6a`
|
||||||
@@ -57,6 +62,9 @@ See changelog in releases for latest updates!
|
|||||||
|
|
||||||
### Community apps included:
|
### Community apps included:
|
||||||
|
|
||||||
|
- RFID Fuzzer plugin [(by Ganapati)](https://github.com/Eng1n33r/flipperzero-firmware/pull/54) with changes by @xMasterX & New protocols by @mvanzanten
|
||||||
|
- Sub-GHz bruteforce plugin [(by Ganapati & xMasterX)](https://github.com/Eng1n33r/flipperzero-firmware/pull/57) & Refactored by @derskythe
|
||||||
|
- Sub-GHz playlist plugin [(by darmiel)](https://github.com/Eng1n33r/flipperzero-firmware/pull/62)
|
||||||
- ESP8266 Deauther plugin [(by SequoiaSan)](https://github.com/SequoiaSan/FlipperZero-Wifi-ESP8266-Deauther-Module)
|
- ESP8266 Deauther plugin [(by SequoiaSan)](https://github.com/SequoiaSan/FlipperZero-Wifi-ESP8266-Deauther-Module)
|
||||||
- WiFi Scanner plugin [(by SequoiaSan)](https://github.com/SequoiaSan/FlipperZero-WiFi-Scanner_Module)
|
- WiFi Scanner plugin [(by SequoiaSan)](https://github.com/SequoiaSan/FlipperZero-WiFi-Scanner_Module)
|
||||||
- MultiConverter plugin [(by theisolinearchip)](https://github.com/theisolinearchip/flipperzero_stuff)
|
- MultiConverter plugin [(by theisolinearchip)](https://github.com/theisolinearchip/flipperzero_stuff)
|
||||||
@@ -65,17 +73,26 @@ See changelog in releases for latest updates!
|
|||||||
- GPIO: Sentry Safe plugin [(by H4ckd4ddy)](https://github.com/H4ckd4ddy/flipperzero-sentry-safe-plugin)
|
- GPIO: Sentry Safe plugin [(by H4ckd4ddy)](https://github.com/H4ckd4ddy/flipperzero-sentry-safe-plugin)
|
||||||
- ESP32: WiFi Marauder companion plugin [(by 0xchocolate)](https://github.com/0xchocolate/flipperzero-firmware-with-wifi-marauder-companion)
|
- ESP32: WiFi Marauder companion plugin [(by 0xchocolate)](https://github.com/0xchocolate/flipperzero-firmware-with-wifi-marauder-companion)
|
||||||
- NRF24: Sniffer & MouseJacker (with changes) [(by mothball187)](https://github.com/mothball187/flipperzero-nrf24/tree/main/mousejacker)
|
- NRF24: Sniffer & MouseJacker (with changes) [(by mothball187)](https://github.com/mothball187/flipperzero-nrf24/tree/main/mousejacker)
|
||||||
- Simple Clock (fixed) [(Original by CompaqDisc)](https://gist.github.com/CompaqDisc/4e329c501bd03c1e801849b81f48ea61)
|
- Simple Clock (timer by GMMan / settings by kowalski7cc) [(Original by CompaqDisc)](https://gist.github.com/CompaqDisc/4e329c501bd03c1e801849b81f48ea61)
|
||||||
- UniversalRF Remix / Sub-GHz Remote [(by ESurge)](https://github.com/ESurge/flipperzero-firmware-unirfremix)[(updated and all protocol support added by darmiel & xMasterX)](https://github.com/darmiel/flipper-playlist/tree/feat/unirf-protocols)
|
- UniversalRF Remix / Sub-GHz Remote [(by ESurge)](https://github.com/ESurge/flipperzero-firmware-unirfremix)[(updated and all protocol support added by darmiel & xMasterX)](https://github.com/darmiel/flipper-playlist/tree/feat/unirf-protocols)
|
||||||
- Tetris (with fixes) [(by jeffplang)](https://github.com/jeffplang/flipperzero-firmware/tree/tetris_game/applications/tetris_game)
|
|
||||||
- Spectrum Analyzer (with changes) [(by jolcese)](https://github.com/jolcese/flipperzero-firmware/tree/spectrum/applications/spectrum_analyzer) - [Ultra Narrow mode & scan channels non-consecutively](https://github.com/theY4Kman/flipperzero-firmware/commits?author=theY4Kman)
|
- Spectrum Analyzer (with changes) [(by jolcese)](https://github.com/jolcese/flipperzero-firmware/tree/spectrum/applications/spectrum_analyzer) - [Ultra Narrow mode & scan channels non-consecutively](https://github.com/theY4Kman/flipperzero-firmware/commits?author=theY4Kman)
|
||||||
- Arkanoid (with fixes) [(by gotnull)](https://github.com/gotnull/flipperzero-firmware-wPlugins)
|
|
||||||
- Tic Tac Toe (with fixes) [(by gotnull)](https://github.com/gotnull/flipperzero-firmware-wPlugins)
|
Games:
|
||||||
|
- DOOM (fixed) [(By p4nic4ttack)](https://github.com/p4nic4ttack/doom-flipper-zero/)
|
||||||
|
- Zombiez [(Reworked By DevMilanIan)](https://github.com/RogueMaster/flipperzero-firmware-wPlugins/pull/240) [(Original By Dooskington)](https://github.com/Dooskington/flipperzero-zombiez)
|
||||||
|
- Flappy Bird [(By DroomOne)](https://github.com/DroomOne/flipperzero-firmware/tree/dev/applications/flappy_bird)
|
||||||
|
- Arkanoid (refactored by xMasterX) [(by gotnull)](https://github.com/gotnull/flipperzero-firmware-wPlugins)
|
||||||
|
- Tic Tac Toe (refactored by xMasterX) [(by gotnull)](https://github.com/gotnull/flipperzero-firmware-wPlugins)
|
||||||
|
- Tetris (with fixes) [(by jeffplang)](https://github.com/jeffplang/flipperzero-firmware/tree/tetris_game/applications/tetris_game)
|
||||||
|
|
||||||
### Other changes
|
### Other changes
|
||||||
|
|
||||||
- BadUSB Keyboard layouts [(by rien > dummy-decoy)](https://github.com/dummy-decoy/flipperzero-firmware/tree/dummy_decoy/bad_usb_keyboard_layout)
|
- BadUSB -> Keyboard layouts [(by rien > dummy-decoy)](https://github.com/dummy-decoy/flipperzero-firmware/tree/dummy_decoy/bad_usb_keyboard_layout)
|
||||||
- New frequency analyzer - [(by ClusterM)](https://github.com/ClusterM)
|
- SubGHz -> New frequency analyzer - [(by ClusterM)](https://github.com/Eng1n33r/flipperzero-firmware/pull/43)
|
||||||
|
- SubGHz -> Detect RAW feature - [(by perspecdev)](https://github.com/RogueMaster/flipperzero-firmware-wPlugins/pull/152)
|
||||||
|
- SubGHz -> Save last used frequency and moduluation [(by derskythe)](https://github.com/Eng1n33r/flipperzero-firmware/pull/77)
|
||||||
|
- SubGHz -> Press OK in frequency analyzer to use detected frequency in Read modes [(by derskythe)](https://github.com/Eng1n33r/flipperzero-firmware/pull/77)
|
||||||
|
* SubGHz -> Long press OK button in SubGHz Frequency analyzer to switch to Read menu [(by derskythe)](https://github.com/Eng1n33r/flipperzero-firmware/pull/79)
|
||||||
|
|
||||||
# Instructions
|
# Instructions
|
||||||
## [- How to install firmware](https://github.com/Eng1n33r/flipperzero-firmware/blob/dev/documentation/HowToInstall.md)
|
## [- How to install firmware](https://github.com/Eng1n33r/flipperzero-firmware/blob/dev/documentation/HowToInstall.md)
|
||||||
@@ -88,6 +105,8 @@ See changelog in releases for latest updates!
|
|||||||
|
|
||||||
### **Plugins**
|
### **Plugins**
|
||||||
|
|
||||||
|
## [- 🎲 Download Extra plugins for Unleashed](https://github.com/UberGuidoZ/Flipper/tree/main/Applications/Unleashed)
|
||||||
|
|
||||||
## [- Configure Sub-GHz Remote App](https://github.com/Eng1n33r/flipperzero-firmware/blob/dev/documentation/SubGHzRemotePlugin.md)
|
## [- Configure Sub-GHz Remote App](https://github.com/Eng1n33r/flipperzero-firmware/blob/dev/documentation/SubGHzRemotePlugin.md)
|
||||||
|
|
||||||
## [- Barcode Generator](https://github.com/Eng1n33r/flipperzero-firmware/blob/dev/documentation/BarcodeGenerator.md)
|
## [- Barcode Generator](https://github.com/Eng1n33r/flipperzero-firmware/blob/dev/documentation/BarcodeGenerator.md)
|
||||||
@@ -96,6 +115,8 @@ See changelog in releases for latest updates!
|
|||||||
|
|
||||||
## [- WAV Player sample files & how to convert](https://github.com/UberGuidoZ/Flipper/tree/main/Wav_Player#readme)
|
## [- WAV Player sample files & how to convert](https://github.com/UberGuidoZ/Flipper/tree/main/Wav_Player#readme)
|
||||||
|
|
||||||
|
## [- SubGHz playlist generator script](https://github.com/darmiel/flipper-scripts/blob/main/playlist/playlist_creator_by_chunk.py)
|
||||||
|
|
||||||
### **Plugins that works with external hardware**
|
### **Plugins that works with external hardware**
|
||||||
|
|
||||||
## [- How to use: [NRF24] plugins](https://github.com/Eng1n33r/flipperzero-firmware/blob/dev/documentation/NRF24.md)
|
## [- How to use: [NRF24] plugins](https://github.com/Eng1n33r/flipperzero-firmware/blob/dev/documentation/NRF24.md)
|
||||||
@@ -124,16 +145,17 @@ See changelog in releases for latest updates!
|
|||||||
<br>
|
<br>
|
||||||
|
|
||||||
# Where I can find IR, SubGhz, ... files, DBs, and other stuff?
|
# Where I can find IR, SubGhz, ... files, DBs, and other stuff?
|
||||||
## [Awesome Flipper Zero - Github](https://github.com/djsime1/awesome-flipperzero)
|
|
||||||
## [UberGuidoZ Playground - Large collection of files - Github](https://github.com/UberGuidoZ/Flipper)
|
## [UberGuidoZ Playground - Large collection of files - Github](https://github.com/UberGuidoZ/Flipper)
|
||||||
|
## [Awesome Flipper Zero - Github](https://github.com/djsime1/awesome-flipperzero)
|
||||||
## [CAME-12bit, NICE-12bit, Linear-10bit, PT-2240 - SubGHz fixed code bruteforce](https://github.com/tobiabocchi/flipperzero-bruteforce)
|
## [CAME-12bit, NICE-12bit, Linear-10bit, PT-2240 - SubGHz fixed code bruteforce](https://github.com/tobiabocchi/flipperzero-bruteforce)
|
||||||
|
## [SMC5326, UNILARM - SubGHz fixed code bruteforce](https://github.com/Hong5489/flipperzero-gate-bruteforce)
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
<br>
|
<br>
|
||||||
|
|
||||||
# Links
|
# Links
|
||||||
|
|
||||||
* Unofficial Discord: [discord.gg/58D6E8BtTU](https://discord.gg/58D6E8BtTU)
|
* Unofficial Discord: [discord.gg/flipperzero-unofficial](https://discord.gg/flipperzero-unofficial)
|
||||||
* Docs by atmanos / How to write your own app (outdated API): [https://flipper.atmanos.com/docs/overview/intro](https://flipper.atmanos.com/docs/overview/intro)
|
* Docs by atmanos / How to write your own app (outdated API): [https://flipper.atmanos.com/docs/overview/intro](https://flipper.atmanos.com/docs/overview/intro)
|
||||||
|
|
||||||
* Official Docs: [http://docs.flipperzero.one](http://docs.flipperzero.one)
|
* Official Docs: [http://docs.flipperzero.one](http://docs.flipperzero.one)
|
||||||
@@ -151,4 +173,4 @@ See changelog in releases for latest updates!
|
|||||||
- `site_scons` - Build helpers
|
- `site_scons` - Build helpers
|
||||||
- `scripts` - Supplementary scripts and python libraries home
|
- `scripts` - Supplementary scripts and python libraries home
|
||||||
|
|
||||||
Also pay attention to `ReadMe.md` files inside of those directories.
|
Also pay attention to `ReadMe.md` files inside those directories.
|
||||||
|
|||||||
41
SConstruct
41
SConstruct
@@ -9,9 +9,10 @@
|
|||||||
import os
|
import os
|
||||||
import subprocess
|
import subprocess
|
||||||
|
|
||||||
|
DefaultEnvironment(tools=[])
|
||||||
|
|
||||||
EnsurePythonVersion(3, 8)
|
EnsurePythonVersion(3, 8)
|
||||||
|
|
||||||
DefaultEnvironment(tools=[])
|
|
||||||
# Progress(["OwO\r", "owo\r", "uwu\r", "owo\r"], interval=15)
|
# Progress(["OwO\r", "owo\r", "uwu\r", "owo\r"], interval=15)
|
||||||
|
|
||||||
|
|
||||||
@@ -43,6 +44,8 @@ distenv = coreenv.Clone(
|
|||||||
"target extended-remote ${GDBREMOTE}",
|
"target extended-remote ${GDBREMOTE}",
|
||||||
"-ex",
|
"-ex",
|
||||||
"set confirm off",
|
"set confirm off",
|
||||||
|
"-ex",
|
||||||
|
"set pagination off",
|
||||||
],
|
],
|
||||||
GDBOPTS_BLACKMAGIC=[
|
GDBOPTS_BLACKMAGIC=[
|
||||||
"-ex",
|
"-ex",
|
||||||
@@ -58,6 +61,8 @@ distenv = coreenv.Clone(
|
|||||||
"-ex",
|
"-ex",
|
||||||
"source debug/FreeRTOS/FreeRTOS.py",
|
"source debug/FreeRTOS/FreeRTOS.py",
|
||||||
"-ex",
|
"-ex",
|
||||||
|
"source debug/flipperapps.py",
|
||||||
|
"-ex",
|
||||||
"source debug/PyCortexMDebug/PyCortexMDebug.py",
|
"source debug/PyCortexMDebug/PyCortexMDebug.py",
|
||||||
"-ex",
|
"-ex",
|
||||||
"svd_load ${SVD_FILE}",
|
"svd_load ${SVD_FILE}",
|
||||||
@@ -160,6 +165,28 @@ if GetOption("fullenv") or any(
|
|||||||
basic_dist = distenv.DistCommand("fw_dist", distenv["DIST_DEPENDS"])
|
basic_dist = distenv.DistCommand("fw_dist", distenv["DIST_DEPENDS"])
|
||||||
distenv.Default(basic_dist)
|
distenv.Default(basic_dist)
|
||||||
|
|
||||||
|
dist_dir = distenv.GetProjetDirName()
|
||||||
|
plugin_dist = [
|
||||||
|
distenv.Install(
|
||||||
|
f"#/dist/{dist_dir}/apps/debug_elf",
|
||||||
|
firmware_env["FW_EXTAPPS"]["debug"].values(),
|
||||||
|
),
|
||||||
|
*(
|
||||||
|
distenv.Install(f"#/dist/{dist_dir}/apps/{dist_entry[0]}", dist_entry[1])
|
||||||
|
for dist_entry in firmware_env["FW_EXTAPPS"]["dist"].values()
|
||||||
|
),
|
||||||
|
]
|
||||||
|
Depends(plugin_dist, firmware_env["FW_EXTAPPS"]["validators"].values())
|
||||||
|
Alias("plugin_dist", plugin_dist)
|
||||||
|
# distenv.Default(plugin_dist)
|
||||||
|
|
||||||
|
plugin_resources_dist = list(
|
||||||
|
distenv.Install(f"#/assets/resources/apps/{dist_entry[0]}", dist_entry[1])
|
||||||
|
for dist_entry in firmware_env["FW_EXTAPPS"]["dist"].values()
|
||||||
|
)
|
||||||
|
distenv.Depends(firmware_env["FW_RESOURCES"], plugin_resources_dist)
|
||||||
|
|
||||||
|
|
||||||
# Target for bundling core2 package for qFlipper
|
# Target for bundling core2 package for qFlipper
|
||||||
copro_dist = distenv.CoproBuilder(
|
copro_dist = distenv.CoproBuilder(
|
||||||
distenv.Dir("assets/core2_firmware"),
|
distenv.Dir("assets/core2_firmware"),
|
||||||
@@ -209,10 +236,19 @@ distenv.PhonyTarget(
|
|||||||
distenv.PhonyTarget(
|
distenv.PhonyTarget(
|
||||||
"debug_other",
|
"debug_other",
|
||||||
"${GDBPYCOM}",
|
"${GDBPYCOM}",
|
||||||
GDBPYOPTS='-ex "source debug/PyCortexMDebug/PyCortexMDebug.py" ',
|
GDBOPTS="${GDBOPTS_BASE}",
|
||||||
GDBREMOTE="${OPENOCD_GDB_PIPE}",
|
GDBREMOTE="${OPENOCD_GDB_PIPE}",
|
||||||
|
GDBPYOPTS='-ex "source debug/PyCortexMDebug/PyCortexMDebug.py" ',
|
||||||
)
|
)
|
||||||
|
|
||||||
|
distenv.PhonyTarget(
|
||||||
|
"debug_other_blackmagic",
|
||||||
|
"${GDBPYCOM}",
|
||||||
|
GDBOPTS="${GDBOPTS_BASE} ${GDBOPTS_BLACKMAGIC}",
|
||||||
|
GDBREMOTE="$${BLACKMAGIC_ADDR}",
|
||||||
|
)
|
||||||
|
|
||||||
|
|
||||||
# Just start OpenOCD
|
# Just start OpenOCD
|
||||||
distenv.PhonyTarget(
|
distenv.PhonyTarget(
|
||||||
"openocd",
|
"openocd",
|
||||||
@@ -240,7 +276,6 @@ firmware_env.Append(
|
|||||||
"site_scons",
|
"site_scons",
|
||||||
"scripts",
|
"scripts",
|
||||||
# Extra files
|
# Extra files
|
||||||
"applications/extapps.scons",
|
|
||||||
"SConstruct",
|
"SConstruct",
|
||||||
"firmware.scons",
|
"firmware.scons",
|
||||||
"fbt_options.py",
|
"fbt_options.py",
|
||||||
|
|||||||
@@ -1,38 +1,89 @@
|
|||||||
# Structure
|
# Structure
|
||||||
|
|
||||||
- `about` - Small About application that shows flipper info
|
## debug
|
||||||
- `accessor` - Wiegand server
|
|
||||||
|
Applications for factory testing the Flipper.
|
||||||
|
|
||||||
|
- `accessor` - Wiegand server
|
||||||
|
- `battery_test_app` - Battery debug app
|
||||||
|
- `blink_test` - LED blinker
|
||||||
|
- `bt_debug_app` - BT test app. Requires full BT stack installed
|
||||||
|
- `display_test` - Various display tests & tweaks
|
||||||
|
- `file_browser_test` - Test UI for file picker
|
||||||
|
- `keypad_test` - Keypad test
|
||||||
|
- `lfrfid_debug` - LF RFID debug tool
|
||||||
|
- `text_box_test` - UI tests
|
||||||
|
- `uart_echo` - UART mode test
|
||||||
|
- `unit_tests` - Unit tests
|
||||||
|
- `usb_mouse` - USB HID test
|
||||||
|
- `usb_test` - Other USB tests
|
||||||
|
- `vibro_test` - Vibro test
|
||||||
|
|
||||||
|
|
||||||
|
## main
|
||||||
|
|
||||||
|
Applications for main Flipper menu.
|
||||||
|
|
||||||
- `archive` - Archive and file manager
|
- `archive` - Archive and file manager
|
||||||
- `bad_usb` - Bad USB application
|
- `bad_usb` - Bad USB application
|
||||||
|
- `fap_loader` - External applications loader
|
||||||
|
- `gpio` - GPIO application: includes USART bridge and GPIO control
|
||||||
|
- `ibutton` - iButton application, onewire keys and more
|
||||||
|
- `infrared` - Infrared application, controls your IR devices
|
||||||
|
- `lfrfid` - LF RFID application
|
||||||
|
- `nfc` - NFC application, HF rfid, EMV and etc
|
||||||
|
- `subghz` - SubGhz application, 433 fobs and etc
|
||||||
|
- `u2f` - U2F Application
|
||||||
|
|
||||||
|
|
||||||
|
## plugins
|
||||||
|
|
||||||
|
Extra apps for Plugins & App Loader menus.
|
||||||
|
|
||||||
|
- `bt_hid_app` - BT Remote controller
|
||||||
|
- `music_player` - Music player app (demo)
|
||||||
|
- `picopass` - Picopass tool
|
||||||
|
- `snake_game` - Snake game application
|
||||||
|
|
||||||
|
|
||||||
|
## services
|
||||||
|
|
||||||
|
Background services providing system APIs to applications.
|
||||||
|
|
||||||
|
- `applications.h` - Firmware application list header
|
||||||
|
|
||||||
- `bt` - BLE service and application
|
- `bt` - BLE service and application
|
||||||
- `cli` - Console service and API
|
- `cli` - Console service and API
|
||||||
- `crypto` - Crypto cli tools
|
- `crypto` - Crypto cli tools
|
||||||
- `debug_tools` - Different tools that we use for debug
|
|
||||||
- `desktop` - Desktop service
|
- `desktop` - Desktop service
|
||||||
- `dialogs` - Dialogs service: GUI Dialogs for your app
|
- `dialogs` - Dialogs service: GUI Dialogs for your app
|
||||||
- `dolphin` - Dolphin service and supplementary apps
|
- `dolphin` - Dolphin service and supplementary apps
|
||||||
- `gpio` - GPIO application: includes USART bridge and GPIO control
|
|
||||||
- `gui` - GUI service and API
|
- `gui` - GUI service and API
|
||||||
- `ibutton` - iButton application, onewire keys and more
|
|
||||||
- `input` - Input service
|
- `input` - Input service
|
||||||
- `infrared` - Infrared application, controls your IR devices
|
|
||||||
- `lfrfid` - LF RFID application
|
|
||||||
- `lfrfid_debug` - LF RFID debug tool
|
|
||||||
- `loader` - Application loader service
|
- `loader` - Application loader service
|
||||||
- `music_player` - Music player app (demo)
|
|
||||||
- `nfc` - NFC application, HF rfid, EMV and etc
|
|
||||||
- `notification` - Notification service
|
- `notification` - Notification service
|
||||||
- `power` - Power service
|
- `power` - Power service
|
||||||
- `power_observer` - Power debug tool
|
|
||||||
- `rpc` - RPC service and API
|
- `rpc` - RPC service and API
|
||||||
- `scened_app_example` - C++ application example
|
|
||||||
- `snake_game` - Snake game application
|
|
||||||
- `storage` - Storage service, internal + sdcard
|
- `storage` - Storage service, internal + sdcard
|
||||||
- `storage_settings` - Storage settings app
|
|
||||||
- `subghz` - SubGhz application, 433 fobs and etc
|
|
||||||
- `system` - System settings, tools and API
|
|
||||||
- `tests` - Unit tests and etc
|
|
||||||
- `u2f` - U2F Application
|
|
||||||
- `updater` - Update service & application
|
|
||||||
|
|
||||||
- `application.h` - Firmware application list header
|
|
||||||
|
## settings
|
||||||
|
|
||||||
|
Small applications providing configuration for basic firmware and its services.
|
||||||
|
|
||||||
|
- `about` - Small About application that shows flipper info
|
||||||
|
- `bt_settings_app` - Bluetooth options
|
||||||
|
- `desktop_settings` - Desktop configuration
|
||||||
|
- `dolphin_passport` - Dolphin passport app
|
||||||
|
- `notification_settings` - LCD brightness, sound volume, etc configuration
|
||||||
|
- `power_settings_app` - Basic power options
|
||||||
|
- `storage_settings` - Storage settings app
|
||||||
|
- `system` - System settings
|
||||||
|
|
||||||
|
|
||||||
|
## system
|
||||||
|
|
||||||
|
Utility apps not visible in other menus.
|
||||||
|
|
||||||
|
- `storage_move_to_sd` - Data migration tool for internal storage
|
||||||
|
- `updater` - Update service & application
|
||||||
|
|||||||
@@ -1,79 +0,0 @@
|
|||||||
#include "archive_i.h"
|
|
||||||
#include "m-string.h"
|
|
||||||
|
|
||||||
bool archive_custom_event_callback(void* context, uint32_t event) {
|
|
||||||
furi_assert(context);
|
|
||||||
ArchiveApp* archive = (ArchiveApp*)context;
|
|
||||||
return scene_manager_handle_custom_event(archive->scene_manager, event);
|
|
||||||
}
|
|
||||||
|
|
||||||
bool archive_back_event_callback(void* context) {
|
|
||||||
furi_assert(context);
|
|
||||||
ArchiveApp* archive = (ArchiveApp*)context;
|
|
||||||
return scene_manager_handle_back_event(archive->scene_manager);
|
|
||||||
}
|
|
||||||
|
|
||||||
ArchiveApp* archive_alloc() {
|
|
||||||
ArchiveApp* archive = malloc(sizeof(ArchiveApp));
|
|
||||||
|
|
||||||
archive->gui = furi_record_open(RECORD_GUI);
|
|
||||||
archive->text_input = text_input_alloc();
|
|
||||||
string_init(archive->fav_move_str);
|
|
||||||
|
|
||||||
archive->view_dispatcher = view_dispatcher_alloc();
|
|
||||||
archive->scene_manager = scene_manager_alloc(&archive_scene_handlers, archive);
|
|
||||||
|
|
||||||
view_dispatcher_enable_queue(archive->view_dispatcher);
|
|
||||||
view_dispatcher_attach_to_gui(
|
|
||||||
archive->view_dispatcher, archive->gui, ViewDispatcherTypeFullscreen);
|
|
||||||
|
|
||||||
view_dispatcher_set_event_callback_context(archive->view_dispatcher, archive);
|
|
||||||
view_dispatcher_set_custom_event_callback(
|
|
||||||
archive->view_dispatcher, archive_custom_event_callback);
|
|
||||||
view_dispatcher_set_navigation_event_callback(
|
|
||||||
archive->view_dispatcher, archive_back_event_callback);
|
|
||||||
|
|
||||||
archive->browser = browser_alloc();
|
|
||||||
|
|
||||||
view_dispatcher_add_view(
|
|
||||||
archive->view_dispatcher, ArchiveViewBrowser, archive_browser_get_view(archive->browser));
|
|
||||||
|
|
||||||
view_dispatcher_add_view(
|
|
||||||
archive->view_dispatcher, ArchiveViewTextInput, text_input_get_view(archive->text_input));
|
|
||||||
|
|
||||||
archive->widget = widget_alloc();
|
|
||||||
view_dispatcher_add_view(
|
|
||||||
archive->view_dispatcher, ArchiveViewWidget, widget_get_view(archive->widget));
|
|
||||||
|
|
||||||
return archive;
|
|
||||||
}
|
|
||||||
|
|
||||||
void archive_free(ArchiveApp* archive) {
|
|
||||||
furi_assert(archive);
|
|
||||||
|
|
||||||
view_dispatcher_remove_view(archive->view_dispatcher, ArchiveViewBrowser);
|
|
||||||
view_dispatcher_remove_view(archive->view_dispatcher, ArchiveViewTextInput);
|
|
||||||
view_dispatcher_remove_view(archive->view_dispatcher, ArchiveViewWidget);
|
|
||||||
widget_free(archive->widget);
|
|
||||||
view_dispatcher_free(archive->view_dispatcher);
|
|
||||||
scene_manager_free(archive->scene_manager);
|
|
||||||
browser_free(archive->browser);
|
|
||||||
string_clear(archive->fav_move_str);
|
|
||||||
|
|
||||||
text_input_free(archive->text_input);
|
|
||||||
|
|
||||||
furi_record_close(RECORD_GUI);
|
|
||||||
archive->gui = NULL;
|
|
||||||
|
|
||||||
free(archive);
|
|
||||||
}
|
|
||||||
|
|
||||||
int32_t archive_app(void* p) {
|
|
||||||
UNUSED(p);
|
|
||||||
ArchiveApp* archive = archive_alloc();
|
|
||||||
scene_manager_next_scene(archive->scene_manager, ArchiveAppSceneBrowser);
|
|
||||||
view_dispatcher_run(archive->view_dispatcher);
|
|
||||||
archive_free(archive);
|
|
||||||
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
@@ -1,89 +0,0 @@
|
|||||||
#include "../archive_i.h"
|
|
||||||
#include "../helpers/archive_favorites.h"
|
|
||||||
#include "../helpers/archive_files.h"
|
|
||||||
#include "../helpers/archive_browser.h"
|
|
||||||
#include "archive/views/archive_browser_view.h"
|
|
||||||
#include "toolbox/path.h"
|
|
||||||
|
|
||||||
#define SCENE_RENAME_CUSTOM_EVENT (0UL)
|
|
||||||
#define MAX_TEXT_INPUT_LEN 22
|
|
||||||
|
|
||||||
void archive_scene_rename_text_input_callback(void* context) {
|
|
||||||
ArchiveApp* archive = (ArchiveApp*)context;
|
|
||||||
view_dispatcher_send_custom_event(archive->view_dispatcher, SCENE_RENAME_CUSTOM_EVENT);
|
|
||||||
}
|
|
||||||
|
|
||||||
void archive_scene_rename_on_enter(void* context) {
|
|
||||||
ArchiveApp* archive = (ArchiveApp*)context;
|
|
||||||
|
|
||||||
TextInput* text_input = archive->text_input;
|
|
||||||
ArchiveFile_t* current = archive_get_current_file(archive->browser);
|
|
||||||
|
|
||||||
string_t filename;
|
|
||||||
string_init(filename);
|
|
||||||
path_extract_filename(current->path, filename, true);
|
|
||||||
strlcpy(archive->text_store, string_get_cstr(filename), MAX_NAME_LEN);
|
|
||||||
|
|
||||||
path_extract_extension(current->path, archive->file_extension, MAX_EXT_LEN);
|
|
||||||
|
|
||||||
text_input_set_header_text(text_input, "Rename:");
|
|
||||||
|
|
||||||
text_input_set_result_callback(
|
|
||||||
text_input,
|
|
||||||
archive_scene_rename_text_input_callback,
|
|
||||||
archive,
|
|
||||||
archive->text_store,
|
|
||||||
MAX_TEXT_INPUT_LEN,
|
|
||||||
false);
|
|
||||||
|
|
||||||
ValidatorIsFile* validator_is_file = validator_is_file_alloc_init(
|
|
||||||
string_get_cstr(archive->browser->path), archive->file_extension, "");
|
|
||||||
text_input_set_validator(text_input, validator_is_file_callback, validator_is_file);
|
|
||||||
|
|
||||||
string_clear(filename);
|
|
||||||
|
|
||||||
view_dispatcher_switch_to_view(archive->view_dispatcher, ArchiveViewTextInput);
|
|
||||||
}
|
|
||||||
|
|
||||||
bool archive_scene_rename_on_event(void* context, SceneManagerEvent event) {
|
|
||||||
ArchiveApp* archive = (ArchiveApp*)context;
|
|
||||||
bool consumed = false;
|
|
||||||
|
|
||||||
if(event.type == SceneManagerEventTypeCustom) {
|
|
||||||
if(event.event == SCENE_RENAME_CUSTOM_EVENT) {
|
|
||||||
Storage* fs_api = furi_record_open(RECORD_STORAGE);
|
|
||||||
|
|
||||||
const char* path_src = archive_get_name(archive->browser);
|
|
||||||
ArchiveFile_t* file = archive_get_current_file(archive->browser);
|
|
||||||
|
|
||||||
string_t path_dst;
|
|
||||||
string_init(path_dst);
|
|
||||||
path_extract_dirname(path_src, path_dst);
|
|
||||||
string_cat_printf(path_dst, "/%s%s", archive->text_store, known_ext[file->type]);
|
|
||||||
|
|
||||||
storage_common_rename(fs_api, path_src, string_get_cstr(path_dst));
|
|
||||||
furi_record_close(RECORD_STORAGE);
|
|
||||||
|
|
||||||
if(file->fav) {
|
|
||||||
archive_favorites_rename(path_src, string_get_cstr(path_dst));
|
|
||||||
}
|
|
||||||
|
|
||||||
string_clear(path_dst);
|
|
||||||
|
|
||||||
scene_manager_next_scene(archive->scene_manager, ArchiveAppSceneBrowser);
|
|
||||||
consumed = true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return consumed;
|
|
||||||
}
|
|
||||||
|
|
||||||
void archive_scene_rename_on_exit(void* context) {
|
|
||||||
ArchiveApp* archive = (ArchiveApp*)context;
|
|
||||||
|
|
||||||
// Clear view
|
|
||||||
void* validator_context = text_input_get_validator_callback_context(archive->text_input);
|
|
||||||
text_input_set_validator(archive->text_input, NULL, NULL);
|
|
||||||
validator_is_file_free(validator_context);
|
|
||||||
|
|
||||||
text_input_reset(archive->text_input);
|
|
||||||
}
|
|
||||||
@@ -1,10 +0,0 @@
|
|||||||
App(
|
|
||||||
appid="arkanoid_game",
|
|
||||||
name="Arkanoid",
|
|
||||||
apptype=FlipperAppType.GAME,
|
|
||||||
entry_point="arkanoid_game_app",
|
|
||||||
cdefines=["APP_ARKANOID_GAME"],
|
|
||||||
requires=["gui"],
|
|
||||||
stack_size=4 * 1024,
|
|
||||||
order=30,
|
|
||||||
)
|
|
||||||
@@ -1,66 +0,0 @@
|
|||||||
App(
|
|
||||||
appid="bt",
|
|
||||||
name="BtSrv",
|
|
||||||
apptype=FlipperAppType.SERVICE,
|
|
||||||
entry_point="bt_srv",
|
|
||||||
cdefines=["SRV_BT"],
|
|
||||||
requires=[
|
|
||||||
"cli",
|
|
||||||
"dialogs",
|
|
||||||
],
|
|
||||||
provides=[
|
|
||||||
"bt_start",
|
|
||||||
"bt_settings",
|
|
||||||
"bt_debug",
|
|
||||||
],
|
|
||||||
stack_size=1 * 1024,
|
|
||||||
order=20,
|
|
||||||
)
|
|
||||||
|
|
||||||
App(
|
|
||||||
appid="bt_start",
|
|
||||||
apptype=FlipperAppType.STARTUP,
|
|
||||||
entry_point="bt_on_system_start",
|
|
||||||
order=70,
|
|
||||||
)
|
|
||||||
|
|
||||||
App(
|
|
||||||
appid="bt_settings",
|
|
||||||
name="Bluetooth",
|
|
||||||
apptype=FlipperAppType.SETTINGS,
|
|
||||||
entry_point="bt_settings_app",
|
|
||||||
stack_size=1 * 1024,
|
|
||||||
requires=[
|
|
||||||
"bt",
|
|
||||||
"gui",
|
|
||||||
],
|
|
||||||
order=10,
|
|
||||||
)
|
|
||||||
|
|
||||||
App(
|
|
||||||
appid="bt_debug",
|
|
||||||
name="Bluetooth Debug",
|
|
||||||
apptype=FlipperAppType.DEBUG,
|
|
||||||
entry_point="bt_debug_app",
|
|
||||||
stack_size=1 * 1024,
|
|
||||||
requires=[
|
|
||||||
"bt",
|
|
||||||
"gui",
|
|
||||||
"dialogs",
|
|
||||||
],
|
|
||||||
order=110,
|
|
||||||
)
|
|
||||||
|
|
||||||
App(
|
|
||||||
appid="bt_hid",
|
|
||||||
name="Bluetooth Remote",
|
|
||||||
apptype=FlipperAppType.PLUGIN,
|
|
||||||
entry_point="bt_hid_app",
|
|
||||||
stack_size=1 * 1024,
|
|
||||||
cdefines=["APP_BLE_HID"],
|
|
||||||
requires=[
|
|
||||||
"bt",
|
|
||||||
"gui",
|
|
||||||
],
|
|
||||||
order=10,
|
|
||||||
)
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
App(
|
|
||||||
appid="clock",
|
|
||||||
name="Clock",
|
|
||||||
apptype=FlipperAppType.APP,
|
|
||||||
entry_point="clock_app",
|
|
||||||
cdefines=["APP_CLOCK"],
|
|
||||||
requires=["gui"],
|
|
||||||
icon="A_Clock_14",
|
|
||||||
stack_size=2 * 1024,
|
|
||||||
order=9,
|
|
||||||
)
|
|
||||||
@@ -1,146 +0,0 @@
|
|||||||
#include <furi.h>
|
|
||||||
#include <furi_hal.h>
|
|
||||||
|
|
||||||
#include <gui/elements.h>
|
|
||||||
|
|
||||||
#include <gui/gui.h>
|
|
||||||
#include <input/input.h>
|
|
||||||
|
|
||||||
#define TAG "Clock"
|
|
||||||
#define CLOCK_DATE_FORMAT "%.4d-%.2d-%.2d"
|
|
||||||
#define CLOCK_TIME_FORMAT "%.2d:%.2d:%.2d"
|
|
||||||
|
|
||||||
typedef enum {
|
|
||||||
EventTypeTick,
|
|
||||||
EventTypeKey,
|
|
||||||
} EventType;
|
|
||||||
|
|
||||||
typedef struct {
|
|
||||||
EventType type;
|
|
||||||
InputEvent input;
|
|
||||||
} PluginEvent;
|
|
||||||
|
|
||||||
typedef struct {
|
|
||||||
FuriHalRtcDateTime datetime;
|
|
||||||
} ClockState;
|
|
||||||
|
|
||||||
static void clock_input_callback(InputEvent* input_event, FuriMessageQueue* event_queue) {
|
|
||||||
furi_assert(event_queue);
|
|
||||||
|
|
||||||
PluginEvent event = {.type = EventTypeKey, .input = *input_event};
|
|
||||||
furi_message_queue_put(event_queue, &event, FuriWaitForever);
|
|
||||||
}
|
|
||||||
|
|
||||||
static void clock_render_callback(Canvas* const canvas, void* ctx) {
|
|
||||||
canvas_clear(canvas);
|
|
||||||
canvas_set_color(canvas, ColorBlack);
|
|
||||||
|
|
||||||
ClockState* state = (ClockState*)acquire_mutex((ValueMutex*)ctx, 25);
|
|
||||||
|
|
||||||
char strings[2][20];
|
|
||||||
|
|
||||||
snprintf(
|
|
||||||
strings[0],
|
|
||||||
sizeof(strings[0]),
|
|
||||||
CLOCK_DATE_FORMAT,
|
|
||||||
state->datetime.year,
|
|
||||||
state->datetime.month,
|
|
||||||
state->datetime.day);
|
|
||||||
snprintf(
|
|
||||||
strings[1],
|
|
||||||
sizeof(strings[1]),
|
|
||||||
CLOCK_TIME_FORMAT,
|
|
||||||
state->datetime.hour,
|
|
||||||
state->datetime.minute,
|
|
||||||
state->datetime.second);
|
|
||||||
|
|
||||||
release_mutex((ValueMutex*)ctx, state);
|
|
||||||
canvas_set_font(canvas, FontBigNumbers);
|
|
||||||
canvas_draw_str_aligned(canvas, 64, 42 - 16, AlignCenter, AlignCenter, strings[1]);
|
|
||||||
canvas_set_font(canvas, FontSecondary);
|
|
||||||
canvas_draw_str_aligned(canvas, 64, 52 - 8, AlignCenter, AlignTop, strings[0]);
|
|
||||||
}
|
|
||||||
|
|
||||||
static void clock_state_init(ClockState* const state) {
|
|
||||||
furi_hal_rtc_get_datetime(&state->datetime);
|
|
||||||
}
|
|
||||||
|
|
||||||
// Runs every 1000ms by default
|
|
||||||
static void clock_tick(void* ctx) {
|
|
||||||
furi_assert(ctx);
|
|
||||||
FuriMessageQueue* event_queue = ctx;
|
|
||||||
PluginEvent event = {.type = EventTypeTick};
|
|
||||||
// It's OK to loose this event if system overloaded
|
|
||||||
furi_message_queue_put(event_queue, &event, 0);
|
|
||||||
}
|
|
||||||
|
|
||||||
int32_t clock_app(void* p) {
|
|
||||||
UNUSED(p);
|
|
||||||
FuriMessageQueue* event_queue = furi_message_queue_alloc(8, sizeof(PluginEvent));
|
|
||||||
|
|
||||||
ClockState* plugin_state = malloc(sizeof(ClockState));
|
|
||||||
clock_state_init(plugin_state);
|
|
||||||
ValueMutex state_mutex;
|
|
||||||
if(!init_mutex(&state_mutex, plugin_state, sizeof(ClockState))) {
|
|
||||||
FURI_LOG_E(TAG, "cannot create mutex\r\n");
|
|
||||||
furi_message_queue_free(event_queue);
|
|
||||||
free(plugin_state);
|
|
||||||
return 255;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Set system callbacks
|
|
||||||
ViewPort* view_port = view_port_alloc();
|
|
||||||
view_port_draw_callback_set(view_port, clock_render_callback, &state_mutex);
|
|
||||||
view_port_input_callback_set(view_port, clock_input_callback, event_queue);
|
|
||||||
FuriTimer* timer = furi_timer_alloc(clock_tick, FuriTimerTypePeriodic, event_queue);
|
|
||||||
furi_timer_start(timer, furi_kernel_get_tick_frequency());
|
|
||||||
|
|
||||||
// Open GUI and register view_port
|
|
||||||
Gui* gui = furi_record_open(RECORD_GUI);
|
|
||||||
gui_add_view_port(gui, view_port, GuiLayerFullscreen);
|
|
||||||
|
|
||||||
// Main loop
|
|
||||||
PluginEvent event;
|
|
||||||
for(bool processing = true; processing;) {
|
|
||||||
FuriStatus event_status = furi_message_queue_get(event_queue, &event, 100);
|
|
||||||
ClockState* plugin_state = (ClockState*)acquire_mutex_block(&state_mutex);
|
|
||||||
|
|
||||||
if(event_status == FuriStatusOk) {
|
|
||||||
// press events
|
|
||||||
if(event.type == EventTypeKey) {
|
|
||||||
if(event.input.type == InputTypeShort || event.input.type == InputTypeRepeat) {
|
|
||||||
switch(event.input.key) {
|
|
||||||
case InputKeyUp:
|
|
||||||
case InputKeyDown:
|
|
||||||
case InputKeyRight:
|
|
||||||
case InputKeyLeft:
|
|
||||||
case InputKeyOk:
|
|
||||||
break;
|
|
||||||
case InputKeyBack:
|
|
||||||
// Exit the plugin
|
|
||||||
processing = false;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} else if(event.type == EventTypeTick) {
|
|
||||||
furi_hal_rtc_get_datetime(&plugin_state->datetime);
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
FURI_LOG_D(TAG, "furi_message_queue: event timeout");
|
|
||||||
// event timeout
|
|
||||||
}
|
|
||||||
|
|
||||||
view_port_update(view_port);
|
|
||||||
release_mutex(&state_mutex, plugin_state);
|
|
||||||
}
|
|
||||||
|
|
||||||
furi_timer_free(timer);
|
|
||||||
view_port_enabled_set(view_port, false);
|
|
||||||
gui_remove_view_port(gui, view_port);
|
|
||||||
furi_record_close(RECORD_GUI);
|
|
||||||
view_port_free(view_port);
|
|
||||||
furi_message_queue_free(event_queue);
|
|
||||||
delete_mutex(&state_mutex);
|
|
||||||
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
@@ -7,4 +7,5 @@ App(
|
|||||||
requires=["gui"],
|
requires=["gui"],
|
||||||
stack_size=4 * 1024,
|
stack_size=4 * 1024,
|
||||||
order=40,
|
order=40,
|
||||||
|
fap_category="Debug",
|
||||||
)
|
)
|
||||||
16
applications/debug/application.fam
Normal file
16
applications/debug/application.fam
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
App(
|
||||||
|
appid="debug_apps",
|
||||||
|
name="Basic debug apps bundle",
|
||||||
|
apptype=FlipperAppType.METAPACKAGE,
|
||||||
|
provides=[
|
||||||
|
"blink_test",
|
||||||
|
"vibro_test",
|
||||||
|
"keypad_test",
|
||||||
|
"usb_test",
|
||||||
|
"USB_Mouse",
|
||||||
|
"UART_Echo",
|
||||||
|
"display_test",
|
||||||
|
"text_box_test",
|
||||||
|
"file_browser_test",
|
||||||
|
],
|
||||||
|
)
|
||||||
14
applications/debug/battery_test_app/application.fam
Normal file
14
applications/debug/battery_test_app/application.fam
Normal file
@@ -0,0 +1,14 @@
|
|||||||
|
App(
|
||||||
|
appid="battery_test",
|
||||||
|
name="Battery Test",
|
||||||
|
apptype=FlipperAppType.DEBUG,
|
||||||
|
entry_point="battery_test_app",
|
||||||
|
cdefines=["APP_BATTERY_TEST"],
|
||||||
|
requires=[
|
||||||
|
"gui",
|
||||||
|
"power",
|
||||||
|
],
|
||||||
|
stack_size=1 * 1024,
|
||||||
|
order=130,
|
||||||
|
fap_category="Debug",
|
||||||
|
)
|
||||||
@@ -27,7 +27,7 @@ static void battery_test_battery_info_update_model(void* context) {
|
|||||||
.charge = app->info.charge,
|
.charge = app->info.charge,
|
||||||
.health = app->info.health,
|
.health = app->info.health,
|
||||||
};
|
};
|
||||||
battery_info_set_data(app->batery_info, &battery_info_data);
|
battery_info_set_data(app->battery_info, &battery_info_data);
|
||||||
notification_message(app->notifications, &sequence_display_backlight_on);
|
notification_message(app->notifications, &sequence_display_backlight_on);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -48,13 +48,13 @@ BatteryTestApp* battery_test_alloc() {
|
|||||||
view_dispatcher_attach_to_gui(app->view_dispatcher, app->gui, ViewDispatcherTypeFullscreen);
|
view_dispatcher_attach_to_gui(app->view_dispatcher, app->gui, ViewDispatcherTypeFullscreen);
|
||||||
|
|
||||||
// Views
|
// Views
|
||||||
app->batery_info = battery_info_alloc();
|
app->battery_info = battery_info_alloc();
|
||||||
view_set_previous_callback(
|
view_set_previous_callback(
|
||||||
battery_info_get_view(app->batery_info), battery_test_exit_confirm_view);
|
battery_info_get_view(app->battery_info), battery_test_exit_confirm_view);
|
||||||
view_dispatcher_add_view(
|
view_dispatcher_add_view(
|
||||||
app->view_dispatcher,
|
app->view_dispatcher,
|
||||||
BatteryTestAppViewBatteryInfo,
|
BatteryTestAppViewBatteryInfo,
|
||||||
battery_info_get_view(app->batery_info));
|
battery_info_get_view(app->battery_info));
|
||||||
|
|
||||||
app->dialog = dialog_ex_alloc();
|
app->dialog = dialog_ex_alloc();
|
||||||
dialog_ex_set_header(app->dialog, "Close Battery Test?", 64, 12, AlignCenter, AlignTop);
|
dialog_ex_set_header(app->dialog, "Close Battery Test?", 64, 12, AlignCenter, AlignTop);
|
||||||
@@ -76,7 +76,7 @@ void battery_test_free(BatteryTestApp* app) {
|
|||||||
|
|
||||||
// Views
|
// Views
|
||||||
view_dispatcher_remove_view(app->view_dispatcher, BatteryTestAppViewBatteryInfo);
|
view_dispatcher_remove_view(app->view_dispatcher, BatteryTestAppViewBatteryInfo);
|
||||||
battery_info_free(app->batery_info);
|
battery_info_free(app->battery_info);
|
||||||
view_dispatcher_remove_view(app->view_dispatcher, BatteryTestAppViewExitDialog);
|
view_dispatcher_remove_view(app->view_dispatcher, BatteryTestAppViewExitDialog);
|
||||||
dialog_ex_free(app->dialog);
|
dialog_ex_free(app->dialog);
|
||||||
// View dispatcher
|
// View dispatcher
|
||||||
@@ -6,14 +6,15 @@
|
|||||||
#include <notification/notification.h>
|
#include <notification/notification.h>
|
||||||
|
|
||||||
#include <gui/modules/dialog_ex.h>
|
#include <gui/modules/dialog_ex.h>
|
||||||
#include <power/power_settings_app/views/battery_info.h>
|
// FIXME
|
||||||
|
#include "../settings/power_settings_app/views/battery_info.h"
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
Power* power;
|
Power* power;
|
||||||
Gui* gui;
|
Gui* gui;
|
||||||
NotificationApp* notifications;
|
NotificationApp* notifications;
|
||||||
ViewDispatcher* view_dispatcher;
|
ViewDispatcher* view_dispatcher;
|
||||||
BatteryInfo* batery_info;
|
BatteryInfo* battery_info;
|
||||||
DialogEx* dialog;
|
DialogEx* dialog;
|
||||||
PowerInfo info;
|
PowerInfo info;
|
||||||
} BatteryTestApp;
|
} BatteryTestApp;
|
||||||
11
applications/debug/blink_test/application.fam
Normal file
11
applications/debug/blink_test/application.fam
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
App(
|
||||||
|
appid="blink_test",
|
||||||
|
name="Blink Test",
|
||||||
|
apptype=FlipperAppType.DEBUG,
|
||||||
|
entry_point="blink_test_app",
|
||||||
|
cdefines=["APP_BLINK"],
|
||||||
|
requires=["gui"],
|
||||||
|
stack_size=1 * 1024,
|
||||||
|
order=10,
|
||||||
|
fap_category="Debug",
|
||||||
|
)
|
||||||
18
applications/debug/bt_debug_app/application.fam
Normal file
18
applications/debug/bt_debug_app/application.fam
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
App(
|
||||||
|
appid="bt_debug",
|
||||||
|
name="Bluetooth Debug",
|
||||||
|
apptype=FlipperAppType.DEBUG,
|
||||||
|
entry_point="bt_debug_app",
|
||||||
|
cdefines=["SRV_BT"],
|
||||||
|
requires=[
|
||||||
|
"bt",
|
||||||
|
"gui",
|
||||||
|
"dialogs",
|
||||||
|
],
|
||||||
|
provides=[
|
||||||
|
"bt_debug",
|
||||||
|
],
|
||||||
|
stack_size=1 * 1024,
|
||||||
|
order=110,
|
||||||
|
fap_category="Debug",
|
||||||
|
)
|
||||||
@@ -9,7 +9,7 @@
|
|||||||
#include <gui/modules/submenu.h>
|
#include <gui/modules/submenu.h>
|
||||||
#include "views/bt_carrier_test.h"
|
#include "views/bt_carrier_test.h"
|
||||||
#include "views/bt_packet_test.h"
|
#include "views/bt_packet_test.h"
|
||||||
#include "../bt_settings.h"
|
#include <bt/bt_settings.h>
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
BtSettings settings;
|
BtSettings settings;
|
||||||
11
applications/debug/display_test/application.fam
Normal file
11
applications/debug/display_test/application.fam
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
App(
|
||||||
|
appid="display_test",
|
||||||
|
name="Display Test",
|
||||||
|
apptype=FlipperAppType.DEBUG,
|
||||||
|
entry_point="display_test_app",
|
||||||
|
cdefines=["APP_DISPLAY_TEST"],
|
||||||
|
requires=["gui"],
|
||||||
|
stack_size=1 * 1024,
|
||||||
|
order=120,
|
||||||
|
fap_category="Debug",
|
||||||
|
)
|
||||||
11
applications/debug/file_browser_test/application.fam
Normal file
11
applications/debug/file_browser_test/application.fam
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
App(
|
||||||
|
appid="file_browser_test",
|
||||||
|
name="File Browser Test",
|
||||||
|
apptype=FlipperAppType.DEBUG,
|
||||||
|
entry_point="file_browser_app",
|
||||||
|
cdefines=["APP_FILE_BROWSER_TEST"],
|
||||||
|
requires=["gui"],
|
||||||
|
stack_size=2 * 1024,
|
||||||
|
order=150,
|
||||||
|
fap_category="Debug",
|
||||||
|
)
|
||||||
11
applications/debug/keypad_test/application.fam
Normal file
11
applications/debug/keypad_test/application.fam
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
App(
|
||||||
|
appid="keypad_test",
|
||||||
|
name="Keypad Test",
|
||||||
|
apptype=FlipperAppType.DEBUG,
|
||||||
|
entry_point="keypad_test_app",
|
||||||
|
cdefines=["APP_KEYPAD_TEST"],
|
||||||
|
requires=["gui"],
|
||||||
|
stack_size=1 * 1024,
|
||||||
|
order=30,
|
||||||
|
fap_category="Debug",
|
||||||
|
)
|
||||||
@@ -5,8 +5,11 @@ App(
|
|||||||
entry_point="lfrfid_debug_app",
|
entry_point="lfrfid_debug_app",
|
||||||
requires=[
|
requires=[
|
||||||
"gui",
|
"gui",
|
||||||
"lfrfid",
|
],
|
||||||
|
provides=[
|
||||||
|
"lfrfid_debug",
|
||||||
],
|
],
|
||||||
stack_size=1 * 1024,
|
stack_size=1 * 1024,
|
||||||
order=100,
|
order=100,
|
||||||
|
fap_category="Debug",
|
||||||
)
|
)
|
||||||
81
applications/debug/lfrfid_debug/lfrfid_debug.c
Normal file
81
applications/debug/lfrfid_debug/lfrfid_debug.c
Normal file
@@ -0,0 +1,81 @@
|
|||||||
|
#include "lfrfid_debug_i.h"
|
||||||
|
|
||||||
|
static bool lfrfid_debug_custom_event_callback(void* context, uint32_t event) {
|
||||||
|
furi_assert(context);
|
||||||
|
LfRfidDebug* app = context;
|
||||||
|
return scene_manager_handle_custom_event(app->scene_manager, event);
|
||||||
|
}
|
||||||
|
|
||||||
|
static bool lfrfid_debug_back_event_callback(void* context) {
|
||||||
|
furi_assert(context);
|
||||||
|
LfRfidDebug* app = context;
|
||||||
|
return scene_manager_handle_back_event(app->scene_manager);
|
||||||
|
}
|
||||||
|
|
||||||
|
static LfRfidDebug* lfrfid_debug_alloc() {
|
||||||
|
LfRfidDebug* app = malloc(sizeof(LfRfidDebug));
|
||||||
|
|
||||||
|
app->view_dispatcher = view_dispatcher_alloc();
|
||||||
|
app->scene_manager = scene_manager_alloc(&lfrfid_debug_scene_handlers, app);
|
||||||
|
view_dispatcher_enable_queue(app->view_dispatcher);
|
||||||
|
view_dispatcher_set_event_callback_context(app->view_dispatcher, app);
|
||||||
|
view_dispatcher_set_custom_event_callback(
|
||||||
|
app->view_dispatcher, lfrfid_debug_custom_event_callback);
|
||||||
|
view_dispatcher_set_navigation_event_callback(
|
||||||
|
app->view_dispatcher, lfrfid_debug_back_event_callback);
|
||||||
|
|
||||||
|
// Open GUI record
|
||||||
|
app->gui = furi_record_open(RECORD_GUI);
|
||||||
|
view_dispatcher_attach_to_gui(app->view_dispatcher, app->gui, ViewDispatcherTypeFullscreen);
|
||||||
|
|
||||||
|
// Submenu
|
||||||
|
app->submenu = submenu_alloc();
|
||||||
|
view_dispatcher_add_view(
|
||||||
|
app->view_dispatcher, LfRfidDebugViewSubmenu, submenu_get_view(app->submenu));
|
||||||
|
|
||||||
|
// Tune view
|
||||||
|
app->tune_view = lfrfid_debug_view_tune_alloc();
|
||||||
|
view_dispatcher_add_view(
|
||||||
|
app->view_dispatcher,
|
||||||
|
LfRfidDebugViewTune,
|
||||||
|
lfrfid_debug_view_tune_get_view(app->tune_view));
|
||||||
|
|
||||||
|
return app;
|
||||||
|
}
|
||||||
|
|
||||||
|
static void lfrfid_debug_free(LfRfidDebug* app) {
|
||||||
|
furi_assert(app);
|
||||||
|
|
||||||
|
// Submenu
|
||||||
|
view_dispatcher_remove_view(app->view_dispatcher, LfRfidDebugViewSubmenu);
|
||||||
|
submenu_free(app->submenu);
|
||||||
|
|
||||||
|
// Tune view
|
||||||
|
view_dispatcher_remove_view(app->view_dispatcher, LfRfidDebugViewTune);
|
||||||
|
lfrfid_debug_view_tune_free(app->tune_view);
|
||||||
|
|
||||||
|
// View Dispatcher
|
||||||
|
view_dispatcher_free(app->view_dispatcher);
|
||||||
|
|
||||||
|
// Scene Manager
|
||||||
|
scene_manager_free(app->scene_manager);
|
||||||
|
|
||||||
|
// GUI
|
||||||
|
furi_record_close(RECORD_GUI);
|
||||||
|
app->gui = NULL;
|
||||||
|
|
||||||
|
free(app);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t lfrfid_debug_app(void* p) {
|
||||||
|
UNUSED(p);
|
||||||
|
LfRfidDebug* app = lfrfid_debug_alloc();
|
||||||
|
|
||||||
|
scene_manager_next_scene(app->scene_manager, LfRfidDebugSceneStart);
|
||||||
|
|
||||||
|
view_dispatcher_run(app->view_dispatcher);
|
||||||
|
|
||||||
|
lfrfid_debug_free(app);
|
||||||
|
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
30
applications/debug/lfrfid_debug/lfrfid_debug_i.h
Normal file
30
applications/debug/lfrfid_debug/lfrfid_debug_i.h
Normal file
@@ -0,0 +1,30 @@
|
|||||||
|
#pragma once
|
||||||
|
#include <furi.h>
|
||||||
|
#include <furi_hal.h>
|
||||||
|
|
||||||
|
#include <gui/gui.h>
|
||||||
|
#include <gui/view.h>
|
||||||
|
#include <gui/view_dispatcher.h>
|
||||||
|
#include <gui/scene_manager.h>
|
||||||
|
|
||||||
|
#include <gui/modules/submenu.h>
|
||||||
|
|
||||||
|
#include "views/lfrfid_debug_view_tune.h"
|
||||||
|
#include "scenes/lfrfid_debug_scene.h"
|
||||||
|
|
||||||
|
typedef struct LfRfidDebug LfRfidDebug;
|
||||||
|
|
||||||
|
struct LfRfidDebug {
|
||||||
|
Gui* gui;
|
||||||
|
ViewDispatcher* view_dispatcher;
|
||||||
|
SceneManager* scene_manager;
|
||||||
|
|
||||||
|
// Common Views
|
||||||
|
Submenu* submenu;
|
||||||
|
LfRfidTuneView* tune_view;
|
||||||
|
};
|
||||||
|
|
||||||
|
typedef enum {
|
||||||
|
LfRfidDebugViewSubmenu,
|
||||||
|
LfRfidDebugViewTune,
|
||||||
|
} LfRfidDebugView;
|
||||||
@@ -0,0 +1,44 @@
|
|||||||
|
#include "../lfrfid_debug_i.h"
|
||||||
|
|
||||||
|
typedef enum {
|
||||||
|
SubmenuIndexTune,
|
||||||
|
} SubmenuIndex;
|
||||||
|
|
||||||
|
static void lfrfid_debug_scene_start_submenu_callback(void* context, uint32_t index) {
|
||||||
|
LfRfidDebug* app = context;
|
||||||
|
|
||||||
|
view_dispatcher_send_custom_event(app->view_dispatcher, index);
|
||||||
|
}
|
||||||
|
|
||||||
|
void lfrfid_debug_scene_start_on_enter(void* context) {
|
||||||
|
LfRfidDebug* app = context;
|
||||||
|
Submenu* submenu = app->submenu;
|
||||||
|
|
||||||
|
submenu_add_item(
|
||||||
|
submenu, "Tune", SubmenuIndexTune, lfrfid_debug_scene_start_submenu_callback, app);
|
||||||
|
|
||||||
|
submenu_set_selected_item(
|
||||||
|
submenu, scene_manager_get_scene_state(app->scene_manager, LfRfidDebugSceneStart));
|
||||||
|
|
||||||
|
view_dispatcher_switch_to_view(app->view_dispatcher, LfRfidDebugViewSubmenu);
|
||||||
|
}
|
||||||
|
|
||||||
|
bool lfrfid_debug_scene_start_on_event(void* context, SceneManagerEvent event) {
|
||||||
|
LfRfidDebug* app = context;
|
||||||
|
bool consumed = false;
|
||||||
|
|
||||||
|
if(event.type == SceneManagerEventTypeCustom) {
|
||||||
|
if(event.event == SubmenuIndexTune) {
|
||||||
|
scene_manager_next_scene(app->scene_manager, LfRfidDebugSceneTune);
|
||||||
|
consumed = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return consumed;
|
||||||
|
}
|
||||||
|
|
||||||
|
void lfrfid_debug_scene_start_on_exit(void* context) {
|
||||||
|
LfRfidDebug* app = context;
|
||||||
|
|
||||||
|
submenu_reset(app->submenu);
|
||||||
|
}
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
#include "lfrfid_debug_app_scene_tune.h"
|
#include "../lfrfid_debug_i.h"
|
||||||
#include <furi_hal.h>
|
#include <furi_hal.h>
|
||||||
|
|
||||||
static void comparator_trigger_callback(bool level, void* comp_ctx) {
|
static void comparator_trigger_callback(bool level, void* comp_ctx) {
|
||||||
@@ -6,32 +6,38 @@ static void comparator_trigger_callback(bool level, void* comp_ctx) {
|
|||||||
furi_hal_gpio_write(&gpio_ext_pa7, !level);
|
furi_hal_gpio_write(&gpio_ext_pa7, !level);
|
||||||
}
|
}
|
||||||
|
|
||||||
void LfRfidDebugAppSceneTune::on_enter(LfRfidDebugApp* app, bool /* need_restore */) {
|
void lfrfid_debug_scene_tune_on_enter(void* context) {
|
||||||
app->view_controller.switch_to<LfRfidViewTuneVM>();
|
LfRfidDebug* app = context;
|
||||||
|
|
||||||
furi_hal_gpio_init_simple(&gpio_ext_pa7, GpioModeOutputPushPull);
|
furi_hal_gpio_init_simple(&gpio_ext_pa7, GpioModeOutputPushPull);
|
||||||
|
|
||||||
furi_hal_rfid_comp_set_callback(comparator_trigger_callback, this);
|
furi_hal_rfid_comp_set_callback(comparator_trigger_callback, app);
|
||||||
furi_hal_rfid_comp_start();
|
furi_hal_rfid_comp_start();
|
||||||
|
|
||||||
furi_hal_rfid_pins_read();
|
furi_hal_rfid_pins_read();
|
||||||
furi_hal_rfid_tim_read(125000, 0.5);
|
furi_hal_rfid_tim_read(125000, 0.5);
|
||||||
furi_hal_rfid_tim_read_start();
|
furi_hal_rfid_tim_read_start();
|
||||||
|
|
||||||
|
view_dispatcher_switch_to_view(app->view_dispatcher, LfRfidDebugViewTune);
|
||||||
}
|
}
|
||||||
|
|
||||||
bool LfRfidDebugAppSceneTune::on_event(LfRfidDebugApp* app, LfRfidDebugApp::Event* /* event */) {
|
bool lfrfid_debug_scene_tune_on_event(void* context, SceneManagerEvent event) {
|
||||||
|
UNUSED(event);
|
||||||
|
|
||||||
|
LfRfidDebug* app = context;
|
||||||
bool consumed = false;
|
bool consumed = false;
|
||||||
|
|
||||||
LfRfidViewTuneVM* tune = app->view_controller;
|
if(lfrfid_debug_view_tune_is_dirty(app->tune_view)) {
|
||||||
|
furi_hal_rfid_set_read_period(lfrfid_debug_view_tune_get_arr(app->tune_view));
|
||||||
if(tune->is_dirty()) {
|
furi_hal_rfid_set_read_pulse(lfrfid_debug_view_tune_get_ccr(app->tune_view));
|
||||||
furi_hal_rfid_set_read_period(tune->get_ARR());
|
|
||||||
furi_hal_rfid_set_read_pulse(tune->get_CCR());
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return consumed;
|
return consumed;
|
||||||
}
|
}
|
||||||
|
|
||||||
void LfRfidDebugAppSceneTune::on_exit(LfRfidDebugApp* /* app */) {
|
void lfrfid_debug_scene_tune_on_exit(void* context) {
|
||||||
|
UNUSED(context);
|
||||||
|
|
||||||
furi_hal_rfid_comp_stop();
|
furi_hal_rfid_comp_stop();
|
||||||
furi_hal_rfid_comp_set_callback(NULL, NULL);
|
furi_hal_rfid_comp_set_callback(NULL, NULL);
|
||||||
|
|
||||||
30
applications/debug/lfrfid_debug/scenes/lfrfid_debug_scene.c
Normal file
30
applications/debug/lfrfid_debug/scenes/lfrfid_debug_scene.c
Normal file
@@ -0,0 +1,30 @@
|
|||||||
|
#include "lfrfid_debug_scene.h"
|
||||||
|
|
||||||
|
// Generate scene on_enter handlers array
|
||||||
|
#define ADD_SCENE(prefix, name, id) prefix##_scene_##name##_on_enter,
|
||||||
|
void (*const lfrfid_debug_on_enter_handlers[])(void*) = {
|
||||||
|
#include "lfrfid_debug_scene_config.h"
|
||||||
|
};
|
||||||
|
#undef ADD_SCENE
|
||||||
|
|
||||||
|
// Generate scene on_event handlers array
|
||||||
|
#define ADD_SCENE(prefix, name, id) prefix##_scene_##name##_on_event,
|
||||||
|
bool (*const lfrfid_debug_on_event_handlers[])(void* context, SceneManagerEvent event) = {
|
||||||
|
#include "lfrfid_debug_scene_config.h"
|
||||||
|
};
|
||||||
|
#undef ADD_SCENE
|
||||||
|
|
||||||
|
// Generate scene on_exit handlers array
|
||||||
|
#define ADD_SCENE(prefix, name, id) prefix##_scene_##name##_on_exit,
|
||||||
|
void (*const lfrfid_debug_on_exit_handlers[])(void* context) = {
|
||||||
|
#include "lfrfid_debug_scene_config.h"
|
||||||
|
};
|
||||||
|
#undef ADD_SCENE
|
||||||
|
|
||||||
|
// Initialize scene handlers configuration structure
|
||||||
|
const SceneManagerHandlers lfrfid_debug_scene_handlers = {
|
||||||
|
.on_enter_handlers = lfrfid_debug_on_enter_handlers,
|
||||||
|
.on_event_handlers = lfrfid_debug_on_event_handlers,
|
||||||
|
.on_exit_handlers = lfrfid_debug_on_exit_handlers,
|
||||||
|
.scene_num = LfRfidDebugSceneNum,
|
||||||
|
};
|
||||||
29
applications/debug/lfrfid_debug/scenes/lfrfid_debug_scene.h
Normal file
29
applications/debug/lfrfid_debug/scenes/lfrfid_debug_scene.h
Normal file
@@ -0,0 +1,29 @@
|
|||||||
|
#pragma once
|
||||||
|
|
||||||
|
#include <gui/scene_manager.h>
|
||||||
|
|
||||||
|
// Generate scene id and total number
|
||||||
|
#define ADD_SCENE(prefix, name, id) LfRfidDebugScene##id,
|
||||||
|
typedef enum {
|
||||||
|
#include "lfrfid_debug_scene_config.h"
|
||||||
|
LfRfidDebugSceneNum,
|
||||||
|
} LfRfidDebugScene;
|
||||||
|
#undef ADD_SCENE
|
||||||
|
|
||||||
|
extern const SceneManagerHandlers lfrfid_debug_scene_handlers;
|
||||||
|
|
||||||
|
// Generate scene on_enter handlers declaration
|
||||||
|
#define ADD_SCENE(prefix, name, id) void prefix##_scene_##name##_on_enter(void*);
|
||||||
|
#include "lfrfid_debug_scene_config.h"
|
||||||
|
#undef ADD_SCENE
|
||||||
|
|
||||||
|
// Generate scene on_event handlers declaration
|
||||||
|
#define ADD_SCENE(prefix, name, id) \
|
||||||
|
bool prefix##_scene_##name##_on_event(void* context, SceneManagerEvent event);
|
||||||
|
#include "lfrfid_debug_scene_config.h"
|
||||||
|
#undef ADD_SCENE
|
||||||
|
|
||||||
|
// Generate scene on_exit handlers declaration
|
||||||
|
#define ADD_SCENE(prefix, name, id) void prefix##_scene_##name##_on_exit(void* context);
|
||||||
|
#include "lfrfid_debug_scene_config.h"
|
||||||
|
#undef ADD_SCENE
|
||||||
@@ -0,0 +1,2 @@
|
|||||||
|
ADD_SCENE(lfrfid_debug, start, Start)
|
||||||
|
ADD_SCENE(lfrfid_debug, tune, Tune)
|
||||||
229
applications/debug/lfrfid_debug/views/lfrfid_debug_view_tune.c
Normal file
229
applications/debug/lfrfid_debug/views/lfrfid_debug_view_tune.c
Normal file
@@ -0,0 +1,229 @@
|
|||||||
|
#include "lfrfid_debug_view_tune.h"
|
||||||
|
#include <gui/elements.h>
|
||||||
|
|
||||||
|
#define TEMP_STR_LEN 128
|
||||||
|
|
||||||
|
struct LfRfidTuneView {
|
||||||
|
View* view;
|
||||||
|
};
|
||||||
|
|
||||||
|
typedef struct {
|
||||||
|
bool dirty;
|
||||||
|
bool fine;
|
||||||
|
uint32_t ARR;
|
||||||
|
uint32_t CCR;
|
||||||
|
int pos;
|
||||||
|
} LfRfidTuneViewModel;
|
||||||
|
|
||||||
|
static void lfrfid_debug_view_tune_draw_callback(Canvas* canvas, void* _model) {
|
||||||
|
LfRfidTuneViewModel* model = _model;
|
||||||
|
canvas_set_color(canvas, ColorBlack);
|
||||||
|
|
||||||
|
if(model->fine) {
|
||||||
|
canvas_draw_box(
|
||||||
|
canvas,
|
||||||
|
128 - canvas_string_width(canvas, "Fine") - 4,
|
||||||
|
0,
|
||||||
|
canvas_string_width(canvas, "Fine") + 4,
|
||||||
|
canvas_current_font_height(canvas) + 1);
|
||||||
|
canvas_set_color(canvas, ColorWhite);
|
||||||
|
}
|
||||||
|
canvas_draw_str_aligned(canvas, 128 - 2, 2, AlignRight, AlignTop, "Fine");
|
||||||
|
canvas_set_color(canvas, ColorBlack);
|
||||||
|
|
||||||
|
char buffer[TEMP_STR_LEN + 1];
|
||||||
|
double freq = ((float)SystemCoreClock / ((float)model->ARR + 1));
|
||||||
|
double duty = ((float)model->CCR + 1) / ((float)model->ARR + 1) * 100.0f;
|
||||||
|
snprintf(
|
||||||
|
buffer,
|
||||||
|
TEMP_STR_LEN,
|
||||||
|
"%sARR: %lu\n"
|
||||||
|
"freq = %.4f\n"
|
||||||
|
"%sCCR: %lu\n"
|
||||||
|
"duty = %.4f",
|
||||||
|
model->pos == 0 ? ">" : "",
|
||||||
|
model->ARR,
|
||||||
|
freq,
|
||||||
|
model->pos == 1 ? ">" : "",
|
||||||
|
model->CCR,
|
||||||
|
duty);
|
||||||
|
elements_multiline_text_aligned(canvas, 2, 2, AlignLeft, AlignTop, buffer);
|
||||||
|
}
|
||||||
|
|
||||||
|
static void lfrfid_debug_view_tune_button_up(LfRfidTuneView* tune_view) {
|
||||||
|
with_view_model(
|
||||||
|
tune_view->view, (LfRfidTuneViewModel * model) {
|
||||||
|
if(model->pos > 0) model->pos--;
|
||||||
|
return true;
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
static void lfrfid_debug_view_tune_button_down(LfRfidTuneView* tune_view) {
|
||||||
|
with_view_model(
|
||||||
|
tune_view->view, (LfRfidTuneViewModel * model) {
|
||||||
|
if(model->pos < 1) model->pos++;
|
||||||
|
return true;
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
static void lfrfid_debug_view_tune_button_left(LfRfidTuneView* tune_view) {
|
||||||
|
with_view_model(
|
||||||
|
tune_view->view, (LfRfidTuneViewModel * model) {
|
||||||
|
if(model->pos == 0) {
|
||||||
|
if(model->fine) {
|
||||||
|
model->ARR -= 1;
|
||||||
|
} else {
|
||||||
|
model->ARR -= 10;
|
||||||
|
}
|
||||||
|
} else if(model->pos == 1) {
|
||||||
|
if(model->fine) {
|
||||||
|
model->CCR -= 1;
|
||||||
|
} else {
|
||||||
|
model->CCR -= 10;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
model->dirty = true;
|
||||||
|
return true;
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
static void lfrfid_debug_view_tune_button_right(LfRfidTuneView* tune_view) {
|
||||||
|
with_view_model(
|
||||||
|
tune_view->view, (LfRfidTuneViewModel * model) {
|
||||||
|
if(model->pos == 0) {
|
||||||
|
if(model->fine) {
|
||||||
|
model->ARR += 1;
|
||||||
|
} else {
|
||||||
|
model->ARR += 10;
|
||||||
|
}
|
||||||
|
} else if(model->pos == 1) {
|
||||||
|
if(model->fine) {
|
||||||
|
model->CCR += 1;
|
||||||
|
} else {
|
||||||
|
model->CCR += 10;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
model->dirty = true;
|
||||||
|
return true;
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
static void lfrfid_debug_view_tune_button_ok(LfRfidTuneView* tune_view) {
|
||||||
|
with_view_model(
|
||||||
|
tune_view->view, (LfRfidTuneViewModel * model) {
|
||||||
|
model->fine = !model->fine;
|
||||||
|
return true;
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
static bool lfrfid_debug_view_tune_input_callback(InputEvent* event, void* context) {
|
||||||
|
LfRfidTuneView* tune_view = context;
|
||||||
|
bool consumed = false;
|
||||||
|
|
||||||
|
// Process key presses only
|
||||||
|
if(event->type == InputTypeShort || event->type == InputTypeRepeat) {
|
||||||
|
consumed = true;
|
||||||
|
|
||||||
|
switch(event->key) {
|
||||||
|
case InputKeyLeft:
|
||||||
|
lfrfid_debug_view_tune_button_left(tune_view);
|
||||||
|
break;
|
||||||
|
case InputKeyRight:
|
||||||
|
lfrfid_debug_view_tune_button_right(tune_view);
|
||||||
|
break;
|
||||||
|
case InputKeyUp:
|
||||||
|
lfrfid_debug_view_tune_button_up(tune_view);
|
||||||
|
break;
|
||||||
|
case InputKeyDown:
|
||||||
|
lfrfid_debug_view_tune_button_down(tune_view);
|
||||||
|
break;
|
||||||
|
case InputKeyOk:
|
||||||
|
lfrfid_debug_view_tune_button_ok(tune_view);
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
consumed = false;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return consumed;
|
||||||
|
}
|
||||||
|
|
||||||
|
LfRfidTuneView* lfrfid_debug_view_tune_alloc() {
|
||||||
|
LfRfidTuneView* tune_view = malloc(sizeof(LfRfidTuneView));
|
||||||
|
tune_view->view = view_alloc();
|
||||||
|
view_set_context(tune_view->view, tune_view);
|
||||||
|
view_allocate_model(tune_view->view, ViewModelTypeLocking, sizeof(LfRfidTuneViewModel));
|
||||||
|
|
||||||
|
with_view_model(
|
||||||
|
tune_view->view, (LfRfidTuneViewModel * model) {
|
||||||
|
model->dirty = true;
|
||||||
|
model->fine = false;
|
||||||
|
model->ARR = 511;
|
||||||
|
model->CCR = 255;
|
||||||
|
model->pos = 0;
|
||||||
|
return true;
|
||||||
|
});
|
||||||
|
|
||||||
|
view_set_draw_callback(tune_view->view, lfrfid_debug_view_tune_draw_callback);
|
||||||
|
view_set_input_callback(tune_view->view, lfrfid_debug_view_tune_input_callback);
|
||||||
|
|
||||||
|
return tune_view;
|
||||||
|
}
|
||||||
|
|
||||||
|
void lfrfid_debug_view_tune_free(LfRfidTuneView* tune_view) {
|
||||||
|
view_free(tune_view->view);
|
||||||
|
free(tune_view);
|
||||||
|
}
|
||||||
|
|
||||||
|
View* lfrfid_debug_view_tune_get_view(LfRfidTuneView* tune_view) {
|
||||||
|
return tune_view->view;
|
||||||
|
}
|
||||||
|
|
||||||
|
void lfrfid_debug_view_tune_clean(LfRfidTuneView* tune_view) {
|
||||||
|
with_view_model(
|
||||||
|
tune_view->view, (LfRfidTuneViewModel * model) {
|
||||||
|
model->dirty = true;
|
||||||
|
model->fine = false;
|
||||||
|
model->ARR = 511;
|
||||||
|
model->CCR = 255;
|
||||||
|
model->pos = 0;
|
||||||
|
return true;
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
bool lfrfid_debug_view_tune_is_dirty(LfRfidTuneView* tune_view) {
|
||||||
|
bool result = false;
|
||||||
|
with_view_model(
|
||||||
|
tune_view->view, (LfRfidTuneViewModel * model) {
|
||||||
|
result = model->dirty;
|
||||||
|
model->dirty = false;
|
||||||
|
return false;
|
||||||
|
});
|
||||||
|
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
uint32_t lfrfid_debug_view_tune_get_arr(LfRfidTuneView* tune_view) {
|
||||||
|
uint32_t result = false;
|
||||||
|
with_view_model(
|
||||||
|
tune_view->view, (LfRfidTuneViewModel * model) {
|
||||||
|
result = model->ARR;
|
||||||
|
return false;
|
||||||
|
});
|
||||||
|
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
uint32_t lfrfid_debug_view_tune_get_ccr(LfRfidTuneView* tune_view) {
|
||||||
|
uint32_t result = false;
|
||||||
|
with_view_model(
|
||||||
|
tune_view->view, (LfRfidTuneViewModel * model) {
|
||||||
|
result = model->CCR;
|
||||||
|
return false;
|
||||||
|
});
|
||||||
|
|
||||||
|
return result;
|
||||||
|
}
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
#pragma once
|
||||||
|
#include <gui/view.h>
|
||||||
|
|
||||||
|
typedef struct LfRfidTuneView LfRfidTuneView;
|
||||||
|
|
||||||
|
LfRfidTuneView* lfrfid_debug_view_tune_alloc();
|
||||||
|
|
||||||
|
void lfrfid_debug_view_tune_free(LfRfidTuneView* tune_view);
|
||||||
|
|
||||||
|
View* lfrfid_debug_view_tune_get_view(LfRfidTuneView* tune_view);
|
||||||
|
|
||||||
|
void lfrfid_debug_view_tune_clean(LfRfidTuneView* tune_view);
|
||||||
|
|
||||||
|
bool lfrfid_debug_view_tune_is_dirty(LfRfidTuneView* tune_view);
|
||||||
|
|
||||||
|
uint32_t lfrfid_debug_view_tune_get_arr(LfRfidTuneView* tune_view);
|
||||||
|
|
||||||
|
uint32_t lfrfid_debug_view_tune_get_ccr(LfRfidTuneView* tune_view);
|
||||||
11
applications/debug/text_box_test/application.fam
Normal file
11
applications/debug/text_box_test/application.fam
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
App(
|
||||||
|
appid="text_box_test",
|
||||||
|
name="Text Box Test",
|
||||||
|
apptype=FlipperAppType.DEBUG,
|
||||||
|
entry_point="text_box_test_app",
|
||||||
|
cdefines=["APP_TEXT_BOX_TEST"],
|
||||||
|
requires=["gui"],
|
||||||
|
stack_size=1 * 1024,
|
||||||
|
order=140,
|
||||||
|
fap_category="Debug",
|
||||||
|
)
|
||||||
12
applications/debug/uart_echo/application.fam
Normal file
12
applications/debug/uart_echo/application.fam
Normal file
@@ -0,0 +1,12 @@
|
|||||||
|
App(
|
||||||
|
appid="UART_Echo",
|
||||||
|
name="UART Echo",
|
||||||
|
apptype=FlipperAppType.PLUGIN,
|
||||||
|
entry_point="uart_echo_app",
|
||||||
|
cdefines=["APP_UART_ECHO"],
|
||||||
|
requires=["gui"],
|
||||||
|
stack_size=2 * 1024,
|
||||||
|
order=70,
|
||||||
|
fap_icon="../../../assets/icons/Archive/keyboard_10px.png",
|
||||||
|
fap_category="Misc",
|
||||||
|
)
|
||||||
@@ -10,7 +10,7 @@ App(
|
|||||||
App(
|
App(
|
||||||
appid="delay_test",
|
appid="delay_test",
|
||||||
name="Delay Test",
|
name="Delay Test",
|
||||||
apptype=FlipperAppType.DEBUG,
|
apptype=FlipperAppType.SYSTEM,
|
||||||
entry_point="delay_test_app",
|
entry_point="delay_test_app",
|
||||||
stack_size=1 * 1024,
|
stack_size=1 * 1024,
|
||||||
requires=["unit_tests"],
|
requires=["unit_tests"],
|
||||||
@@ -57,6 +57,23 @@ static const char* test_data_win = "Filetype: Flipper File test\r\n"
|
|||||||
"Hex data: DE AD BE";
|
"Hex data: DE AD BE";
|
||||||
|
|
||||||
#define READ_TEST_FLP "ff_flp.test"
|
#define READ_TEST_FLP "ff_flp.test"
|
||||||
|
#define READ_TEST_ODD "ff_oddities.test"
|
||||||
|
static const char* test_data_odd = "Filetype: Flipper File test\n"
|
||||||
|
// Tabs before newline
|
||||||
|
"Version: 666\t\t\n"
|
||||||
|
"# This is comment\n"
|
||||||
|
// Windows newline in a UNIX file
|
||||||
|
"String data: String\r\n"
|
||||||
|
// Trailing whitespace
|
||||||
|
"Int32 data: 1234 -6345 7813 0 \n"
|
||||||
|
// Extra whitespace
|
||||||
|
"Uint32 data: 1234 0 5678 9098 7654321 \n"
|
||||||
|
// Mixed whitespace
|
||||||
|
"Float data: 1.5\t \t1000.0\n"
|
||||||
|
// Leading tabs after key
|
||||||
|
"Bool data:\t\ttrue false\n"
|
||||||
|
// Mixed trailing whitespace
|
||||||
|
"Hex data: DE AD BE\t ";
|
||||||
|
|
||||||
// data created by user on linux machine
|
// data created by user on linux machine
|
||||||
static const char* test_file_linux = TEST_DIR READ_TEST_NIX;
|
static const char* test_file_linux = TEST_DIR READ_TEST_NIX;
|
||||||
@@ -64,6 +81,8 @@ static const char* test_file_linux = TEST_DIR READ_TEST_NIX;
|
|||||||
static const char* test_file_windows = TEST_DIR READ_TEST_WIN;
|
static const char* test_file_windows = TEST_DIR READ_TEST_WIN;
|
||||||
// data created by flipper itself
|
// data created by flipper itself
|
||||||
static const char* test_file_flipper = TEST_DIR READ_TEST_FLP;
|
static const char* test_file_flipper = TEST_DIR READ_TEST_FLP;
|
||||||
|
// data containing odd user input
|
||||||
|
static const char* test_file_oddities = TEST_DIR READ_TEST_ODD;
|
||||||
|
|
||||||
static bool storage_write_string(const char* path, const char* data) {
|
static bool storage_write_string(const char* path, const char* data) {
|
||||||
Storage* storage = furi_record_open(RECORD_STORAGE);
|
Storage* storage = furi_record_open(RECORD_STORAGE);
|
||||||
@@ -503,6 +522,12 @@ MU_TEST(flipper_format_multikey_test) {
|
|||||||
mu_assert(test_read_multikey(TEST_DIR "ff_multiline.test"), "Multikey read test error");
|
mu_assert(test_read_multikey(TEST_DIR "ff_multiline.test"), "Multikey read test error");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
MU_TEST(flipper_format_oddities_test) {
|
||||||
|
mu_assert(
|
||||||
|
storage_write_string(test_file_oddities, test_data_odd), "Write test error [Oddities]");
|
||||||
|
mu_assert(test_read(test_file_linux), "Read test error [Oddities]");
|
||||||
|
}
|
||||||
|
|
||||||
MU_TEST_SUITE(flipper_format) {
|
MU_TEST_SUITE(flipper_format) {
|
||||||
tests_setup();
|
tests_setup();
|
||||||
MU_RUN_TEST(flipper_format_write_test);
|
MU_RUN_TEST(flipper_format_write_test);
|
||||||
@@ -516,6 +541,7 @@ MU_TEST_SUITE(flipper_format) {
|
|||||||
MU_RUN_TEST(flipper_format_update_2_test);
|
MU_RUN_TEST(flipper_format_update_2_test);
|
||||||
MU_RUN_TEST(flipper_format_update_2_result_test);
|
MU_RUN_TEST(flipper_format_update_2_result_test);
|
||||||
MU_RUN_TEST(flipper_format_multikey_test);
|
MU_RUN_TEST(flipper_format_multikey_test);
|
||||||
|
MU_RUN_TEST(flipper_format_oddities_test);
|
||||||
tests_teardown();
|
tests_teardown();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1,8 +1,9 @@
|
|||||||
#include <furi.h>
|
#include <furi.h>
|
||||||
#include <furi_hal.h>
|
#include <furi_hal.h>
|
||||||
#include <applications/storage/storage.h>
|
#include <storage/storage.h>
|
||||||
#include <lib/flipper_format/flipper_format.h>
|
#include <lib/flipper_format/flipper_format.h>
|
||||||
#include <lib/nfc/protocols/nfca.h>
|
#include <lib/nfc/protocols/nfca.h>
|
||||||
|
#include <lib/nfc/helpers/mf_classic_dict.h>
|
||||||
#include <lib/digital_signal/digital_signal.h>
|
#include <lib/digital_signal/digital_signal.h>
|
||||||
|
|
||||||
#include <lib/flipper_format/flipper_format_i.h>
|
#include <lib/flipper_format/flipper_format_i.h>
|
||||||
@@ -170,10 +171,59 @@ MU_TEST(nfc_digital_signal_test) {
|
|||||||
"NFC long digital signal test failed\r\n");
|
"NFC long digital signal test failed\r\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
MU_TEST(mf_classic_dict_test) {
|
||||||
|
MfClassicDict* instance = NULL;
|
||||||
|
uint64_t key = 0;
|
||||||
|
string_t temp_str;
|
||||||
|
string_init(temp_str);
|
||||||
|
|
||||||
|
instance = mf_classic_dict_alloc(MfClassicDictTypeUnitTest);
|
||||||
|
mu_assert(instance != NULL, "mf_classic_dict_alloc\r\n");
|
||||||
|
|
||||||
|
mu_assert(
|
||||||
|
mf_classic_dict_get_total_keys(instance) == 0,
|
||||||
|
"mf_classic_dict_get_total_keys == 0 assert failed\r\n");
|
||||||
|
|
||||||
|
string_set(temp_str, "2196FAD8115B");
|
||||||
|
mu_assert(
|
||||||
|
mf_classic_dict_add_key_str(instance, temp_str),
|
||||||
|
"mf_classic_dict_add_key == true assert failed\r\n");
|
||||||
|
|
||||||
|
mu_assert(
|
||||||
|
mf_classic_dict_get_total_keys(instance) == 1,
|
||||||
|
"mf_classic_dict_get_total_keys == 1 assert failed\r\n");
|
||||||
|
|
||||||
|
mu_assert(mf_classic_dict_rewind(instance), "mf_classic_dict_rewind == 1 assert failed\r\n");
|
||||||
|
|
||||||
|
mu_assert(
|
||||||
|
mf_classic_dict_get_key_at_index_str(instance, temp_str, 0),
|
||||||
|
"mf_classic_dict_get_key_at_index_str == true assert failed\r\n");
|
||||||
|
mu_assert(
|
||||||
|
string_cmp(temp_str, "2196FAD8115B") == 0,
|
||||||
|
"string_cmp(temp_str, \"2196FAD8115B\") == 0 assert failed\r\n");
|
||||||
|
|
||||||
|
mu_assert(mf_classic_dict_rewind(instance), "mf_classic_dict_rewind == 1 assert failed\r\n");
|
||||||
|
|
||||||
|
mu_assert(
|
||||||
|
mf_classic_dict_get_key_at_index(instance, &key, 0),
|
||||||
|
"mf_classic_dict_get_key_at_index == true assert failed\r\n");
|
||||||
|
mu_assert(key == 0x2196FAD8115B, "key == 0x2196FAD8115B assert failed\r\n");
|
||||||
|
|
||||||
|
mu_assert(mf_classic_dict_rewind(instance), "mf_classic_dict_rewind == 1 assert failed\r\n");
|
||||||
|
|
||||||
|
mu_assert(
|
||||||
|
mf_classic_dict_delete_index(instance, 0),
|
||||||
|
"mf_classic_dict_delete_index == true assert failed\r\n");
|
||||||
|
|
||||||
|
mf_classic_dict_free(instance);
|
||||||
|
string_clear(temp_str);
|
||||||
|
}
|
||||||
|
|
||||||
MU_TEST_SUITE(nfc) {
|
MU_TEST_SUITE(nfc) {
|
||||||
nfc_test_alloc();
|
nfc_test_alloc();
|
||||||
|
|
||||||
MU_RUN_TEST(nfc_digital_signal_test);
|
MU_RUN_TEST(nfc_digital_signal_test);
|
||||||
|
MU_RUN_TEST(mf_classic_dict_test);
|
||||||
|
|
||||||
nfc_test_free();
|
nfc_test_free();
|
||||||
}
|
}
|
||||||
@@ -58,7 +58,7 @@ MU_TEST(storage_file_open_lock) {
|
|||||||
storage_file_close(file);
|
storage_file_close(file);
|
||||||
|
|
||||||
// file_locker thread stop
|
// file_locker thread stop
|
||||||
mu_check(furi_thread_join(locker_thread) == FuriStatusOk);
|
mu_check(furi_thread_join(locker_thread));
|
||||||
furi_thread_free(locker_thread);
|
furi_thread_free(locker_thread);
|
||||||
|
|
||||||
// clean data
|
// clean data
|
||||||
@@ -148,7 +148,7 @@ MU_TEST(storage_dir_open_lock) {
|
|||||||
storage_dir_close(file);
|
storage_dir_close(file);
|
||||||
|
|
||||||
// file_locker thread stop
|
// file_locker thread stop
|
||||||
mu_check(furi_thread_join(locker_thread) == FuriStatusOk);
|
mu_check(furi_thread_join(locker_thread));
|
||||||
furi_thread_free(locker_thread);
|
furi_thread_free(locker_thread);
|
||||||
|
|
||||||
// clean data
|
// clean data
|
||||||
@@ -13,7 +13,7 @@
|
|||||||
#define CAME_ATOMO_DIR_NAME EXT_PATH("subghz/assets/came_atomo")
|
#define CAME_ATOMO_DIR_NAME EXT_PATH("subghz/assets/came_atomo")
|
||||||
#define NICE_FLOR_S_DIR_NAME EXT_PATH("subghz/assets/nice_flor_s")
|
#define NICE_FLOR_S_DIR_NAME EXT_PATH("subghz/assets/nice_flor_s")
|
||||||
#define TEST_RANDOM_DIR_NAME EXT_PATH("unit_tests/subghz/test_random_raw.sub")
|
#define TEST_RANDOM_DIR_NAME EXT_PATH("unit_tests/subghz/test_random_raw.sub")
|
||||||
#define TEST_RANDOM_COUNT_PARSE 232
|
#define TEST_RANDOM_COUNT_PARSE 233
|
||||||
#define TEST_TIMEOUT 10000
|
#define TEST_TIMEOUT 10000
|
||||||
|
|
||||||
static SubGhzEnvironment* environment_handler;
|
static SubGhzEnvironment* environment_handler;
|
||||||
@@ -434,6 +434,13 @@ MU_TEST(subghz_decoder_clemsa_test) {
|
|||||||
"Test decoder " SUBGHZ_PROTOCOL_CLEMSA_NAME " error\r\n");
|
"Test decoder " SUBGHZ_PROTOCOL_CLEMSA_NAME " error\r\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
MU_TEST(subghz_decoder_oregon2_test) {
|
||||||
|
mu_assert(
|
||||||
|
subghz_decoder_test(
|
||||||
|
EXT_PATH("unit_tests/subghz/oregon2_raw.sub"), SUBGHZ_PROTOCOL_OREGON2_NAME),
|
||||||
|
"Test decoder " SUBGHZ_PROTOCOL_OREGON2_NAME " error\r\n");
|
||||||
|
}
|
||||||
|
|
||||||
//test encoders
|
//test encoders
|
||||||
MU_TEST(subghz_encoder_princeton_test) {
|
MU_TEST(subghz_encoder_princeton_test) {
|
||||||
mu_assert(
|
mu_assert(
|
||||||
@@ -595,6 +602,7 @@ MU_TEST_SUITE(subghz) {
|
|||||||
MU_RUN_TEST(subghz_decoder_magellen_test);
|
MU_RUN_TEST(subghz_decoder_magellen_test);
|
||||||
MU_RUN_TEST(subghz_decoder_intertechno_v3_test);
|
MU_RUN_TEST(subghz_decoder_intertechno_v3_test);
|
||||||
MU_RUN_TEST(subghz_decoder_clemsa_test);
|
MU_RUN_TEST(subghz_decoder_clemsa_test);
|
||||||
|
MU_RUN_TEST(subghz_decoder_oregon2_test);
|
||||||
|
|
||||||
MU_RUN_TEST(subghz_encoder_princeton_test);
|
MU_RUN_TEST(subghz_encoder_princeton_test);
|
||||||
MU_RUN_TEST(subghz_encoder_came_test);
|
MU_RUN_TEST(subghz_encoder_came_test);
|
||||||
12
applications/debug/usb_mouse/application.fam
Normal file
12
applications/debug/usb_mouse/application.fam
Normal file
@@ -0,0 +1,12 @@
|
|||||||
|
App(
|
||||||
|
appid="USB_Mouse",
|
||||||
|
name="USB Mouse",
|
||||||
|
apptype=FlipperAppType.PLUGIN,
|
||||||
|
entry_point="usb_mouse_app",
|
||||||
|
cdefines=["APP_USB_MOUSE"],
|
||||||
|
requires=["gui"],
|
||||||
|
stack_size=1 * 1024,
|
||||||
|
order=60,
|
||||||
|
fap_icon="../../plugins/mousejacker/mouse_10px.png",
|
||||||
|
fap_category="Misc",
|
||||||
|
)
|
||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user