RomRaider Logo

RomRaider

Open Source ECU Tools
 FAQ •  Register •  Login 

RomRaider

Documentation

Community

Developers

It is currently Thu Dec 25, 2025 6:55 am

All times are UTC - 5 hours [ DST ]





Post new topic Reply to topic  [ 30 posts ]  Go to page 1, 2  Next
Author Message
 Post subject: How to create xml document for ms43
PostPosted: Fri Feb 19, 2016 10:35 am 
Offline
Experienced

Joined: Thu Dec 04, 2014 6:37 pm
Posts: 139
Ok we're starting to make some really good progress with ms43, however I also play with ms41 stuff which has made me fall in love with romraider. I would really like to move over our XDF stuff over to xml. We have some pretty good minds both on ms43 and ms41 which a lot of the time the information could be shared across both ecus. Where can I find info on how to build the xml file? Fortunately most of us use only one file version, ms430056, so that should help. Unfortunately ms43 seems to have A LOT more maps and things to move over. Any help in this area would be greatly appreciated


Top
 Profile  
 
 Post subject: Re: How to create xml document for ms43
PostPosted: Fri Feb 19, 2016 5:10 pm 
Offline
RomRaider Developer

Joined: Wed May 20, 2009 9:49 pm
Posts: 7314
Location: Canada eh!
There's really no docs since it's written in XML and that's somewhat self documenting.
The general layout is a BASE section with defaults (excluding the address) for all the maps/tables/values/static data you want to define with the appropriate data conversions (you can have multiple scaling conversions for different measurement systems).
Then you create ECU ID specific sections which inherit the BASE and you define only the tables and the attributes you wish to change from default. It is here that you add the ROM specific address for the table data and axis(es) values.
Have a look at the MS41 def: viewtopic.php?t=10695
If you use an XML editor you can collapse/expanded sections and perform validation on syntax as you go. Notpead++ with the XML Tools plug-in is quite handy.

If you have specific questions on elements and attributes then just post up the question.
Here's the parser in RR code with all the supported elements and attribute names.

Also: viewtopic.php?t=11906


Top
 Profile  
 
 Post subject: Re: How to create xml document for ms43
PostPosted: Sat Feb 20, 2016 1:27 pm 
Offline
Experienced

Joined: Thu Dec 04, 2014 6:37 pm
Posts: 139
Thank you! I'm sure I'm going to have some questions the more I get into it but this should be a good start


Top
 Profile  
 
 Post subject: Re: How to create xml document for ms43
PostPosted: Mon Feb 22, 2016 10:17 am 
Offline
RomRaider Developer

Joined: Wed May 20, 2009 9:49 pm
Posts: 7314
Location: Canada eh!
This might get you started...
Attachment:
MS43 ECU Definitions v0.xml


You do not have the required permissions to view the files attached to this post.


Top
 Profile  
 
 Post subject: Re: How to create xml document for ms43
PostPosted: Mon Feb 22, 2016 1:22 pm 
Offline
Experienced

Joined: Thu Dec 04, 2014 6:37 pm
Posts: 139
thank you! its starting to look a bit simpler to me now.


Top
 Profile  
 
 Post subject: Re: How to create xml document for ms43
PostPosted: Mon Feb 22, 2016 5:14 pm 
Offline
Experienced

Joined: Thu Dec 04, 2014 6:37 pm
Posts: 139
well I added the ignition table :) this is going to be very time consuming lol


You do not have the required permissions to view the files attached to this post.


Top
 Profile  
 
 Post subject: Re: How to create xml document for ms43
PostPosted: Mon Feb 22, 2016 11:13 pm 
Offline
RomRaider Developer

Joined: Wed May 20, 2009 9:49 pm
Posts: 7314
Location: Canada eh!
I suggest that you follow the proper XML encoding convention and use ° for degrees rather than °. This has been known to cause problems at times.

I had it in my head last year that I was going to write a converter to take the A2L file and make a RR ECU Editor def. That and many other things are on the back burner for now.


Top
 Profile  
 
 Post subject: Re: How to create xml document for ms43
PostPosted: Tue Feb 23, 2016 1:34 am 
Offline
Experienced

Joined: Thu Dec 04, 2014 6:37 pm
Posts: 139
dschultz wrote:
I suggest that you follow the proper XML encoding convention and use ° for degrees rather than °. This has been known to cause problems at times.

I had it in my head last year that I was going to write a converter to take the A2L file and make a RR ECU Editor def. That and many other things are on the back burner for now.


