Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
38 commits
Select commit Hold shift + click to select a range
994937e
Remove old rocket code
Mandeson Oct 17, 2025
39be789
Initial new firmware commit
Mandeson Oct 17, 2025
6bf456f
Add C++17 build flags
Mandeson Oct 17, 2025
972fc95
Fix compile error, change code style, use declared style
Mandeson Oct 17, 2025
0bf5a89
Add barometer
Mandeson Oct 17, 2025
71e2697
Increase clang-format column limit
Mandeson Oct 18, 2025
c548f94
Add I2C driver
Mandeson Oct 18, 2025
e8d5a3b
Use libdriver BMP280 driver
Mandeson Oct 18, 2025
63c04fb
Remove unused libraries
Mandeson Oct 18, 2025
5b3be8d
Check I2C write size to prevent buffer overflow, add size constant an…
Mandeson Oct 22, 2025
604e137
Make bmp280_interface_debug_print memory safe, mark SPI driver interf…
Mandeson Oct 22, 2025
5f1591b
Add comment informing about ignoring the bmp280_deinit return code
Mandeson Oct 22, 2025
0526853
Fix inconsistent pointer alignment
Mandeson Oct 22, 2025
c7cdd4a
Fix swapped SDL and SCL pins
Mandeson Oct 24, 2025
de90c37
Change .gitignore
Mandeson Oct 24, 2025
c2eb8cd
Add .clang-tidy and Makefile
Mandeson Oct 24, 2025
8853f59
Remove VSCode-specific config
Mandeson Oct 24, 2025
837e5db
Change i2c return type from bool to enum
Mandeson Oct 24, 2025
eaf2941
Add support for CosmoChip ESP board
Mandeson Oct 25, 2025
3eb43b9
Add LSM6DSO32 sensor support, change BMP280 driver to support BME280,…
Mandeson Oct 26, 2025
adc7c58
Make GitHub Actions init and update submodules
Mandeson Oct 26, 2025
94b73f5
Move LSM6DSO32 driver dependency management to platformio.ini
Mandeson Oct 26, 2025
5dc0ac2
Change main loop tick method to the precise ESP timer
Mandeson Oct 27, 2025
ef0dd92
Support BME280 using dedicated driver from the manufacturer, remove o…
Mandeson Oct 27, 2025
c30be33
Improve LSM6DSO32 error handling
Mandeson Oct 27, 2025
f9abf98
Improve main loop time stats
Mandeson Oct 27, 2025
b248847
Make wait methods consistent
Mandeson Oct 27, 2025
eb629c5
Improve main loop output formatting
Mandeson Oct 27, 2025
4586f22
Add GPS module
Mandeson Nov 13, 2025
0e24ab4
Refactor code to use std::array instead of C-style arrays
Mandeson Nov 14, 2025
61009d5
Add storage module, store sensor and GPS data in thread-safe buffers
Mandeson Nov 14, 2025
8c96019
Change I2C API being used to ESP-IDF driver
Mandeson Nov 14, 2025
252af13
Add NMEA decoder
Bober1337IT Nov 21, 2025
d60ee8f
Fix I2C write not actually sending any data
Mandeson Nov 21, 2025
5412f0d
Remove unused compile definition from CosmoChip.json
Mandeson Nov 27, 2025
e10c851
Add NMEA decoding
Mandeson Nov 28, 2025
2a1a129
Enable clang-tidy
Mandeson Dec 5, 2025
aea3f6d
Clean up code, change error handling, add comments
Mandeson Dec 5, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .github/workflows/pio-build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ jobs:
python-version: '3.11'
- name: Install PlatformIO Core
run: pip install --upgrade platformio

- name: Submodule update
run: git submodule update --init
- name: Build PlatformIO Project
run: pio run -d ${{ github.workspace }}/boards
3 changes: 2 additions & 1 deletion .github/workflows/pio-check.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ jobs:
python-version: '3.11'
- name: Install PlatformIO Core
run: pip install --upgrade platformio

- name: Submodule update
run: git submodule update --init
- name: Check PlatformIO Project
run: pio check --fail-on-defect=high -d ${{ github.workspace }}/boards
284 changes: 4 additions & 280 deletions boards/.clang-format
Original file line number Diff line number Diff line change
@@ -1,280 +1,4 @@
---
Language: Cpp
# BasedOnStyle: Google
AccessModifierOffset: -1
AlignAfterOpenBracket: Align
AlignArrayOfStructures: None
AlignConsecutiveAssignments:
Enabled: false
AcrossEmptyLines: false
AcrossComments: false
AlignCompound: false
AlignFunctionPointers: false
PadOperators: true
AlignConsecutiveBitFields:
Enabled: false
AcrossEmptyLines: false
AcrossComments: false
AlignCompound: false
AlignFunctionPointers: false
PadOperators: false
AlignConsecutiveDeclarations:
Enabled: false
AcrossEmptyLines: false
AcrossComments: false
AlignCompound: false
AlignFunctionPointers: false
PadOperators: false
AlignConsecutiveMacros:
Enabled: false
AcrossEmptyLines: false
AcrossComments: false
AlignCompound: false
AlignFunctionPointers: false
PadOperators: false
AlignConsecutiveShortCaseStatements:
Enabled: false
AcrossEmptyLines: false
AcrossComments: false
AlignCaseColons: false
AlignEscapedNewlines: Left
AlignOperands: Align
AlignTrailingComments:
Kind: Always
OverEmptyLines: 0
AllowAllArgumentsOnNextLine: true
AllowAllParametersOfDeclarationOnNextLine: true
AllowBreakBeforeNoexceptSpecifier: Never
AllowShortBlocksOnASingleLine: Never
AllowShortCaseLabelsOnASingleLine: false
AllowShortCompoundRequirementOnASingleLine: true
AllowShortEnumsOnASingleLine: true
AllowShortFunctionsOnASingleLine: All
AllowShortIfStatementsOnASingleLine: WithoutElse
AllowShortLambdasOnASingleLine: All
AllowShortLoopsOnASingleLine: true
AlwaysBreakAfterDefinitionReturnType: None
AlwaysBreakAfterReturnType: None
AlwaysBreakBeforeMultilineStrings: true
AlwaysBreakTemplateDeclarations: Yes
AttributeMacros:
- __capability
BinPackArguments: true
BinPackParameters: true
BitFieldColonSpacing: Both
BraceWrapping:
AfterCaseLabel: false
AfterClass: false
AfterControlStatement: Never
AfterEnum: false
AfterExternBlock: false
AfterFunction: false
AfterNamespace: false
AfterObjCDeclaration: false
AfterStruct: false
AfterUnion: false
BeforeCatch: false
BeforeElse: false
BeforeLambdaBody: false
BeforeWhile: false
IndentBraces: false
SplitEmptyFunction: true
SplitEmptyRecord: true
SplitEmptyNamespace: true
BreakAdjacentStringLiterals: true
BreakAfterAttributes: Leave
BreakAfterJavaFieldAnnotations: false
BreakArrays: true
BreakBeforeBinaryOperators: None
BreakBeforeConceptDeclarations: Always
BreakBeforeBraces: Attach
BreakBeforeInlineASMColon: OnlyMultiline
BreakBeforeTernaryOperators: true
BreakConstructorInitializers: BeforeColon
BreakInheritanceList: BeforeColon
BreakStringLiterals: true
ColumnLimit: 80
CommentPragmas: '^ IWYU pragma:'
CompactNamespaces: false
ConstructorInitializerIndentWidth: 4
ContinuationIndentWidth: 4
Cpp11BracedListStyle: true
DerivePointerAlignment: true
DisableFormat: false
EmptyLineAfterAccessModifier: Never
EmptyLineBeforeAccessModifier: LogicalBlock
ExperimentalAutoDetectBinPacking: false
FixNamespaceComments: true
ForEachMacros:
- foreach
- Q_FOREACH
- BOOST_FOREACH
IfMacros:
- KJ_IF_MAYBE
IncludeBlocks: Regroup
IncludeCategories:
- Regex: '^<ext/.*\.h>'
Priority: 2
SortPriority: 0
CaseSensitive: false
- Regex: '^<.*\.h>'
Priority: 1
SortPriority: 0
CaseSensitive: false
- Regex: '^<.*'
Priority: 2
SortPriority: 0
CaseSensitive: false
- Regex: '.*'
Priority: 3
SortPriority: 0
CaseSensitive: false
IncludeIsMainRegex: '([-_](test|unittest))?$'
IncludeIsMainSourceRegex: ''
IndentAccessModifiers: false
IndentCaseBlocks: false
IndentCaseLabels: true
IndentExternBlock: AfterExternBlock
IndentGotoLabels: true
IndentPPDirectives: None
IndentRequiresClause: true
IndentWidth: 2
IndentWrappedFunctionNames: false
InsertBraces: false
InsertNewlineAtEOF: false
InsertTrailingCommas: None
IntegerLiteralSeparator:
Binary: 0
BinaryMinDigits: 0
Decimal: 0
DecimalMinDigits: 0
Hex: 0
HexMinDigits: 0
JavaScriptQuotes: Leave
JavaScriptWrapImports: true
KeepEmptyLinesAtTheStartOfBlocks: false
KeepEmptyLinesAtEOF: false
LambdaBodyIndentation: Signature
LineEnding: DeriveLF
MacroBlockBegin: ''
MacroBlockEnd: ''
MaxEmptyLinesToKeep: 1
NamespaceIndentation: None
ObjCBinPackProtocolList: Never
ObjCBlockIndentWidth: 2
ObjCBreakBeforeNestedBlockParam: true
ObjCSpaceAfterProperty: false
ObjCSpaceBeforeProtocolList: true
PackConstructorInitializers: NextLine
PenaltyBreakAssignment: 2
PenaltyBreakBeforeFirstCallParameter: 1
PenaltyBreakComment: 300
PenaltyBreakFirstLessLess: 120
PenaltyBreakOpenParenthesis: 0
PenaltyBreakScopeResolution: 500
PenaltyBreakString: 1000
PenaltyBreakTemplateDeclaration: 10
PenaltyExcessCharacter: 1000000
PenaltyIndentedWhitespace: 0
PenaltyReturnTypeOnItsOwnLine: 200
PointerAlignment: Left
PPIndentWidth: -1
QualifierAlignment: Leave
RawStringFormats:
- Language: Cpp
Delimiters:
- cc
- CC
- cpp
- Cpp
- CPP
- 'c++'
- 'C++'
CanonicalDelimiter: ''
BasedOnStyle: google
- Language: TextProto
Delimiters:
- pb
- PB
- proto
- PROTO
EnclosingFunctions:
- EqualsProto
- EquivToProto
- PARSE_PARTIAL_TEXT_PROTO
- PARSE_TEST_PROTO
- PARSE_TEXT_PROTO
- ParseTextOrDie
- ParseTextProtoOrDie
- ParseTestProto
- ParsePartialTestProto
CanonicalDelimiter: pb
BasedOnStyle: google
ReferenceAlignment: Pointer
ReflowComments: true
RemoveBracesLLVM: false
RemoveParentheses: Leave
RemoveSemicolon: false
RequiresClausePosition: OwnLine
RequiresExpressionIndentation: OuterScope
SeparateDefinitionBlocks: Leave
ShortNamespaceLines: 1
SkipMacroDefinitionBody: false
SortIncludes: CaseSensitive
SortJavaStaticImport: Before
SortUsingDeclarations: LexicographicNumeric
SpaceAfterCStyleCast: false
SpaceAfterLogicalNot: false
SpaceAfterTemplateKeyword: true
SpaceAroundPointerQualifiers: Default
SpaceBeforeAssignmentOperators: true
SpaceBeforeCaseColon: false
SpaceBeforeCpp11BracedList: false
SpaceBeforeCtorInitializerColon: true
SpaceBeforeInheritanceColon: true
SpaceBeforeJsonColon: false
SpaceBeforeParens: ControlStatements
SpaceBeforeParensOptions:
AfterControlStatements: true
AfterForeachMacros: true
AfterFunctionDefinitionName: false
AfterFunctionDeclarationName: false
AfterIfMacros: true
AfterOverloadedOperator: false
AfterPlacementOperator: true
AfterRequiresInClause: false
AfterRequiresInExpression: false
BeforeNonEmptyParentheses: false
SpaceBeforeRangeBasedForLoopColon: true
SpaceBeforeSquareBrackets: false
SpaceInEmptyBlock: false
SpacesBeforeTrailingComments: 2
SpacesInAngles: Never
SpacesInContainerLiterals: true
SpacesInLineCommentPrefix:
Minimum: 1
Maximum: -1
SpacesInParens: Never
SpacesInParensOptions:
InCStyleCasts: false
InConditionalStatements: false
InEmptyParentheses: false
Other: false
SpacesInSquareBrackets: false
Standard: Auto
StatementAttributeLikeMacros:
- Q_EMIT
StatementMacros:
- Q_UNUSED
- QT_REQUIRE_VERSION
TabWidth: 8
UseTab: Never
VerilogBreakBetweenInstancePorts: true
WhitespaceSensitiveMacros:
- BOOST_PP_STRINGIZE
- CF_SWIFT_NAME
- NS_SWIFT_NAME
- PP_STRINGIZE
- STRINGIZE
...

