2511 Commits

Author SHA1 Message Date
Dániel Buga
fd66bd3dcc
Encode AES key lengths in metadata (#3843) 2025-07-21 19:01:45 +00:00
Dániel Buga
0d9f43db29
Rewrite RNG (#3829) 2025-07-21 15:10:35 +00:00
Dániel Buga
94d955bfb0
Fix GPIO matrix typo (#3840) 2025-07-21 14:59:36 +00:00
Björn Quentin
7af0f3f3bb
use riscv 0.14.0 (#3842)
* use riscv 0.14.0

* Don't use the re-exports from esp-riscv-rt because of the RT feature

* fmt

* More fixes caused by the existence of the `rt` feature
2025-07-21 14:37:12 +00:00
Kirill Mikhailov
2518789a5f
cleanup esp-wifi README (#3841)
* cleanup `esp-wifi` README

* better links format

* lose weight, less words
2025-07-21 14:25:11 +00:00
Dániel Buga
39d1e115c1
Add SOC config that is hidden from the peri table (#3839) 2025-07-21 11:48:15 +00:00
Dániel Buga
da9a933e7e
Panic in exception handler (#3838) 2025-07-21 11:43:14 +00:00
Denys Vitali
c4c8d1d5b9
feat(esp-wifi): add Country Code (#3837)
* feat(esp-wifi): add Country Code

* fix: fmt, changelog

* fix: cast

* chore: cargo xtask fmt-packages

* chore: remove example

* fix: use Option<[u8;2]> for country code

* fix: return Some

* Use an opaque type

---------

Co-authored-by: Dániel Buga <bugadani@gmail.com>
2025-07-21 11:00:57 +00:00
Dániel Buga
af6ffb102f
Update instability (#3836) 2025-07-21 09:37:58 +00:00
Kirill Mikhailov
de67c31013
Add additional configuration section to docs in packages that lacked this (#3827)
* Add `additional configuration` to docs in packages that lacked this

* update esp-backtrace doc

* address review

Co-authored-by: Dániel Buga <bugadani@gmail.com>

* update the "greeting" entry

* conditioned "force frame pointers" entry

* oopsy

---------

Co-authored-by: Dániel Buga <bugadani@gmail.com>
2025-07-18 18:54:09 +00:00
Dániel Buga
fc27f983c9
Generate new semver baseline (#3835) 2025-07-18 15:32:05 +00:00
Szybet
d02dd21871
Make stats fields in esp alloc public (#3828)
* Update lib.rs

* Update CHANGELOG.md

* Update CHANGELOG.md
2025-07-18 12:44:55 +00:00
Dániel Buga
8c64b09ba7
Allow configuring longer WDT periods (#3816)
* Clean up with new PAC

* Allow configuring longer WDT periods

* Enable WDT after updating timeout
2025-07-17 14:50:26 +00:00
Dániel Buga
422f232f94
Add assign_resources (#3809)
* Add assign_resources

* Mark unstable
2025-07-17 14:48:00 +00:00
Dániel Buga
f9419afcc2
Update PAC (#3802) 2025-07-17 12:23:51 +00:00
Dániel Buga
e146e03c72
Use metadata to define LP peripheral FIFO sizes (#3812) 2025-07-17 12:16:24 +00:00
Dániel Buga
fdc2a33e67
Fix S2 PSRAM (#3811) 2025-07-17 09:53:07 +00:00
Dániel Buga
93ffa2ce8e
Clean up some unnecessary lints (#3807)
* Clean up unnecessary lint allows

* Clean up some unnecessary lints
2025-07-17 09:19:37 +00:00
rmsyn
eea0446e77
xtask: add metadata check (#3808)
* xtask: add metadata check

Adds a check for metadata changes to the xtask `update-metadata` task.

* ci: add metadata check to the `ci` workflow

Adds a check for uncommitted metadata changes to the `ci` workflow.
2025-07-16 18:11:53 +00:00
Scott Mabin
6b758d75b8
Finalize releases (#3805)
* Finalize crate releases

* changelog fixup

* fixup docsrs ci test

* docs fixup
esp-riscv-rt-v0.12.0 esp-hal-procmacros-v0.19.0 esp-backtrace-v0.17.0 esp-storage-v0.7.0 esp-rom-sys-v0.1.1 esp-hal-v1.0.0-rc.0 esp-ieee802154-v0.8.0 esp-metadata-generated-v0.1.0 esp-metadata-v0.8.0 esp-println-v0.15.0 esp-config-v0.5.0 esp-bootloader-esp-idf-v0.2.0 esp-hal-embassy-v0.9.0 esp-wifi-v0.15.0 xtensa-lx-rt-proc-macros-v0.4.0 xtensa-lx-rt-v0.20.0 xtensa-lx-v0.12.0
2025-07-16 10:29:34 +00:00
Scott Mabin
9dcaa153a3
fixup (#3804) 2025-07-16 08:46:42 +00:00
Scott Mabin
d15b6ac4e9
xtask: allow manually creating the PR (#3803) 2025-07-15 17:32:31 +00:00
Scott Mabin
21069f30a0
allow pre version bumps, run xtask tests in CI (#3800) 2025-07-15 16:23:56 +00:00
Scott Mabin
1d99fae9ee
ensure the plan phase accounts for perma-unstable packages (#3799) 2025-07-15 14:46:09 +00:00
Dániel Buga
634120f700
Clean up (#3798)
* Clean up unnecessary unsafe code

* Do not print level of unhandled interrupt

* Remove transmutes

* Changelog
2025-07-15 11:40:50 +00:00
Scott Mabin
e620244dfa
use new pac releases (#3797) 2025-07-15 11:13:57 +00:00
Dániel Buga
906fa56435
Update PAC (#3794) 2025-07-15 10:38:29 +00:00
Scott Mabin
6db771c80e
(re-)introduce the rt feature on esp-hal (#3706)
Adds the `rt` feature which disables `esp_hal::init` and removes
runtime symbols from the global name space.

Disabling the `rt` feature is the recommended way to use esp-hal as a
library.
2025-07-15 09:20:26 +00:00
Dániel Buga
978f9083a6
Use array-ified TWAI DATA registers (#3793) 2025-07-15 09:07:26 +00:00
Dániel Buga
9e5e643bb0
Disable USB pads before connecting a function (#3795) 2025-07-15 08:02:30 +00:00
Dániel Buga
496aeb864b
More touching up of generated code (#3791)
* Document remaining macros, update gpio syntax

* Update if_pin_is_type syntax, simplify impl

* Remove impl_for_pin_type

* Remove if_pin_is_type

* Remove the gpio macro
2025-07-14 13:05:27 +00:00
Dániel Buga
40fc4f2c6c
Make sure repeated matchers in for_each macros don't overlap (#3790)
* Allow generating separate repeat branches

* Generate separate repeated matchers for simple/expanded signals
2025-07-14 13:04:51 +00:00
Dániel Buga
df7ba7d427
Document esp-metadata-generated (#3787)
* Try to make it more obvious how to update e-m-g

* Document top level, ensure build-script docs are present

* Document Chip, hide Config
2025-07-11 12:48:25 +00:00
Dániel Buga
9e20bc3807
Fix, simplify and ignore PSRAM doc example (#3789)
* Run doctests with all needed features

* Fix, simplify and ignore PSRAM doc example
2025-07-11 12:47:20 +00:00
Björn Quentin
1e611aaf80
More doc replace (#3788)
* Allow macros for `doc_replace`

* Use `doc_replace` for the DMA macros

* Cleanup
2025-07-11 12:04:56 +00:00
Dániel Buga
3a5aa72c4e
Define analog/LP functions (#3781)
* Shorten name

* Define analog/rtc functions

* Try to make the data useable

* Remove general pin attributes

* Do not generate unnecessary expanded matchers

* Remove expanded GPIO cases

* Move simplified io_type to where it is used

* Fix RTC IO with resistors calls

* Hide macros on H2

* Define rtcio pins for C2/C3

* Fix S2

* Compare against the correct GPIO number

* Deduplicate

* Restore one waker per pin

* Remove case that is no longer needed, avoid inline(always)
2025-07-11 09:41:50 +00:00
Björn Quentin
5d1472d73e
Use doc_replace more (#3786)
* Use `doc_replace` more

* Fix

* Fix
2025-07-11 09:32:12 +00:00
Chris Mumford
d585f75997
Add configuration option to pin the RMT driver in RAM (#3778)
* Add configuration option to pin the RMT driver in RAM

Allow the RMT driver to pinned in RAM. Doing so avoids
a costly load from flash as using the RMT peripheral is often
a very time senstive operation.

Controlled by the `ESP_HAL_CONFIG_PLACE_RMT_DRIVER_IN_RAM`
environment variable.

* Update esp-config/CHANGELOG.md

* Add PR's

* Remove ESP_HAL_PLACE_RMT_DRIVER_IN_RAM from esp-config/README.md

* Make internal functions inline

This also results in a smaller executable. With a release build:

|           | In RAM    |   inline  |
|-----------|----------:|----------:|
| File size | 1,108,028 | 1,104,956 |
| .rwtext   | 0016d0    | 00153c    |
2025-07-11 09:29:18 +00:00
mennovf
b2c3b1d9bb
ESP32-S2: Go into hibernation if there's only Ext1 WakeupSource (#3785)
* Don't request rtc_perip power up in ext1 and enable hold for pad in case of rtc_peri power down.

* Update CHANGELOG.md with pull-request id

---------

Co-authored-by: Dániel Buga <bugadani@gmail.com>
2025-07-11 08:00:35 +00:00
Dániel Buga
547afd5cb9
Fix warnings, lint esp-hal without unstable (#3782)
* Prevent warnings

* Test esp-hal with no features enabled

* Update wording of error variants

* Re-generate semver baseline
2025-07-11 07:14:59 +00:00
Dániel Buga
c907645422
Add downcast to AnyPeripherals (#3784) 2025-07-10 14:10:28 +00:00
Dániel Buga
fbac30993a
Add AnyPin::downcast (#3783) 2025-07-10 12:53:30 +00:00
Juraj Sadel
cbdb4f05ba
Fix nightly CI (#3755)
* fix nightly ci

* reviews
2025-07-10 11:00:14 +00:00
Björn Quentin
3700497d7a
Better deal with multiple config files (#3774)
* Better deal with multiple config files

* Improve key handling

* Apply suggestion from review
2025-07-09 12:47:02 +00:00
Sergio Gasquez Arcos
3bc667ee4f
Add missing c-examples (#3770)
* docs: Add missing c-examples

* feat: Config docflags for `run doc-tests`

* docs: Update before/after macro and format code in docs

* docs: Improve chip! example

* docs: Fix format and error

* feat: Add ESP_HAL_DOCTEST environment variable for documentation tests
2025-07-09 12:46:22 +00:00
Dániel Buga
7343929d0e
Fix ADC resolution variant name (#3777)
* Fix ADC resolution variant

* Update esp-hal/src/analog/adc/xtensa.rs

Co-authored-by: Juraj Sadel <jurajsadel@gmail.com>

---------

Co-authored-by: Juraj Sadel <jurajsadel@gmail.com>
2025-07-09 09:38:31 +00:00
Simon Neuenhausen
3d6e522cbc
Allow splitting control over modem clocks. (#3687)
* Minimal architecture for split RCC.

* Removed critical section.

* Add all modem clock controllers and adjust esp-ieee802154.

* Fixed incorrect cfg.

* Fixed unstable attribute usage.

* Replaced AtomicU8 with Cell<u8>

* Reverted example channel back to 15

* Added unstable attribute to ModemClockController impls.

* Remember to actually increase the ref count.

* Experimentally removed RadioClockController

* Merged ref counters and made decrease panic if zero is reached.

* Removed RADIO_CLK peripheral.

* Removed RADIO_CLK again.

* Revert "Removed RADIO_CLK again."

This reverts commit 6da2d2834850068aa21bc52b141de2cfd8154acc.

* Removed RADIO_CLK without reformatting the files.

* Applied changes to examples and hil-tests.

* Fixed OS adapter for C2 and H2

* Adjusted docs and used unwrap!

* Fixed comments.

* Added changelog.

* Fixed esp-wifi for esp32h2.

* Changed comment for PHY_CLOCK_REF_COUNTER.

* Fixed lint for esp32c2.

* Update esp-hal/src/clock/mod.rs

Co-authored-by: Dániel Buga <bugadani@gmail.com>

* Update esp-hal/src/clock/mod.rs

Co-authored-by: Dániel Buga <bugadani@gmail.com>

* Removed unnecessary comments and made init_radio_clocks unstable.

* Update esp-hal/src/clock/mod.rs

Co-authored-by: Dániel Buga <bugadani@gmail.com>

* Fixed lint.

* Removed clocks_ll functions for chips that don't have those peripherals.

* fmt

* Changed modem clock controller stealing.

* Added lifetime

* fixed peripheral stealing again

* Made modem_clock_controller not const.

* Used type alias instead of function for peripheral stealing.

* fmt

* Adjusted remaining comments.

* Added note about coex.

* fmt

* misc

* Revert "misc"

This reverts commit d8740421e0dff84af605160939e246f2308a48e1.

* Regenerated esp metadata

---------

Co-authored-by: Dániel Buga <bugadani@gmail.com>
2025-07-08 17:23:55 +00:00
Dániel Buga
1a9b4bafe0
Calculate max input/output signal ID automatically (#3773) 2025-07-08 13:39:00 +00:00
Björn Quentin
41fed590c2
Requires unstable feature (#3772)
* Add `requires-unstable` feature

* Docs

* CHANGELOG.md

* Advise for library authors
2025-07-08 11:40:06 +00:00
Dániel Buga
3537b5ecae
Use indexmap to ensure stable iteration order (#3771) 2025-07-08 09:51:43 +00:00