Sitruunapatonki.fi http://www.sitruunapatonki.fi/forum/ |
|
Xantia trip computer ... http://www.sitruunapatonki.fi/forum/viewtopic.php?f=17&t=18396 |
Sivu 1/1 |
Kirjoittaja: | longgo [ 16.06.2014 21:27 ] |
Viestin otsikko: | Xantia trip computer ... |
Hi folks, Probably if someone of you visit the UK forum dedicated to French cars saw my topic there, but if you did not here is what i talk about. As you know PEUGEOT add trip computers in their cars but in ours.. ![]() There are a lot of topics in Internet how to add from XM or Peugeot in Xantia but i decide to try something else, something that i do not understand well ![]() I bought arduino boards and few atmel chips that i can program via the boards, few parts and.. the project start. I can`t promise how it will work in other car, because mine is XU7JP4 1.8 16V engine , but i presume won`t be problem with few mods in the code. Parts - all i bought from ebay as arduino and that NOKIA LCD what come ready for arduino use. Unfortunately that LCD screens come with any strange led back light but green, so there was need for modification there also. Old/ original one light: ![]() New moded one: ![]() ![]() So the electrical charts are: Trip computer: ![]() Dynamic back light ![]() Video: http://www.youtube.com/watch?v=povKbB1ur80&feature=player_embedded So, What was that Dynamic Back light idea - There are cars or dashes which change their back light on RPM department, so because the Xantia dash have green foil on top the colors play is limited.. or almost.. none ![]() With few "test runs" i found that what you see on the video is the maximum. I mean, in normal bulb(which is yellow by natural light) socket i soldier RGB LED 5050(again from ebay). Then i put the controller default state to be Green + Red colors together which give yellow and together with the green dash make same light as the rest of the board. Well you need to know that you loose the light intensity adjustment on that LED bulbs.. Probably if you use PWM function will be possible to combine something but i decide to use simple chip to safe space and it .. work actually Work - The RGB bacl light take signal form the wire going to the plug in the dash. I was almost sure is straight signal from Hall sensor on the crank but.. not. It comes from the ECU and is really strange signal. Also it is double. What i mean, if you take multimeter/freq. reader - you will see 29Hz at idle , which is 870rpm and should be 14.5Hz signal. That doesn`t matter so much for the chip work. Next step was only to divide the interval "from... to.." to determine what light to be on and off or combination. 2000-3000Green,3000-4000 yellow and so on.. You get the idea. The Trip computer currently shows only inside temperature,based on thermistor what i add close to the original for the A/C control, car voltage, temporary consumption and how many kilometers or hours(at stop and idle) you can do with current tank fuel level(dynamic calculated), speed(taken from VSS sensor), and as last 0-50, 0-100 km/h automatic timer. That last one is for fun only ![]() How actually work - i need to know only the RPM and injector time to calculate the fuel. For my car, engine 1.8 16V XU7JP4 injectors make 181ml/min , that taken from bosch catalogue (XLS file from internet) or 181ml/min what make > 181/60 -> 3.01666666 -> 3.012ml/sec -> /1000 -> 0.003012ml/ms -> if pulse is 2.1ms for example, then -> 0.003012*2.1 -> 0.0063252ml/pulse. My car`s engine is 2x2 groups injections -> or inject every engine rotation , then again example: 900rpm are 900 turns per minute -> /60 -> 15 rotation per second or 15 injections per second per injector group or 15 * 2.1ms -> 31.5ms injector time -> *0.003012ml/ms -> 0.094878 ml * 4 cylinders -> 0.379512 *3600 -> 1366.24 ml/h -> /1000 -> 1.366 l/h. In every moment - idle,fast run, slow run engine take l/h. If you take it in relation with speed you`ve get l/100 All variables that change at my engine are rpm and injector pulse length. Injector size and pressure not change (i hope ![]() Example - In my case: 14.6hz(850rpm) - 105hz(6300rpm) and injector pulses 1.2ms - 8.5ms(about) , depending load , ecu setup and so on or (0.003012ml/ms) * 4 (injectors work) in 1Hour * 3600sec in 1H / 1000(1000ml =1L) => 0.0433728 -> 0.0434(that is my constant) * Hz(varies) * inject pulse(varies) => return car consumption as L/H , then based on VSS signal(return calculation as KM/H) have L/100 What about VSS speed - my car`s original tires are 185/65/15 -> (185*0.65)*2 + 15*25.4 -> diameter : 621.5mm -> 0.6215m * 3.1416 -> or 1.9525m for 1 rotation. VSS sensor is based on teeth wheels with size - 22(shaft gear) : 18(sensor gear) or > 1.222 : 1 gear ratio. It make 8 pulses for 1 self rotation so > 1.9525m / 1.222:1 > 1.5975m for 1 sensor rotation or 1.5975m / 8 pulses > 0.19969m for 1 pulse or if we round - 0.2m/per pulse. I found manuals that mention 5000pulses for 1km of distance and then that 0.2m/pp make sense..i guess ![]() If get 1 pulse/second(1Hz signal) > 0.19969m *3.6 -> 0.7189 m/s speed with 1pulse per second. In my case i took the tire length as 1.9m Why? Because when it is with load the measure from the tire center to the ground will not be 0.6215m/2 -> R=0.31075m but less(i guess) so if i take 1.9m as tire length and divide to 1.222 => 1.5545 -> 1.5545 / 8 -> 0.19432 m/per pulse -> * 3.6 to go to m/s -> 0.69955 < that is my variable or if i have 100hz pulses signal * 0.69954 -> 69.954 km/h If you wish to try, take the VSS signal to some suitable frequency measure device and make 70km/h on tachometer and check if you have 100Hz signal.. If not, make based on top info reverse calculation for 50km/h and add that variable in the code. Good luck, and sorry for the long post Arduino with all libraries used - longgo.eu/arduino-1.5.zip , code - longgo.eu/projects.zip |
Kirjoittaja: | lukkis [ 17.06.2014 00:05 ] |
Viestin otsikko: | Re: Xantia trip computer ... |
![]() ![]() |
Kirjoittaja: | longgo [ 20.06.2014 12:06 ] |
Viestin otsikko: | Re: Xantia trip computer ... |
Opss, sorry folks, but i forgot to write something about that RGB back-light idea and cam`t edit that first post. I took in my case 12V for it from one bulb. Can`t remember if that is clear from the video but here is what i mean - where is fuel level indicator there is bulb to give light on it when the car lights are on. So there i soldier on the bulb holder(not on the dash board) 2 wires with connector. In that case - lights everywhere on the dash including that dynamic one. lights off - all is off. Measure with multimeter which is + and - on the board pins and mark it with pen or lipstick ![]() |
Kirjoittaja: | longgo [ 20.04.2016 17:38 ] |
Viestin otsikko: | Re: Xantia trip computer ... |
Just to bring up little the topic. Here is one dash test video: http://www.youtube.com/watch?v=YKu1ned-haE First half is my current dash installed in the car, and after moving RPM arrow is the test with WS2812B LEDS |
Sivu 1/1 | Kaikki ajat ovat UTC + 2 tuntia [ DST ] |
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group http://www.phpbb.com/ |