Commit Graph

99 Commits

Author SHA1 Message Date
rusefi 943b9dcc14 only:smart chips in QC 2023-12-24 19:44:38 -05:00
Andrey ab4b451195 os_access.h dead? 2022-09-07 15:56:45 -04:00
Matthew Kennedy e9d092f975
big delete ICU (#4270)
* big delete

* icu vestiges

* changelog
2022-07-07 15:27:59 -04:00
Matthew Kennedy 8cdac4cac0
remove engine pointer passing (#3556)
* some

* more

* more

* the last?!
2021-11-16 04:15:29 -05:00
rusefillc b4884498cb OBD error renames 2021-10-03 01:30:42 -04:00
Matthew Kennedy b52d50bbf2
Use pch in lots of files (#3066)
* most engine.h

* most engine_configuration

* more

* more

* more

* more

* more

* moooooore

* ok I'm done for now

* oops
2021-07-26 01:05:17 -04:00
Matthew Kennedy 2ce7777865
don't require EXTERN_ENGINE in every file (#2969)
* move enginePins

* no more extern engine

* uses

* more

* extern config too

* put this where it belongs

* include correct header

* merge
2021-07-16 18:13:33 -04:00
Andrey 70cc334eb2 trigger signal debug pins - logic level output #2959 2021-07-15 01:56:04 -04:00
Andrey c513e976ed trigger signal debug pins - logic level output #2959 2021-07-15 01:46:30 -04:00
Andrey 23be588af6 trigger signal debug pins - logic level output #2959 2021-07-15 01:28:44 -04:00
rusefillc b65c4b5612 trigger signal debug pins - logic level output #2959 2021-07-15 00:03:31 -04:00
Andrey b2f09de277 refactoring - making method available 2021-07-13 19:28:03 -04:00
Matthew Kennedy bbb6b6dd14
remove simple cases of LoggingWithStorage (#2569)
* remove simple cases

* more simple

* serial

* s

* more

* try memory

* easy

* mmc acc

* that's how much memory

Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
2021-04-19 08:11:59 -04:00
Andrey G 2af32084f4
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
rusefi a254c79d93 trigger and start button pins not displayed by "pins" command #2084 2020-12-22 21:20:57 -05:00
Matthew Kennedy 690ab7e917
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 5f69d23976
fix mock pins array (#2050)
* fix

* fix probably
2020-12-10 00:10:58 -05:00
rusefillc 66ae6a1ecf Starter is engaged on start-up in pull-up configuration #1969 2020-11-26 00:24:15 -05:00
rusefi 1238758c0f Starter is engaged on start-up in pull-up configuration #1969 2020-11-26 00:16:59 -05:00
Matthew Kennedy 2a1e2c53e3
proteus SD card defaults (#1796)
* proteus SD defaults

* disable serial console pins
2020-09-14 10:54:25 +03:00
David Holdeman 337106cd24
DebounceButton A/C switch (#1782)
* change acSwitch name, add mode

* fix

* remove some adc stuff

* remove some adc stuff

* semicolon stupid

* left behind

* add readpinstate

* wrong var name

* add functions back

* fix name

* bool, not void, plus fix name

* move

* not sure what I broke

* try setMockValue

* namespace

* whoops missed one

* switch values because adc was set up for pullup

* try 5

* comment for now

* comment for now

* uncomment tests, add function to mock, add mock to efiReadPin

* fixes

* for F's sake

* if

* add defy

* pass params

* use ASSERT_TRUE/FALSE

* advance time

* remove ifdef from readPin

* try moving if

* move to separate func

* move extern

* move include

* try engine_test_helper

* am confuse

* move func to else

* include hal

* add efi prod check

* remove include

* try extern

* move include

* semicolon stupid

* move extern again

* include

* move mockPinStates

* size

* add if

* add comment

* clean on instantiation
2020-09-10 22:16:20 -04:00
Matthew Kennedy 53679fab54
Finally rename injector_central to bench_test (#1229)
* bench test rename

* rename consumers

* good lord what are all of these externs doing

* fix tests
2020-03-26 08:03:55 -04:00
Matthew Kennedy c1319342d5
don't use standard sprintf/snprintf (#1174) 2020-03-07 10:28:18 -05:00
rusefi bb217b01dd happy new year unification 2020-01-13 21:57:43 -05:00
rusefi 221ef7d9bb unit tests progress 2019-09-19 22:10:39 -04:00
andreika-git 970f67862c STM32-specific GPIO refactor (stm32_pins.cpp) (#817)
* stm32_pins.cpp

* PIN_USED & other
2019-06-02 16:48:38 -04:00
rusefi de571eee82 refactoring 2019-05-10 17:51:12 -04:00
dron0gus 04ee37548b Smart gpios fixes 3 (#795)
* pin_repository: provide readable pin names in error cases

* io_pins: remove getBrain_pin_eExt

We have getBrain_pin_eExt in io_pins.cpp and hwPortname in
pin_repository.cpp.
First uses auto-generated enums, second one uses runtime data to
provide name of hw pin.
Removing first saves us about 2K of flash couse big auto-generated
switch with pin names no more used by anyone and gets optimized out.

* gpios: mc33972: CS pin is now requested at smart_gpios.pcc

* getSpiDevice: support SPI4

* smart_gpios.cpp: startSmartCsPins set CSs to inactive state

OutputPin:initPin initializes pin with false value. This is active
state for SPI Chip Selects. Set to 1 to deselect all chips.
2019-05-09 18:09:24 -04:00
dron0gus def0123503 Exti rework (#770)
* io_pins: implement efiSetPadUnused

When pin becomes unused it should be switched to safe mode and
disconnected from any IP block. Assume that gpio input mode with
pull-up is safe enough.

* trigger_input: switch triggers pins to safe mode on stop/reinit

* digital_input_exti: rework

* rename enableExti to efiExtiEnablePin
* add efiExtiDisablePin
* keep track of used exti channels

* trigger_input: use digital_input_exti functions
2019-04-21 09:28:49 -04:00
rusefi 508e9d74e7 defined(__DOXYGEN__) ? #748 2019-04-12 20:52:51 -04:00
rusefi dcb3771b16 SPI-controlled outputs #697
better spot for this code
2019-04-10 18:23:31 -04:00
rusefi a829206947 fixing build - BOOTLOADER has it's special limitations 2019-04-10 09:02:32 -04:00
dron0gus 1b39480e64 Gpiochips integration (#740)
* gpio-chips core function renames

* efi_gpio, pin_repository: add support for external gpios

* gpio-chips update

* gpio-chips: add api to name each pin of gpiochip

* tle6240: provide individual names for each pin
2019-04-10 14:43:54 +02:00
dron0gus c6a1d0cbe0 gpios rework (#739)
* Some more include fixes for linux

* Pass cross-compile path through CROSS_COMPILE

* Lower-upper case conversion fixes for linux

* Rename unmarkPin to brain_pin_markUnused

This is part of external gpiochip integration

* Add gpio_pin prefix to markUsed and markUnused

To distinguish from similar functions using brain_pin

* pin_repository: add helpers

this is part of gpio chips integration

* efi_gpio: simplify getHwPin using brain_pin_is_onchip
2019-04-10 01:31:10 +02:00
rusefi d94b6d74e7 better ICU error handling 2019-04-07 18:25:46 -04:00
rusefi bd2b992918 unifying_file_naming 2019-03-29 09:11:13 -04:00
andreika-git c34d7cac48 More compatibility for ADC_inputs, etc. (#716)
* Move STM32-specific ADC pinouts to ports/stm32/stm32_common.cpp

* Move STM32-specific files to ports/*

* setAdcChannelOverrides()

* Add #ifdefs for adc_inputs (PWM_FREQ_*, PWM_PERIOD_*, ADC_*_DEVICE)

* addChannel(), removeChannel()

* fix tle6240 compilation

* Add stm32_common.cpp to Makefile

* More ports/stm32/* paths

* More ports/stm32/* paths

* More flexible GPIO ports

* Add #ifdef for GPTDEVICE

* EFI_BOARD_TEST and EFI_JOYSTICK

* EFI_TLE8888

* Fix HIP9011_logic compilation

* ADC_CHANNEL_SENSOR

* Move ioportid_t PORTS[] to ports/*

* Fix simulator
2019-03-28 22:46:10 -04:00
rusefi 9547c44ff1
688 brainpins (#694)
* GPIOF, GPIOG and GPIOH ports are not available #688
2019-02-22 22:10:41 -05:00
rusefi bb5775f1aa docs 2019-02-05 19:00:52 -05:00
rusefi e6ac26bf2b better conditional compilation 2019-01-04 00:16:08 -05:00
rusefi 81837cad7d EXTI refactoring 2018-12-18 23:50:29 -05:00
rusefi 28d58c41eb exti clean-up 2018-12-12 18:02:00 -05:00
andreika-git 23fea3c0c5 STM32 Nucleo144-F767ZI board: Initial support (#620)
* More EFI_ #ifdefs for config flexibility

* Even more config flexibility

* New firmware/config/stm32f7ems/* files

* New firmware/config/boards/NUCLEO_F767/* files

* New firmware/hw_layer/stm32f7/* files

* Fix for EFI_USB_SERIAL

* Adding #if defined(STM32F7XX)

* SPI flags changed in F7: SPI_CR1_DFF --> SPI_CR1_CRCL

* I2Cv2 config changed in F7

* More versatile CCM defines

* Makefiles

* Double #ifs cleanup

* docs
2018-11-16 07:40:06 -05:00
rusefi 1f90cf153d refactoring 2018-09-16 22:26:57 -04:00
rusefi 959a91ae4c unique error codes #598 2018-07-25 23:03:04 -04:00
rusefi 1d31067d19 happy new year 2018-01-20 20:55:31 -05:00
rusefi 3a0b7f66c5 better error handling 2017-07-28 14:32:51 -04:00
rusefi f53177f5d7 better error handling 2017-07-28 14:27:37 -04:00
Andrei ef4cb7d3c2 Add || DOXYGEN 2017-05-30 22:46:02 +03:00
Andrei 69d9483291 Add || DOXYGEN 2017-05-30 22:43:33 +03:00