mirror of https://github.com/rusefi/wideband.git
send dummy can msg
This commit is contained in:
parent
72c2c271fb
commit
2a38367225
|
@ -1,6 +1,7 @@
|
||||||
#include "ch.h"
|
#include "ch.h"
|
||||||
#include "hal.h"
|
#include "hal.h"
|
||||||
|
|
||||||
|
#include "can.h"
|
||||||
#include "pwm.h"
|
#include "pwm.h"
|
||||||
|
|
||||||
// 400khz / 1024 = 390hz PWM
|
// 400khz / 1024 = 390hz PWM
|
||||||
|
@ -14,13 +15,17 @@ Pwm pumpDac(PWMD3, 1, 48000000, 1024);
|
||||||
* Application entry point.
|
* Application entry point.
|
||||||
*/
|
*/
|
||||||
int main(void) {
|
int main(void) {
|
||||||
halInit();
|
halInit();
|
||||||
chSysInit();
|
chSysInit();
|
||||||
|
|
||||||
heaterPwm.Start();
|
InitCan();
|
||||||
pumpDac.Start();
|
|
||||||
|
|
||||||
while (true) {
|
heaterPwm.Start();
|
||||||
|
pumpDac.Start();
|
||||||
|
|
||||||
}
|
while (true) {
|
||||||
|
// dummy data
|
||||||
|
SendCanData(0.5f, 300);
|
||||||
|
chThdSleepMilliseconds(10);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue