Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
257 commits
Select commit Hold shift + click to select a range
f69d894
fix pre-commit and fix READONLY linker keyword with clang
hathach Sep 3, 2025
2d979ee
ohci: Add functions used for explicit cache operations
ArcaneNibble Sep 12, 2025
839149c
ohci: Align TDs to cache lines
ArcaneNibble Sep 12, 2025
330d9d7
ohci: Re-implement TD allocation, matching the specification
ArcaneNibble Sep 12, 2025
915d212
ohci: Perform explicit cache operations on TDs, buffers
ArcaneNibble Sep 12, 2025
b9378eb
ohci: Use uncached alias to access EDs
ArcaneNibble Sep 12, 2025
24bc2ff
Add UAC1.0 defines
HiFiPhile Sep 27, 2025
78121a8
Update UAC2 naming
HiFiPhile Sep 27, 2025
9637a20
More descriptors working
HiFiPhile Sep 28, 2025
289680a
Add basic UAC1 support
HiFiPhile Sep 28, 2025
8f9eee6
Implement UAC1 IN flow control
HiFiPhile Sep 28, 2025
5d179c2
Update TUD_AUDIO_EP_SIZE macro
HiFiPhile Sep 29, 2025
9afe71c
Add UAC1 support to speaker example
HiFiPhile Sep 29, 2025
9f75b32
Add UAC1 support to audio_test_multi_rate example
HiFiPhile Sep 29, 2025
56b1ce2
fix descriptor walking
HiFiPhile Sep 29, 2025
e463e87
support UAC1 without IAD
HiFiPhile Sep 30, 2025
7867fa6
Remove feedback format correction since no longer needed
HiFiPhile Sep 30, 2025
d510858
Minor fixes
HiFiPhile Sep 30, 2025
1ee113e
better EP type detection
HiFiPhile Oct 1, 2025
1cec005
examples/device/*_freertos: expand stack size when needed
karlp Oct 1, 2025
cd9266b
Add note about bRefresh value
HiFiPhile Oct 1, 2025
e0a589c
dwc2: support ISO IN transfer when bInterval > 1
HiFiPhile Oct 2, 2025
12a2fe3
Update feedback params on frequency change
HiFiPhile Oct 2, 2025
01477c4
cleanup
HiFiPhile Oct 2, 2025
4ae26db
Fix feedback param lag
HiFiPhile Oct 2, 2025
d322207
Add UAC1 support to uac2_headset example
HiFiPhile Oct 2, 2025
05ea8cf
Merge remote-tracking branch 'tinyusb/master' into uac1
HiFiPhile Oct 3, 2025
1ded8ac
Update headset example
HiFiPhile Oct 3, 2025
0b630f0
Merge branch 'master' into fork/HiFiPhile/uac1
hathach Oct 4, 2025
e38172f
Fix descriptor looping
HiFiPhile Oct 4, 2025
3c33aff
Fix jlink device name
HiFiPhile Oct 4, 2025
6acf49e
Use one control buffer as EP0 has no concurrency
HiFiPhile Oct 4, 2025
afdfb08
Fix HIS stylus descriptor and hid_composite example
HiFiPhile Oct 5, 2025
f272d87
remove dcd_esp32sx which is replaced by dwc2
hathach Oct 6, 2025
f8ef71d
Merge pull request #3282 from hathach/remove-dcd_esp32sx
hathach Oct 6, 2025
e72a9eb
Merge pull request #3280 from HiFiPhile/hid_stylus
hathach Oct 6, 2025
044512c
fix typo
hathach Oct 6, 2025
7a96291
Merge pull request #3283 from hathach/fix-typo
hathach Oct 6, 2025
54fffd0
Fix preset with espressif
HiFiPhile Oct 6, 2025
5ac0bed
dcd/dwc2: fix enumration when EP0 size=8
HiFiPhile Oct 6, 2025
fedcdef
Merge remote-tracking branch 'tinyusb/master' into dwc2_ep0
HiFiPhile Oct 6, 2025
16dd749
dcd/dwc2: cleanup previous pending EP0 IN transfer if a SETUP packet …
HiFiPhile Oct 7, 2025
bf69c49
fix incorrect MTP xact_len calculation
RigoLigoRLC Oct 7, 2025
21ed72b
Merge pull request #3284 from RigoLigoRLC/upstream-contrib-mtp-xact
HiFiPhile Oct 8, 2025
e976a80
stm32h7rs: fix typo in makefile
HiFiPhile Oct 8, 2025
87523f2
Merge pull request #3288 from hathach/h7rs_typo
hathach Oct 9, 2025
2f90d7b
added AGENTS.md
hathach Oct 9, 2025
97f814a
Update AGENTS.md
hathach Oct 9, 2025
5cc9ade
Merge pull request #3289 from hathach/add-agents-md
hathach Oct 9, 2025
970384d
Merge branch 'master' into fork/ArcaneNibble/ohci-upstream
hathach Oct 9, 2025
0587419
Initial plan
Copilot Oct 9, 2025
5a82112
docs: fix .rst links to use Sphinx :doc: role for proper HTML generation
Copilot Oct 9, 2025
20c8e92
Merge pull request #3290 from hathach/copilot/fix-dependency-link-in-…
hathach Oct 9, 2025
d4374bb
centralize hcd_dcache_uncached() for ED
hathach Oct 9, 2025
a97da37
Fix dcd_int_enable when remapping the USB interrupt
tangpipi Oct 9, 2025
cc82e08
fix todo size in list_reverse()
hathach Oct 9, 2025
0fab57b
Merge pull request #3279 from HiFiPhile/dwc2_ep0
hathach Oct 9, 2025
8f2e3ed
Merge pull request #3292 from tangpipi/fix_at32_remap
hathach Oct 9, 2025
aa0fc2e
successfully
poornadharshan13-rgb Oct 10, 2025
83baf13
try to enable ohci for lpc55 but not working, probably clock issue
hathach Oct 10, 2025
d4fa891
dcd/dwc2: fix EP0 mulit-packet logic, write the packet directly if nu…
HiFiPhile Oct 10, 2025
37592da
usbd: support set EP0 buffer size
HiFiPhile Oct 10, 2025
c566db8
example/dfu: add MSOS 2.0 descriptor for auto driver loading
HiFiPhile Oct 10, 2025
b5faf4f
increase timeout for mtp hil test
hathach Oct 11, 2025
33b6954
Merge pull request #3297 from hathach/hil-increase-timeout-for-mtp
hathach Oct 11, 2025
2e29d1c
Merge pull request #3293
hathach Oct 11, 2025
b19d863
Merge branch 'master' into fork/adam-embedded/with-stm32l496nucleo
hathach Oct 11, 2025
10e86b0
correct l496zg variant, fix build warning
hathach Oct 11, 2025
785454a
Merge branch 'master' into dwc2_ep0
HiFiPhile Oct 11, 2025
4a52edd
dfu: remove transfer buffer out of USB section, since data will copy …
HiFiPhile Oct 11, 2025
080ca2e
Move control buffer out of USB section
HiFiPhile Oct 11, 2025
1902377
Merge branch 'master' into uac1
HiFiPhile Oct 11, 2025
b9b1c64
Merge branch 'master' into dwc2_iso_incomp
HiFiPhile Oct 11, 2025
97741a5
Merge pull request #3220 from adam-embedded/with-stm32l496nucleo
hathach Oct 12, 2025
ee7a7c5
get cmake build with 54h20 not tested on actual hw, probably not running
hathach Oct 13, 2025
dacbe8e
update make build system rename pca10095 to nrf5340dk
hathach Oct 13, 2025
84f0cda
rename pca10056 to nrf52840dk, pca10059 to nrf52840dongle
hathach Oct 13, 2025
e0ee32c
fix build with west zephyr
hathach Oct 13, 2025
8242ffd
Add qodana.yaml file
qodana-bot Oct 13, 2025
23fc90a
Add github workflow file
qodana-bot Oct 13, 2025
77e0d06
Merge pull request #3300 from hathach/qodana-automation-241005150
hathach Oct 13, 2025
92d3414
Revert "Add qodana CI checks"
hathach Oct 13, 2025
7ccda4d
Merge pull request #3302 from hathach/revert-3300-qodana-automation-2…
hathach Oct 13, 2025
0c3631c
add tools that provided freely to develop project
hathach Oct 13, 2025
9a25b9e
Update README.rst
hathach Oct 14, 2025
9fd9fc6
Merge pull request #3304 from hathach/add-tool-for-oss
hathach Oct 14, 2025
38255ff
Merge pull request #3299 from hathach/initial-nrf54h20
hathach Oct 14, 2025
9bf18d0
move make.mk to hw/bsp/family_support.mk
hathach Oct 14, 2025
47b13f6
improve cmake warning flags, fix various warnings in examples
hathach Oct 14, 2025
a5fde08
refactor same7x using codex
hathach Oct 14, 2025
0a2b6e7
more warnings fix
hathach Oct 14, 2025
c48bbfa
more make refactor
hathach Oct 14, 2025
4bdd08e
fix missing prototypes
hathach Oct 14, 2025
367044e
fix lots of warnings for missing-prototypes for irqhandler
hathach Oct 14, 2025
6f93fee
suppress some warnings in zephyr build
hathach Oct 14, 2025
2a8811e
merge samd2x and saml2x bsp, add OPT_MCU_SAML2X to replace OPT_MCU_SA…
hathach Oct 14, 2025
6a1117a
refactor sltb009a to family efm32
hathach Oct 14, 2025
4efb171
fix unused warnings
hathach Oct 15, 2025
ce2dab7
more warning fix
hathach Oct 15, 2025
9bd3622
merge nuc121 and 125
hathach Oct 15, 2025
0d690c8
update nuc121/125
hathach Oct 15, 2025
8199ed6
refactor all nuc to family
hathach Oct 15, 2025
3ce037d
add nuc to ci build
hathach Oct 15, 2025
a8be575
fix build warning with clang
hathach Oct 15, 2025
53deb6c
fix more warnings
hathach Oct 15, 2025
55227a6
fix more warnings
hathach Oct 15, 2025
fd9d43d
refactor spresense into cxd56. there is no orphan board in bsp.
hathach Oct 15, 2025
d96d468
skip mtp in hil test, it seems not stable and failed too often
hathach Oct 15, 2025
4dfac3f
Update hw/bsp/same7x/boards/same70_qmtech/board.h
hathach Oct 15, 2025
79445c2
Merge pull request #3306 from hathach/refactor-buildsystem
hathach Oct 15, 2025
e93e47a
add tu_div_round_nearest() (only handle positive) to replace DIV_ROUN…
hathach Oct 16, 2025
2f3b21a
fix some warnings detected by pvs-studio
hathach Oct 16, 2025
e4ff88f
WIP improved docs (feat. LLM)
c1570 Sep 22, 2025
e7b851d
Naming conventions, buffer handling
c1570 Sep 24, 2025
75f2a84
improve flow
c1570 Sep 24, 2025
a332acf
rearrage TOC
c1570 Sep 24, 2025
39e2e51
improved getting_started, integrated "first device/host"
c1570 Sep 26, 2025
82aa46d
more consolidation
c1570 Sep 26, 2025
1f908d8
getting_started structure
c1570 Sep 26, 2025
fa599e3
streamlined getting_started
c1570 Sep 27, 2025
9dd67b1
revert unnecessary Sphinx config changes
c1570 Oct 20, 2025
418239a
add missing class driver callbacks
c1570 Oct 20, 2025
3cb248f
add note about CMake
c1570 Oct 20, 2025
989acc1
use CMake in getting_started examples
c1570 Oct 21, 2025
c8a1b75
refactor family.cmake: rename add_board_target() to family_add_board(…
hathach Oct 17, 2025
bde4499
fix more build
hathach Oct 22, 2025
7c95d9b
force clang asm with -x assembler-with-cpp
hathach Oct 23, 2025
ac37176
Merge pull request #3316 from hathach/more-cmake-refactor
hathach Oct 23, 2025
878c8f2
enable IAR CState with IAR_CSTAT=1
hathach Oct 24, 2025
f39dcae
fix several warnings
hathach Oct 24, 2025
55c6d07
fix more warnings
hathach Oct 24, 2025
4dd9122
Merge remote-tracking branch 'upstream/master' into uac1
HiFiPhile Oct 24, 2025
b08f672
add pvs-studio analyze to ci
hathach Oct 24, 2025
9f1a86c
Ensure type promotion
HiFiPhile Oct 24, 2025
948ba20
add pvs-studio analyze to ci
hathach Oct 24, 2025
5e3e243
merge codeql and pvs-studio to static_analysis.yml
hathach Oct 25, 2025
6cc445e
download ninja binary, apt seems take too long ~ 1 min
hathach Oct 25, 2025
531009c
add SonarQube scan
hathach Oct 25, 2025
5818db4
add SonarQube scan
hathach Oct 25, 2025
80309e4
dcd/dwc2: clear pending suspend interrupt before usb reset
peppapighs Oct 25, 2025
d7c4bf1
add IAR CStat to static_analysis.yml
hathach Oct 25, 2025
42f000d
iar cstat require cmake at least 4.1
hathach Oct 25, 2025
96d5109
Merge pull request #3318 from hathach/static-analysis
hathach Oct 25, 2025
a6efc7d
Merge pull request #3319 from peppapighs/dwc2-usbsuspm
HiFiPhile Oct 25, 2025
8865ec4
update static_analysis.yml workflow
hathach Oct 27, 2025
d55e074
improve warnings with rp2040 family
hathach Oct 27, 2025
cc597d5
disable warning for startup file
hathach Oct 27, 2025
621123b
added .pvsconfig to exclude some rules
hathach Oct 27, 2025
a12806a
fix descriptor warning when shifting zero
hathach Oct 27, 2025
113a763
fix warning with strict prototypes warnings
hathach Oct 27, 2025
417f44a
fix security in gh action
hathach Oct 28, 2025
d92b810
fix Identifiers that start with '__' or '_[A-Z]' are reserved.
hathach Oct 28, 2025
f35c421
IAR C-Stat exclude mcu folder
hathach Oct 28, 2025
78bd623
filter out sarif for codeql hw/mcu and lib/
hathach Oct 28, 2025
3ff5415
Merge pull request #3320 from hathach/more-sast
hathach Oct 29, 2025
4da7845
Merge branch 'master' into dwc2_ep0
hathach Oct 29, 2025
53c155b
Implement tud_audio_set_ep_in_target_fifo_size function to set the ta…
gabChouin Oct 29, 2025
ec8ef7a
increase freertos stack size when debug is enabled
hathach Oct 30, 2025
813eba2
Merge pull request #3271 from karlp/pr/examplesd-freertos-stacks
hathach Oct 30, 2025
88305b1
Merge branch 'master' into add-ohci-lpc55
hathach Oct 30, 2025
3f1f714
update lpc55 family.c
hathach Oct 30, 2025
fc3857e
Merge pull request #3294 from hathach/add-ohci-lpc55
hathach Oct 30, 2025
032de0b
Video Class: New callback function added which allows to generate fra…
Oct 30, 2025
7c4cc0f
Refactor IN fifo write
HiFiPhile Oct 30, 2025
b8cea4a
Added bufferless operation to the video capture example. Can be teste…
Oct 30, 2025
889cde7
Video class: Changed pararameters of payload request to a dedicated s…
Oct 30, 2025
aa739c9
Merge branch 'master' into uac1
HiFiPhile Oct 30, 2025
82b0e2d
Retry until bInterval
HiFiPhile Oct 30, 2025
beea882
Simply restart the transfer
HiFiPhile Oct 30, 2025
6837e47
Merge branch 'master' into fork/ArcaneNibble/ohci-upstream
hathach Oct 31, 2025
dfcab87
Merge pull request #3270 from HiFiPhile/uac1
hathach Oct 31, 2025
cee7937
Add boundary check
HiFiPhile Oct 31, 2025
be4b38c
Skip TXFE for EP0
HiFiPhile Oct 31, 2025
6b3970d
Fixed trailing whitespaces in files (used wrong editor)
Oct 31, 2025
a6c16d1
Merge pull request #3248 from ArcaneNibble/ohci-upstream
hathach Nov 1, 2025
9d46cca
add STM32U3 device (adjusted from STM32U0)
tswan22 Nov 1, 2025
ca44c77
Merge branch 'master' of https://github.com/hathach/tinyusb
tswan22 Nov 1, 2025
bda7efb
fix #2942, include stdio if CFG_TUSB_DEBUG > 0 and CFG_TUSB_DEBUG_PRI…
hathach Nov 3, 2025
8e9ba21
fix alert using input in gh action. fix some conversion int
hathach Nov 3, 2025
67b2a5c
remove binary prefix for portability
hathach Nov 3, 2025
00f3746
fixing alert by scanning tool
hathach Nov 3, 2025
22f01ae
fix more warnings/alerts
hathach Nov 3, 2025
8979af3
Fixed more alert found by PVS-Studio
hathach Nov 3, 2025
1f04fe7
added .clang-format
hathach Nov 5, 2025
58b4104
Merge pull request #3326 from hathach/fix-code-alerts
hathach Nov 5, 2025
0172f40
update espressif cmake
hathach Nov 6, 2025
1f84dd5
fix compile issue when enable both host and device for dwc2
hathach Nov 6, 2025
cd90d94
make host info to devcie cdc to work with freertos/noos
hathach Nov 6, 2025
94c1e05
fix typo detected by copilot
hathach Nov 6, 2025
6641550
Merge pull request #3333 from hathach/espressif-dual-mode
hathach Nov 6, 2025
86a4990
fix more alerts
hathach Nov 5, 2025
9fac6dd
fix more alerts found by pvs-studio
hathach Nov 7, 2025
5d35182
Apply suggestions from code review
hathach Nov 7, 2025
1634d11
Merge pull request #3325 from tswan22/master
HiFiPhile Nov 7, 2025
bec9676
osal/none: add nested count to spin lock
HiFiPhile Jun 15, 2025
f9bbad7
Merge remote-tracking branch 'tinyusb/master' into audio_ep_in_target…
HiFiPhile Nov 7, 2025
58f2951
Fixup
HiFiPhile Nov 7, 2025
239ed48
Cleanup
HiFiPhile Nov 7, 2025
4fcce0f
Implement RX FIFO threshold adjustment
HiFiPhile Nov 7, 2025
f188a40
Typo
HiFiPhile Nov 7, 2025
91c3a4f
Merge pull request #3321 from gabChouin/audio_ep_in_target_fifo_size
HiFiPhile Nov 7, 2025
652342b
fix more alerts found by pvs-studio
hathach Nov 7, 2025
b83b36b
Merge remote-tracking branch 'origin/fix-alerts-3' into fix-alerts-3
hathach Nov 7, 2025
dc196b2
Prevent tu_edpt_number() from returning an invalid endpoint number
ldube Nov 7, 2025
7f173ab
fix more alerts
hathach Nov 8, 2025
96f35fc
Merge pull request #3334 from hathach/fix-alerts-3
hathach Nov 8, 2025
6364a4d
Merge branch 'master' into fork/c1570/improved_docs
hathach Nov 10, 2025
a1ae5b2
update doc
hathach Nov 11, 2025
8a094e8
Merge pull request #3278 from c1570/improved_docs
hathach Nov 11, 2025
fc661ab
migrate midi_device to use edpt stream API
hathach Nov 12, 2025
8b8f1f8
Merge pull request #3337 from hathach/midi-edpt-stream
hathach Nov 12, 2025
f11adb0
migrate cdc device to use edpt stream API
hathach Nov 12, 2025
397a3af
clear endpoint stream when open for cdc_host and midi_host
hathach Nov 13, 2025
2b07fa6
Apply suggestions from code review
hathach Nov 13, 2025
aac7ad1
cdc device tx_persistent for dual host info to help with hil test
hathach Nov 13, 2025
1f8968f
Merge remote-tracking branch 'origin/cdc-edpt-stream' into cdc-edpt-s…
hathach Nov 13, 2025
c9a9e94
tweak to dual host info device cdc to make it easier to pass hil test
hathach Nov 13, 2025
a3a5a41
Merge pull request #3339 from hathach/cdc-edpt-stream
hathach Nov 14, 2025
fc5415b
Merge pull request #3335 from ldube/master
HiFiPhile Nov 14, 2025
ac903db
Merge remote-tracking branch 'tinyusb/master' into embedded-ideas/master
HiFiPhile Nov 14, 2025
20c3644
Merge pull request #3322 from embedded-ideas/master
HiFiPhile Nov 14, 2025
6b28a44
make TUP_DCD_EDPT_ISO_ALLOC i.e dcd_edpt_iso_alloc()/dcd_edpt_iso_act…
hathach Nov 15, 2025
be9d197
make TUP_DCD_EDPT_ISO_ALLOC i.e dcd_edpt_iso_alloc()/dcd_edpt_iso_act…
hathach Nov 17, 2025
1173502
circcleci run all job with large, also try to fix context deadline ex…
hathach Nov 17, 2025
66c8452
Merge pull request #3345 from hathach/update-iso-alloc
hathach Nov 17, 2025
98f7b0c
Merge branch 'master' into fork/HiFiPhile/dwc2_iso_incomp
hathach Nov 18, 2025
6c14093
Merge branch 'master' into fork/HiFiPhile/xfer_close
hathach Nov 18, 2025
3b728c7
Fix link to Getting Started documentation
ToonVanEyck Nov 18, 2025
d46f71b
Merge pull request #3347 from ToonVanEyck/master
HiFiPhile Nov 18, 2025
e4a04b2
improve closing endpoint and channel
hathach Nov 18, 2025
fd31610
Merge branch 'refs/heads/master' into dwc2_ep0
hathach Nov 19, 2025
1df116a
clean up
hathach Nov 19, 2025
b2dc419
rename CFG_TUD_ENDPOINT0_BUFSIZE to make it more consistent
hathach Nov 19, 2025
4b92d32
device_info wait 100ms for host's uart, needed for hil test
hathach Nov 19, 2025
35447b7
Merge pull request #3295 from hathach/dwc2_ep0
hathach Nov 19, 2025
21ef00f
Merge branch 'master' into fork/HiFiPhile/dwc2_iso_incomp
hathach Nov 19, 2025
39c7808
extract to handle_incomplete_iso_in() for readability
hathach Nov 19, 2025
6daf07b
Merge pull request #3275 from HiFiPhile/dwc2_iso_incomp
hathach Nov 19, 2025
650c4b0
return if spin is underflow
hathach Nov 19, 2025
284895b
Merge pull request #3151 from HiFiPhile/lock_cnt
hathach Nov 19, 2025
15ed920
Merge pull request #3076 from HiFiPhile/xfer_close
hathach Nov 19, 2025
e0155eb
fix more alerts
hathach Nov 19, 2025
19fd616
Apply suggestions from code review
hathach Nov 19, 2025
d1a261e
Merge pull request #3348 from hathach/fix-more-warnings
hathach Nov 19, 2025
9d7b401
remove copilot-instructions.md, update and use AGENTS.md instead
hathach Nov 19, 2025
f6a77b8
Bump version to 0.20.0
hathach Nov 19, 2025
790c7a0
Merge pull request #3349 from hathach/update-agents
hathach Nov 19, 2025
551520d
update changelog.rst
hathach Nov 19, 2025
3af1bec
Merge pull request #3350 from hathach/update-changelog
hathach Nov 20, 2025
5080fa8
Merge tag '0.20.0' into sync/upstream_v0.20
roma-jam Nov 26, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
19 changes: 19 additions & 0 deletions .PVS-Studio/.pvsconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
//V_EXCLUDE_PATH */iar/cxarm*
//V_EXCLUDE_PATH */pico-sdk/*
//V_EXCLUDE_PATH */esp-idf/*
//V_EXCLUDE_PATH */hw/mcu/*
//V_EXCLUDE_PATH */hw/bsp/espressif/components/*
//V_EXCLUDE_PATH */lib/*

