mirror of https://github.com/rusefi/wideband.git
save ram
This commit is contained in:
parent
2737e710d4
commit
fa00aa0ad4
|
@ -7,7 +7,7 @@
|
|||
#include "hal.h"
|
||||
|
||||
// 48MHz / 1024 = 46.8khz PWM
|
||||
PWMConfig pumpDacConfig = {
|
||||
static const PWMConfig pumpDacConfig = {
|
||||
48'000'000,
|
||||
1024,
|
||||
nullptr,
|
||||
|
|
|
@ -31,7 +31,7 @@ void Pwm::Start()
|
|||
Start(config);
|
||||
}
|
||||
|
||||
void Pwm::Start(PWMConfig& config)
|
||||
void Pwm::Start(const PWMConfig& config)
|
||||
{
|
||||
m_counterFrequency = config.frequency;
|
||||
m_counterPeriod = config.period;
|
||||
|
|
|
@ -13,7 +13,7 @@ public:
|
|||
Pwm(PWMDriver& driver);
|
||||
|
||||
void Start();
|
||||
void Start(PWMConfig& config);
|
||||
void Start(const PWMConfig& config);
|
||||
void SetDuty(int channel, float duty);
|
||||
float GetLastDuty(int channel);
|
||||
|
||||
|
|
Loading…
Reference in New Issue