Commit Graph

26 Commits

Author SHA1 Message Date
rusefi b83a5310be happy new year 2020-01-08 00:02:40 -05:00
dron0gus 9f0d84f338 Gpio fixes (#1086)
* drivers: gpio: add MC33810 driver (skeleton)

* pin_repository: debug: do not show absent chips
2020-01-07 07:55:50 -05:00
dron0gus 1b42748e60 Spi fixes (#1083)
* spi: add support for SPI4

* mpu_util: spi: add 8BIT mode definitions for F4, F7 and kineris (?)
2020-01-06 08:44:23 -05:00
rusefi af4f20551b getting rid of boardConfiguration / binary compatible change 2019-12-11 17:48:55 -05:00
rusefi 6262a5e84e Hall mode for TLE88888 - VRSConfig1 VRSM #915 2019-09-04 09:24:01 -04:00
rusefi 07cc3cffff Hall mode for TLE88888 - VRSConfig1 VRSM #915 2019-09-04 00:27:19 -04:00
rusefi f393c5e2de low side channels on MRE #900
this kind of makes a bit more sense like this?
2019-08-10 15:53:03 -04:00
rusefi 074c99fab7 low side channels on MRE #900
this should NOT work but it works?

2019-08-10_15_19_19_770: EngineState: injection #1 @ ext:TLE8888.OUT22 led1
2019-08-10_15_19_19_771: EngineState: injection #2 @ PE10 led10
2019-08-10_15_19_19_773: EngineState: injection #3 @ PE12 led5
2019-08-10_15_19_19_774: EngineState: injection #4 @ PE14 led4
2019-08-10_15_19_19_775: EngineState: injection #5 @ ext:TLE8888.OUT24 led7
2019-08-10_15_19_19_775: EngineState: injection #6 @ PE11 led6
2019-08-10_15_19_19_777: EngineState: injection #7 @ PE9 led9
2019-08-10_15_19_19_777: EngineState: injection #8 @ PE8 led8
2019-08-10_15_19_19_779: EngineState: injection #9 @ PE13 led3
2019-08-10_15_19_19_780: EngineState: injection #10 @ ext:TLE8888.OUT23
 led2
2019-08-10 15:23:41 -04:00
rusefi 4ddf0ba5a2 low side channels on MRE #900
getting closer but still issues
2019-08-10 14:53:57 -04:00
rusefi ef79fb15ba low side channels on MRE #900
progress - now all 10 BLINK, but two are blinking together
2019-08-10 13:45:00 -04:00
rusefi 5503de12fb low side channels on MRE #900
progress - at least something is blinking now
2019-08-10 13:25:08 -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
andreika-git b80d95578d EFI_CONSOLE_UART_DEVICE, flash->hw_ports, Fix TLE6240 and misc.fixes (#793)
* rename EFI_CONSOLE_UART_DEVICE -> EFI_CONSOLE_SERIAL_DEVICE

* Impl. EFI_CONSOLE_UART_DEVICE

* Move flash source files to ports/stm32/ & hw_ports.mk

* Fix TLE6240

* Fix EFI_NO_CONFIG_WORKING_COPY

* EFI_PRINT_MESSAGES_TO_TERMINAL
2019-05-05 11:06:27 -04:00
dron0gus e9aed8dd7a Smart gpio error path and minor fixes (#772)
* smart_gpio: fix error path

If chip driver disable in FW, disabled in settings or failed to init
we still need to ocupy its gpio range.

* smart_gpio: get tle6240 CS from config

* smart_gpio: fix debug messaging
2019-04-21 10:35:13 -04:00
rusefi f3a6ce0769 USB and TLE8888 not working for F4 or F767 #764 2019-04-20 23:49:26 -04:00
rusefi f62731cc99 USB and TLE8888 not working for F4 or F767 #764 2019-04-20 23:39:06 -04:00
rusefi f54887320e USB not working for F4 or F767 #764 2019-04-19 06:07:40 -04:00
dron0gus 71cc657f10 Smart gpio fixes 2 (#765)
* gpio chips: relax error checking on _add

Do not halt whole system if wrong or nulled config is passed.
In current smart-gpio implementation this can happen and it is not
as error. Let smart-gpio handle this, kust reurn negative.

* tle8888: return back includes needed for debug

* smar-gpio: -Werror=missing-field-initializers fix
2019-04-19 01:42:24 -04:00
dron0gus ec75c47b73 Smart gpios fixes - now without cleanup of smart_gpio.cpp (#758)
* smart_gpio.cpp: check _add return values

And occupy gpiochip's pin range if disabled of failed. So base will
align with enum.

* TLE8888: cleanup, move high level code to smart_gpio.cpp

* smart_gpio.cpp: fix compilation when BOARD_EXT_GPIOCHIPS == 0

* board-subaru: fix compilation after latest smart_gpio updates

* tle8888: now we have all 28 pins supported
2019-04-16 09:23:24 -04:00
andreika-git ffd44bf0fe More config portability: TLE6240, Trigger_input, UART/Serial (#759)
* Add fields to UART/Serial configs

* trigger_input: can be both HAL_USE_PAL and HAL_USE_COMP

* tle6240 config: local temporary solution

* Fix for custom_engine::setFsio

* EFI_ACTIVE_CONFIGURATION_IN_FLASH
2019-04-15 08:40:12 -04:00
andreika-git 21346c0063 Add more portability to smart_gpio & SPI (#754) 2019-04-14 13:35:30 -04:00
rusEfi f8fec2e2fb thank you Dron_gus fot the idea! 2019-04-13 19:55:18 -04:00
dron0gus 76cc822b1e Smart gpios (#752)
* efi_gpio: update cached pin value for ext gpios to

* tle6240: update and fix

* gpiochips_init should be called after all gpio chips are added

or we can lost calls to _init of chips

* smart_gpio.c: fix for tle6240 and mc33972

now config structs are not const. waste of ram...
2019-04-14 01:32:46 +02:00
rusefi fb0bbc075c steps towards smarter gpio 2019-04-13 12:02:34 -04:00
rusefi 00e848c243 steps towards smarter gpio 2019-04-13 11:22:40 -04:00
rusefi db9456902f steps towards smarter gpio 2019-04-13 10:58:52 -04:00