//-V::2506 MISRA. A function should have a single point of exit at the end.
//-V::2514 MISRA. Unions should not be used.
//-V::2520 [MISRA-C-16.3] Every switch-clause should be terminated by an unconditional 'break' statement
//-V:memcpy:2547 [MISRA-C-17.7] The return value of non-void function 'memcpy' should be used.
//-V:memmove:2547 [MISRA-C-17.7] The return value of non-void function 'memmove' should be used.
//-V:printf:2547 [MISRA-C-17.7]
//-V::2584::{gintsts} dwc2 interrupt handler
//-V::2584::{hcint} dwc2 interrupt handler
//-V::2600 [MISRA-C-21.6] The function with the 'printf' name should not be used.
//+V2614 DISABLE_LENGHT_LIMIT_CHECK:YES
//-V:memcpy:2628 Pointer arguments to the 'memcpy' function should be pointers to qualified or unqualified versions of compatible types.
//-V::2659 [MISRA-C-16.1] Switch statements should be well-formed. Every switch-clause should be terminated by an unconditional 'break' statement
18 changes: 1 addition & 17 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,6 @@ jobs:
BUILDSYSTEM_TOOLCHAIN+=("cmake arm-iar")
fi
RESOURCE_LARGE='["nrf", "imxrt", "stm32f4", "stm32h7 stm32h7rs"]'
gen_build_entry() {
local build_system="$1"
local toolchain="$2"
Expand Down Expand Up @@ -61,21 +59,7 @@ jobs:
FAMILY=$(echo $MATRIX_JSON | jq -r ".\"$toolchain\"")
echo "FAMILY_${toolchain}=$FAMILY"
# FAMILY_LARGE = FAMILY - RESOURCE_LARGE
# Separate large from medium+ resources
FAMILY_LARGE=$(jq -n --argjson family "$FAMILY" --argjson resource "$RESOURCE_LARGE" '$family | map(select(IN($resource[])))')
FAMILY=$(jq -n --argjson family "$FAMILY" --argjson resource "$RESOURCE_LARGE" '$family | map(select(IN($resource[]) | not))')
if [[ $toolchain == esp-idf || $toolchain == arm-iar ]]; then
gen_build_entry "$build_system" "$toolchain" "$FAMILY" "large"
else
gen_build_entry "$build_system" "$toolchain" "$FAMILY" "medium+"
# add large resources if available
if [ "$(echo $FAMILY_LARGE | jq 'length')" -gt 0 ]; then
gen_build_entry "$build_system" "$toolchain" "$FAMILY_LARGE" "large"
fi
fi
gen_build_entry "$build_system" "$toolchain" "$FAMILY" "large"
done
- continuation/continue:
Expand Down
5 changes: 4 additions & 1 deletion .circleci/config2.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ commands:
chmod +x toolchain.run
./toolchain.run -p ~/cache/<< parameters.toolchain >>/gnurx -y
elif [[ << parameters.toolchain >> == arm-iar ]]; then
wget --progress=dot:giga https://netstorage.iar.com/FileStore/STANDARD/001/003/926/iar-lmsc-tools_1.8_amd64.deb -O ~/cache/<< parameters.toolchain >>/iar-lmsc-tools.deb
wget --progress=dot:giga $toolchain_url -O ~/cache/<< parameters.toolchain >>/toolchain.deb
else
wget --progress=dot:giga $toolchain_url -O toolchain.tar.gz
Expand All @@ -44,6 +45,7 @@ commands:
# Add toolchain to PATH
if [[ << parameters.toolchain >> == arm-iar ]]; then
# Install IAR since we only cache deb file
sudo dpkg -i ~/cache/<< parameters.toolchain >>/iar-lmsc-tools.deb
sudo dpkg --ignore-depends=libusb-1.0-0 -i ~/cache/<< parameters.toolchain >>/toolchain.deb
echo "export PATH=$PATH:/opt/iar/cxarm/arm/bin" >> $BASH_ENV
else
Expand Down Expand Up @@ -102,6 +104,7 @@ commands:

- run:
name: Build
no_output_timeout: 20m
command: |
if [ << parameters.toolchain >> == esp-idf ]; then
docker run --rm -v $PWD:/project -w /project espressif/idf:v5.3.2 python tools/build.py << parameters.family >>
Expand All @@ -125,7 +128,7 @@ jobs:
parameters:
resource_class:
type: string
default: medium+
default: large
build-system:
type: string
toolchain:
Expand Down
107 changes: 70 additions & 37 deletions .clang-format
Original file line number Diff line number Diff line change
@@ -1,66 +1,99 @@
# Generated from CLion C/C++ Code Style settings
---
Language: Cpp
BasedOnStyle: LLVM
AccessModifierOffset: -2
AlignAfterOpenBracket: Align
AlignConsecutiveAssignments: None
AlignOperands: Align
AlignConsecutiveAssignments:
Enabled: true
AcrossEmptyLines: false
AcrossComments: false
AlignConsecutiveBitFields:
Enabled: true
AcrossEmptyLines: false
AcrossComments: false
AlignConsecutiveDeclarations:
Enabled: true
AcrossEmptyLines: false
AcrossComments: false
AlignConsecutiveMacros:
Enabled: true
AcrossEmptyLines: true
AcrossComments: false
AlignConsecutiveShortCaseStatements:
Enabled: true
AcrossEmptyLines: true
AcrossComments: true
AlignCaseColons: false
AlignEscapedNewlines: LeftWithLastLine
AlignOperands: true
AlignTrailingComments:
Kind: Always
OverEmptyLines: 2
AllowAllArgumentsOnNextLine: false
AllowAllConstructorInitializersOnNextLine: false
AllowAllParametersOfDeclarationOnNextLine: false
AllowShortBlocksOnASingleLine: Always
AllowShortBlocksOnASingleLine: Empty
AllowShortCaseExpressionOnASingleLine: true
AllowShortCaseLabelsOnASingleLine: false
AllowShortFunctionsOnASingleLine: All
AllowShortIfStatementsOnASingleLine: Always
AllowShortLambdasOnASingleLine: All
AllowShortLoopsOnASingleLine: true
AlwaysBreakAfterReturnType: None
AllowShortEnumsOnASingleLine: false
AllowShortFunctionsOnASingleLine: None
AllowShortIfStatementsOnASingleLine: Never
AlwaysBreakTemplateDeclarations: Yes
BinPackArguments: true
BreakBeforeBraces: Custom
BraceWrapping:
AfterCaseLabel: false
AfterClass: false
AfterControlStatement: Never
AfterControlStatement: false
AfterEnum: false
AfterFunction: false
AfterNamespace: false
AfterStruct: false
AfterUnion: false
BeforeCatch: false
AfterExternBlock: false
BeforeCatch: true
BeforeElse: false
IndentBraces: false
SplitEmptyFunction: false
BeforeLambdaBody: false
BeforeWhile: false
SplitEmptyFunction: true
SplitEmptyRecord: true
SplitEmptyNamespace: true
BracedInitializerIndentWidth: 2
BreakBeforeBinaryOperators: None
BreakBeforeTernaryOperators: true
BreakConstructorInitializers: BeforeColon
BreakInheritanceList: BeforeColon
ColumnLimit: 0
CompactNamespaces: false
ContinuationIndentWidth: 4
IndentCaseLabels: true
BreakConstructorInitializers: AfterColon
BreakConstructorInitializersBeforeComma: false
ContinuationIndentWidth: 2
ColumnLimit: 120
ConstructorInitializerAllOnOneLineOrOnePerLine: false
Cpp11BracedListStyle: true
IncludeBlocks: Preserve
IncludeCategories:
- Regex: '^<.*'
Priority: 1
- Regex: '^".*'
Priority: 2
- Regex: '.*'
Priority: 3
IncludeIsMainRegex: '([-_](test|unittest))?$'
IndentPPDirectives: BeforeHash
IndentWidth: 2
KeepEmptyLinesAtTheStartOfBlocks: true
InsertBraces: true
IndentCaseLabels: true
InsertNewlineAtEOF: true
MacroBlockBegin: ''
MacroBlockEnd: ''
MaxEmptyLinesToKeep: 2
NamespaceIndentation: All
ObjCSpaceAfterProperty: false
ObjCSpaceBeforeProtocolList: true
PointerAlignment: Right
PenaltyBreakBeforeFirstCallParameter: 1000000
PenaltyBreakOpenParenthesis: 1000000
QualifierAlignment: Custom
QualifierOrder: ['static', 'const', 'volatile', 'restrict', 'type']
ReflowComments: false
SpaceAfterCStyleCast: true
SpaceAfterLogicalNot: false
SpaceAfterTemplateKeyword: false
SpaceBeforeAssignmentOperators: true
SpaceBeforeCpp11BracedList: false
SpaceBeforeCtorInitializerColon: true
SpaceBeforeInheritanceColon: true
SpaceBeforeParens: ControlStatements
SpaceBeforeRangeBasedForLoopColon: false
SpaceInEmptyParentheses: false
SpacesBeforeTrailingComments: 0
SpacesInAngles: false
SpacesInConditionalStatement: false
SpacesInCStyleCastParentheses: false
SpacesInContainerLiterals: true
SpacesInParentheses: false
SpacesInSquareBrackets: false
SortIncludes: false
TabWidth: 2
UseTab: Never
...
9 changes: 7 additions & 2 deletions .github/actions/get_deps/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,16 @@ runs:
- name: Linux dependencies
if: runner.os == 'Linux'
run: |
sudo apt install -y ninja-build
NINJA_URL=https://github.com/ninja-build/ninja/releases/download/v1.13.1/ninja-linux.zip
wget $NINJA_URL -O ninja-linux.zip
unzip ninja-linux.zip -d ninja-bin
echo >> $GITHUB_PATH "${{ github.workspace }}/ninja-bin"
shell: bash

- name: Get Dependencies
env:
ARG: ${{ inputs.arg }}
run: |
python3 tools/get_deps.py ${{ inputs.arg }}
python3 tools/get_deps.py ${ARG}
echo "PICO_SDK_PATH=${{ github.workspace }}/pico-sdk" >> $GITHUB_ENV
shell: bash
10 changes: 7 additions & 3 deletions .github/actions/setup_toolchain/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,10 @@ runs:
inputs.toolchain != 'arm-gcc' &&
inputs.toolchain != 'esp-idf'
id: set-toolchain-url
env:
TOOLCHAIN: ${{ inputs.toolchain }}
run: |
TOOLCHAIN_URL=$(jq -r '."${{ inputs.toolchain }}"' .github/actions/setup_toolchain/toolchain.json)
TOOLCHAIN_URL=$(jq -r --arg tc "$TOOLCHAIN" '.[$tc]' .github/actions/setup_toolchain/toolchain.json)
echo "toolchain_url=$TOOLCHAIN_URL"
echo "toolchain_url=$TOOLCHAIN_URL" >> $GITHUB_OUTPUT
shell: bash
Expand All @@ -47,11 +49,13 @@ runs:

- name: Set toolchain option
id: set-toolchain-option
env:
TOOLCHAIN: ${{ inputs.toolchain }}
run: |
BUILD_OPTION=""
if [[ "${{ inputs.toolchain }}" == *"clang"* ]]; then
if [[ "$TOOLCHAIN" == *"clang"* ]]; then
BUILD_OPTION="--toolchain clang"
elif [[ "${{ inputs.toolchain }}" == "arm-iar" ]]; then
elif [[ "$TOOLCHAIN" == "arm-iar" ]]; then
BUILD_OPTION="--toolchain iar"
fi
echo "build_option=$BUILD_OPTION"
Expand Down
29 changes: 18 additions & 11 deletions .github/actions/setup_toolchain/download/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,27 +21,34 @@ runs:

- name: Install Toolchain
if: steps.cache-toolchain-download.outputs.cache-hit != 'true'
env:
TOOLCHAIN: ${{ inputs.toolchain }}
TOOLCHAIN_URL: ${{ inputs.toolchain_url }}
run: |
mkdir -p ~/cache/${{ inputs.toolchain }}
mkdir -p ~/cache/${TOOLCHAIN}

if [[ ${{ inputs.toolchain }} == rx-gcc ]]; then
wget --progress=dot:giga ${{ inputs.toolchain_url }} -O toolchain.run
if [[ ${TOOLCHAIN} == rx-gcc ]]; then
wget --progress=dot:giga ${TOOLCHAIN_URL} -O toolchain.run
chmod +x toolchain.run
./toolchain.run -p ~/cache/${{ inputs.toolchain }}/gnurx -y
elif [[ ${{ inputs.toolchain }} == arm-iar ]]; then
wget --progress=dot:giga ${{ inputs.toolchain_url }} -O ~/cache/${{ inputs.toolchain }}/cxarm.deb
./toolchain.run -p ~/cache/${TOOLCHAIN}/gnurx -y
elif [[ ${TOOLCHAIN} == arm-iar ]]; then
wget --progress=dot:giga https://netstorage.iar.com/FileStore/STANDARD/001/003/926/iar-lmsc-tools_1.8_amd64.deb -O ~/cache/${TOOLCHAIN}/iar-lmsc-tools.deb
wget --progress=dot:giga ${TOOLCHAIN_URL} -O ~/cache/${TOOLCHAIN}/cxarm.deb
else
wget --progress=dot:giga ${{ inputs.toolchain_url }} -O toolchain.tar.gz
tar -C ~/cache/${{ inputs.toolchain }} -xaf toolchain.tar.gz
wget --progress=dot:giga ${TOOLCHAIN_URL} -O toolchain.tar.gz
tar -C ~/cache/${TOOLCHAIN} -xaf toolchain.tar.gz
fi
shell: bash

- name: Setup Toolchain
env:
TOOLCHAIN: ${{ inputs.toolchain }}
run: |
if [[ ${{ inputs.toolchain }} == arm-iar ]]; then
sudo apt-get install -y ~/cache/${{ inputs.toolchain }}/cxarm.deb
if [[ ${TOOLCHAIN} == arm-iar ]]; then
sudo dpkg -i ~/cache/${TOOLCHAIN}/iar-lmsc-tools.deb
sudo apt install -y ~/cache/${TOOLCHAIN}/cxarm.deb
echo >> $GITHUB_PATH "/opt/iar/cxarm/arm/bin"
else
echo >> $GITHUB_PATH `echo ~/cache/${{ inputs.toolchain }}/*/bin`
echo >> $GITHUB_PATH `echo ~/cache/${TOOLCHAIN}/*/bin`
fi
shell: bash
14 changes: 10 additions & 4 deletions .github/actions/setup_toolchain/espressif/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,10 @@ runs:
using: "composite"
steps:
- name: Set DOCKER_ESP_IDF
env:
TOOLCHAIN: ${{ inputs.toolchain }}
run: |
DOCKER_ESP_IDF=$HOME/cache/${{ inputs.toolchain }}/docker_image.tar
DOCKER_ESP_IDF=$HOME/cache/${TOOLCHAIN}/docker_image.tar
echo "DOCKER_ESP_IDF=$DOCKER_ESP_IDF" >> $GITHUB_ENV
shell: bash

Expand All @@ -27,10 +29,12 @@ runs:

- name: Pull and Save Docker Image
if: steps.cache-toolchain-espressif.outputs.cache-hit != 'true'
env:
TOOLCHAIN_VERSION: ${{ inputs.toolchain_version }}
run: |
docker pull espressif/idf:${{ inputs.toolchain_version }}
docker pull espressif/idf:${TOOLCHAIN_VERSION}
mkdir -p $(dirname $DOCKER_ESP_IDF)
docker save -o $DOCKER_ESP_IDF espressif/idf:${{ inputs.toolchain_version }}
docker save -o $DOCKER_ESP_IDF espressif/idf:${TOOLCHAIN_VERSION}
du -sh $DOCKER_ESP_IDF
shell: bash

Expand All @@ -42,7 +46,9 @@ runs:
shell: bash

- name: Tag Local Image
env:
TOOLCHAIN_VERSION: ${{ inputs.toolchain_version }}
run: |
docker tag espressif/idf:${{ inputs.toolchain_version }} espressif/idf:tinyusb
docker tag espressif/idf:${TOOLCHAIN_VERSION} espressif/idf:tinyusb
docker images
shell: bash
2 changes: 1 addition & 1 deletion .github/actions/setup_toolchain/toolchain.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,5 @@
"msp430-gcc": "http://software-dl.ti.com/msp430/msp430_public_sw/mcu/msp430/MSPGCC/9_2_0_0/export/msp430-gcc-9.2.0.50_linux64.tar.bz2",
"riscv-gcc": "https://github.com/xpack-dev-tools/riscv-none-elf-gcc-xpack/releases/download/v13.2.0-2/xpack-riscv-none-elf-gcc-13.2.0-2-linux-x64.tar.gz",
"rx-gcc": "https://github.com/hathach/rx_device/releases/download/0.0.1/gcc-8.3.0.202411-GNURX-ELF.run",
"arm-iar": "https://netstorage.iar.com/FileStore/STANDARD/001/003/583/cxarm-9.60.4.deb"
"arm-iar": "https://netstorage.iar.com/FileStore/STANDARD/001/003/723/cxarm-9.70.1.deb"
}
Loading
Loading