EM1.0 Custom Gauge Info.

 This information is to help you understand how to modify the files directly on the micro SDCard of the Electron(EM1.0). DOWNLOAD and using the Gauge Designer makes it really easy to customize without a need to know all this information. 

Customize your gauges for any vehicle. The EM1.0 is designed to allow you to change and add new gauges for any vehicle OBD II compliant vehicle. The configuration files can be easily edited in word pad or other text editor.

SDCARD:

The "CARS" folder on the micro SDCard.

Each vehicle uses 4 files ending in ".pid",".dtc",".car" and ".bmp". The file names are based on the VIN number. Positions 1,2,3,8 and 10. File names can be from 3 characters (Positions 1,2 and 3) to 5 characters (Positions 1,2,3,8,10). 

File Extensions: 

"car" files contain information on decoding the rest of the VIN (XML Format)

"pid" files are the gauges info. (XML format)

"dtc" files have a list of controllers and how to read and clear there trouble codes(XML Format)

"bmp" files are standard Bitmap Files. (Must be in 16-bit 5-6-5 format)

File Names:

The Electron Tuner searches for the longest names first. The VIN (Vehicle Identification Number) contains all the information about your vehicle. The first three character are the country the vehicle was made in. Who made it and what series of vehicle. The eight character is what engine is in the vehicle and the tenth is what year it was made.

example:

Vehicle:

Ford F-250 2008 with 6.4L Power Stroke turbo diesel.

VIN: 1FDXW46R18EC30554

Shortest file name:

1FD.pid  - This is gauges for all Ford cabin chassis trucks.

1FDR.pid  - This is gauges for Ford cabin chassis 6.4L power strokes.

1FDR8.pid - This is gauges for Ford cabin chassis 6.4L built in 2008.

1FDR.bmp  - 200 x100 bitmap image representing the 6.4L Power Stroke series.

 

 

PID files:

<?xml version="1.0" encoding="UTF-8"?>
<PID>
     <DASH>  What will be displayed on the DASH screen.
          <MPH>  Where to get the MPH or KPH 
               <ECU>PCM</ECU>
               <CODE>0x010d</CODE>
               <UNITS>MPH</UNITS>
               <FORMULA>(A) * 0.62137119223733</FORMULA>
           </MPH>
          <MIL> Where to check for and Engine Code
              <ECU>PCM</ECU>
              <CODE>0x221103</CODE>
              <FORMULA>A &amp; 0x20</FORMULA>
          </MIL>
          <DTC> Where to check How many Engine Codes.
                 <ECU>PCM</ECU>
                 <CODE>0x220200</CODE>
                 <FORMULA>A &amp; 0b01111111</FORMULA>
         </DTC>
         <CRUISE> Where to read the cruise state. (Does not work for all vehicles)
                <ECU>PCM</ECU>
               <CODE>0x22A213</CODE>
               <FORMULA>A</FORMULA>
         </CRUISE>
         <GAUGES>  Gauges down the right side. total of 7 different ones.
               <SLOT1>
                    <NAME>Gauge Name</NAME>
                    <ECU>ECU ADDRESS or NAME e.g. PCM,TCM 0x7e0</ECU>
                    <CODE>PID Code in hex. eg. 0x01c</CODE>
                    <UNITS>Displayed Units</UNITS>
                   <FORMULA>Formula to covert raw gauge data e.g. (A*100)/255</FORMULA>
                   <TYPE>Gauge Type. see List</TYPE>
                   <WARNINGS>Warning level triggers for both high and low see below.</WARNINGS>
                   <LOWWARNING>e.g. 25</LOWWARNING>
                   <LOWDANGER>e.g. 10</LOWDANGER>
             </SLOT1>
             <SLOT2>
                    ...
             </SLOT2>
             <SLOT3>
                   ...
             </SLOT3>
             <SLOT4>
                   ...
             </SLOT4>
             <SLOT5>
                  ...
             </SLOT5>
             <SLOT6>
                  ...
             </SLOT6>
            <SLOT7>
                ...
            </SLOT7>
          </GAUGES>
     </DASH>


     <TAB1>   Different tabs each one can have there own XML objects.
          <NAME>Displayed name on tab</NAME>
          XML OBJECTS here...
     </TAB1>

     <TAB2>
          <NAME>Tab 2</NAME>
          XML OBJECTS here...
     </TAB2>

     <TAB3>
          <NAME>Tab 3</NAME>
          XML OBJECTS here...
     </TAB3>

     <TAB4>
          <NAME>Tab 4</NAME>
          XML OBJECTS here...
     </TAB4>
</PID>
 

 

OBJECTS:


XML:(eXtended Markup Language).