BasedOnStyle: Google
IndentWidth: 4
ColumnLimit: 100
PointerAlignment: Right
6 changes: 1 addition & 5 deletions boards/.gitignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,2 @@
.pio
.vscode
compile_commands.json
.cache
unpacked_fs/
partition_table_from_flash.bin
.vscode/*
1 change: 0 additions & 1 deletion boards/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -27,4 +27,3 @@ monitor:

update:
pio -f -c vim update

51 changes: 51 additions & 0 deletions boards/boards/CosmoChip.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
{
"build": {
"arduino": {
"ldscript": "esp32s3_out.ld",
"partitions": "default.csv"
},
"core": "esp32",
"extra_flags": [
"-DARDUINO_USB_MODE=1",
"-DARDUINO_USB_CDC_ON_BOOT=1",
"-DARDUINO_RUNNING_CORE=1",
"-DARDUINO_EVENT_RUNNING_CORE=1"
],
"f_cpu": "240000000L",
"f_flash": "80000000L",
"flash_mode": "qio",
"hwids": [
[
"0x303A",
"0x1001"
]
],
"mcu": "esp32s3",
"variant": "esp32s3"
},
"connectivity": [
"bluetooth",
"wifi"
],
"debug": {
"default_tool": "esp-builtin",
"onboard_tools": [
"esp-builtin"
],
"openocd_target": "esp32s3.cfg"
},
"frameworks": [
"arduino",
"espidf"
],
"name": "CosmoChip ESP32-S3",
"upload": {
"flash_size": "4MB",
"maximum_ram_size": 327680,
"maximum_size": 4194304,
"require_upload_port": true,
"speed": 921600
},
"url": "",
"vendor": "Cosmo PK"
}
Empty file removed boards/data/cfg
Empty file.
Empty file removed boards/data/data.log
Empty file.
Loading