Commit Graph

1687 Commits

Author SHA1 Message Date
GitHub build-firmware Action 7430bad8d7 Auto-generated configs and docs 2021-03-05 02:01:14 +00:00
Matthew Kennedy caa161db42 STM32H7 Slow ADC (#2421)
* extract

* guard

* put some back

* put back

* slow is actually 500hz so slow is fine here

* no magic

* fix printFullAdcReport

* cast

* implement h7 adc ish

* analog switches

* bad merge

* no map avg on h7

* fix master while we're at it

Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
2021-03-04 20:58:56 -05:00
Matthew Kennedy b9e0d4db47 Extract slow adc (#2402)
* extract

* guard

* put some back

* put back

* slow is actually 500hz so slow is fine here

* no magic

* fix printFullAdcReport

* cast

* if we turn those off is it happy

* stub cypress/kinetis

* guard fast stuff better

* bad merge

Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
2021-03-04 19:55:09 -05:00
Matthew Kennedy 8edb115113 Embed ini (#2417)
* replace null device with rusefi ini

* comment

* warning

* stub ramdisk for when we don' thave an image

* maybe generate the image with a build

* install mtools

* fail on error

* install deps _before_ we need them

* embed a little readme

* oops
2021-03-03 07:50:53 -05:00
Matthew Kennedy 243ecdf3dd prep proteus config for h7 (#2413)
* prep for h7

* weak link that

* make those weak

* remove other stubs

Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
2021-02-28 16:57:57 -05:00
Andrey G cd548b4db2 hip9011 compilation fix, cosmetic clean-ups (#2414)
* Board subaru eg33: has HIP9011 knock sensor

* hip9011: lastExecutionCount does not exist any more

* hip9011: extranc commands to header, use logic math for bitfields
2021-02-28 15:42:57 -05:00
Matthew Kennedy f8747a35bf set all thread priorities in the same place (#2412)
* unify thread priority

* header

* mmc
2021-02-28 07:30:45 -05:00
Matthew Kennedy f347b92f45 allow disabling fast ADC (#2406)
* mostly guard against no fast adc

* disable on h7

* guard more

* guard adc init

* you can't do that in c++

* we need that

* s

Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
2021-02-28 07:30:19 -05:00
Matthew Kennedy dcd72a87f9 H7 flash (#2408)
* enable

* defines and mpu util

* implement flash for h7

* format
2021-02-26 17:38:17 -05:00
Matthew Kennedy 4c98c99162 make h7 chconf like f4 (#2405)
* make h7 chconf like f4

* clean up f7 while we're at it

Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
2021-02-26 07:59:39 -05:00
Matthew Kennedy daf52f85de fixes for f7, sdio/sdmmc (#2400) 2021-02-25 13:37:41 -05:00
Matthew Kennedy f18ef02fa6 maybe hook up sdmmc (#2398)
* maybe hook up sdmmc

* the complier didn't like that very much

* mcuconf

* guard properly

* fix

* duh

* omg that's an extra close paren

* explicitly set which device fatfs should use

Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
2021-02-25 01:37:44 -05:00
Matthew Kennedy 6e41aeb165 deduplication in halconf (#2377)
* rusefi_halconf

* h7 gpt

* don't redefine that

* maybe this was necessary

* format

* no usb in cypress

* flags for bl

* cypress

* maybe bootloader

* no smart build for cypress/kinetis

* no smart build

* no really, disable smart build

* don't need to clean that env var

* cypress

* format
2021-02-24 14:08:03 -05:00
Matthew Kennedy 84a43ec10b don't cache temperature samples at all (#2392) 2021-02-24 08:15:03 -05:00
Matthew Kennedy 76c423ccca enable H7 spi (#2391)
* enable features

* move MMC SPI config to port

* correct word length

* related cleanup

* doesn't need nocache

* include

* enable that
2021-02-24 08:14:21 -05:00
Matthew Kennedy f45d837754 update h7 clock config (#2388)
* h7 clocks

* run the core at 400

* disable LSE

* 8mhz timer clock

* osc

* it has to be even slower

* something is wrong with WFI

* this was wrong anyway
2021-02-23 22:55:38 -05:00
Matthew Kennedy 726be2232e yet more TS sanity (#2382)
* ts cleanup part 1

* move more stuff in to the class

* extract base class

* switch to TsChannelBase where we can

* dfu

* more to TsChannelBase

* bad merge

* another bad merge

* bootloader

* bluetooth

* format

Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
2021-02-20 02:11:39 -05:00
Matthew Kennedy 12a31e5132 start making tunerstudio more sane: part 2 (#2381)
* ts cleanup part 1

* move more stuff in to the class

Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
2021-02-19 20:48:21 -05:00
rusefillc 369d68d464 would this give me h72 SD? 2021-02-18 17:04:51 -05:00
rusefillc 14e8ebd034 would this give me h72 SD? 2021-02-18 16:16:45 -05:00
Matthew Kennedy 8237dd6a41 merge mcuconf for f4/f7 (#2375)
* merge for f4/f7

* more

* include efifeatures

* s

* no TS serial on f7 for now

Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
2021-02-18 15:04:32 -05:00
Matthew Kennedy f9536791f0 set MCU properly (#2371) 2021-02-17 15:25:57 -05:00
Matthew Kennedy 179a3cb89e use spiPolledExchange for small transfers (#2358)
* configure for no cache

* this doesn't need a setting

* now we don't need invalidate

* reorder and comment

* mmc

* sw knock

* use spiPolledExchange for small transfers

* mock spi

Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
2021-02-17 14:48:21 -05:00
rusefillc 3354691778 trying to fix AuxValves 2021-02-17 08:57:18 -05:00
rusefillc 95b78a48ed aux to vvt rename 2021-02-17 08:53:39 -05:00
Matthew Kennedy 55facb6613 use DECLARE_ENGINE_PTR for Engine class (#2365)
* engine cleanup

* do the cleanup

* one last spot

* expand_engine noop for firmware

* simulator
2021-02-16 16:58:54 -05:00
Matthew Kennedy dbebc353a2 remove unused msg parameter (#2360)
* dead parameter

* last few
2021-02-16 09:32:16 -05:00
Matthew Kennedy c75af2ac75 properly put buffers in no-cache regions (#2357)
* configure for no cache

* this doesn't need a setting

* now we don't need invalidate

* reorder and comment

* mmc

* sw knock
2021-02-15 17:39:11 -05:00
Matthew Kennedy a576c2e109 USB mass storage tweaking (#2352)
* disable TS in case of USB MSD

* housekeeping while we're here

* enable on MRE

* changelog
2021-02-14 15:03:07 -05:00
Andrey G b5ebd7e4c4 RusEFI is green: put cpu in standby in idle (#2342)
* MRE is green: put cpu in standby in idle

* Revert "MRE is green: put cpu in standby in idle"

This reverts commit 62b5cadda014ace749b145b629da62b182b5e3ce.

* RusEFI is green on all boards
2021-02-14 10:24:21 -05:00
Matthew Kennedy 5391b4260f automatic switch between internal and MSD SD card (#2349)
* auto enable usb msd

* guard and turn on for proteus
2021-02-14 08:10:39 -05:00
Matthew Kennedy f9e30057fa pullup (#2348) 2021-02-14 08:04:09 -05:00
Matthew Kennedy d27b8f8d13 rewrite SD initialization (#2346)
* rewrite SD init

* static

* return a pointer instead
2021-02-13 21:26:11 -05:00
Andrey G c9ccf021d2 Config cleanups (#2347)
* Remove duplication

* Ports: STM32F7: we want PAL_USE_CALLBACKS for F7 too
2021-02-13 18:45:33 -05:00
Matthew Kennedy ba3bf4169d usb mass storage progress (#2345)
* usb mass storage

* remove old files

* this file is gone
2021-02-13 15:06:05 -05:00
rusefi fc2f44b7e9 not great solution to code duplication, also helping QC build 2021-02-13 11:19:39 -05:00
Matthew Kennedy e7895f80d5 USB mass storage descriptor (#2330)
* enable msd

* modify descriptors for composite device

* makefile cleanup

* format

* define

* embiggen fifos

* needed that

* cleanup too while we're at it

* rename endpoints

* switchable descriptors

* guard the request hook too

* don't need this changed yet

* cleanup

* update ep0 response

* cleanup

* use the msd hook from chibios

* this was wrong

* this was covered by other PR

* this is also covered

* s
2021-02-13 08:54:08 -05:00
Matthew Kennedy e3dadd3d51 implement null block device (#2341)
* implement null device

* fix build
2021-02-13 08:53:10 -05:00
Matthew Kennedy 70eee46e3a fix usb descriptor mistakes (#2340)
Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
2021-02-13 01:06:55 -05:00
Matthew Kennedy 56c2315115 Rename USB endpoints, update ChibiOS-Contrib (#2334)
* rename endpoints

* update chibios contrib

Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
2021-02-12 14:21:56 -05:00
Matthew Kennedy 594c9a76eb increase SD card speed (#2333)
* fast sd card

* fair enough
2021-02-11 20:42:23 -05:00
Matthew Kennedy b833b58c3f turn in to a composite device (#2332) 2021-02-11 15:52:06 -05:00
Matthew Kennedy adff68748c move chconf/mcuconf/halconf in to hw_ports (#2321)
* move f4 config files

* don't need this

* f7

* f7

* h7

* this was duplicated

* turn off smart build

* loader too

* update prometheus paths

* bootloader should include confdir

* fix the flash size while we're at it

* move chconf_common

* use wait

* normalize board.mk

Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
2021-02-10 19:38:24 -05:00
rusefi 6c9416daa9 aux pid is now VVT 2021-02-10 12:41:38 -05:00
Matthew Kennedy a3d0b61cf1 get mcu temperature within port (#2326)
* remove EFI_ADC_TEMP_SENSOR

* implement

* comment

* s

* switch adc_inputs over

* header

* s

* I think aligned-on-stack should work ok

* num channels

* cache safety

* move adc init too

* don't compile that file for the h7

* cypress & kinetis

* ports

* guard against bootloader

Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
2021-02-09 22:04:36 -05:00
rusefillc 63bd40c706 Create readme.md 2021-02-09 13:43:26 -05:00
Matthew Kennedy ff8f24d30c stm32h7 usb (#2319)
* enable

* enable

* serial number

* usb defines

* buffer size

* more stuff we can enable
2021-02-08 16:24:49 -06:00
Matthew Kennedy 8cc6ef83f9 h7 flash, guard against no CAN (#2317)
* h7 flash

* guard some other stuff

* I guess it just builds now?

* maybe ci too
2021-02-08 16:24:38 -05:00
Matthew Kennedy 1a5a3b8a42 consolidate stm32 mpu util (#2314)
Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
2021-02-08 15:52:00 -05:00
Matthew Kennedy ad6fc5415d move board.h for f7/h7 (#2316)
* f7 board.h

* h7
2021-02-08 15:46:48 -05:00
Matthew Kennedy 3412d8fe64 move f4 board.h (#2313)
Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
2021-02-08 15:29:07 -05:00
Matthew Kennedy 37fa81b5d0 include board.c from hw_ports.mk (#2311)
* set mcu type in hw_ports

* move f4 linker script

* move f7 linker script

* don't set default linker file in makefiles

* extra line

* prometheus actually didn't depend on anything special for f469

* dead line

* h7

* dead

* move board.c

* set explicit cpu type for simulator

Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
2021-02-08 07:52:31 -06:00
Matthew Kennedy c0757a7d13 simplify MCU selection (#2308)
* set mcu type in hw_ports

* move f4 linker script

* move f7 linker script

* don't set default linker file in makefiles

* extra line

* prometheus actually didn't depend on anything special for f469

* dead line

* h7

* dead
2021-02-08 02:11:44 -05:00
Matthew Kennedy 63c9612602 implement lps25 (#2301)
* bb

* implement

* tweaks

* s

* comment, format

* guard

* implement lps25

* headers and comment

* sensor works

* headers

* guard

Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
2021-02-06 23:59:44 -06:00
Matthew Kennedy a5f269d733 implement bit-banged I2C driver (#2289)
* bb

* implement

* tweaks

* s

* comment, format

* guard

* headers and comment
2021-02-06 16:59:06 -06:00
Andrey G 04c7ad67aa Some fixes prior to board pull request (#2291)
* ChibiOS: add support for STM32F765

This chip is used on Subaru EG33 p'n'p RusEFI board from Dron_Gus

* drivers: gpio: mc33810: commulative update

- use BIT macro
- fix wake-up method
- fix order of arguments in _add function

* port: stm32f4/7: detectCanDevice check for enabled interfaces only

* ADC: fix internal array size

internalAdcIndexByHardwareIndex should be EFI_ADC_LAST_CHANNEL size
couse adc_channel_e is used as index

* status LEDs: support status LEDs that driven by low level
2021-02-06 12:22:57 -05:00
rusefillc 4936b9fab3 reducing code duplication 2021-02-06 00:46:40 -05:00
rusefillc 83d8bd9369 H7 compilation #2284 2021-02-06 00:37:12 -05:00
rusefillc 7c107a6551 reducing code duplication 2021-02-06 00:25:13 -05:00
rusefillc 0573d29b22 reducing code duplication 2021-02-06 00:18:47 -05:00
rusefillc 096c67b4de H7 compilation #2284 2021-02-05 23:57:28 -05:00
rusefillc 3be5714e94 H7 compilation #2284 2021-02-05 23:37:18 -05:00
rusefillc bb7af93e66 let's build for h7 2021-02-05 22:29:23 -05:00
rusefillc c549a13c1f let's build for h7 2021-02-05 22:10:59 -05:00
rusefillc d824f3d12a let's build for h7 2021-02-05 21:37:33 -05:00
rusefillc 5afcb400a7 let's build for h7 2021-02-05 21:09:36 -05:00
Matthew Kennedy 3cf6b67b87 fix #2269 (#2272)
* fix #2269

* cleanup
2021-02-03 08:04:22 -06:00
rusefillc 11aa253ae9 vvt/cam events to pass index 2021-01-31 22:24:45 -05:00
rusefillc 845ad4e53d trigger: exti: callback parameter is now index 2021-01-31 22:10:10 -05:00
rusefillc 1243225c07 code style 2021-01-31 22:02:01 -05:00
rusefillc b571feffac code style 2021-01-31 21:45:01 -05:00
Matthew Kennedy 9d86488e07 USB reports real STM32 Serial Number (#2254)
* mpu util data

* implementation
2021-01-30 14:51:11 -05:00
rusefillc f8f90cbffb No hablo inglés 2021-01-28 20:43:23 -05:00
rusefillc cbca40dec0 fixing port I 2021-01-25 00:29:48 -05:00
rusefillc fc15eb979b fixing port I 2021-01-22 23:31:21 -05:00
rusefillc 673de10118 Hellen needs text representation of GPIOI
H7 dreams are asking for J and K
2021-01-22 01:25:05 -05:00
Andrey G 27905c6817 Chibi os 20 (#2212)
* Update ChibiOS

* Fix Makefiles includes paths

* halconf.h: remove flash hack

* mcuconf: fix EXTI ptiorityes

* Digital Input: ICU: use designated initializers, initialize 'arr'

* ChibiOS: lis302dl fix

* ADC: update to new API

* UARTConfig: timeout_cb field, formating

* ChibiOS: remove _exit, _kill, _getpid

* Fix lis302dl

* Bump config versions

* chconfig_common: cosmetic changes

* stm32f4ems: commulative config update

* Update Simulator

* ALLCSRC already contain all needed ChibiOS files.

Same for ALLINC and ALLCPPSRC

* ChibiOS fix for Simulator

* ChibiOS: port lock/unlock hook and MMC over SPI timeout

* STM32F7: update configs

* STM32F7: update linker file

* Cypress: port ADC lld to ChibiOS-20

* Cypress: port SPI lld to ChibiOS-20

* Cypress: port CAN lld to ChibiOS-20

* Cypress: fix include path for rules.ld

* Cypress: update chconf.h and halconf.h for ChibiOS-20

* Kinetis: update ADC lld to ChibiOS-20

* Kinetis: update SPI lld to ChibiOS-20

* Kinetis: update UART lld driver for ChibiOS-20

* Kinetis: update chconf.h and halconf.h for ChibiOS-20

* Kinetis: fix include path for rules.ld

* Nucleo F746: update ld script

* Nucleo F746: fix compile

* Bootloader: fix compilation with ChibiOS-20, cleanup

* Bootloader: add way to pass crosscompiler using CROSS_COMPILE

* Debug build arguments

* Simulator: fix windows compilation

Exclude syscalls_cpp.cpp from compilation
2021-01-19 15:20:35 -05:00
rusefi c0abf52bd8 OMG we are not using java yet?! 2021-01-18 19:00:53 -05:00
rusefi 4dcd8a6308 https://refactoring.com/catalog/replaceMagicLiteral.html 2021-01-18 18:54:18 -05:00
Matthew Kennedy 4e6c841729 boost fixes (#2230)
* fix boost pin reinit

* call boost from periodic slow

* ui

Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
2021-01-18 07:04:14 -05:00
Andrey G d134fabc51 Simplify Makefile, unify board.mk files (#2229)
* Proper way to add lis302 driver

* Proper way to add license directory to includes

* Makefile: simplify

All ChibiOS stuff is accumulated in ALLCSRC, ALLINC and so on.

* board.mk: append sources and includes to ALLSRC, ALLCPPSRC, ALLINC

* Cypress: fix CANv2 includence into build
2021-01-17 09:32:06 -05:00
Andrey G 052e2e558b Supress annoing unused warnings (#2216) 2021-01-11 08:49:20 -05:00
rusefillc 5eeb48be51 cherry pick from https://github.com/dron0gus/rusefi/tree/ChibiOS-20 2021-01-09 19:15:50 -05:00
rusefillc ef44f47d5b Lcd fix (I hope) #2211
there is still an issue :(
2021-01-09 17:30:39 -05:00
Andrey G 75098a0d4b Lcd fix (I hope) (#2211)
* LCD: check if settings are valid on each access

* Lada Kalina: remove duplicate code

All LCD pins are set to GPIO_UNASSIGNED in disableLCD()

* Remove duplicate code

* We still need to know when invalid gpio is used...

This reverts commit 9c12c4dd44.
2021-01-09 17:16:10 -05:00
rusefillc 9c12c4dd44 dron0gus please help 2021-01-09 15:31:09 -05:00
Andrey G b61ae75fe2 gpio helper (#2195)
* gpios: isBrainPinValid helper

* LCD HD44780: do not touch pins if DM_NONE or invalid gpio

* Fix isEnabled checks for GPS and Joystick

* LCD HD44780: writePad use this method wider
2021-01-08 20:01:26 -05:00
rusefillc 5a75c69b8e knock v12 2021-01-06 19:42:07 -05:00
Andrey G f962a7bd64 Gpio cleanup #2 (#1530)
* pin repository: PIN_USED size in now equal to brain_pin_e enum size

expect special values...

* smart gpios: register gpio chip to given base (no auto-allocation)

* drivers: gpio: core: add gpiochip_unregister()

* drivers: gpio: MC33810 intergation

* smart_gpio.cpp: cleanup ifdef mess, minor cleanups

* gpio: core: additional check for gpio ranges overlaps

* unit test: gpio chip: fixed and extended
2021-01-06 18:29:47 -05:00
Andrey G 12728ccd82 Call startSmartCsPins when applying new settings (#2194)
Only stopSmartCsPins was called from applyNewHardwareSettings.
This cause lost of CS pins for external gpio chips
2021-01-06 08:59:13 -05:00
Andrey G 71fe582ce5 Adc isAdcChannelValid helper (#2188)
* Guard define argument

* ADC: isAdcChannelValid

Check for both <= EFI_ADC_NONE and >= EFI_ADC_LAST_CHANNEL
Also check for value out of enum range (corrupted settings)

* Fix unit tests
2021-01-05 16:02:20 -05:00
Matthew Kennedy 279f8bad03 use limp mgr for trigger disable (#2145)
Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
2020-12-26 18:12:36 -05:00
Matthew Kennedy 9a1217a128 actually use button name (#2126)
Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
2020-12-24 07:30:56 -05:00
rusefi 4c347026ff Proteus is compiled without VSS feature #2122 2020-12-22 21:28:51 -05:00
rusefi 06e72d6676 trigger and start button pins not displayed by "pins" command #2084 2020-12-22 21:20:57 -05:00
rusefi a06c58d916 trigger and start button pins not displayed by "pins" command #2084 2020-12-22 21:05:49 -05:00
rusefi a65a5330de trigger and start button pins not displayed by "pins" command #2084 2020-12-22 20:54:28 -05:00
rusefi da70fdced4 trigger and start button pins not displayed by "pins" command #2084 2020-12-22 20:53:05 -05:00
rusefi 6ddfff8fd9 Proteus is compiled without VSS feature #2122 2020-12-22 20:50:01 -05:00
rusefi 1e4ae3868c trigger and start button pins not displayed by "pins" command fix #2084 2020-12-22 20:42:30 -05:00
Matthew Kennedy d3a24c568a gpio unit tests (#2099)
* fix unregister api for gpio

* consumers

* guard with a critical section

* index

* guard less

* unregister under lock

* fix reinit

* dead flag

* fix most tests

* initialize properly

* initialize properly

* assertions in tests

* fix message

* move gpio mocking

* test gpios

* we must lock earlier to be truly safe

* this was using huge memory

* devirtualize

* test deinit
2020-12-18 17:19:02 -05:00
Matthew Kennedy 30fd52d82d Fix gpio reinit race condition (#2098)
* fix unregister api for gpio

* consumers

* guard with a critical section

* index

* guard less

* unregister under lock

* fix reinit

* dead flag

* fix most tests

* initialize properly

* initialize properly

* assertions in tests

* fix message

* we must lock earlier to be truly safe

* this was using huge memory

* devirtualize
2020-12-18 17:18:12 -05:00
rusefillc 33bc6b7957 HW CI is flaky :( #2063
more detailed error messages
2020-12-17 20:22:04 -05:00
rusefillc 39a292a46a trigger and start button pins not displayed by "pins" command fix #2084 2020-12-16 22:53:26 -05:00
rusefillc 88bb2f4569 trigger and start button pins not displayed by "pins" command fix #2084 2020-12-16 22:24:19 -05:00
rusefillc f147aabcd7 trigger and start button pins not displayed by "pins" command #2084
progress but not complete fix yet
2020-12-16 22:00:42 -05:00
Andrey G 119ac4f6f5 TLE8888: temp fix of #2065 (#2079) 2020-12-14 15:33:27 -05:00
Matthew Kennedy 27e4d89f5a add support for ext ids (#2060)
Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
2020-12-12 16:34:21 -05:00
Matthew Kennedy 6f491cf5c4 switch stm32 scheduling to use PWM driver (#1983)
* move to folder

* extract hardware part of microsecond_timer

* dead ST forum link

* de-volatile

* simulator build

* guard

* switch stm32 to pwm timer

* comments

* f7 mcuconf

* simulator

* guard

* warning

* header, cleanup

* constant

* less magic

Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
2020-12-11 00:44:40 -05:00
Matthew Kennedy ce2e7d3cbe fix mock pins array (#2050)
* fix

* fix probably
2020-12-10 00:10:58 -05:00
rusefillc 2f15c08498 basic hw in the loop - pwm self validation #2028 2020-12-08 04:52:49 -05:00
rusefillc 3a3586f730 basic hw in the loop - pwm self validation #2028 2020-12-07 20:42:47 -05:00
rusefillc 89cebd7d72 basic hw in the loop - pwm self validation #2028 2020-12-07 20:26:47 -05:00
rusefillc ee9aaf4e0d basic hw in the loop - pwm self validation #2028 2020-12-07 20:01:05 -05:00
rusefillc 93e69bea93 refactoring 2020-12-06 19:04:23 -05:00
Andrey G 4980fc49d9 Fixes after clenup (#2019)
* We still need consoleEventListener for boards with EFI_CONSOLE_SERIAL_DEVICE

* MC33810: add MC_ prefix for command defines

As CMD_PWM define is now used by console command
2020-12-05 11:54:09 -05:00
Andrey G f31731d380 ADC: correctly calculate cache invalidate range for STM32F7xxx (#2021)
Bug was introduced in 5d421f7ffa when
sample buffer was moved out of class. So sample become adcsample_t*
instead of adcsample_t[] and sizeof returns 4.
2020-12-05 10:14:33 -05:00
Andrey G 040e07ec48 adc: fix CPU temperature read for STM32F76x/77x (#2020) 2020-12-05 09:58:23 -05:00
Matthew Kennedy b34759f3c9 fix warnings (#2003)
Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
2020-12-03 07:27:27 -05:00
Matthew Kennedy c442f1f785 fix gpio the right way (#1990)
* fix the right way

* use the api

* explain

Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
2020-11-27 00:24:41 -05:00
rusefillc 5390fccada Starter is engaged on start-up in pull-up configuration #1969 2020-11-26 10:55:39 -05:00
rusefillc 7b8d20108f Starter is engaged on start-up in pull-up configuration #1969 2020-11-26 10:41:22 -05:00
rusefillc fa3410ec07 Starter is engaged on start-up in pull-up configuration #1969 2020-11-26 00:24:15 -05:00
rusefi ab98e15f01 Starter is engaged on start-up in pull-up configuration #1969 2020-11-26 00:16:59 -05:00
rusefillc 3cbb33c763 avoid float -> int64 conversion #1977
cherry picking...
2020-11-24 20:33:51 -05:00
Matthew Kennedy ebb8ede1da squash warnings (#1984)
* warnings

* unused

* a few more

* too much

* uint16_t-ify
2020-11-23 09:43:16 -05:00
Matthew Kennedy eb7a26be14 Port-ify microsecond_timer hardware implementation (#1964)
* move to folder

* extract hardware part of microsecond_timer

* dead ST forum link

* de-volatile

* simulator build

* guard
2020-11-22 20:39:32 -05:00
rusefi 954d214919 adc fixed #1979
partial revert
2020-11-22 15:31:33 -05:00
rusefillc b1510791c5 ADC: fixes: #1979
better error handling?
2020-11-22 13:42:24 -05:00
rusefi ba97b22236 ADC: fixes: #1979
more detailed error message
2020-11-22 12:57:04 -05:00
Andrey G 005a5daa74 ADC: fixes: (#1979)
* ADC: fixes:

-use enums
-internalAdcIndexByHardwareIndex array should be adc_channel_e size
-add sanity checks
-save few bytes of RAM

* ADC: use logical OR instead of math add
2020-11-22 12:23:27 -05:00
Andrey G 83f5c8e6b6 Typo fix (#1978) 2020-11-22 08:27:03 -05:00
rusefillc 12187b4254 Starter is engaged on start-up in pull-up configuration #1969
maintainability
2020-11-20 00:18:38 -05:00
shadowm60 e69d103461 Launch control unit tests update (#1972)
* testable launch start

* extract base class

* add a test

* fix ts debug

* Launch control unit_tests

updated launch control for a better split
VSS mock for unit tests

Co-authored-by: Matthew Kennedy <matthewkennedy@outlook.com>
2020-11-19 21:14:38 -05:00
Matthew Kennedy 2792828dce Remove lockAnyContext, replace with CriticalSectionLocker (#1938)
* switch to CriticalSectionLocker

* that's just about all

* clean up last usage

* include hpp for sim

* need the cpp wrappers in the makefile too

* include dir

* include
2020-11-19 06:56:02 -05:00
rusefillc dbdfd87c6d Starter seems to be engaged forever fix #1965 2020-11-18 23:54:30 -05:00
rusefillc 3a38c837cc Starter seems to be engaged forever #1965 2020-11-18 22:45:37 -05:00
rusefillc 9f94205b2b Starter seems to be engaged forever #1965 2020-11-18 21:45:17 -05:00
Matthew Kennedy 776dd75a8a consolidate to common (#1962) 2020-11-18 16:22:19 -05:00
Matthew Kennedy 786aaf2e3c put getTimeNowLowerNt in to mpu_util (#1950)
* put getTimeNowLowerNt in to mpu_util

* move GPTDEVICE to port_mpu_util

* and remove from efifeatures
2020-11-18 14:17:00 -05:00
rusefi 5a249e1b8f better MC33816 start-up status 2020-11-18 01:07:09 -05:00
Andrey G 39bc608ce5 TLE8888: disable diagnostic for OUTPUT8..13 (#1956)
Enabled pull-down affects analog inputs that shares same pins.
Disable it.
DOTO: enable diagnostic if ouput requested through tle8888_setPadMode
2020-11-17 18:33:37 -05:00
rusefillc ecbdfe379e docs 2020-11-17 08:25:50 -05:00
Matthew Kennedy 319384143e read SD card config exactly once (#1955)
* only read mmc device once

* format

Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
2020-11-17 07:48:43 -05:00
Matthew Kennedy e0d0727896 adjust microsecond_timer api (#1952)
* change timer api

* don't need all that
2020-11-16 18:50:13 -05:00
Matthew Kennedy d9f625c8ba prevent MMC preemption by TS thread (#1949)
* prevent preemption by TS thread

* didn't need that
2020-11-15 20:44:36 -05:00
Matthew Kennedy 6b0c533d2c consolidate EFI_UNIT_TEST and friends (#1940)
* restructure

* guard c++

* idle too

* status_loop.h

* consolidate definitions

* use 1/0 instead, check for existence

* missed a few

* dead define

* defs for bootloader
2020-11-11 20:34:39 -05:00
Andrey G 2f891cc23a Tle8888 stepper (#1936)
* TLE8888: enable PP mode for OUT21..24 in case of useTLE8888_stepper

* Lada Kalina is a test mule for stepper idle
2020-11-10 14:16:46 -05:00
rusefi 9f237d963b debounce unintended auto-increment bug (was: Proteus TCU gear shift configuration) #1927
refactoring
2020-11-07 00:46:59 -05:00
rusefi 55065781f8 debounce unintended auto-increment bug (was: Proteus TCU gear shift configuration) #1927
undoing brain fart
2020-11-07 00:43:42 -05:00