Commit Graph

2184 Commits

Author SHA1 Message Date
rusefillc cb3c070928 refactoring: type safety 2022-09-11 02:57:35 -04:00
rusefillc f9b849dd8f refactoring - reducing API between FW and Java 2022-09-11 02:16:47 -04:00
Andrey 3c1cc0b857 trigger: in corner cases like NB2 and VQ35 those are not revolutions 2022-09-07 22:24:28 -04:00
Andrey 91179ac54b brutal encapsulation 2022-09-07 20:31:04 -04:00
Andrey a7c8ce61f4 brutal encapsulation 2022-09-07 19:37:11 -04:00
Andrey 25b6d39802 os_access.h dead? 2022-09-07 15:56:45 -04:00
rusefi 06552b6bee servo is truly not alive 2022-09-06 16:29:12 -04:00
Andrey 6188703384 tear down Engine god object #4511
just trying different things
2022-09-05 04:09:59 -04:00
Andrey 1ffa98ba89 a bit of dead code 2022-09-01 11:47:56 -04:00
rusefillc bd9a177074 helping CI stay green 2022-08-27 14:51:41 -04:00
Matthew Kennedy 58e27505db log missed exti events (#4473)
* log missed exti events

* units

* s

* guard

* stub for non stm32
2022-08-23 19:45:28 -04:00
rusefillc fdde38c203 better method name 2022-08-22 18:07:59 -04:00
rusefi 27c1165560 canRxAdd bus does not convert from Lua/human value into zero-indexed implementation value fix #4467 2022-08-21 23:48:10 -04:00
rusefi b94195255c less violent error handling 2022-08-21 22:46:59 -04:00
rusefi 3eeff9e388 Lua CAN bus index: let's fail if invalid value specified 2022-08-21 22:31:52 -04:00
rusefillc d418a7f288 RUSEFI virtual drive to spell out firmware version fix #4458 2022-08-18 21:02:26 -04:00
rusefillc eb5f0abd3b RUSEFI virtual drive to spell out firmware version fix #4458 2022-08-18 20:13:00 -04:00
rusefillc 09027e90ec RUSEFI virtual drive to spell out firmware version fix #4458 2022-08-18 19:49:01 -04:00
rusefillc 82d2cf2187 RUSEFI virtual drive to spell out firmware version fix #4458
# Mac OS comes with Bash version 3 which is quite limiting and lack key features
2022-08-18 19:46:42 -04:00
rusefillc c65f64200f RUSEFI virtual drive to spell out firmware version fix #4458
80% of the result for 20% of the effort
2022-08-18 19:31:49 -04:00
rusefillc dfd4953f0d unconditional VVT PID logging 2022-08-17 00:47:31 -04:00
Matthew Kennedy aafd128b13 update libfirmware (#4446)
* update libfirmware

* s
2022-08-16 23:02:34 -04:00
rusefi 8a15a4facc verboseCan bugfix 2022-08-11 01:19:10 -04:00
rusefi 5a5f857895 ISO-TP does not work on real car #4427 2022-08-11 00:29:09 -04:00
rusefillc 19ad9672a4 verboseCan EXT fix 2022-08-09 20:39:27 -04:00
Matthew Kennedy 5fc7000834 Pt2001 module (#4396)
* pt2001 uses module

* read flag0

* c

* libfirmware

* makefiles

* are unit tests happy?

* bootloader
2022-08-08 08:53:08 -04:00
Andrey G 074563ddfd OpenBLT shared params (#4417)
* OpenBLT: linker file: use last 16 bytes of ram for shared area

This area is used for communication between FW and OpenBLT.

* OpenBLT: startup: invalidate only DFU breadcumb from startup code

Same location (but different seed) is used for shared param's
signature in OpenBLT.

* OpenBLT: enable shared params

* OpenBLT: enable hooks

If 0x01 is stored in shared param idx=0, then stay in OpenBLT forever.

* Jump to OpenBLT: store proper shared param when OpenBLT is requested

TODO: calculate and store CRC too!

* OpenBLT: move shared_params to start of RAM

* Bootloader: Allocate 16 bytes at start of RAM for bootloader shared area

* OpenBLT: shared_params: reuse same .c and .h file for main application

* OpenBLT: shared_params: enable CRC check

* OpenBLT: no need to manualy set breadcumb before reset

* Revert "OpenBLT: startup: invalidate only DFU breadcumb from startup code"

This reverts commit 6b064714b953560227ae53e38355332cf9f46f7f.

* OpenBLT: guard for builds without OpenBLT

* OpenBLT: reboot to OpenBLT on CAN request with ID=0x667 and DLC=2

* config: options to enable OpenBLT on CAN interfaces

* OpenBLT: comments
2022-08-07 19:33:19 -04:00
Matthew Kennedy 61291ad4a5 tle9104 driver (#4410)
* tle9104

* it works!

* cleanup

* cleanup for pr

* efifeatures

* guards
2022-08-02 19:02:03 -04:00
Matthew Kennedy eb442998dc misc fixes (#4411)
* fix warnings

* break to debugger in case of panic

* move the check

* s
2022-08-02 12:19:50 -04:00
Andrey G b8d6d6bf6c MRE: tle8888 ls2 fix and friends (#4409)
* tle8888: ups IGN1

* tle8888: more BIT() macro

* tle8888: fix typos

* tle8888: fix LS2 output on MRE when stepper is enabled

Default settings casue one (or few) not used direct driver inputs
to be mapped to OUT5 (LS2 on MRE)

* smart_gpio: comments for TLE8888 on MicroRusEFI

* smart_gpio: typo

* tle8888: more comments
2022-08-02 00:50:56 +03:00
rusefillc a4dd43da27 https://github.com/andreika-git/hellen-one/issues/173 2022-07-31 04:39:02 -04:00
rusefillc 4bf82d2611 [SECURITY] Cheap password protection against tune modification #4243
ohh cute we have name overlap!
2022-07-30 11:28:56 -04:00
rusefillc b3e13f12b4 Adc mux (#4379)
* adc mux

* cypress is a special ADC size case

Co-authored-by: Matthew Kennedy <matthewkennedy@outlook.com>
Co-authored-by: rusefillc <sdfsdfqsf2334234234>
2022-07-26 14:12:00 +03:00
rusefillc 87df9d1718 safer without LED 2022-07-26 04:35:12 -04:00
Andrey G bdaf1587d7 Openblt to dfu jump fixed (#4367)
* OpenBLT: supress "target 'startup_xxxxxx.o' given more than once in the same rule" warning

* OpenBLT: check for DFU request, do not ignore dead beef
2022-07-22 07:43:15 -04:00
Andrey G 4a4443a27d Add "Reset to OpenBLT" button (#4364)
Similar to "Reset to DFU", but uses different seed
2022-07-22 08:21:11 +03:00
Matthew Kennedy 4c1f624af1 detect too short/too long boost (#4363) 2022-07-21 15:53:57 -04:00
Matthew Kennedy efdae2322d Start -> start (#4366) 2022-07-21 15:17:32 -04:00
rusefillc 5aa9942fe0 more on MRE BT drama part 2 2022-07-18 02:15:31 -04:00
Matthew Kennedy ba8a84e5ce GDI: add min/max boost time config (#4343)
* add min/max boost time config

* add cast

* generated

* UI
2022-07-16 02:23:05 -04:00
Matthew Kennedy 07acf4d405 pt2001 sim project (#4342)
* sim project files

* wave list

* project files

* ignore simulator build files

* ignore .def.hex too

* wave list and readme

* readme
2022-07-14 17:42:57 -04:00
Matthew Kennedy c259b1cf2d pt2001 updates (#4340)
* delete registers/

* update gitignore

* readme

* Revert "delete registers/"

This reverts commit de10448d5479487b529b4e9ee551f45f271daa8c.

* remove dead dram constants

* switch to use generated C source instead of copy/paste

* more memory map
2022-07-14 12:47:51 -04:00
rusefillc 02ce0423bf STM32_HSE_BYPASS where we need it (#4338)
Co-authored-by: rusefillc <sdfsdfqsf2334234234>
2022-07-11 04:30:49 -04:00
Matthew Kennedy 16a39badff Error handling cleanup (#4332)
* dead code in stm32

* rusefi.cpp can have some noreturn

* handle lua panic

* unused error codes

* simplifications of error_handling.cpp

* comment

* put that back

* guard
2022-07-07 23:49:02 -04:00
rusefillc c51881a80d debug is set to idle mode, but none of the debug fields show anything #4335
reducing confusion
2022-07-07 23:04:19 -04:00
Matthew Kennedy 6267b8621a big delete ICU (#4270)
* big delete

* icu vestiges

* changelog
2022-07-07 15:27:59 -04:00
Matthew Kennedy cbdfb7ac5c Write hard faults to backup ram, print on next boot (#4324)
* use backup ram, hard fault handler improvement

* wire it up

* upload elf

* s

* I guess I'll just use strncpy

* s

* what is it even complaining about?

* neat, we don't need a cast

* cypress and kinetis

* cleanup

* ci

* guard for tests
2022-07-07 15:14:31 -04:00
Matthew Kennedy 2c80b8cf19 implement CAN driver for simulator (#4312)
* stub simulator CAN driver

* comments

* CAN sensor

* maybe implement?

* s

* fix

* tx and rx actually work!?!?!

* check_can_isr

* modify chibios

* Sim has no CAN on Windows (for now?)

* safer init/deinit, enable assertions

* smarter handling of missing CAN device

* better guards

* guards for windows
2022-07-03 08:25:24 -04:00
Matthew Kennedy 478549ccdf get rid of setSerialConfigurationOverrides (#4274)
* get rid of setSerialConfigurationOverrides

* missed a few

* kinetis
2022-06-23 19:42:09 -04:00
Matthew Kennedy be3e64fd2a clean up sd overrides (#4272) 2022-06-23 09:15:51 -04:00
rusefillc 57ceda97c6 symmetrical logging 2022-06-19 11:03:26 -04:00
rusefillc 33ba12f130 docs 2022-06-07 17:13:21 -04:00
Matthew Kennedy c2f61dc95f Remove third trigger channel (#4226)
* remove third trigger

* clean up the honda mess

* there was nothing novel about this engine config

* include

* missed a few

* s

* x

* changelog

* don't set the third trigger input

* don't redefine the same thing 3 times

* only two inputs!

* test
2022-06-01 21:24:20 -04:00
Matthew Kennedy c185771362 500 byte blocking factor (#4227) 2022-06-01 20:27:20 -04:00
rusefi 991c4aa7b8 trying to reduce confusion x2 2022-05-30 17:06:56 -04:00
Matthew Kennedy 6ea78efbe7 bail from trigger_central (#4210) 2022-05-29 10:42:08 -04:00
rusefillc 9bf63486b5 less confusing error message https://rusefi.com/forum/viewtopic.php?p=45456#p45456 2022-05-28 17:46:45 -04:00
rusefillc 25c965e822 making file reuseable 2022-05-26 23:54:30 -04:00
rusefillc 160d5305c9 unique file name seems a bit more convenient 2022-05-26 23:43:44 -04:00
rusefillc a9e6a4ba94 why does this fail? (#4196)
Co-authored-by: rusefillc <sdfsdfqsf2334234234>
2022-05-26 20:54:36 -04:00
rusefillc 270968d88f how are these layout files used? is this change legit? (#4198)
* reducing OpenBLT file duplication

* Revert "Revert "what could possibly go wrong with MRE""

This reverts commit 405dbbc681.

Co-authored-by: rusefillc <sdfsdfqsf2334234234>
2022-05-25 17:10:41 -04:00
rusefillc b1927528e7 Matt drives H7 #4175 2022-05-24 18:28:16 -04:00
rusefillc e3d5e9ce0f reducing code duplication, also one step back with HSE 2022-05-24 16:25:16 -04:00
rusefillc ed40d0b0d5 reducing code duplication 2022-05-24 16:05:07 -04:00
rusefillc 9cae07cfd2 reducing code duplication 2022-05-24 15:45:06 -04:00
rusefillc 64338037f9 reducing code duplication 2022-05-24 15:31:14 -04:00
rusefillc 1ade9c4394 promoting openblt to it's own folder 2022-05-24 15:23:55 -04:00
rusefillc 66bdc45ed6 typos 2022-05-24 15:07:31 -04:00
Matthew Kennedy 6813ff141f correct channels (#4190) 2022-05-19 19:09:41 -04:00
Matthew Kennedy 4531ef2286 harley (#4188) 2022-05-19 16:44:56 -04:00
Matthew Kennedy a0d9a584db prototype overcurrent protected driver (#4029)
* stub passthrough protected driver

* plumbing

* include the thing

* signature

* dead

* tdg pdm build task

* s

* pdm pins

* tdg

* init properly

* remove gaps

* board doesn't fatal on start
2022-05-17 23:49:18 -04:00
rusefillc d690544793 Timestamp Error scheduleByTimestampNt too far #3395
improving error message
2022-05-14 21:24:19 -04:00
rusefillc 85c317343e .ini image fix (#4161)
Co-authored-by: rusefillc <sdfsdfqsf2334234234>
2022-05-10 20:06:45 +03:00
rusefillc 4517c2cfe9 CAN category (#4148)
Co-authored-by: rusefillc <sdfsdfqsf2334234234>
2022-05-09 16:49:23 -04:00
rusefillc 54dcb27346 spelling 2022-05-02 16:08:04 -04:00
Matthew Kennedy 83caf1ea1b Brain pin is enum class (#4108)
* change most usages to Gpio::

* board configs

* engine configs etc

* isBrainPinValid, smart gpio

* generator

* generator

* generator

* connector yamls

* kinetis enums

* cypress txt

* kinetis config

* frankenso

* config generator

* actually do it for the others

* disable skips for pr ci

* fix tle8888

* misc

* weird cast from int

* needs this operator too

* this can be an unsigned subtract

* happy tests

* s

* kinetis isConfigurationChanged weirdness

* missed J/K

* cypress efifeatures

* build script mistake (!)

* mistake in smart gpio

* debounce

* eg33

* kinetis, so needy

* it's pretty green, we can skip these again
2022-04-28 17:32:39 -04:00
Matthew Kennedy a2e1a079b8 allow enum_class in rusefi_hw_enums.h (#4104)
* make things c++ friendly

* install various canaries in coal mines

* using is much clearer than typedef

* fixing builds

* lps25

* trigger includes were a mess

* c -> c++ cleanup

* os util

* why did so many include os_util.h?

* fwd declare

* cypress/kinetis

* s

* eg33 happy

* happy sim

* cypress usb

* pch

* cypress

* doesn't need to include all that

* h7
2022-04-25 20:38:16 -04:00
Matthew Kennedy 0a1d18cf3b fix proteus legacy vbatt (#4092) 2022-04-25 17:08:04 -04:00
Matthew Kennedy 8650686ab7 knock threshold table fix (#4077)
* fix knock threshold table

* defaults

* knock controller is engine module

* testable

* test builds

* knock tests work

* s

* format

* everyone loves changelogs
2022-04-18 08:03:16 -04:00
rusefillc 06e7cc9e41 we need a bit extra now 2022-04-17 22:48:48 -04:00
rusefillc e16117f6ce very random progress 2022-04-16 17:04:35 -04:00
Matthew Kennedy 0bf672cd4d exti uses a queue (#4027)
* exti uses a queue

* TRIGGER_BAIL_IF_SELF_STIM
2022-04-03 03:22:54 -04:00
rusefillc 0a0345b754 We have working runtime RAM detection - we shall use it for Lua #3970 2022-03-27 19:39:40 -04:00
Matthew Kennedy 5cf2b1bba5 warning cleanup (#4020) 2022-03-22 16:53:24 -04:00
rusefi 63f430d5d6 typo & progress 2022-03-15 15:50:39 -04:00
rusefillc e6875c4f3f https://github.com/rusefi/rusefi/pull/3976
maybe probably help
2022-03-02 18:52:00 -05:00
rusefillc f37943e56c Feature request: odometer for engine break #3857 2022-02-25 00:46:45 -05:00
Andrey G df1c6a4b7c ports: stm32f7: ld file: fix typo (#3956) 2022-02-23 10:03:44 -05:00
Andrey G 311542e84a Flash size on eg33 (#3955)
* subaru-eg33: 1M of flash is available for FW and bootloader

* ports: stm32f7: allow board define its flash size, otherwise 512K
2022-02-23 07:36:58 -05:00
Matthew Kennedy 6e4cb12275 mitigate F7 flash error by making the image smaller (#3859)
* grumble

* do it for all F7
2022-02-19 15:56:44 -05:00
rusefi bcab9b827f Revert "SD card read prefetcher (#3814)"
This reverts commit 7a5860bf07.
2022-02-13 19:03:09 -05:00
Andrey G 785c9792c3 usb descriptor: we are bus powered and can consume up to 400mA (#3933) 2022-02-13 16:12:22 -05:00
Matthew Kennedy 7a5860bf07 SD card read prefetcher (#3814)
* block cache

* efi::size

* extract function and prefetch at start

* comments

* s

* s

* bool result

* no prints

* refactoring

* enable only on some ECU

* normalize

* adjust defines

* is_protected

* naming, comment

* cleanup

* typo

* priority

* mem

* not that mem
2022-02-09 15:40:37 -05:00
rusefillc 7a49444d00 L9779WD driver L9779 #3768
oops
2022-02-09 08:14:28 -05:00
rusefillc e8665a0c02 L9779WD driver L9779 #3768 2022-02-09 08:00:30 -05:00
Matthew Kennedy 0222aab5e3 support lps22 (#3900)
* support lps22

* s

* changelog, UI
2022-02-07 17:09:51 -05:00
rusefillc 994221442b I2C EEPROM support #3860
helping build
2022-02-06 21:26:22 -05:00
rusefillc 88e72a8116 I2C EEPROM support #3860 2022-02-06 19:48:20 -05:00
rusefi 9264b36ef9 I2C EEPROM support fix #3860
bare bones support works
2022-02-06 19:39:21 -05:00
Andrey G d34e708b55 L9779: update (#3899)
* L9779: update

* L9779: cleanup macro
2022-02-06 17:47:53 -05:00
rusefi 33fcbd56c1 unused code? 2022-02-06 17:44:58 -05:00
rusefi cdbd94a15b I2C EEPROM support #3860 2022-02-06 17:23:07 -05:00
Andrey G 883e1ce4ae L9779: update driver (#3898)
* L9779: update driver

* L9779: missed chip_init

* L9779: signature
2022-02-06 11:39:37 -05:00
Andrey G 48b35df6a3 L9779: initial driver (#3897)
* smart_gpio.cpp: glue to L9779

* L9779: fill with some code

* L9779: missed getDiag

* L9779: no l9779 on subaru-eg33 board
2022-02-06 09:47:18 -05:00
Matthew Kennedy 8f536425fb fix f4 standby (#3894)
* fix the bug

* wake on PD0 = CAN RX

* cleanup
2022-02-05 07:25:09 -05:00
rusefillc 6eefbca135 I2C EEPROM support #3860
let's go with EE24 for now
2022-02-04 22:03:12 -05:00
rusefillc b1a7797c09 Wider usage of contrib (#3892)
* I2C EEPROM support #3860

let's use contrib on all F4

* I2C EEPROM support #3860

let's use contrib on all F4, step 2

* I2C EEPROM support #3860

let's use contrib on all F4, step 3

* I2C EEPROM support #3860

let's use contrib on all F4, step 4

* I2C EEPROM support #3860

huh

* I2C EEPROM support #3860

all the way

Co-authored-by: rusefillc <sdfsdfqsf2334234234>
2022-02-04 21:50:21 -05:00
Matthew Kennedy 31c0afc79f remove mock adc (#3888)
* remove mock adc

* do these do /anything/?
2022-02-03 20:43:34 -05:00
rusefillc c1dd86f1d0 User board-specific terms in error messages #3886
progress
2022-02-03 12:45:26 -05:00
Andreika e6c705ece1 hellen_board_id + hellen-common.mk (#3885)
* Hellen_board_id

* move EXTI init before config load

* add NT2USF()

* Hellen_board_id unit-tests

* hellen-common.mk

* fix for older macos compiler
2022-02-03 11:24:31 -05:00
Matthew Kennedy 0fba5796e9 fix (#3877) 2022-02-01 18:40:40 -05:00
Matthew Kennedy 56240cb668 we have other places to set these MCU values (#3875)
* we have other places to set these values

* missing parts

Co-authored-by: rusefillc <rusefillc@gmail.com>
2022-02-01 18:18:16 -05:00
rusefillc 5c16186919 safer file name (#3861)
* safer file name

* safer file name

Co-authored-by: rusefillc <sdfsdfqsf2334234234>
2022-01-31 21:51:32 -05:00
rusefillc 606476fc57 Revert "I2C EEPROM support #3860"
This reverts commit 22a6d5b0f3.
2022-01-31 20:39:20 -05:00
rusefillc 22a6d5b0f3 I2C EEPROM support #3860 2022-01-31 19:48:53 -05:00
rusefillc 6836c80cd0 I2C EEPROM support #3860 2022-01-31 18:58:39 -05:00
Matthew Kennedy fe6cdf60e3 warnings fixes (#3851)
* unused things

* !!! actual bug !!!

* dead

* unused

* unused

* multi-bus lua RX was just broken

* make the compiler angry about it

* dead config

* alphax 2

* just call, no store

* compiler too angry
2022-01-31 18:37:42 -05:00
Matthew Kennedy 03e8abd5e1 remove getDebugChannels (#3850) 2022-01-27 19:21:05 -05:00
rusefillc 321d032f50 docs 2022-01-26 13:13:06 -05:00
rusefillc 324b90e6e7 https://github.com/rusefi/alphax-2chan/issues/22 2022-01-22 17:28:11 -05:00
rusefillc 93fff340fd https://github.com/rusefi/alphax-2chan/issues/22 2022-01-22 16:50:58 -05:00
Andrey 3e3bdab488 migrating to SensorType::Rpm API 2022-01-20 22:38:08 -05:00
NMSTEC 6cdb5514a5 Add comments to Stop & Stby modes (#3798) 2022-01-17 13:11:24 -05:00
rusefillc 97b194f753 PA0 wake up - sharing is caring? 2022-01-17 01:25:31 -05:00
rusefillc d90eb5259b https://github.com/rusefi/alphax-2chan/issues/17 2022-01-16 10:48:31 -05:00
rusefillc 9ec0393d9e Catch up with Chibios 20.3 #2555 2022-01-15 21:43:01 -05:00
rusefillc afdca12d86 refactoring? 2022-01-14 22:45:49 -05:00
rusefillc 597a3430d9 https://en.wikipedia.org/wiki/Pi 2022-01-14 21:23:27 -05:00
NMSTEC 190c895e05 F429 Working Stby, Stop & Wake PA0 (#3787) 2022-01-12 23:18:58 -05:00
rusefillc f34d968a20 GDI red FATAL led on cranking fix #3766 2022-01-12 01:01:33 -05:00
rusefillc fc996ad339 Code style for methods with zero arguments #3535 2022-01-11 22:26:24 -05:00
rusefillc 3a069be8f2 L9779WD driver #3768 2022-01-10 19:15:36 -05:00
rusefillc cc13519e6d L9779WD driver #3768 2022-01-10 16:53:38 -05:00
Andrey G fc32af43bb F429 discovery ram dev (#3761)
* stm32f429-discovery: mostly copy-paste from ChibiOS-Contrib

* STM32F429-discovery has external SDRAM

* F429-Discovery: add simple memory test for SDRAM (disabled)

* Revert "random piece of https://github.com/dron0gus/rusefi/tree/f429-discovery-ram-dev"

This reverts commit 9625820272.

Co-authored-by: rusefillc <sdfsdfqsf2334234234>
2022-01-10 16:14:39 -05:00
Matthew Kennedy 4ee76aadc2 per-board pre-low-power handlers (#3752)
* per-board pre-low-power handlers

* per-chip standby options

* default implementation
2022-01-10 08:37:05 -05:00
Andrey G 8205c37da0 Sdram preparations (#3764)
* ports: stm32f4: not all stm32f4xx are stm32f407, let board decide

* Do not include mcuconf_community.h in port's mcuconf.h usign relative path

as override file can be provided in board directory.
2022-01-10 08:31:29 -05:00
rusefillc 4537561214 AlphaX few bytes of progress 2022-01-10 01:47:06 -05:00
rusefillc 9625820272 random piece of https://github.com/dron0gus/rusefi/tree/f429-discovery-ram-dev 2022-01-09 22:45:46 -05:00
Andrey G b37c9d546f Enable ENABLE_AUTO_DETECT_HSE only if STM32_HSECLK is not defined (#3758)
Some board (like stm32f429-disco) with SDRAM need clock to be
enabled in __early_init (before .bss and .data initialization).
So if STM32_HSECLK defined - skip clock detection.
2022-01-09 17:39:29 -05:00
Andrey G 26a9795d94 Ports: STM32F4: add optional external SDRAM (#3762) 2022-01-09 17:39:10 -05:00
rusefillc 8857acedbe GDI Epic #1448 2022-01-08 20:16:01 -05:00
Andrey G f139e76345 USB: use OTG1/OTG2 for serial over USB depending on which enabled (#3757) 2022-01-08 16:33:48 -05:00
Andrey G f4730421ed mk files random cleanup (#3759) 2022-01-08 16:33:34 -05:00
Andrey G a3849edbcc CAN: do null check first (#3755)
Otherwise it will emit strange error if both can are disabled
2022-01-08 10:25:21 -05:00
rusefillc 58748c3f70 docs 2022-01-07 21:35:21 -05:00
rusefillc e7e7ffac69 docs 2022-01-07 19:26:43 -05:00
rusefillc 35f3ecbb7e docs 2022-01-07 18:57:23 -05:00
NMSTEC 1bde061b2d Stop & wakeup working on rising edge (#3747)
* Stop & wakeup working on rising edge

* Standby & Sleep mode working Using PA0 only.

* Stop & standby works with wake from PA0.
Added alternative interrupt method to STOP

* Removed hand screwery on registers
2022-01-07 16:46:28 -05:00
Andrey G f043b53c9a TLE8888: do not allow direct gpio drive for Push Pull outputs (#3748)
Some register settings also needs to be changed. Change of direct
drive input is not enought.
2022-01-07 14:11:21 -05:00
rusefillc f52c6ba41e TLE8888 diag says OK on disconnected pins and bench test #3737 2022-01-03 20:33:51 -05:00
rusefillc d4bc7077b3 smart diag into bench test 2022-01-03 14:21:54 -05:00
rusefillc 3c471c9486 typo 2022-01-03 03:09:14 -05:00
rusefillc c2b5c7ce52 GDI/HPFP: Set HPFP current/timing params on MC33816 #3736 follow-up 2022-01-03 02:13:47 -05:00
Scott Smith 5e5750a5d5 GDI/HPFP: Set HPFP current/timing params on MC33816 (#3736) 2022-01-03 01:46:00 -05:00
Matthew Kennedy a6ef26a1d5 fix dual CAN init, update UI (#3719)
* CAN init sequence

* config & UI cleanup

* ui

* simplify
2021-12-24 23:33:54 -05:00
rusefillc 7bac63c2fa Second CAN #3687 2021-12-22 22:02:34 -05:00
rusefillc 604f84fe9f Second CAN #3687 2021-12-22 20:43:08 -05:00
rusefillc 8f51dad2ef Second CAN #3687 2021-12-22 20:39:07 -05:00
rusefillc 319ee90b46 Second CAN #3687 2021-12-22 20:15:22 -05:00
rusefillc 6f0e0a33f2 Second CAN #3687 2021-12-22 20:15:22 -05:00
rusefillc e2dbe85a50 Second CAN #3687 2021-12-21 01:10:37 -05:00
rusefillc dad928a627 Second CAN #3687 2021-12-21 00:48:13 -05:00
rusefillc 7eca4d663b 2 byte table axis #3045 2021-12-19 22:43:10 -05:00
rusefillc 8617531407 Second CAN #3687
what could possibly go wrong?
2021-12-19 11:28:42 -05:00
Matthew Kennedy 0d1539f869 multi CAN plumbing (#3688)
* framing for multi CAN

* typoooooooo
2021-12-10 17:08:10 -05:00
rusefillc 5ee26c81d5 rusEFI console ISO-TP via PCAN #3667
fixing build #3
2021-12-08 16:24:54 -05:00
Andreika 95adac3f03 CAN ISO-TP progress (+unit-tests fix) (#3677)
Co-authored-by: Andrei <andreikagit@users.noreply.github.com>
2021-12-08 15:11:19 -05:00
rusefillc 98dbf0a352 rusEFI console ISO-TP via PCAN #3667 2021-12-08 12:01:28 -05:00
Andrey d2c46b3310 Let's always have TS structure so that unit tests can check values in outputChannels, kind of making outputChannels a god dump for state but whatever since Live View is coming 2021-12-07 20:18:47 -05:00
Matthew Kennedy da28561241 testing stm32 stop/standby (#3666)
* testing stop/standby

* comments

* guard

* s

* we shall figure out f7 later

* ok maybe we do worry about f7

* comments and tweaks

* f7

* f4 maybe probably
2021-12-07 15:12:33 -05:00
rusefillc 359420e93d Pause CAN broadcast on engine stop #3665 2021-12-07 10:35:52 -05:00
rusefillc ebc24cd71b https://rusefi.com/forum/viewtopic.php?f=18&t=2236 2021-12-06 21:31:49 -05:00
Andrei d1f30f10b1 CAN update 2021-12-03 21:44:15 -05:00
rusefillc 97be2908ce doc 2021-12-03 09:57:15 -05:00
Andreika 8b076ee341 more trigger_adc & cypress fixes (#3642)
Co-authored-by: Andrei <andreikagit@users.noreply.github.com>
2021-12-01 17:26:58 -05:00
rusefillc d8418f2228 trigger_adc helping cypress 2021-12-01 15:26:38 -05:00
rusefillc 85cb0de38c trigger_adc helping cypress 2021-12-01 15:09:34 -05:00
rusefillc 533531c92b trigger_adc helping cypress 2021-12-01 14:40:36 -05:00
rusefillc 9dcaa2ecbc trigger_adc helping simulator 2021-12-01 14:17:16 -05:00
rusefillc a13bc09fe4 trigger_adc unit tests 2021-12-01 13:35:44 -05:00
Andreika 99c4dd4cb4 hellen81 ADC trigger 2021-12-01 13:03:08 -05:00
rusefillc c64fb3f595 why so many channels are hidden in debug ? #3614 2021-11-29 01:02:40 -05:00
Matthew Kennedy 2dda9bedb8 verbose CAN bits picker (#3628)
* verbose bits picker

* s
2021-11-28 14:59:26 -05:00
Matthew Kennedy aed334f9ac better VSS configuration (#3542)
* vss uses real values

* some defaults

* test and correct math

* km, not miles!

* comment

* tooltip

* that macro went away

* 100hz and default settings gives 9kph

* changelog

* order of operations safety

* make the test like the pwm test

* housekeeping

* this is why we need sensor automation

Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
2021-11-27 08:49:07 -05:00
Andrey 46f7a3e3dd Mark hit timer watchdog #3608 2021-11-24 20:34:24 -05:00
Matthew Kennedy e7417ef0c0 simulator writes binary log (#3598)
* simulator writes log

* replace the file

* check that the sim actually fails

* put it back

* did the sim really not fail?

* good, asan does catch it
2021-11-23 11:42:45 -05:00
Matthew Kennedy e2a4504728 rpm calculator refactoring, gm 24x test (#3585)
* data

* stub test

* use getTimeSinceSyncPoint

* s

* s

* no

* test

* stray ;

* those were 1/10 what they were supposed to be

* actually check something

* dead log line?
2021-11-20 14:59:02 +03:00
Scott Smith 8406fafa9e Expose console over serial port for H7 proc (#3578)
This way you can use the console/TunerStudio with the ST-Link

In the process, combine TS_PRIMARY_UART and TS_PRIMARY_SERIAL into TS_PRIMARY_PORT, to make UART vs
SERIAL selection more robus.  Ditto for TS_SECONDARY_*.  Also change use of TS_NO_PRIMARY to be #if
not #ifdef, so that it can be properly set as a compile flag and not be overwritten by various
header files.
2021-11-20 00:39:08 -05:00
Matthew Kennedy 739be57ac8 fast exti interrupt handoff (#3497)
* fast exti

* test code snuck in

* full interrupt disable :(

* do it the old fashioned way

* enable interrupt

* consume stored timestamp

* dead

* h7 maybe

* guard maybe

* non-stm32

* exti 16 wrong on f4/f7

* CORTEX_MAXIMUM_PRIORITY

* safer but uglier

* s

* chibios

* no const

* initializers

Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
2021-11-19 06:37:52 -05:00
Scott Smith 659cc68be1 Final cleanup of ENGINE macros (#3567)
Fix some uses of ENGINE() not detected by regex due to parenthesis.
Remove now empty engine_ptr.h
Don't worry about EFI_* not being defined, the compiler defaults to 0 if they aren't.
2021-11-17 13:45:10 -05:00
Scott Smith 80091498a6 Programmatically replace ENGINE() and CONFIG() with engine-> etc (#3565)
git grep -l -w ENGINE | xargs sed -i -r "s/ENGINE\(([]a-zA-Z_0-9.[]+)\)/engine->\1/g"

git grep -l -w CONFIG | xargs sed -i -r "s/([^a-zA-Z_])CONFIG\(([]a-zA-Z_0-9.[]+)\)/\1engineConfiguration->\2/g"
2021-11-17 03:54:21 -05:00
Scott Smith dac2ae9b1d Programmatically remove EnginePtr/inject, EXPAND_Engine, and WITH_ENGINE_TEST_HELPER* (#3560)
* Programmatically remove EnginePtr/inject, EXPAND_Engine, and WITH_ENGINE_TEST_HELPER*

for i in ": public EnginePtr " ", public EnginePtr" "EXPAND_Engine;" "EXPAND_Engine"; do
    git grep -l "$i" | xargs sed -i "s/$i//g"
done

git grep -l "inject" | xargs sed -i "/inject[(][)]/d"

for i in WITH_ENGINE_TEST_HELPER_SENS WITH_ENGINE_TEST_HELPER_BOARD_CALLBACK WITH_ENGINE_TEST_HELPER; do
    git grep -l "$i" | xargs sed -i "s/$i/EngineTestHelper eth/g"
done

git checkout firmware/controllers/core/engine_ptr.h
git checkout unit_tests/global.h

* Review fixups.
2021-11-16 16:52:11 -05:00
Matthew Kennedy 7296593448 remove engine pointer passing (#3556)
* some

* more

* more

* the last?!
2021-11-16 04:15:29 -05:00
Matthew Kennedy c1941f3a49 (void) -> () (#3550)
* static functions with (void)

* more

* Revert "more"

This reverts commit 246e53441f935451437df186ac92d7df26b62fb6.

* s

Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
2021-11-15 13:02:34 +01:00
Matthew Kennedy bd04dc8352 less macro, more c++ (#3549)
* less macro

* s
2021-11-15 12:44:40 +01:00
rusefi eaf7f15eef speed into caninfo 2021-11-13 10:41:23 -05:00
Andrey aecdc84ab8 UART pins validation and dynamic alternative function recognition #3536 2021-11-11 21:29:18 -05:00
rusefillc 25e0678ac1 todo: smarter online change of CAN settings, kill isCanEnabled with fire 2021-11-06 22:23:06 -04:00
Andrey G 51f53aa3fc Openblt (#3430)
* Makefile: define BOOTLOADER=1 for linker in case of OpenBLT too

This will reserve first 32K of flash for bootloader.

* OpenBLT: include into build

* board: subaru eg33: add OpenBLT board code

* board: subaru eg33: use OpenBLT

* Board: Subaru EG33: OpenBLT: reuse HAL and CMSIS from OpenBLT submodule

* Board: Subaru EG33: OpenBLT: reuse linker file from OpenBLT too

* OpenBLT for MRE

* OpenBLT: MRE: adjust LD memory map for smallest variat of MCU on MRE

* OpenBLT: enable for MRE

* OpenBLT: disable CRC check of user application

This allows us to use DFU tool to flash main application too.

* hex2dfu: fresh binary for linux

* OpenBLT: extract common part of OpenBLT makefiles to openblt.mk

* OpenBLT: enable CRC check of user application for MRE and EG33

CRC (actually just a summ) of few first vectors is stored at 0x1c
offset. This is reserved vector for Cortex-M3, M4 and M7

* common_make: append OpenBLT CRC to dfu files

This should allow to use DFU to do main application update when
when OpenBLT is used as bootloader. hex2dfu will store same
styled CRC as OpenBLT expects to see in user app.

* OpenBLT reorganization

Move common stuff to hw_layer/ports/

* OpenBLT: proteus

* Proteus: enable OpenBLT for F4 and F7

Compilation tested only
2021-11-05 19:28:55 -04:00
Scott Smith cb546dd67b Remove correct file in create_ini_image.sh (#3460) 2021-11-04 16:06:44 -04:00