STM32F302R8 with Konrad's inverter boards for senior design.
Fork of Blue_Board_Ticker by
Diff: main.cpp
- Revision:
- 23:cb38086e8695
- Parent:
- 22:72905102b50d
--- a/main.cpp Fri Apr 15 22:23:37 2016 +0000 +++ b/main.cpp Fri Apr 15 22:44:53 2016 +0000 @@ -79,6 +79,21 @@ rpmPrintFlag = 1; } +/* +L6320 + High : Enabled and Pulsing + Low : Enabled not Pulsing + Null : Disabled + +Konrad's Board (6 step) + High : high-side pulsing, low-side off + Low : high-side off, low-side on + Null : high-side off, low-side off + + high-side are PwmOuts + low-side are DigitalOuts +*/ + //original names: CBA CBA, new names: BAC BAC void Output_ANull_BLow_CHigh() //state1, A0 B- C+ { @@ -145,7 +160,7 @@ redLed = !redLed; } -void SixStepNext() +void SixStepNext(int h1, int h2, int h3) { // compute next outputs if (reverse == 0) @@ -201,7 +216,7 @@ prevHallState = currentHallState; spinTickerCounter += 1; // count the number of times spinTicker runs per hall sensor - SixStepNext(); + SixStepNext(h1, h2, h3); toggleRedLed(); }