Commit Graph

420 Commits

Author SHA1 Message Date
Matthew Kennedy
77900d7e68 s 2022-07-03 12:32:54 -07:00
Matthew Kennedy
4610337dbc Merge remote-tracking branch 'origin/master' into multi-controller 2022-07-03 12:15:21 -07:00
rusefillc
1454c10713 AUX outputs (#95)
* AUX outputs

* Rev2: define AUX output PWM device and channels

* Rev2: enalbe TIM1 used for aux outputs

* Rev2: define aux output gain

Co-authored-by: Andrey Gusakov <dron0gus@gmail.com>
2022-07-03 12:11:12 -07:00
rusefillc
fe50e80a89 original hardware by Dave has changed enough (#100)
Co-authored-by: rusefillc <sdfsdfqsf2334234234>
2022-07-03 12:07:01 -07:00
rusefillc
542601da41 Board Rev 2 (#98)
* Board Rev 2

* f1_rev2: fix for new AnalogResult format

Co-authored-by: Andrey Gusakov <dron0gus@gmail.com>
2022-07-03 00:00:43 -07:00
rusefillc
d1a2ee2b5b Rev 2: default settings for LSU4.9 (#99)
* Rev 2: default settings for LSU4.9

* Rev2: LSU 4.2 and ADV ESR drive pins

Co-authored-by: Andrey Gusakov <dron0gus@gmail.com>
2022-07-03 00:00:17 -07:00
rusefillc
1efc499126 Rev2: GD32 ADC workaround (#96)
Co-authored-by: Andrey Gusakov <dron0gus@gmail.com>
2022-07-02 13:48:27 -07:00
rusefillc
0430e4a7ba board: common make script (#73)
* board: common make script

(cherry picked from commit cb087c60e9f0d1d7ee8130c023ba99cdc428765c)

* common_make -> build_f1_board

* f1_rev2: use build_f1_board.sh helper

* Add encedo hex2dfu tools (bin for linux and win)

See https://github.com/encedo/hex2dfu

* Makefile: priduce srec too

* f1_rev2: OpenBLT: build bin and hex files

* f1_rev2: OpenBLT: optimize for size to fit into 8K flash

Co-authored-by: Andrey Gusakov <dron0gus@gmail.com>
2022-07-02 13:47:55 -07:00
rusefillc
2fa9549d83 0701 rev2 2 (#91)
* Rev 2: VM_RESISTOR_VALUE

(cherry picked from commit 84ae91fc67cf6764afd5b00210edbc3cfe4444a5)

* Rev 2: default settings for LSU4.9

(cherry picked from commit 5a1fe84bc1ec8d7ee6e0a5f2906a1b18d2ff8a8e)

* Per-board VM_RESISTOR_VALUE

(cherry picked from commit 0bdd19e058db579bed13488066df1176ea9addb2)

* Rev2: ID correct pins

(cherry picked from commit 59e4b36ad9bc7c166c3dae7e25b6317caf562056)

* Rev2: LSU 4.2 and ADV ESR drive pins

(cherry picked from commit 2f2b4399431136951fe2fa6819f44ba28c3cda17)

* Rev2: aux pwm pins: no need to be 50MHz fast

(cherry picked from commit b0af5c07c391438ca561118174df498207255f3b)

Co-authored-by: Andrey Gusakov <dron0gus@gmail.com>
2022-07-01 15:57:05 -07:00
rusefillc
076406e4b0 f1_rev2: add OpenBLT (#92)
(cherry picked from commit 85e1ac8e5e75e22b247db0f5a512656453425729)

Co-authored-by: Andrey Gusakov <dron0gus@gmail.com>
2022-07-01 12:12:24 -07:00
Andrey G
d3d260b828 f1_rev2: set O0 optimization level due to issue with ADC on GD32 (#94) 2022-07-01 12:10:28 -07:00
Andrey G
5ec79b52a5 f1_rev2: this is single channel board (#93) 2022-07-01 12:03:48 -07:00
Matthew Kennedy
c04819e10d Merge remote-tracking branch 'origin/master' into multi-controller 2022-07-01 01:17:47 -07:00
rusefillc
7d8eaab3d1 Min rev2 (#90)
* Board Rev 2

(cherry picked from commit 2f1e2bd3e27fdfd43f0ccf8292aacfb1194060fc)

* CI good

(cherry picked from commit 2163af402ebc40f76fa53ac8f1648949b12aa50f)

* min r2

* min r2

Co-authored-by: Andrey Gusakov <dron0gus@gmail.com>
Co-authored-by: rusefillc <sdfsdfqsf2334234234>
2022-07-01 01:17:04 -07:00
rusefillc
fad49f553f Crc bootloader (#88)
* more code reuse

* more code reuse

* more code reuse

* more code reuse

* more code reuse

* more code reuse

* make it compile and actually include all the functions

Co-authored-by: rusefillc <sdfsdfqsf2334234234>
Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
2022-06-30 10:07:33 -07:00
Matthew Kennedy
036c74aa19 weird merge 2022-06-29 12:15:02 -07:00
Matthew Kennedy
85231610b0 Merge remote-tracking branch 'origin/master' into multi-controller 2022-06-29 12:14:37 -07:00
Matthew Kennedy
79b817e439 extract heater 2022-06-29 12:14:35 -07:00
rusefillc
1b0145d104 GD32: ADC workaround (#83)
(cherry picked from commit 02fd9f248189e3e801b50c920e1166daa23283bc)

Co-authored-by: Andrey Gusakov <dron0gus@gmail.com>
2022-06-29 12:14:08 -07:00
Matthew Kennedy
b41b2df0bc missing newline end of file 2022-06-29 11:45:23 -07:00
Matthew Kennedy
0164ff3535 Merge remote-tracking branch 'origin/master' into multi-controller 2022-06-29 11:44:45 -07:00
rusefillc
1e19b43d35 s/C/CPP/ (#86)
Co-authored-by: rusefillc <sdfsdfqsf2334234234>
2022-06-29 11:43:36 -07:00
Matthew Kennedy
cca3c6a5de I'll just do it myself, then 2022-06-29 11:41:45 -07:00
rusefillc
1e3dc3808e 0624 pwm (#81)
* pwm.cpp: support multichannel

(cherry picked from commit 27995893ee181e699b8e0ab33283dfcc581fcc88)

* pwm.cpp: allow external config

(cherry picked from commit 70856151b7fee72f2a9c1a6013801ab14c2bffdb)

Co-authored-by: Andrey Gusakov <dron0gus@gmail.com>
2022-06-29 11:39:50 -07:00
Matthew Kennedy
eaec4a1311 extracting class 2022-06-29 11:36:14 -07:00
rusefillc
ccb790f532 Steal tunerstudio files from RusEFI (#71)
* Steal tunerstudio files from RusEFI

(cherry picked from commit dcba04fbd31700f5ca4ef4f12a6e220c5713c7d0)

* Steal crc32 files from RusEFI

(cherry picked from commit bfe88b5297c6fc90c8e647e4144c91edafef25f9)

* fix TS steal

(cherry picked from commit a77b9761da4c185359bb2d7e10abd6a8e69c740d)

* fix crc32

(cherry picked from commit cdb4df09f69c2494316c2b12f97dbe19f6bdb598)

* TS stealed from RE

(cherry picked from commit ff470e134036372425da44e9e0fb98737f31c9e9)

* Steal TS

(cherry picked from commit d11406edc2d6b3c1567ce800e207038745a162e7)

* Steal Thread Controller

(cherry picked from commit 2aa5bbd57150e0d5b51e2e88752bdc8697698861)

* Update TunerStudio protocol files

(cherry picked from commit 58f14216ec6e7fc4408e52ccc28a4f912e340b05)

* byteswap.h

(cherry picked from commit 581d647fd49890af4628f0ff5b51e9f193efcac4)

* bugfix

* one more file to compile, another file not ready - removing from this PR

* removing more from this PR

Co-authored-by: Andrey Gusakov <dron0gus@gmail.com>
Co-authored-by: rusefillc <sdfsdfqsf2334234234>
2022-06-29 01:29:40 -07:00
rusefillc
8269687295 Add OpenBLT submodule (#76)
(cherry picked from commit 712eddf0b837bbfde8be413b4251f4d191fc93cf)

Co-authored-by: Andrey Gusakov <dron0gus@gmail.com>
2022-06-29 01:03:08 -07:00
rusefillc
1dc862229e can: avoid stack overflow (#77)
(cherry picked from commit 6f15807902937a766ebd4c0d4ed8729409258b10)

Co-authored-by: Andrey Gusakov <dron0gus@gmail.com>
2022-06-25 17:27:33 -07:00
rusefillc
3d14be42dc Update ChibiOS submodule (#79)
(cherry picked from commit 799302159782331fd48e4f6a8fd8ebd3c15c93e2)

Co-authored-by: Andrey Gusakov <dron0gus@gmail.com>
2022-06-25 17:27:18 -07:00
rusefillc
e34094e13d Prepare for multi-channel boards (#72)
* Prepare for multi-channel boards

(cherry picked from commit 8b713cebfca9772fa1742ef5a21cae1b9337951b)

* this belongs in wideband_board_config.h they say

Co-authored-by: Andrey Gusakov <dron0gus@gmail.com>
Co-authored-by: rusefillc <sdfsdfqsf2334234234>
2022-06-24 14:51:22 -07:00
rusefillc
725d30c07c sorry those help sometimes (#70) 2022-06-24 14:44:44 -07:00
rusefillc
f6b4b3a34c f1_dave: PA1 is pump PWM output, should be alternate (#75)
(cherry picked from commit b31e642943bdb49470ef091d1657ce1bf62301f8)

Co-authored-by: Andrey Gusakov <dron0gus@gmail.com>
2022-06-22 11:10:51 -07:00
rusefillc
4ee8610645 More stack (#74)
(cherry picked from commit eb20d28bad7dc936e042e0f04e8baa05b7077d26)

Co-authored-by: Andrey Gusakov <dron0gus@gmail.com>
2022-06-22 11:10:16 -07:00
Matthew Kennedy
88278fe7e6 bin 2022-05-18 23:51:17 -07:00
Matthew Kennedy
d4742d81e7 angry comment 2022-05-18 23:50:58 -07:00
Matthew Kennedy
ea8c1a7d1a send temperature for real 2022-05-18 23:49:34 -07:00
Matthew Kennedy
62f5b9e7ae clamp temperature estimation 2022-05-18 23:45:42 -07:00
Andrey G
d3e460a9a6 Uart debug (#64)
* heater: export state and description

* pump_dac: save and export Ipump

* float interpolation helpers

* Show heater state, heater duty, temperature and fault over uart

* uart: more stack for thread
2022-05-11 01:41:07 -07:00
Matthew Kennedy
2167016c16 format 2022-05-07 11:15:11 -07:00
rusefillc
b9b94fcadc Temperature (#63)
* integer id interpolation

* Calculate sensor temperature based on Ri

* Sensor Ri around 25C

Co-authored-by: Andrey Gusakov <dron0gus@gmail.com>
2022-05-07 11:12:20 -07:00
Andrey G
87763c55a4 f1_dave: port: use designated initializers (#65) 2022-05-06 22:36:44 -07:00
Matthew Kennedy
2a2b438fc6 static 2022-04-06 17:23:18 -07:00
Andrey G
bc0686c826 Smarter state machine to use internal vbatt when CAN not connected (#57)
* Smarter state machine to use internal vbatt when CAN not connected

* Style
2022-04-06 14:07:39 -07:00
Andrey G
bcc62880da f1_dave: board cleanup and pinmux fixes (#56)
* f1_dave: clean-up board.h

* f1_dave: PB6 should be output+alternate

Set using VAL_GPIOBCRL, no need to call palSetPadMode

* f1_dave: PB12 ESR driver, should be high speed (hi current)

* f1_dave: PB13 - Blue LED should be output push-pull

* f1_dave: fix pinmuxes, add comments
2022-04-06 14:07:00 -07:00
Matthew Kennedy
354888f2b8 comments 2022-04-06 01:31:35 -07:00
Matthew Kennedy
66b891bf79 heater controller pulls from CAN world instead of push 2022-04-06 01:22:09 -07:00
Matthew Kennedy
dc077caff1 api to get internal battery voltage 2022-04-06 01:08:40 -07:00
Matthew Kennedy
ea262c3822 battery voltage config 2022-04-06 01:07:29 -07:00
Matthew Kennedy
b838c414fa sample battery voltage 2022-04-06 01:07:18 -07:00
Matthew Kennedy
b6985f6416 Merge branch 'master' of https://github.com/mck1117/wideband 2022-04-06 00:55:28 -07:00