cancel
Showing results for 
Search instead for 
Did you mean: 

STM32F407VET6 for emulating flash memory in ECU

Martyn2864
Associate

Hello 

I have Engine Control Unit (Siemens MS43) with Flash memory AM29F400BB and i want to remove this flash memory from PCB and connect STM32F407VET6 on its place simulate as flash memory and be able to change or adjust .bin file in "Real time" without turning off ECU. But i have some question about it.

Is this doable ? Is STM32F407VET6 good enough for something like this ? 

Do i need something else with STM32 or it can do work like this on its own ? 

Iam in learning proecces of this, sorry if it sounds dumb.. 

6 REPLIES 6
mƎALLEm
ST Employee

Hello @Martyn2864 and welcome to the ST community,

Why are you complicating your life by going on this direction? why you wouldn't simply find a replacement of AM29F400? Moreover STM32F407 is not an automotive grade MCU

Suppose the emulation is doable, this will be a very complex task and especially to adapt the original memory timings...

Good luck with that.

To give better visibility on the answered topics, please click on "Accept as Solution" on the reply which solved your issue or answered your question.
Martyn2864
Associate

If i replace this AM29F400BB for better or newer style Flash memory would this allow me to change values in binary in real time without turning off/on whole ECU ?

That depends on the characteristics of the ECU and how it works.

But AM29F400BB is a Flash memory that you could change its content on the fly (by respecting its spec) why are you supposing to power cycle the ECU to change its content? 

mALLEm_0-1744214506446.png

 

To give better visibility on the answered topics, please click on "Accept as Solution" on the reply which solved your issue or answered your question.
Martyn2864
Associate

Iam trying to make something similar to this 

https://www.ms4x.net/index.php?title=CobraRTP_Flash_Online

Your ECU will likely have code and data in the FLASH and I expect that you just want to munge the data to adjust fueling and timing tables.

There's a few issues with replacing the FLASH chip with a processor; first, if the ECU's processor is executing code from the FLASH while you're adjusting the tables and since you have no idea when the processor is doing this, you're going to have bus contention, likely a processor crash or two. Next, older processors ran on 5V power and your '407 is 3.3V, you'll have to figure that out. And emulating a FLASH chip in real time is non-trivial. From the time that the select line goes low, you've got to put the data on the bus in half a clock cycle. That's a pretty agressive ask for someone who is just learning.

An alternative way to do this is to use a dual-ported RAM. The ECU processor would use one port and your '407 would use the other port. You still have to figure out the voltage issue and you have to transfer the content of the FLASH into RAM before the ECU processor booted, and you have to find this obsolete RAM.

I think it might be cheaper/faster/more satisfying to just buy a Haltech. Remember, if you don't get the read/modify/write sequence just right, and you mess up the injection table, you are just as likely to make the engine run lean and melt a piston. Do you want to play with engines or electronics? 

I changed the 407VET6 for NUCLEO F767ZI , i think its better equiped and overall will be better choise for something like this. Power diffrences i was hoping some level shifter/converters would do the work (etc. Data lines - TXS0108E Adresse Lines - 74LVC245 , Controls - 74LVC244) or it's not possible in this case ? 

Well ofc i dont want to hurt the engine or melt the pistons. It was never my plan to put it right away in to the car.. I want to test it multiple times in different conditions on the Bench before i try my first test in the car.