micro rusEFI and MAX31855 SPI
-
- Posts: 22
- Joined: Fri Jul 03, 2020 2:41 pm
- Location: Berlin Germany
micro rusEFI and MAX31855 SPI
Hi from Berlin.
I am trying to get the SPI3 running on microrusEFI.
Is it correct that I need custom firmware to activate the SPI3?
I want to use PB9 PC10 and PC11 on J4.
Thanks
I am trying to get the SPI3 running on microrusEFI.
Is it correct that I need custom firmware to activate the SPI3?
I want to use PB9 PC10 and PC11 on J4.
Thanks
-
- contributor
- Posts: 441
- Joined: Mon Mar 04, 2019 10:19 pm
- Location: Slovakia
Re: micro rusEFI and MAX31855 SPI
Look at this... https://rusefi.com/forum/viewtopic.php?f=4&t=2215&start=30
..(netreba vymyslat teplu vodu ..
) ..
..(netreba vymyslat teplu vodu ..

.. some Proteus and microRusEFI for sale in Europe ..
- AndreyB
- Site Admin
- Posts: 14727
- Joined: Wed Aug 28, 2013 1:28 am
- Location: Jersey City
- Github Username: rusefillc
- Slack: Andrey B
Re: micro rusEFI and MAX31855 SPI
Maybe better question why is SPI3 not available on microrusEFI in the first place. Is that some sort of DMA conflict?
More or less https://en.wikipedia.org/wiki/XY_problem blah blah blah
Very limited telepathic abilities - please post logs & tunes where appropriate - http://rusefi.com/s/questions
Always looking for C/C++/Java/PHP developers! Please help us see https://rusefi.com/s/howtocontribute
Always looking for C/C++/Java/PHP developers! Please help us see https://rusefi.com/s/howtocontribute
-
- Posts: 22
- Joined: Fri Jul 03, 2020 2:41 pm
- Location: Berlin Germany
Re: micro rusEFI and MAX31855 SPI
Hi. I do not know why it would be dissabled
in the board_configuration.cpp the SPI3 is not enabled in setBoardConfigOverrides()
I want to change that to
I am trying to compile the new code but it interrupts with errors.
Is this the correct way?
in the board_configuration.cpp the SPI3 is not enabled in setBoardConfigOverrides()
Code: Select all
void setBoardConfigOverrides() {
// SPI3 for expansion header
// Don't override enable since you might want these pins for something else
engineConfiguration->spi3mosiPin = Gpio::C12;
engineConfiguration->spi3misoPin = Gpio::C11;
engineConfiguration->spi3sckPin = Gpio::C10;
}
Code: Select all
void setBoardConfigOverrides() {
// SPI3 for expansion header
// Don't override enable since you might want these pins for something else
engineConfiguration->is_enabled_spi_3 = true;
//engineConfiguration->spi3mosiPin = Gpio::C12;
engineConfiguration->spi3misoPin = Gpio::C11;
engineConfiguration->spi3sckPin = Gpio::C10;
}
Is this the correct way?
-
- Posts: 22
- Joined: Fri Jul 03, 2020 2:41 pm
- Location: Berlin Germany
Re: micro rusEFI and MAX31855 SPI
Nobody who can point me into the right direction?
Is this problem so hard to solve? Are my simple questions so hard to answer?
Seams rusEFI user support is the biggest drawback compared to other ECUs.
Consoering the overal plan for our project.
Integrate BME280
Integrate Mazda incylinder pressure transducer
traction controll
and many more.
I am fearing this forum cannot support us with the support we need.
I am trying to install the toolchain to compile my own firmware but I still do not know if this is the correct way to use a simple chip like the MAX31855
Is this problem so hard to solve? Are my simple questions so hard to answer?
Seams rusEFI user support is the biggest drawback compared to other ECUs.
Consoering the overal plan for our project.
Integrate BME280
Integrate Mazda incylinder pressure transducer
traction controll
and many more.
I am fearing this forum cannot support us with the support we need.
I am trying to install the toolchain to compile my own firmware but I still do not know if this is the correct way to use a simple chip like the MAX31855
-
- Posts: 22
- Joined: Fri Jul 03, 2020 2:41 pm
- Location: Berlin Germany
Re: micro rusEFI and MAX31855 SPI
Hi found this in the board.mk of the microrusEFI.
We have MRE 0.6.0 so we should be able to use SPI3 on J4. SPI2 is handling the SD Card. Am I correct?
We have MRE 0.6.0 so we should be able to use SPI3 on J4. SPI2 is handling the SD Card. Am I correct?
Code: Select all
# Combine the related files for a specific platform and MCU.
# *TEMPORARY* breaking TTL thus breaking Bluetooth for microRusEFI in order to enable SPI3 for SD card
# *TODO* need to give people the horrible choice between Bluetooth via TTL or SD card via SPI :( horrible choice
# PB10/PB11 uses UART3 peripheral and J12/J13 on MRE
# we also have PC10/PC11 exposed on J4 but that's same UART3
DDEFS += -DEFI_CONSOLE_TX_BRAIN_PIN=Gpio::B10 -DEFI_CONSOLE_RX_BRAIN_PIN=Gpio::B11
# on[b] MRE 0.6.0[/b] we have SD card on SPI2 which shared channel 3 with USART3
# todo: enable serial which would not DMA thus not conflict?
DDEFS += -DSTM32_UART_USE_USART3=FALSE -DHAL_USE_UART=FALSE
DDEFS += -DEFI_USE_UART_DMA=FALSE
-
- contributor
- Posts: 441
- Joined: Mon Mar 04, 2019 10:19 pm
- Location: Slovakia
Re: micro rusEFI and MAX31855 SPI
So ...
try simple thing...
Enable SPI3 interface on TunerStudio ... (try to look at my Online tune ..)
..it can be enabled .. I think ..
My MRE and addon board has SD card slot and EGT chip wired to SPI3 interface..
..and it works ...
..so I have old firmware, on my very first MRE, build by myself .. few years ago ..
try simple thing...
Enable SPI3 interface on TunerStudio ... (try to look at my Online tune ..)
..it can be enabled .. I think ..
My MRE and addon board has SD card slot and EGT chip wired to SPI3 interface..
..and it works ...
..so I have old firmware, on my very first MRE, build by myself .. few years ago ..
.. some Proteus and microRusEFI for sale in Europe ..
-
- Posts: 22
- Joined: Fri Jul 03, 2020 2:41 pm
- Location: Berlin Germany
Re: micro rusEFI and MAX31855 SPI
Hi JRD
Thanks for the reply. I have edited the tunerstudio mainController.ini file and enabled SPI3 setings in full pinout 1/3
However SPI3 is not enabled in microrusEFI?!?! (Still a question) I think.
in board_configuration for microrusefi in .\rusefi-SR1\firmware\config\boards\microrusefi
the SPI3 is not specifically enabled, as far as I see. SPI1 and 2 are though.
engineConfiguration->is_enabled_spi_1 = true;
engineConfiguration->is_enabled_spi_2 = true;
is present
engineConfiguration->is_enabled_spi_3 = true; not.
Is this correct?
It is also not found in any other files that will be compiled for the latest firmware. So I assume I have to enable spi3 and compile a custom firmware correct?
Thanks for the reply. I have edited the tunerstudio mainController.ini file and enabled SPI3 setings in full pinout 1/3
Code: Select all
dialog = spiBus3, "SPI3 settings"
field = "Enable", is_enabled_spi_3
in board_configuration for microrusefi in .\rusefi-SR1\firmware\config\boards\microrusefi
the SPI3 is not specifically enabled, as far as I see. SPI1 and 2 are though.
engineConfiguration->is_enabled_spi_1 = true;
engineConfiguration->is_enabled_spi_2 = true;
is present
engineConfiguration->is_enabled_spi_3 = true; not.
Is this correct?
It is also not found in any other files that will be compiled for the latest firmware. So I assume I have to enable spi3 and compile a custom firmware correct?
You do not have the required permissions to view the files attached to this post.
-
- contributor
- Posts: 441
- Joined: Mon Mar 04, 2019 10:19 pm
- Location: Slovakia
Re: micro rusEFI and MAX31855 SPI
So ..
I have stock firmware..
do not edit inifile... it is not right way to configure MRE..
use stock ini file, create project in TS ...
and then go to Controler > SPI > and set SPI3 enable to true
I have stock firmware..
do not edit inifile... it is not right way to configure MRE..
use stock ini file, create project in TS ...
and then go to Controler > SPI > and set SPI3 enable to true
You do not have the required permissions to view the files attached to this post.
.. some Proteus and microRusEFI for sale in Europe ..
-
- Posts: 22
- Joined: Fri Jul 03, 2020 2:41 pm
- Location: Berlin Germany
Re: micro rusEFI and MAX31855 SPI
Hi. There is no option SPI3 if I use the standard ini.
It looks like this: If i try to configure SPI4 to 6 it always tells me that my board is equipped with it. SPI1 talkes to t8888 and SPI2 to the SD card. So I have to use SPI3.
It looks like this: If i try to configure SPI4 to 6 it always tells me that my board is equipped with it. SPI1 talkes to t8888 and SPI2 to the SD card. So I have to use SPI3.
You do not have the required permissions to view the files attached to this post.
-
- Posts: 22
- Joined: Fri Jul 03, 2020 2:41 pm
- Location: Berlin Germany
Re: micro rusEFI and MAX31855 SPI
I was able to get the toolchain running on a Ubuntu vm.
I flashed a custom rusefi.bin using the MRE updater.
However now I cannot upload any more firmware because the update program thinks the connected board is not the MRE.
I screwed up with the board definition.
Is there a work around or do I have to write the chip directly no with a link programmer?
I flashed a custom rusefi.bin using the MRE updater.
However now I cannot upload any more firmware because the update program thinks the connected board is not the MRE.
I screwed up with the board definition.
Is there a work around or do I have to write the chip directly no with a link programmer?
You do not have the required permissions to view the files attached to this post.
- AndreyB
- Site Admin
- Posts: 14727
- Joined: Wed Aug 28, 2013 1:28 am
- Location: Jersey City
- Github Username: rusefillc
- Slack: Andrey B
Re: micro rusEFI and MAX31855 SPI
https://github.com/rusefi/rusefi/wiki/rusEFI-Quick-Start-PDF#i-has-a-question
https://github.com/rusefi/rusefi/wiki/Support#q-what-is-discord
https://github.com/rusefi/rusefi/wiki/Support#q-what-is-discord
Very limited telepathic abilities - please post logs & tunes where appropriate - http://rusefi.com/s/questions
Always looking for C/C++/Java/PHP developers! Please help us see https://rusefi.com/s/howtocontribute
Always looking for C/C++/Java/PHP developers! Please help us see https://rusefi.com/s/howtocontribute