I have read with interest the work on RAM tuning on the Subarus.
I have an Evo 9, and whilst this is not directly RomRaider related (I have used the software for a Subaru 05 STI - very nice BTW), I thought it would be nice to discuss progress with you guys.
The Evo 7-9 uses SH7052 or 7055 chip.
I am working with others on disassembly. I have already inserted my own code segments to map switch between the existing low and high octane fuel and timing maps in ROM, but like you guys I want to do real time mapping.
The problem is that the Evo MUT protocol we're all using that is high speed compared with OBD II only sends a byte request which is echoed and followed by a byte reply. I need a protocol that can read/write byte/word/long, and then I think locating maps in RAM and modifying them will be possible. Here is what I posted on evolutionm.net that may be of interest. I think you guys are well ahead of me on the Subaru but I think the comms are holding you up too? I'm really interested in your thoughts here or on evolutionm.net.
http://forums.evolutionm.net/showthread.php?t=250922
"Having successfully inserted a jump in to the ECU code and inserted my own routine to change a single RAM variable in response to a requestID, the next step is to consider how to implement real time mapping.
The comms protocol is I suggest the place to start.
We need a method of reading and writing to RAM. To do this we need say:
One byte that is a command such as read or write
Four bytes to give the address (or maybe two if we are always in a 64 kilobyte range)
One, two or four bytes for the result of the read or the value to write
So really we need to send and receive packets. We need three write and three read commands to work on byte, word (2 bytes) or long (4 bytes). We need all of these lengths, because mapped values to change can be either byte or word. Addresses to relocated tables will be long.
A good protocol THAT IS SIMPLE, worked out now will pay dividends later.
This is I think the most difficult part of getting real time mapping going. It is fairly easy I think to relocate tables to other addresses by simply using a vector table in RAM that tells the ECU where to look - either the original ROM or in RAM.
Writing a protocol from scratch would be a pain and buggy! Hijacking something already there would be good. Bez's mods allowed the request ID to write out two bytes, hopefully we can modify it to do up to 8, and also receive up to 8.
I'm fairly happy to write the routines to process these packets I think. I'm using the Lauterbach monitor for assembling snippets, although I have to work out the offsets to read variables manually(!) and I then have to manually transfer the hex into the ROM using a hex editor."