mirror of
https://github.com/arduino/Arduino.git
synced 2024-12-02 13:24:12 +01:00
[sam] fixing analog according to updated pmc api
This commit is contained in:
parent
c0a5eb38e2
commit
f09771258e
@ -227,7 +227,7 @@ void analogWrite(uint32_t ulPin, uint32_t ulValue) {
|
|||||||
uint32_t chA = channelToAB[channel];
|
uint32_t chA = channelToAB[channel];
|
||||||
|
|
||||||
if (!TCChanEnabled[chNo]) {
|
if (!TCChanEnabled[chNo]) {
|
||||||
PMC_EnablePeripheral(TC_INTERFACE_ID + chNo);
|
pmc_enable_periph_clk(TC_INTERFACE_ID + chNo);
|
||||||
TC_Configure(TC_INTERFACE, chNo,
|
TC_Configure(TC_INTERFACE, chNo,
|
||||||
TC_CMR_TCCLKS_TIMER_CLOCK1 |
|
TC_CMR_TCCLKS_TIMER_CLOCK1 |
|
||||||
TC_CMR_WAVE |
|
TC_CMR_WAVE |
|
||||||
|
Loading…
Reference in New Issue
Block a user