Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
arduino-esp32
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
xpstem
arduino-esp32
Commits
65eafd16
Unverified
Commit
65eafd16
authored
Jul 26, 2021
by
Rodrigo Garcia
Committed by
GitHub
Jul 26, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixes ESP32-S2 LEDC PWM #5375 #5050 (#5452)
Fixes: #5375 Fixes: #5050
parent
d5a98f9a
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
0 deletions
+4
-0
cores/esp32/esp32-hal-ledc.c
cores/esp32/esp32-hal-ledc.c
+4
-0
No files found.
cores/esp32/esp32-hal-ledc.c
View file @
65eafd16
...
@@ -115,6 +115,10 @@ static void _ledcSetupTimer(uint8_t chan, uint32_t div_num, uint8_t bit_num, boo
...
@@ -115,6 +115,10 @@ static void _ledcSetupTimer(uint8_t chan, uint32_t div_num, uint8_t bit_num, boo
uint8_t
group
=
(
chan
/
8
),
timer
=
((
chan
/
2
)
%
4
);
uint8_t
group
=
(
chan
/
8
),
timer
=
((
chan
/
2
)
%
4
);
static
bool
tHasStarted
=
false
;
static
bool
tHasStarted
=
false
;
static
uint16_t
_activeChannels
=
0
;
static
uint16_t
_activeChannels
=
0
;
#if CONFIG_IDF_TARGET_ESP32S2
// ESP32-S2 TRM v1.0 on Page 789 -> BIT LEDC_TICK_SEL_TIMERx is 0 for LEDC_PWM_CLK and 1 for REF_TICK
apb_clk
=
0
;
#endif
if
(
!
tHasStarted
)
{
if
(
!
tHasStarted
)
{
tHasStarted
=
true
;
tHasStarted
=
true
;
periph_module_enable
(
PERIPH_LEDC_MODULE
);
periph_module_enable
(
PERIPH_LEDC_MODULE
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment