Loading...
Searching...
No Matches
board_common_esp32s2.h
Go to the documentation of this file.
1/*
2 * Copyright (C) 2025 Gunar Schorcht
3 *
4 * This file is subject to the terms and conditions of the GNU Lesser
5 * General Public License v2.1. See the file LICENSE in the top level
6 * directory for more details.
7 */
8
9#pragma once
10
24
25#ifdef __cplusplus
26extern "C" {
27#endif
28
29#if !DOXYGEN
30
35#if CONFIG_ESP_DEFAULT_CPU_FREQ_MHZ <= 80
36# define CONFIG_ZTIMER_USEC_ADJUST_SET (880/CONFIG_ESP_DEFAULT_CPU_FREQ_MHZ)
37# define CONFIG_ZTIMER_USEC_ADJUST_SLEEP ((CONFIG_ZTIMER_USEC_ADJUST_SET >> 2) * 5)
38#else
39# define CONFIG_ZTIMER_USEC_ADJUST_SET (960/CONFIG_ESP_DEFAULT_CPU_FREQ_MHZ)
40# define CONFIG_ZTIMER_USEC_ADJUST_SLEEP (CONFIG_ZTIMER_USEC_ADJUST_SET + 1)
41#endif
43
44#endif /* !DOXYGEN */
45
46#ifdef __cplusplus
47} /* end extern "C" */
48#endif
49