hmm, I think that was something you did in the original one you posted. I tried &deg but it just labeled it as "&deg". how to you set it properly? also I tried setting up a switch to switch between 1024kg and 2048kg limit, but it doesn't seem to work. the address that need to be changed are 0x3D8A2 and 0x3D8C6


Top
 Profile  
 
 Post subject: Re: How to create xml document for ms43
PostPosted: Tue Feb 23, 2016 10:17 am 
Offline
RomRaider Developer

Joined: Wed May 20, 2009 9:49 pm
Posts: 7314
Location: Canada eh!
The original def uses the correct encoding for the degree symbol as in:
Code:
units="°C"


For a switch definition you can have one of more switch states, but only one state can be selected at any given time. For example from the CarBerry def with 13 options:
Code:
  <table type="Switch" name="Anti-Lag - Input Control" category="CarBerry - Anti-Lag" sizey="6">
   <description>This designates the input that controls Anti-Lag.</description>
   <state name="Anti-Lag Always Enabled - Must Enable Anti-Lag in Table Above." data="27 4C 27 4C 27 4C" />
   <state name="Anti-Lag with Defogger Switch(ECU pin A3)" data="2B 10 08 94 00 4C" />
   <state name="Anti-Lag with Headlight switch(ECU pin A17)" data="2B 02 08 94 00 4C" />
   <state name="Anti-Lag with TID switch(ECU pin E1) - Be sure Auto-Trans Logic is Disabled under Miscellaneous" data="2B 08 08 96 00 4C" />
   <state name="Anti-Lag with Intercooler Auto-Wash Switch(ECU pin B12) - Requires Compatible ECU" data="2A 20 08 9B 00 4C" />
   <state name="Anti-Lag with A/C Switch(ECU pin A2, cannot use stock A/C button)" data="2B 08 08 94 00 4C" />
   <state name="Anti-Lag with Blower Switch(ECU pin A9)" data="2B 04 08 94 00 4C" />
   <state name="Inverted - Anti-Lag with Defogger Switch(ECU pin A3)" data="2A 10 08 94 00 4C" />
   <state name="Inverted - Anti-Lag with Headlight switch(ECU pin A17)" data="2A 02 08 94 00 4C" />
   <state name="Inverted - Anti-Lag with TID switch(ECU pin E1) - Be sure Auto-Trans Logic is Disabled under Miscellaneous" data="2A 08 08 96 00 4C" />
   <state name="Inverted - Anti-Lag with Intercooler Auto-Wash Switch(ECU pin B12) - Requires Compatible ECU" data="2B 20 08 9B 00 4C" />
   <state name="Inverted - Anti-Lag with A/C Switch(ECU pin A2, cannot use stock A/C button)" data="2A 08 08 94 00 4C" />
   <state name="Inverted - Anti-Lag with Blower Switch(ECU pin A9)" data="2A 04 08 94 00 4C" />
  </table>

The address is later defined in the ROM specifc section as:
Code:
  <table name="Anti-Lag - Input Control" storageaddress="0xAF34" />


So your MAF limit switch has only two states but you need to set it at two different addresses.
Code:
  <table type="Switch" name="MAF Threshold 1" category="Miscellaneous Thresholds" sizey="4">
   <description>This changes the limit of the MAF.</description>
   <state name="1024kg (turtle mode)" data="27 4C 27 4C" />
   <state name="2048kg (hare mode)" data="2B 10 08 94" />
  <table type="Switch" name="MAF Threshold 2" category="Miscellaneous Thresholds" sizey="4">
   <description>This changes the limit of the MAF.</description>
   <state name="1024kg (turtle mode)" data="27 4C 27 4C" />
   <state name="2048kg (hare mode)" data="2B 10 08 94" />
I used some arbitrary data, set as you require then set the 'sizey' attribute to the correct length of the data.

Then in your ROM specific def section just add the addresses to change:
Code:
  <table name="MAF Threshold 1" storageaddress="0x3D8A2" />
  <table name="MAF Threshold 2" storageaddress="0x3D8C6" />


Top
 Profile  
 
 Post subject: Re: How to create xml document for ms43
PostPosted: Tue Feb 23, 2016 11:35 am 
Offline
Experienced

Joined: Thu Dec 04, 2014 6:37 pm
Posts: 139
dschultz wrote:
The original def uses the correct encoding for the degree symbol as in:
Code:
units="&deg;C"




thank you for your help! I was able to get the switches set up correctly, however I still seem to be having trouble with this deg thing. It still shows up in romraider as &deg;C what am I doing wrong?


You do not have the required permissions to view the files attached to this post.


Top
 Profile  
 
 Post subject: Re: How to create xml document for ms43
PostPosted: Tue Feb 23, 2016 11:43 pm 
Offline
RomRaider Developer

Joined: Wed May 20, 2009 9:49 pm
Posts: 7314
Location: Canada eh!
I'm not sure. Either seems to work on my computer.
The only difference I see is the case of the very first line:
<?xml version="1.0" encoding="UTF-8"?>
Yours shows: utf-8 (lowercase)


When you get a chance can you fix the scaling of the 'ECT Sensor Scaling' table?
The Imperial conversion should be:
Code:
<scaling name="Imperial" units="&deg;F" expression="(x*.75-48)*1.8+32" to_byte="((x-32)/1.8+48)/.75" format="0.0" fineincrement="2" coarseincrement="10" />


Top
 Profile  
 
 Post subject: Re: How to create xml document for ms43
PostPosted: Wed Feb 24, 2016 12:37 pm 
Offline
Experienced

Joined: Thu Dec 04, 2014 6:37 pm
Posts: 139
I'm not sure if it's the xml editor I'm
Using but it won't save it in capital, always reverts back to lower case.

Fixed the scaling and was also able to figure out a way to have only one switch for the maf threshold


Top
 Profile  
 
 Post subject: Re: How to create xml document for ms43
PostPosted: Wed Feb 24, 2016 8:17 pm 
Offline
Experienced

Joined: Thu Dec 04, 2014 6:37 pm
Posts: 139
Ive notice some xml tables on ms41 have "logparam" with location P2 (for coolant temp as example) is this what allows the logger to display the trace function?


Top
 Profile  
 
 Post subject: Re: How to create xml document for ms43
PostPosted: Thu Feb 25, 2016 12:11 am 
Offline
RomRaider Developer

Joined: Wed May 20, 2009 9:49 pm
Posts: 7314
Location: Canada eh!
Yes, you need to match the logging parameter number to the axis or data and then update or add the attribute for tracing.

Use a different XML editor as it is not encoding correctly.


Top
 Profile  
 
 Post subject: Re: How to create xml document for ms43
PostPosted: Thu Feb 25, 2016 7:43 am 
Alex is coming along well with this.

I added the following to his ECU definition and now the knock learning view shows but the x and y axes are wrong. The data is correct as I wrote some values to the RAM knock table to be sure. The axes show correctly when browsing the ROM.

This in the base MS43 definition copied from MS41:

Code:
<table type="2D" name="Knock Tables X Axis (Load)" category="Knock" storagetype="uint8" sizey="4" endian="little" userlevel="1" >
<scaling units="mg/stroke" expression="x*5.45" to_byte="x/5.45" format="#" fineincrement="5" coarseincrement="50" />
<table type="Static Y Axis" name="Columns" sizey="4">
<data> 1</data>
<data> 2</data>
<data> 3</data>
<data> 4</data>
</table>
<description>This axis is used in all of the Knock Adaptation tables. Changes to this will require immediate reloading of the tuned file.</description>
</table>
<table type="2D" name="Knock Tables Y Axis (Engine Speed)" category="Knock" storagetype="uint8" sizey="16" endian="little" userlevel="1" >
<scaling units="RPM" expression="x*32" to_byte="x/32" format="#" fineincrement="30" coarseincrement="300" />
<table type="Static Y Axis" name="Rows" sizey="16">
<data> 1</data>
<data> 2</data>
<data> 3</data>
<data> 4</data>
<data> 5</data>
<data> 6</data>
<data> 7</data>
<data> 8</data>
<data> 9</data>
<data> 10</data>
<data> 11</data>
<data> 12</data>
<data> 13</data>
<data> 14</data>
<data> 15</data>
<data> 16</data>
</table>
<description>This axis is used in all of the Knock Adaptation tables. Changes to this will require immediate reloading of the tuned file.</description>
</table>


This in the individual ECU definition:

Code:
<table name="Knock Tables X Axis (Load)" storageaddress="0x74095" />
<table name="Knock Tables Y Axis (Engine Speed)" storageaddress="0x7400C" />


You do not have the required permissions to view the files attached to this post.


Top
  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 30 posts ]  Go to page 1, 2  Next

All times are UTC - 5 hours [ DST ]


Who is online

Users browsing this forum: No registered users and 0 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
Style based on FI Subsilver by phpBBservice.nl