wuzhenghui
c7de92feda
change(hal): rename PLL_F80M to REF_80M for esp32s31 peripherals clock defination
2026-07-22 16:32:13 +08:00
morris
70ddc14d4f
refactor(emac): move sleep retention config into driver layer
...
Keep the EMAC regdma retention definitions in esp_eth so the backup
layout stays aligned with driver-owned sleep retention behavior.
2026-07-10 16:01:41 +08:00
Ondrej Kosta
2765aa7ec9
Merge branch 'contrib/github_pr_18642' into 'master'
...
fix(eth): use stored base_increment when computing PTP addend (GitHub PR)
Closes IDFGH-17700
See merge request espressif/esp-idf!48902
2026-05-28 16:11:59 +08:00
Scramble Tools
3d54178bc6
fix(esp_eth): use stored base_increment when computing PTP addend
...
The addend in `emac_hal_ptp_start()` was derived from the floating-point
`config->ptp_req_accuracy_ns` instead of the integer `base_increment`
register that actually drives the sub-second update. The cast to
`uint8_t` loses the fractional part, so the un-corrected addend leaves
the PTP clock running off-rate.
Example: with a 40 MHz XTAL and the default `req_accuracy_ns = 40`,
`base_increment` rounds 85.899 up to 86, leaving the clock +1170 ppm
fast — well outside the IEEE 802.1AS neighborRateRatio limit (~±200
ppm), so strict-1AS bridges refuse asCapable.
Compute the addend from the stored `base_increment` for both rollover
modes: `addend = 2^32 * clk_period_ns / increment_ns`.
Measured on ESP32-P4: neighborRateRatio drops from +1147.5 ppm to
+4.2 ppm, and asCapable is granted.
Co-authored-by: Ondrej Kosta <panzer412@gmail.com >
2026-05-26 00:00:44 -07:00
Ondrej Kosta
41976c732e
fix(esp_eth): fixed build issues introduced by EMAC S31 support
2026-05-25 16:06:53 +02:00
Ondrej Kosta
edbf8856ae
feat(esp_eth): add ESP32-S31 EMAC support
...
Add internal EMAC support for ESP32-S31, including:
- HAL/LL layer: emac_ll, emac_hal, emac_clk, emac_periph for S31
- SOC layer: register structs, soc_caps, peripherals linker script,
interrupt definitions
- MAC driver: clock source configuration via Kconfig, GPIO/DMA
adaptations, PHY register defs for clause-45 MDIO
- Ethernet examples updated for S31 (basic, build-test-rules, PTP
readme)
- Refactored existing ESP32/ESP32-P4 EMAC code for shared patterns
(emac_clk extraction, struct alignment, periph descriptor cleanup)
2026-05-21 15:59:42 +08:00
Ondrej Kosta
ed2e6735ff
feat(esp_libc): refactored POSIX timers get/set functions
...
- Added sys/timex.h and clock_adjtime API
2026-03-31 22:32:33 +08:00
armando
bb6ea458d2
change(gpio): move gpio_num.h to gpio hal
2026-02-02 09:47:54 +08:00
Ondrej Kosta
f8b055bd11
feat(esp_eth): added PTP EMAC PPS0 support on ESP32P4v3
...
feat(esp_eth): added options to configure PTP module
feat(esp_eth): removed all PTP ioctl commands and created API
2026-01-12 17:13:25 +08:00
morris
c7117a8f03
Merge branch 'feat/s31_gpio_support' into 'master'
...
feat(gpio): basic support of gpio on s31
Closes IDF-14780
See merge request espressif/esp-idf!44228
2025-12-29 09:35:20 +08:00
Chen Chen
f98b9e2b21
feat(gpio): basic support of gpio on s31
2025-12-26 14:54:56 +08:00
C.S.M
4034446cc7
refactor(hal): Cleanup some missing hal files
2025-12-26 10:33:32 +08:00
Ondrej Kosta
ae3fbe1ada
fix(esp_eth): fixes EMAC MDC out of the range issue
...
Closes https://github.com/espressif/esp-idf/issues/17984
2025-12-11 17:30:30 +01:00
morris
af02c173fb
refactor(soc): remove soc_caps_full.h
2025-12-04 10:48:07 +08:00
glmfe
9fd020d9da
refactor(hal): graduate emac hal into a new component
...
- Separate emac from hal component to a new one: esp_hal_emac.
2025-11-12 06:55:46 -03:00