<OBJECT>
        <SETTING>VALUE</SETTING>
        <SETTING>VALUE</SETTING>
</OBJECT>


Object Types:

<GAUGE>
- <ECU> Select Electronic Control Unit to read Gauge info from. Can us "PCM","TCM","ABS" or Raw Address e.g. 0x7E0
- <CODE> PID code for specific gauge info. e.g. 0x010C is RPM on PCM. Can pass 0x01XX for mode 1 or 0x22XXXX for
Extended mode 22 or 0x23XXXXXX to do a direct memory read...
- <NAME> Title of Gauge.
- <FORMULA> Formula for converting raw data. See Below...
(FORMULA can contain an XML string with the tag VALUES and seprate tags for different values and what to display)
- <UNITS> Text to display in the units field of the gauge.
- <TYPE> See Types above...
- <X> X location on the screen. (between 0 - 319) in Pixels.(Remeber to calculate object width)
- <Y> Y location on the screen. (between 0 - 239) in Pixels.(Remeber to calculate object height)
- <WARNINGAUDIO> WAV file to play when gauge hit warning level. (e.g. "0:/snd/warn.wav")
- <ALERTAUDIO> WAV file to play when gauge hit alert level. (e.g. "0:/snd/alert.wav")
- <WARNINGS> Mask Flag for choosing warning and alert on a gauge. See Above...
- <LOWWARNING> bit 4
- <LOWDANGER> bit 8
- <HIGHWARNING> bit 1
- <HIGHDANGER> bit 2
- <DECIMAL> How many numbers after the decimal point to display.(Depends on gauge type).
- <MINVALUE"
- <MAXVALUE"
- <OFFTXT> Text displayed on a Text type gauge when formula equals 0.
- <ONTXT> Text displayed on a Text type gauge when the formula is not 0.


<CLEARSCREEN>
- <VALUE> What color to clear the screen with. RGB format 0x00FF00 is green.

<TOUCHAREA>
- <XMIN> X location from left.
- <YMIN> Y location from top.
- <XMAX> X location from right.
- <YMAX> Y location from bottom.
- <CLICKEVENT> Sub routine index. See Above.
- <STATUS> Area thingy status.sEE above..

<CURRENTSCREEN>
- <VALUE> pass the current screen you have loaded.

<BUTTON>
- <STATUS> Area thingy status.sEE above..
- <X> X location on the screen. (between 0 - 319) in Pixels.(Remeber to calculate object width)
- <Y> Y location on the screen. (between 0 - 239) in Pixels.(Remeber to calculate object height)
- <SIZE> Size Code...


<PICBUTTON>
- <STATUS> Area thingy status.sEE above..
- <X> X location on the screen. (between 0 - 319) in Pixels.(Remeber to calculate object width)
- <Y> Y location on the screen. (between 0 - 239) in Pixels.(Remeber to calculate object height)


<TEXTWRAP>
- <TITLE> Text to display. can pass system variable($variables)...See Above.
- <COLOR> What color to clear the screen with. RGB format 0x00FF00 is green.
- <X> X location on the screen. (between 0 - 319) in Pixels.(Remeber to calculate object width)
- <Y> Y location on the screen. (between 0 - 239) in Pixels.(Remeber to calculate object height)
- <WIDTH> Maxium width of text on the screen.
- <HEIGHT> Maxium height of text on the screen.
- <FONT> See ABOVE...


<TEXTFIXED>
- <TITLE> Text to display. can pass system variable($variables)...See Above.
- <COLOR> What color to clear the screen with. RGB format 0x00FF00 is green.
- <X> X location on the screen. (between 0 - 319) in Pixels.(Remeber to calculate object width)
- <Y> Y location on the screen. (between 0 - 239) in Pixels.(Remeber to calculate object height)
- <FONT> See ABOVE...


<IMAGE>
- <X> X location on the screen. (between 0 - 319) in Pixels.(Remeber to calculate object width)
- <Y> Y location on the screen. (between 0 - 239) in Pixels.(Remeber to calculate object height)
- <INDEX> Index of an image stored in the firmware.
- <FILE> File path for an image on the SDCard. (INDEX must not exist in tags.)



<TEXTCENTER>
- <TITLE> Text to display. can pass system variable($variables)...See Above.
- <COLOR> What color to clear the screen with. RGB format 0x00FF00 is green.
- <Y> Y location on the screen. (between 0 - 239) in Pixels.(Remeber to calculate object height)
- <FONT> See ABOVE...


<VLINE>
- <COLOR> What color to clear the screen with. RGB format 0x00FF00 is green.
- <X> X location on the screen. (between 0 - 319) in Pixels.
- <YMIN> Y location from top.
- <YMAX> Y location from bottom.


<HLINE>
- <COLOR> What color to clear the screen with. RGB format 0x00FF00 is green.
- <Y> Y location on the screen. (between 0 - 239) in Pixels.
- <XMIN> X location from left.
- <XMAX> X location from right.


<RECTFILL>
- <COLOR> What color to clear the screen with. RGB format 0x00FF00 is green.
- <XMIN> X location from left.
- <YMIN> Y location from top.
- <XMAX> X location from right.
- <YMAX> Y location from bottom.

<RECT>
- <COLOR> What color to clear the screen with. RGB format 0x00FF00 is green.
- <XMIN> X location from left.
- <YMIN> Y location from top.
- <XMAX> X location from right.
- <YMAX> Y location from bottom.

<TRIGGER>
- <COUNTDOWN> Count down increments...
- <WARMUP> Warm up after count down. if this is zero the trigger will only happen once.
- <EVENT> Sub routine to run. usually 0.
- <XMLFILE> XML file to process based on sub routine.


<DISPLAYSTATUS> (Not Fully implemented)
- <X> X location on the screen. (between 0 - 319) in Pixels.(Remeber to calculate object width)
- <Y> Y location on the screen. (between 0 - 239) in Pixels.(Remeber to calculate object height)
- <OPTION> System Option to execute...

<MODE> (Not Fully implemented)
- <VALUE> Set a Special mode.

 

Gauge Options:

Type:


0 - Floating Number.
1 - Standard Number Gauge 90x30
2 - Big Number Gauge. 145x50
3 - Standard Text Gauge 90x30
4 - Big Text Gauge 145x50
5 - Bar Gauge 90x30
6 - On/Off Text Gauge 90x30
7 - Bitmap Gauge size of bitmaps
8 - Dial Guage scales...
9 - Graph Gauge


Warnings & Danger:

1 = High Warning
2 = High Danger
4 = Low Warning
8 = Low Danger


1 + 4 =5 (Low & High Warnings only)



Formulas:

XML Data Literals: (Must use these in place of characters in the XML config files.)

AND & = &amp;
QUOTE " = &quot;
Less Than < = &lt;
Greater Than > = &gt;


Raw Data:

A CAN RETURN DATA Byte 1.
B CAN RETURN DATA Byte 2.
C CAN RETURN DATA Byte 3.
D CAN RETURN DATA Byte 4.
E CAN RETURN DATA Byte 5.
F CAN RETURN DATA Byte 6.
G CAN RETURN DATA Byte 7.
H CAN RETURN DATA Byte 8.
I CAN RETURN DATA Byte 9.
J CAN RETURN DATA Byte 10.

Z - Barometer.

 

Supported arithmetical operations:

A+B sum

A-B subtraction

A*B multiplication

A/B dividing

signed(A). A means as signed value - assuming highest bit is a sign bit 

A&256 bitwise comparison

Fonts:

// Cm.. is the
// computer modern font, which is a serif font. ..Cmsc.. is the computer
// modern small-caps font, which is also a serif font. ..Cmss.. is the
// computer modern sans-serif font.


0 = Computer Modern 12
1 = Computer Modern 12 Bold
2 = Computer Modern 12 Italic
3 = Computer Modern 14
4 = Computer Modern 14 Bold
5 = Computer Modern 14 Italic
6 = Computer Modern 16
7 = Computer Modern 16 Bold
8 = Computer Modern 16 Italic
9 = Computer Modern 18
10 = Computer Modern 18 Bold
11 = Computer Modern 18 Italic
12 = Computer Modern 20
13 = Computer Modern 20 Bold
14 = Computer Modern 20 Italic
15 = Computer Modern 22
16 = Computer Modern 22 Bold
17 = Computer Modern 22 Italic
18 = Computer Modern 24
19 = Computer Modern 24 Bold
20 = Computer Modern 24 Italic
21 = Computer Modern 26
22 = Computer Modern 26 Bold
23 = Computer Modern 26 Italic
24 = Computer Modern 28
25 = Computer Modern 28 Bold
26 = Computer Modern 28 Italic
27 = Computer Modern 30
28 = Computer Modern 30 Bold
29 = Computer Modern 30 Italic
30 = Computer Modern 32
31 = Computer Modern 32 Bold
32 = Computer Modern 32 Italic
33 = Computer Modern 34
34 = Computer Modern 34 Bold
35 = Computer Modern 34 Italic
36 = Computer Modern 36
37 = Computer Modern 36 Bold
38 = Computer Modern 36 Italic
39 = Computer Modern 38
40 = Computer Modern 38 Bold
41 = Computer Modern 38 Italic
42 = Computer Modern 40
43 = Computer Modern 40 Bold
44 = Computer Modern 40 Italic
45 = Computer Modern 42
46 = Computer Modern 42 Bold
47 = Computer Modern 42 Italic
48 = Computer Modern 44
49 = Computer Modern 44 Bold
50 = Computer Modern 44 Italic
51 = Computer Modern 46
52 = Computer Modern 46 Bold
53 = Computer Modern 46 Italic
54 = Computer Modern 48
55 = Computer Modern 48 Bold
56 = Computer Modern 48 Italic
57 = Computer Modern small caps 12
58 = Computer Modern small caps 14
59 = Computer Modern small caps 16
60 = Computer Modern small caps 18
61 = Computer Modern small caps 20
62 = Computer Modern small caps 22
63 = Computer Modern small caps 24
64 = Computer Modern small caps 26
65 = Computer Modern small caps 28
66 = Computer Modern small caps 30
67 = Computer Modern small caps 32
68 = Computer Modern small caps 34
69 = Computer Modern small caps 36
70 = Computer Modern small caps 38
71 = Computer Modern small caps 40
72 = Computer Modern small caps 42
73 = Computer Modern small caps 44
74 = Computer Modern small caps 46
75 = Computer Modern small caps 48
76 = Computer Modern san serif 12
77 = Computer Modern san serif 12 Bold
78 = Computer Modern san serif 12 Italic
79 = Computer Modern san serif 14
80 = Computer Modern san serif 14 Bold
81 = Computer Modern san serif 14 Italic
82 = Computer Modern san serif 16
83 = Computer Modern san serif 16 Bold
84 = Computer Modern san serif 16 Italic
85 = Computer Modern san serif 18
86 = Computer Modern san serif 18 Bold
87 = Computer Modern san serif 18 Italic
88 = Computer Modern san serif 20
89 = Computer Modern san serif 20 Bold
90 = Computer Modern san serif 20 Italic
91 = Computer Modern san serif 22
92 = Computer Modern san serif 22 Bold
93 = Computer Modern san serif 22 Italic
94 = Computer Modern san serif 24
95 = Computer Modern san serif 24 Bold
96 = Computer Modern san serif 24 Italic
97 = Computer Modern san serif 26
98 = Computer Modern san serif 26 Bold
99 = Computer Modern san serif 26 Italic
100 = Computer Modern san serif 28
101 = Computer Modern san serif 28 Bold
102 = Computer Modern san serif 28 Italic
103 = Computer Modern san serif 30
104 = Computer Modern san serif 30 Bold
105 = Computer Modern san serif 30 Italic
106 = Computer Modern san serif 32
107 = Computer Modern san serif 32 Bold
108 = Computer Modern san serif 32 Italic
109 = Computer Modern san serif 34
110 = Computer Modern san serif 34 Bold
111 = Computer Modern san serif 34 Italic
112 = Computer Modern san serif 36
113 = Computer Modern san serif 36 Bold
114 = Computer Modern san serif 36 Italic
115 = Computer Modern san serif 38
116 = Computer Modern san serif 38 Bold
117 = Computer Modern san serif 38 Italic
118 = Computer Modern san serif 40
119 = Computer Modern san serif 40 Bold
120 = Computer Modern san serif 40 Italic
121 = Computer Modern san serif 42
122 = Computer Modern san serif 42 Bold
123 = Computer Modern san serif 42 Italic
124 = Computer Modern san serif 44
125 = Computer Modern san serif 44 Bold
126 = Computer Modern san serif 44 Italic
127 = Computer Modern san serif 46
129 = Computer Modern san serif 46 Bold
130 = Computer Modern san serif 46 Italic
131 = Computer Modern san serif 48
132 = Computer Modern san serif 48 Bold
133 = Computer Modern san serif 48 Italic
134 = Computer Modern Typewriter 12
135 = Computer Modern Typewriter 14
136 = Computer Modern Typewriter 16
137 = Computer Modern Typewriter 18
138 = Computer Modern Typewriter 20
139 = Computer Modern Typewriter 22
140 = Computer Modern Typewriter 24
141 = Computer Modern Typewriter 26
142 = Computer Modern Typewriter 28
143 = Computer Modern Typewriter 30
144 = Computer Modern Typewriter 32
145 = Computer Modern Typewriter 34
146 = Computer Modern Typewriter 36
147 = Computer Modern Typewriter 38
148 = Computer Modern Typewriter 40
149 = Computer Modern Typewriter 42
150 = Computer Modern Typewriter 44
151 = Computer Modern Typewriter 46
152 = Computer Modern Typewriter 48
154 = Fixed6x8

 BITMAPS (Images):

All images must be stored in a 16 bit 5-6-5 format. Not all program support that format.