type clean-up to avoid nasty cast
This commit is contained in:
parent
1067e27a50
commit
c8302be4ae
|
@ -330,7 +330,7 @@ void startSimplePwm(SimplePwm *state, const char *msg, ExecutorInterface *execut
|
||||||
|
|
||||||
state->setFrequency(frequency);
|
state->setFrequency(frequency);
|
||||||
state->setSimplePwmDutyCycle(dutyCycle);
|
state->setSimplePwmDutyCycle(dutyCycle);
|
||||||
state->weComplexInit(msg, executor, &state->seq, NULL, (pwm_gen_callback*)applyPinState);
|
state->weComplexInit(msg, executor, &state->seq, NULL, applyPinState);
|
||||||
}
|
}
|
||||||
|
|
||||||
void startSimplePwmExt(SimplePwm *state, const char *msg,
|
void startSimplePwmExt(SimplePwm *state, const char *msg,
|
||||||
|
|
|
@ -39,7 +39,7 @@ typedef struct {
|
||||||
class PwmConfig;
|
class PwmConfig;
|
||||||
|
|
||||||
typedef void (pwm_cycle_callback)(PwmConfig *state);
|
typedef void (pwm_cycle_callback)(PwmConfig *state);
|
||||||
typedef void (pwm_gen_callback)(int stateIndex, void *arg);
|
typedef void (pwm_gen_callback)(int stateIndex, PwmConfig *arg);
|
||||||
|
|
||||||
typedef enum {
|
typedef enum {
|
||||||
PM_ZERO,
|
PM_ZERO,
|
||||||
|
|
|
@ -170,7 +170,7 @@ static void startSimulatedTriggerSignal() {
|
||||||
triggerEmulatorSignal.weComplexInit("position sensor",
|
triggerEmulatorSignal.weComplexInit("position sensor",
|
||||||
&engine->executor,
|
&engine->executor,
|
||||||
&s->wave,
|
&s->wave,
|
||||||
updateTriggerWaveformIfNeeded, (pwm_gen_callback*)emulatorApplyPinState);
|
updateTriggerWaveformIfNeeded, emulatorApplyPinState);
|
||||||
|
|
||||||
hasInitTriggerEmulator = true;
|
hasInitTriggerEmulator = true;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue