Commit Graph

76 Commits

Author SHA1 Message Date
rusefillc 06f10b48df simulator board name 2023-04-29 06:47:09 -04:00
Andrey 7464275b00 progress: bringing simulator closer to real code
only:hellen-honda-k
2023-03-05 01:50:51 -05:00
Nathan Schulte d144248a6f
fix simulator build (via MinGW) (#4799)
* firmware: kill -9 dead hipLastExecutionCount

* firmware: pin_repository C includes efi_gpio.h

* firmware: controllers: tidy #endif comments

* firmware: primary_pins logic depends EFI_GPIO_HARDWARE

* firmware: only print ADC info if HAL_USE_ADC

* firmware: digital_input: tidy #endif comments

* firmware: digital_input logic depends on e.g. HAL_USE_ADC

* firmware: digital_input logic depends !EFI_SIMULATOR

* firmware: digital_input logic depends e.g. HAL_USE_ADC

* simulator: Makefile includes RUSEFI_LIB_C as CSRC

* Revert "GHA/build-firmware: pin agents to Ubuntu 20.04 (#4793)"

This reverts commit cb2477be6c.
2022-11-18 23:43:43 -05:00
Nathan Schulte 4c197b4745
simulator: use CC and CPPC for LD (#4794)
this allows to specify a different GCC when building
2022-11-18 21:15:13 -05:00
Nathan Schulte 777c683319 simulator: Makefile uses spaces ...
... tabs are reserved for recipes
2022-11-18 10:09:28 -05:00
Matthew Kennedy c3d6bd7e59
Pt2001 module (#4396)
* pt2001 uses module

* read flag0

* c

* libfirmware

* makefiles

* are unit tests happy?

* bootloader
2022-08-08 08:53:08 -04:00
Matthew Kennedy a0d8ae3f4f
use libfirmware for a few things (#4351)
* use libfirmware

* unit tests

* crc

* missed one

* bootloader
2022-07-16 02:22:51 -04:00
Matthew Kennedy a95bc3ad03
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 bc6a87cadc
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
rusefillc f4fe1ce310
Explicit fw (#3968)
* explicit FW ID

* explicit FW ID

Co-authored-by: rusefillc <sdfsdfqsf2334234234>
2022-02-27 00:49:47 -05:00
Matthew Kennedy 736c7f33d9
make the simulator smaller (#3869)
* small sim

* o2 is ok
2022-02-01 16:19:46 -05:00
rusefillc fcdb7b340d mk files refactoring
saving build
2022-01-06 22:19:00 -05:00
rusefillc 04ab6a0488 mk files refactoring 2022-01-06 21:48:48 -05:00
rusefillc a13a0a2cc9 mk files refactoring 2022-01-06 20:32:39 -05:00
rusefillc 7f0357ffcb mk files refactoring 2022-01-06 20:06:31 -05:00
rusefillc 7c0fd37dfe Live Data progress 2022-01-06 19:02:35 -05:00
Matthew Kennedy bb57a4b084
detect more overflows with asan (#3582)
* overflow detector

* type list dynamic allocate

* fix the buffer length

* comment

* pr fb

* sanitize sim

* fix sim sanitizer bug

* didn't mean to turn off optimization for sim

* asan can do that, if you turn it on!

* cleaning
2021-11-20 01:38:39 -05:00
Matthew Kennedy cdd27abb09
turn on c++ 20 (#3579)
* set flags

* emit initializers

* jar
2021-11-19 22:19:34 -05:00
Scott Smith 37da55c920
Compile each project's PCH to a separate file to reduce developer friction. (#3505)
Having to remove the precompiled header when switching from firmware to simulator to unit_tests and
back again is annoying.  Use a directory to store the precompiled header output.  Turn off
precompiled header warnings as GCC still complains even if it finds a valid one eventually.
2021-11-08 15:52:58 -05:00
Andrey 0e6a51e5c0 export board-specific macro for stm32 pins based on board yaml #3298
meta progress
2021-10-26 10:27:10 -04:00
rusefillc 392c91ef69 progress 2021-10-17 18:40:05 -04:00
Matthew Kennedy 3518da97a7
set up precompiled header (#2971)
* ignore

* set up precompiled header

* makefile

* fixes

* cleanup

* only depend cpp on pch

* efifeatures in pch

* f7 efifeatures

* consolidate

* simulator

* proteus build

* error handling is a good one

* bootloader pch

* don't auto include pch

* dirs

* delete on clean

* bootloader cleans

* clean.sh deletes pch

* disable in bl for now

* there was a typo so maybe it'll work now

* remove todo

* don't need that any more

* don't need these parts

* don't need this part

* undo changes

* use a different cpp as example

* s

* Revert "cleanup"

This reverts commit 8de8698490.

* also unnecessary now

* buh

* comment

Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
2021-07-25 21:23:23 -04:00
rusefillc 995ed02ff7 helping build? 2021-07-05 11:36:23 -04:00
Matthew Kennedy 1fd5b4560b
don't debug info (#2798) 2021-06-07 09:17:56 +03:00
Matthew Kennedy f3ff40724a
simulator usability (#2794)
* simulator

* simulator is debuggable

* s

* format
2021-06-04 01:34:49 -04:00
Matthew Kennedy 5cb659a7b0
lua pwm hooks (#2687)
* pwm hook

* dedicated pins

* write hook

* UI

* more info

* zero based, clamp

* memory

* don't compile lua in bootloader at all
2021-05-20 19:01:17 -04:00
Matthew Kennedy 0ea1f15ca3
compile gpiochips as cpp (#2702)
* rename

* core

* structing

* more

* makefile

* structing

* 6240 compiles

* explicit cast instead of implicit narrowing

* 8888

* no extern C

* fix tests build

* extern "C"

* 33810

* 8860

* 33810

* linker

* unbreak master

* don't need that if compiling as C++

* bump config

* fix test

* tests

* unit tests bad merge

* build

* move subaru logic to cpp file

* cpp goodness

* hpp include

* this is probably the right thing to do

* simulator
2021-05-17 08:42:56 +03:00
Andrey G 8ac3de90fd
Hw layer rearrangement (#2705)
* Fix simulator compilation

* HW_SENSORS_SRC -> HW_SENSORS_CPP
2021-05-16 14:11:28 +03:00
Matthew Kennedy 7b33ebfa9c
build (#2399) 2021-02-24 21:55:51 -05:00
Matthew Kennedy b995e7bcaa
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 10c31c2955
-g3 to -g (#2256)
Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
2021-01-31 14:13:55 -05:00
Andrey G 777979c3ca
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
Matthew Kennedy f3b7a1d9da
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
Matthew Kennedy bb8650179c
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
rusefi adcf368cc9 Hellen says simulator 2020-09-07 12:19:17 -04:00
rusefi 8f4aecf7ca The Big Refactoring of 2019: folder structure #723 2020-08-02 20:46:40 -04:00
David Holdeman 15e44ae9cc
Use github actions to build and upload bundles (#1583)
* add env var to skip upload

* remove checking from compile.bat

* working on push.yaml

* finish sorting

* progress

* rename push to builds

* rename push to builds

* Add skip upload env var

* fix pull_request name

* fixed typo and changed name

* fixed indentation and runs-on

* try different env var setup

* add nucleos and switch to underscore

* add quotes

* remove boards that were commented

* remove boards that were commented

* fix project board name

* fixed variable name

* add ini-file and console-settings

* try installing gcc-multilib first

* Install g++-multilib as well

* remove unnecessary export

* fixed exit numbers

* change to different env setup

* add simulator and console compilation to board bundles

* changed OS and added linux simulator build

* add checkout and missing colon

* add gcc-multilib installes

* Install mingw

* fixed install

* remove mingw from linux sim and call compile directly

* change directory

* moved envs to command

* debug ls

* debug ls

* set ftp vars

* add makefile debug info

* removed batchecks

* redirect stdout to easier see orrs

* change name

* remove redirect, add file inpection

* Add conditional project name

* Try software upgrade

* missing char

* update ine files

* try quotes

* add escapes

* add quotes

* add escapes and quotes

* remove quotes and escapes

* remove software upgrade

* ignore test 2

* update apt

* like this then

* forgot import

* fix case

* remove RUSEFI_SKIP_UPLOAD and check RUSEFI_FTP_SERVER instead

* break workflow back apart

* upload simulator artifact

* fixed operator

* update apt

* change paths

* Update build-firmware.yaml

* move update bundle to artifacts

* fix var name

* Install ncftp

* set env vars conditionally

* remove check so zips are created

* try things the github way and copy to primary

* re-enable test

* missing space
2020-07-08 11:10:24 -04:00
rusefi c39d135e94 Makefile clean-up 2020-05-25 13:42:55 -04:00
Matthew Kennedy 94e63e7c43
binary logging (#1443)
* field support

* tests

* makefiles

* test data too

* missing include dir

* write correct thing

* fix one test

* fix test

* omnomnomnom ram

* format

* use defined names

Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
2020-05-17 15:56:37 -04:00
Matthew Kennedy a8f466c615
trigger emulator refactoring (#1358)
* trigger gen refactoring

* missed one

* fix makefile

* commentary

Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
2020-04-24 14:00:06 -04:00
Matthew Kennedy 5fc82e21f8
Move can_hw.cpp in to drivers folder (#1184)
* relocate

* include path

* simulator makefile

* fix mre while we're at it

* it would help if I fixed it right
2020-03-13 09:50:43 -04:00
rusefi 0dd517bcc7 The Big Refactoring of 2019: folder structure #723 2019-12-04 00:22:34 -05:00
rusefi de36f76882 The Big Refactoring of 2019: folder structure #723 2019-12-03 23:52:44 -05:00
rusefi 48db08aaae shared GCC settings between projects 2019-12-02 10:26:16 -05:00
rusEfi 1991437f77 development into unit tests, makefile cleanup 2019-11-19 20:05:12 -05:00
Matthew Kennedy 3bd1ddcc1f Sensors: composition >> inheritance (#953)
* functional sensors

* format

* tests

* sim makefile

* eol

* format tests
2019-09-24 21:11:41 -04:00
rusefi b3d0f63ab3 magic command to facilitate linux build 2019-09-21 17:11:32 -04:00
rusefi 9ad82b03b5 fixing build 2019-09-21 15:33:13 -04:00
rusefi 0384b0488f docs 2019-08-26 21:56:10 -04:00
rusefi 7772dbe3e2 Try ccache #769 2019-04-20 21:57:00 -04:00