# Displaying Boost on the DIS



## John949 (Apr 12, 2017)

Finally got it working! It's been quite a journey.









I'm using an Arduino (mega) and two CAN shields. The engine data (or data from any other ECU if you wanted) is read from the diagnostic bus in the same way that VCDS reads Measurement Blocks. The data is then displayed on the DIS by impersonating a BNS / RNSe. Basically it's a very crude version of FIS (https://fis-control.de/index_en.html) but it could be further developed to do anything FIS does (given the time and the inclination).

At the moment it displays: Engine power (calculated from air flow), engine torque (calculated from power and engine speed), Boost (calculated from atmospheric pressure and manfold pressure) and Oil temperature.

The hardware can be bought for about £30 and it only needs 6 wires to connect it to the car. I wish I could say: go buy the hardware download my software and it will work, but if I've learnt anything doing this project it's that nothing is easy. So many things that should have worked didn't and the DIS is just downright temperamental. Even with pcbbc's help I still don't understand all the messages it sends and sometimes it behaves differently and I Just don't know why. If you fancy trying it then I think you are going to have to learn to program Arduinos (not that hard) and spend quite some time getting to grips with how the software works. On the plus side, if you do this, it's pretty easy to modify it to display what you want.

There is a fairly detailed description of how it works on Github

https://github.com/John949949/DIS-Display

Here are some pictures of the installation - It fits rather neatly in the glove box (where the CD changer used to be) and this allows me to get at it easily. The obvious place to wire it in is at the Gateway. Being a bit anal I didn't want to touch the original wiring unless I absolutely had to so I bought the cheapest gateway unit I could find, where someone had hacked of the wire rather than undo the connector. I turned this into an extension lead and tapped into the buses / power supply inside the box. The box on the right is the car's original gateway unit - I moved this a short distance into the glovebox. This also allows me to put the car back to standard by just swapping the plugs over.

If anyone wants to have a go then I'm happy to help.

P.S. The digital displays are a bit tiresome and dials would be better for the top three. I suppose one could read the data nd then use a Bluetooth module to impersonate an ELM327 and then get Torque to draw dials on the Xtrons - maybe next winter.


----------



## TTsdsgomg (Mar 19, 2013)

very nice project, needs possible degree in electronics ... way over my pay grade  
I have to stick to simple things that just require a screwdriver and sticky tape


----------



## pcbbc (Sep 4, 2009)

Great work John. Adapting the second gateway so you didn't have to splice any wires was very imaginative.

I actually have a gateway here you could have had, complete with harness. It used to be installed in the 8N purely to get the road speed limits to display on the RNS-E. Not needed now I've fixed the firmware.

@TTsdsgomg: It looks hard, but I'm not sure it's that complex you need a degree! Buy a few modules of eBay, install some software (Arduino is VERY easy - it's designed a hobby platform after all), and do a little bit of wiring.

I'd rate this a level above installing a car stereo.


----------



## IPG3.6 (Sep 5, 2015)

great job!!


----------



## John949 (Apr 12, 2017)

Installing the hardware is about the same difficulty as installing a radio (without a dedicated adapter kit). Downloading and compiling the software is about as hard as say updating your BIOS. The problems come if it doesn't work. Then you'll need to find out why and that requires an understanding of how it works. I may be being a bit pessimistic but I don't want anyone to believe this is a commercial grade product. It's something I developed for personnal interest and has only ever been tested on my car. Also I think you will find it much more useful if you learn how to change it to display the data you want to see.

If anybody is keen to try it and wants to make their way to Fleet in Hampshire, it is really easy to plug it into your car to try it. You just need to remove the glovebox and swap the gateway connectors over - no wiring changes needed on your car. Same goes if you build one and it doesn't work. If you come to me 'll do my best to fix it.

Don't forget that it will not work with an RNS/e or a BNS - same as FIS. There are a couple of ways to make it work with an RNS but both require quite a bit of work and as I have an Xtrons.....

In fact this isn't what I was originally aiming to do with the DIS, it was meant to be a stepping stone to something much more complicated, but then I realised it might be a useful addition.


----------



## pcbbc (Sep 4, 2009)

John949 said:


> Don't forget that it will not work with an RNS/e or a BNS - same as FIS. There are a couple of ways to make it work with an RNS but both require quite a bit of work and as I have an Xtrons.....


I would think that a "bridge mode" using the FisControl mod for the RNS-E firmware I released last month wouldn't be too hard. BNS more difficult as there isn't a firmware mod for that, and so you'd require extra hardware.

Of course not easy for you to test with your Xtrons setup.


----------



## jazzor (Feb 10, 2021)

Hi,
I have aftermarket android headunit with a canbus module (red box with 16 pins), which allows sending messages directly via the CANH and CANL pins on the vehicle connector. Is it possible to refit your code to allow updating the DIS via the canbus module that comes with the head unit?


----------



## SwissJetPilot (Apr 27, 2014)

If the *FIS-Control* was compatible with RNS-E I would seriously consider it -

https://fis-control.de/index_en.html


----------



## pcbbc (Sep 4, 2009)

Swiss, it's more compatible now with my custom firmware.
You can select at ignition on if you want FIS-Comtrol (default) or RNS-E to use the central DIS area.


----------



## SwissJetPilot (Apr 27, 2014)

Oh, that's very cool!


----------



## jazzor (Feb 10, 2021)

pcbbc said:


> Swiss, it's more compatible now with my custom firmware.
> You can select at ignition on if you want FIS-Comtrol (default) or RNS-E to use the central DIS area.


I can see that in this forum you posted a way to display custom data on the DIS, can this be possible using the canbus pins on the quadlock (D block pin 9 and 10)? Is that how you did it? Any help appreciated.

My vehicle is the RNS-e quadlock.


----------



## Steve in Ireland (Oct 13, 2017)

jazzor said:


> Hi,
> I have aftermarket android headunit with a canbus module (red box with 16 pins), which allows sending messages directly via the CANH and CANL pins on the vehicle connector. Is it possible to refit your code to allow updating the DIS via the canbus module that comes with the head unit?


My Xtrons can display very basic information using just the top line of the DIS, such as radio frequency, or CD track number. I assume that the programmers simply couldn't be arsed to do a better job, and that there is a software interface in there which allows CANBUS access to the DIS. I did do a search of the xda-developers forums to see if anyone had any info or had reverse-engineered the code, but I didn't find anything.


----------



## SwissJetPilot (Apr 27, 2014)

@ *Steve in Ireland* - Your Xtron should be able to support an App like *Torque Pro* which can connect via Bluetooth to an OBD reader to visualize performance data. Since the OBD port is always live, you may want an OBD reader with an on-off switch. The OBDeleven OBD device would work, but if you leave it plugged in to the OBD port, it will drain your battery.

This YouTube shows how to set it up and what it will look like -

*How to use OBD02 on XTRONS Android unit*





*Xtron YouTube site - *
https://www.youtube.com/user/ourxtrons/ ... query=audi

Another post on this topic-

*Reading DSG Temperature*
https://www.ttforum.co.uk/forum/viewtop ... &t=1982035


----------



## pcbbc (Sep 4, 2009)

The problem is the headunit is on the infotainment CANBUS, whereas most of the useful engine/performance released data is on the drivetrain CANBUS. So some alternate method (e.g. Bluetooth adapter in the OBDII port) is needed to gain access to the required data.


----------



## John949 (Apr 12, 2017)

Lots of things are possible but unfortunately it gets complicated quickly.

Displaying on the top two lines of the display is easy. Taking over the cental section is way more complicated.

You can read almost any data from the OBD port i.e. anything that VCDS can display, however some data is easy, some is harder.

The OBD port (well actually it's the gateway module connected to it) supports two protocols; OBDII and the one VCDS uses. They work entirely differently. THe OBDII protocol is dead easy and you can fairly easily program a typical Bluetooth dongle to read any available data. The catch is that you can only read the data the Audi choose to make available. On the Mk 2 this is fairly limited and does NOT include boost pressure.

In order to read other data, such as boost or non-emissions related data, you have to use the VCDS style protocol to read the 'measurement blocks'. Whilst it is theoretically possible to do this with an ELM327 based Bluetooth dongle, none of the cheap ones (i.e. the Chinese clones) support the necessary functions. To read boost you probably need to use a microcontroller and a CAN interface - as my original post describes.


----------



## idbpalacei (Jun 1, 2017)

Hi all sorry to jump in
Can i ask if anyone has actually installed the FIS Control from our German friends. Cant see from other posts 
It looks really interesting. Wonder if there would be conflicts with my aftermarket Kenwood or would it be better
Cheers
Ian


----------



## Steve in Ireland (Oct 13, 2017)

SwissJetPilot said:


> @ *Steve in Ireland* - Your Xtron should be able to support an App like *Torque Pro*


You've misunderstood. I was talking about getting stuff from the head unit onto the Audi DIS. The Xtrons can do it, but it's limited, and only a couple of the built-in apps make use of it.

I have played with Torque, and I have an Xtrons-branded ODB-II reader somewhere which has an on/off switch.


----------



## wyx (Dec 21, 2020)

John949 said:


> The catch is that you can only read the data the Audi choose to make available. On the Mk 2 this is fairly limited and does NOT include boost pressure.


At leats, on my headunit, I can see the boost pressure via ODB2 dongle. Or something similar?


----------



## SwissJetPilot (Apr 27, 2014)

@ *Steve in Ireland* - Ah, okay.

So how do you like the combination of the OBD reader and Torque with your Xtron? It looks like a pretty nice set up. Shame the RNS-E can't be set up like that.


----------



## John949 (Apr 12, 2017)

> At leats, on my headunit, I can see the boost pressure via ODB2 dongle. Or something similar?


Is yours a 3.2? I was a little careless saying you can't display it on a Mk2, I should have said a 2008 2.0 TFSI. If you connect a terminal emulator to the OBD dongle you can send it raw commands (Google ELM 327 AT commands). One of these returns all the parameters that the ECU supports. If I try it on my car Boost Pressure is not supported.

On the TFSI there isn't a boost pressure sensor as such, but there is an inlet manfold pressure sensor, so you have to subtract atmospheric pressure from this to get an indication of boost. It's not quite perfect because the sensor is upstream of the throttle and you get pressure spikes when you shut the throttle. You would need a sensor downstream of the throttle to get true boost.


----------



## jazzor (Feb 10, 2021)

John949 said:


> Lots of things are possible but unfortunately it gets complicated quickly.
> 
> Displaying on the top two lines of the display is easy. Taking over the cental section is way more complicated.
> 
> ...


How do you display on the top 2 lines? Could someone enlighten me on this, as it would be a great start? I have seen someone do some work but it was for an older unit that had 3 pins CLK, DATA and ENABLE. but for rns-e style plug it only has 2 pins CANH and CANL? 
The canbus box that comes with the head unit is able to detect other things such as doors being opened and steering wheel controls. How does it filter for the DIS messages?


----------



## Steve in Ireland (Oct 13, 2017)

SwissJetPilot said:


> @ *Steve in Ireland* - Ah, okay.
> 
> So how do you like the combination of the OBD reader and Torque with your Xtron? It looks like a pretty nice set up. Shame the RNS-E can't be set up like that.


You can configure a big BHP dial in the middle of the Xtrons screen and try to max it out...

Well, estimated power based on acceleration, and Torque needs to know the car's weight. I got mine to show 252 BHP, which is more than a factory-fresh 3.2 would have had, so I'm sure it's well over the true figure.

I have an OBDeleven now, but the combination of Torque and bluetooth reader can be used without an internet connection, which makes it worth keeping to hand.


----------



## Steve in Ireland (Oct 13, 2017)

I noticed yesterday when I got a phone call that the Xtrons writes the following to the top two lines of the DIS:

B u T t
BT

Yes. Really useful.

(The HU itself shows the contact name, mutes the music, and so on. All of that works fine.)


----------



## pcbbc (Sep 4, 2009)

Steve in Ireland said:


> I noticed yesterday when I got a phone call that the Xtrons writes the following to the top two lines of the DIS:
> 
> B u T t
> BT
> ...


BlueTooth

Unfortunately the character set used by the DIS is not standard ASCII...








Where the lowercase l, e and o are supposed to be in the ASCII set are replaced with blanks of various widths.
The h would be replaced by a wide -, but is actually absent because the top line only supports 8 characters.

If you want to send lowercase characters a through p to the DIS you need to translate them to ASCII control codes 0x01 through 0x10. It appears the Xtrons programmers aren't aware of that peculiarity though.


----------



## Steve in Ireland (Oct 13, 2017)

pcbbc said:


> If you want to send lowercase characters a through p to the DIS you need to translate them to ASCII control codes 0x01 through 0x10. It appears the Xtrons programmers aren't aware of that peculiarity though.


Aha! That would explain why their radio app correctly displays the likes of "92,30 MHz FM1". They were just lucky.

After a lifetime of programming, I can still read a string of hex digits as ASCII text.


----------



## nick2000 (Oct 14, 2018)

John, what a brilliant project, and kudos to get it working !

Just out of interest, so you tapped onto the same can bus thats used by the OBD connection ?

Slightly off topic... but with CAN being a request / response scheme, did you get a feel for the latency in response on this bus ?

When ive used torque as good as it is, its always felt slightly laggy. ( even with minimum PIDS requested and a proper ELM chip adapter )


----------



## John949 (Apr 12, 2017)

On the MK2 the OBD connector CAN wires go to the gateway unit and nowhere else. If you plug into the OBD socket you can send requests for data to the gateway and it will forward them on to the appropriate ECU (if you get the message sequence right).

The OBDII protocol is limited to 'emissions related data' and it is up to the manufacturer to decide which data they support from the list defined in the standard. If you use Torque you will see that many of the data items are greyed out becuase your car doesn't support them.

The Audi protocol can access any ECU (with a CAN diagnostics interface) on any of the networks in the car and makes far more data items available.

I haven't tried to measure it but both OBDII & measurement block data seem quite laggy, it seems to me that measurement block data is worse. If you wanted fast data then sniffing the appropriate bus for the 'live' data would be the way to go. I haven't tried this but it should be easy enough. You would need a separate CAN interface for each bus you want to listen to but the real difficulty is finding out which CAN message contains the data you are interested in. If you search, some of the more obvious ones (like engine speed have been found) but basically you are looking at hundreds of different CAN addresses with no idea what the message means of how the data is encoded within it. Unsurprisingly Audi won't publish this data.

In contrast the message formats and data encoding for OBDII are in Wikipedia. For measurement blocks it's esy to sniff the diagnostic messages to find the required measurement block (each of which contains 8 data items). There is also some data on the encoding used on the web but it is not beyond the wit of man to work it out.

BTW the data encoding used by Audi is bizarre, the OBDII codings are more accurate and more effecient. It's almost as if Audi deliberately try to disguise the data. You can see this in action if you look at VCDS logs of say engine speed, if you look closely you will see that only certain values of engine speed are ever returned.


----------



## TTwsm (Apr 16, 2021)

BRILLIANT work, both John and pcbbc! Quick question - do either of you by chance know how to change the backlighting to amber and back? I see it on the top of the screen at start (the "OK" that displays briefly).


----------



## pcbbc (Sep 4, 2009)

TTwsm said:


> BRILLIANT work, both John and pcbbc! Quick question - do either of you by chance know how to change the backlighting to amber and back? I see it on the top of the screen at start (the "OK" that displays briefly).


Not possible for an external message, as far as I know. I've certainly never seen it done.
All the things that illuminate there in amber are hard coded warning symbols provided by the cluster itself.


----------



## SwissJetPilot (Apr 27, 2014)

Looks like VAG has been busy reorganizing their software division for the past year or so. I wonder if this means their vehicles will be come more or less user interface (e.g. VCDS, OBDeleven) friendly?

*Volkswagen strengthens new software organization*

_Volkswagen strengthens its Car.Software organization with its Group responsibility for in-car software. Starting January 1, 2020, the Car.Software organization will operate as an in-dependent business unit. As a Group company, the Car.Software organization will centralize the associates and subsidiaries within the Group that develop car software and software for the digital ecosystems _

Source -
https://www.volkswagenag.com/en/news/20 ... ation.html
https://cariad.technology/de/en.html


----------



## TTwsm (Apr 16, 2021)

pcbbc said:


> Not possible for an external message, as far as I know. I've certainly never seen it done.
> All the things that illuminate there in amber are hard coded warning symbols provided by the cluster itself.


Shoot. Thanks for the quick reply!


----------



## Rufflesj (Jun 22, 2020)

SwissJetPilot said:


> Looks like VAG has been busy reorganizing their software division for the past year or so. I wonder if this means their vehicles will be come more or less user interface (e.g. VCDS, OBDeleven) friendly?
> 
> *Volkswagen strengthens new software organization*
> 
> ...


I had an auto spark check my ECU last year and he told me VAG have recently more or less locked everything electronic to themselves and simple fault clearing will even become extremely challenging


----------



## Steve in Ireland (Oct 13, 2017)

SwissJetPilot said:


> Looks like VAG has been busy reorganizing their software division for the past year or so.


Perhaps something to do with the laughable "rogue engineer" excuse for the diesel cheat code fiasco?


----------



## MrRNel (17 d ago)

Hi guys,

i am very interested to try and implement this project on my a3, i noted that there are multiple multiple can shields, how are these modules wired up ?


----------



## marvenednsson_7 (22 d ago)

Is it possible to refit your code to allow updating the DIS via the canbus module that comes with the head unit?


Showbox jiofi.local.html tplinklogin​


----------



## John949 (Apr 12, 2017)

MrRNel said:


> Hi guys,
> 
> i am very interested to try and implement this project on my a3, i noted that there are multiple multiple can shields, how are these modules wired up ?


One is connected to the Diagnostic Bus, the other to the Infotainment Bus. Both buses are present at the Gateway Module so that's where I tap into them.



marvenednsson_7 said:


> Is it possible to refit your code to allow updating the DIS via the canbus module that comes with the head unit?


It might be possible to run the code on the CANBus module but I have no knowledge of either the hardware or the original code. You would also need a second CAN interface to access the Diagnostic Bus.


----------



## MrRNel (17 d ago)

John949 said:


> One is connected to the Diagnostic Bus, the other to the Infotainment Bus. Both buses are present at the Gateway Module so that's where I tap into them.
> 
> hi John
> 
> ...


hi John

after going through your research thoroughly, i assumed that is what you did. i got around to installing everything yesterday. now i am struggling to get the information to show on the DIS, i can see that all the information is being pulled from the module connected to the diagnostic BUS and i tested communication on the information bus and can see that i am receiving information from that module, but there is no change as to what happens on the DIS.

i have an audi a3 2010 with a white display so I assume that the bytes might be different for the DIS.


----------



## John949 (Apr 12, 2017)

PM user 'pcbbc' and ask if he knows how to drive the white display. He has modified the RNSE code and may have experience with the white DIS. Failing that, your are going to have to sniff the bus while the RNSE / BNS talks to the DIS. I have never played with a white DIS but I believe it has more pixels so the format of the messages may be different


----------



## pcbbc (Sep 4, 2009)

There’s no difference for the RNSE in how it talks to a white DIS vs red from the RNSE end. The pixel doubling all happens on the display itself (so drawing coordinates can only address even numbered pixels), and as a result all of the coordinates for printing text remain unchanged for either display type. So the RNSE can send the exact same drawing/printing commands to either display and achieve the exact same results. The only thing that may be different is the initialisation message coming from the cluster to identify it, so if John’s code is expecting a very specific sequence of bytes then it may fail.

Unfortunately I have no experience of talking to a high resolution white DIS vehicle, as from my point of view (when modifying the RNSE firmware) it functions 100% identically to the lower resolution red display. As John says, your best bet is sniffing the bus from a working system such as BNS or RNSE.


----------



## pcbbc (Sep 4, 2009)

Also I assume you have added NAV to the installation list on the cluster with VCDS. If not, you will usually need to do that before anything gets displayed.


----------



## marvenednsson_7 (22 d ago)

some alternate method (e.g. Bluetooth adapter in the OBDII port) is needed to gain access to the required data.





Speed Test​


----------



## MrRNel (17 d ago)

pcbbc said:


> Also I assume you have added NAV to the installation list on the cluster with VCDS. If not, you will usually need to do that before anything gets displayed.


just an update to my attempts so far, the modules i bought locally are not able to switch between cs pin 10 and 9 so i had to splice the traces and manually move one module to cs 9 and for some reason yesterday the untouched module stopped working, so it finally pushed me to connect everything up neatly and fit the arduino into an enclosure, non the less after a good clean the module started working.

i did not enable the nav on the installation list, i was fiddling around with it today and it seems the White DIS does not have the option (i think channel 62) to enable NAV on the cluster.
my theory was also confirmed by this post (How to cancel NAV info on DIS for A3 8P) i might be wrong though, i even checked if it can be enabled with the coding but there is no nav option on the list.

so it seems the only option would be to sniff the instruments buss, but sadly RNS-E radios are very rare here.


----------



## MrRNel (17 d ago)

John949 said:


> PM user 'pcbbc' and ask if he knows how to drive the white display. He has modified the RNSE code and may have experience with the white DIS. Failing that, your are going to have to sniff the bus while the RNSE / BNS talks to the DIS. I have never played with a white DIS but I believe it has more pixels so the format of the messages may be different


the reset button also does not seem to register, might it be that the reset button is also using a different bit ? or can it be something else altogether ?


----------



## MrRNel (17 d ago)

MrRNel said:


> the reset button also does not seem to register, might it be that the reset button is also using a different bit ? or can it be something else altogether ?


 ahhh i think i found my mistake, i tapped into the cluster can bus instead of the infotaiment bus


----------



## John949 (Apr 12, 2017)

Wasn't aware that there is such a thing as the cluster CAN Bus. Does your CAN interface have a built in termination resistor? Most of the commercial CAN Shields do and this needs to be removed to achieve reliable communications. Are you checking your send messages by reading them? Because of the way CAN works it is easy to read the messages that you send out,


----------



## MrRNel (17 d ago)

John949 said:


> Wasn't aware that there is such a thing as the cluster CAN Bus. Does your CAN interface have a built in termination resistor? Most of the commercial CAN Shields do and this needs to be removed to achieve reliable communications. Are you checking your send messages by reading them? Because of the way CAN works it is easy to read the messages that you send out,


 while going through the wiring diagrams, i saw that there is a different bus fo the cluster, on my wiring its a orange blue and orange brown pair, where as the infotaimnt bus is a orange purple orange brown pair. Yes, as per your well laid out instructions i was able to find and remove the termination resistor. I am still new to the CAN world so i am still trying to figure out how it all works.


----------



## John949 (Apr 12, 2017)

That's the Diagnostic Bus. On the TT the Diagnostic Bus is only connected to the Cluster. If you want to talk to say, the Engine Management ECU then you send a message to the cluster, which then puts it on the Infotainment Bus. The Gateway then sees that this message is for the EM ECU and puts it on the Powertrain Bus. The response makes the same hops. I think this is why there is a quite a lag in reading the measurement blocks as Diagnostic messages have a low priority and have to make 4 hops before you get a response.


----------



## MrRNel (17 d ago)

Finally got it working though ! so it was only a matter of being connected to the wrong bus.

now i only need to sort the values, its seems the boost value is way off at the time.

i also still have an engine problem, at low rpm the EPC light comes on, and as soon as the epc message takes priority it gets confused at what needs to display so it starts flickering.
the only way i can seem to fix it is by completely powering down the arduino and powering it back up again. when i reset it, it grabs hold of the screen until the values start pulling through then it starts flickering again.

well i should probably get the engine resolved then it wouldn't be a problem.

i was wondering why the values seemed to update so slow, now i understand why.


----------



## domnulvlad (May 22, 2020)

John949 said:


> Finally got it working! It's been quite a journey.


Hi! A couple of months ago, seeing your post inspired me to start developing a fully-featured Arduino library for DIS communications (for writing text, drawing bitmaps etc.). It is very near completion now, but I still need to check functionality on as many models as possible, as I intend to release this open-source.

Say, do you have the same cluster model as user pcbbc?


----------



## MrRNel (17 d ago)

domnulvlad said:


> Hi! A couple of months ago, seeing your post inspired me to start developing a fully-featured Arduino library for DIS communications (for writing text, drawing bitmaps etc.). It is very near completion now, but I still need to check functionality on as many models as possible, as I intend to release this open-source.
> 
> Say, do you have the same cluster model as user pcbbc?


I would be more then interested in helping out with the project.


----------



## domnulvlad (May 22, 2020)

MrRNel said:


> I would be more then interested in helping out with the project.


Thanks. Do you have any kind of navigation unit in the car, like a BNS or RNSE?
What kind of CAN modules do you have for the Arduino and how many?


----------



## MrRNel (17 d ago)

domnulvlad said:


> Thanks. Do you have any kind of navigation unit in the car, like a BNS or RNSE?
> What kind of CAN modules do you have for the Arduino and how many?


No sadly not.

the only modules that were available here are these 









ELE Can-Bus Shield-V1.5


CAN-BUS is a common industrial bus because of its long travel distance, medium communication speed and high reliability. It is widely used as the automotive diagnostic bus, and also commonly used on modern machine tools.




www.elecrow.com





which i assume is a cheaper version of the ones that John used.

i have 2 installed at the time.


----------



## domnulvlad (May 22, 2020)

Do you have one Arduino?


----------



## MrRNel (17 d ago)

domnulvlad said:


> Do you have one Arduino?


Yes, that would be correct.


----------



## domnulvlad (May 22, 2020)

What model of cluster do you have, from what car?


----------



## MrRNel (17 d ago)

domnulvlad said:


> What model of cluster do you have, from what car?


Its an Audi A3 8P with a high resolution white DIS


----------



## domnulvlad (May 22, 2020)

I have no clue about these models, what year is it from?


----------



## MrRNel (17 d ago)

domnulvlad said:


> I have no clue about these models, what year is it from?


My car is a 2010 but 2010-2012 should be the same.


----------



## domnulvlad (May 22, 2020)

When using John's code, does the display turn red and look like his photo from the first post or does it stay white? Just curious.


----------



## MrRNel (17 d ago)

domnulvlad said:


> When using John's code, does the display turn red and look like his photo from the first post or does it stay white? Just curious.


it stays white.


----------



## domnulvlad (May 22, 2020)

Interesting.
I will write an Arduino sketch for you to test later today.
What CS pins do the shields use?
Also, do you have a laptop you can take with you to the car?


----------



## MrRNel (17 d ago)

i use the same CS pins as John










yes i do.


----------



## domnulvlad (May 22, 2020)

Install this library GitHub - autowp/arduino-mcp2515: Arduino MCP2515 CAN interface library.

After that, download the file sketch.txt from the attachment. Change the extension to .ino or just open it with notepad and copy-paste the contents to a new sketch in the Arduino IDE. Sorry for unreadable code, written quickly!

When you have the time, upload this file. Then, with the Arduino connected to your laptop and to the car, open the Serial Monitor and set the baud rate to 115200. Also make sure the car's ignition is on and the DIS is on. Please tell me if/what it shows on the DIS and also send me what it outputs in the Serial Monitor (uncheck Autoscroll, click inside the monitor window, press Ctrl+A to select all, Ctrl+C to copy).


----------



## MrRNel (17 d ago)

domnulvlad said:


> Install this library GitHub - autowp/arduino-mcp2515: Arduino MCP2515 CAN interface library.
> 
> After that, download the file sketch.txt from the attachment. Change the extension to .ino or just open it with notepad and copy-paste the contents to a new sketch in the Arduino IDE. Sorry for unreadable code, written quickly!
> 
> When you have the time, upload this file. Then, with the Arduino connected to your laptop and to the car, open the Serial Monitor and set the baud rate to 115200. Also make sure the car's ignition is on and the DIS is on. Please tell me if/what it shows on the DIS and also send me what it outputs in the Serial Monitor (uncheck Autoscroll, click inside the monitor window, press Ctrl+A to select all, Ctrl+C to copy).


Got it, il do it in the next hour or so.


----------



## Wolvez (Jun 22, 2018)

You can easily read all measuring value block on all modules using VAG UDS and ELM327.


----------



## domnulvlad (May 22, 2020)

Wolvez said:


> You can easily read all measuring value block on all modules using VAG UDS and ELM327.


Haven't used UDS before, but if it's similar to the usual KWP1281/KWP2000 protocols then it is far slower than CAN-Bus like John949 uses.


----------



## MrRNel (17 d ago)

domnulvlad said:


> Install this library GitHub - autowp/arduino-mcp2515: Arduino MCP2515 CAN interface library.
> 
> After that, download the file sketch.txt from the attachment. Change the extension to .ino or just open it with notepad and copy-paste the contents to a new sketch in the Arduino IDE. Sorry for unreadable code, written quickly!
> 
> When you have the time, upload this file. Then, with the Arduino connected to your laptop and to the car, open the Serial Monitor and set the baud rate to 115200. Also make sure the car's ignition is on and the DIS is on. Please tell me if/what it shows on the DIS and also send me what it outputs in the Serial Monitor (uncheck Autoscroll, click inside the monitor window, press Ctrl+A to select all, Ctrl+C to copy).


as requested find attached.


----------



## domnulvlad (May 22, 2020)

Very nice, it displays as I expected.
But I can see from the serial monitor that I made a mistake! Apparently the request for keep-alive is slightly different than for my older cluster. The sketch was supposed to keep that "A3" in the corner forever, but I am sure after some time it disappeared. I have fixed this mistake in the file attached.
I have also changed the size to fullscreen, now it should not show those 2 horizontal lines and the radio/ temperature. I am very interested in what it sends now.

You should also get a capture where the ignition is off (DIS is off as well), then you reset Arduino and start Serial Monitor and after some time you turn the ignition on. As well as a capture of resetting Arduino while the DIS is on.


----------



## MrRNel (17 d ago)

domnulvlad said:


> Very nice, it displays as I expected.
> But I can see from the serial monitor that I made a mistake! Apparently the request for keep-alive is slightly different than for my older cluster. The sketch was supposed to keep that "A3" in the corner forever, but I am sure after some time it disappeared. I have fixed this mistake in the file attached.
> I have also changed the size to fullscreen, now it should not show those 2 horizontal lines and the radio/ temperature. I am very interested in what it sends now.
> 
> You should also get a capture where the ignition is off (DIS is off as well), then you reset Arduino and start Serial Monitor and after some time you turn the ignition on. As well as a capture of resetting Arduino while the DIS is on.



there is no change on the DIS in other words its only displaying the standard information on the DIS as if there is no communication from the arduino to the cluster


----------



## domnulvlad (May 22, 2020)

You mean the DIS never changed in any way?


----------



## MrRNel (17 d ago)

domnulvlad said:


> You mean the DIS never changed in any way?


Yes


----------



## domnulvlad (May 22, 2020)

Hm. I wonder if the RNSE master knows anything.
@pcbbc do you know anything about clusters not working in fullscreen mode? Or have you ever seen status message C0? Maybe I am missing something.

Edit: my cluster also sends status C0 when trying to claim the screen with unexpected coordinates/size. It seems likeMrRNel's cluster doesn't "know" about fullscreen mode. But then mine also sends status 00 and the 2E error. I guess this is why it's useful to document as many models as possible...


```
6C0: 13 20 3B A0 00
6C1: B4
6C0: 14 52 05 82 00 00 40 58
6C1: B5
6C1: 11 21 3B A0 00
6C0: B2
6C1: 12 53 C0
6C0: B3
6C0: 15 57 05 02 00 01 41 33
6C1: B6
6C0: 16 39
6C1: B7
//not showing anything
```


----------



## domnulvlad (May 22, 2020)

MrRNel said:


> there is no change on the DIS in other words its only displaying the standard information on the DIS as if there is no communication from the arduino to the cluster


Well then, it's getting late, but if you ever have any more time, it would be appreciated if you could repeat the same tests but after changing `setScreenSize(FULLSCREEN);` to `setScreenSize(HALFSCREEN);` near the end of void setup(). It seems either your cluster doesn't support accessing the whole DIS or I am still doing something wrong. For me it works fine. Arghhh... Audi...


----------



## MrRNel (17 d ago)

domnulvlad said:


> Well then, it's getting late, but if you ever have any more time, it would be appreciated if you could repeat the same tests but after changing `setScreenSize(FULLSCREEN);` to `setScreenSize(HALFSCREEN);` near the end of void setup(). It seems either your cluster doesn't support accessing the whole DIS or I am still doing something wrong. For me it works fine. Arghhh... Audi...


Not a problem, i offered my help so time is no object to me.
it works perfectly fine when it is set to half screen, might it be because of the resolution difference between the red DIS and white DIS?


----------



## domnulvlad (May 22, 2020)

Another useful test for me would be capturing what is sent when turning the ignition off while running.

I mean, in the Serial Monitor, with Autoscroll _on_, when you see "Idle" and A3, A1 0F messages coming periodically, switch the ignition off.

Also, even when screenSize is set to FULLSCREEN and you don't see anything on the DIS, I can see communications still happening. So you can do this "ignition off while running" test there as well.


----------



## domnulvlad (May 22, 2020)

MrRNel said:


> Not a problem, i offered my help so time is no object to me.


Thank you a lot. I have no idea why it is refusing to show anything. Have you surely enabled navigation properly? I suppose you have because otherwise nothing would have worked. Weird.
Edit: the way your cluster responds to fullscreen suggests it is not a valid screen size. This "halfscreen" represents the screen starting from X0,Y27 and a size of 64x48 pixels. "Fullscreen" would have meant from X0,Y0 with a size of 64x88 pixels.


> it works perfectly fine when it is set to half screen, might it be because of the resolution difference between the red DIS and white DIS?


This would have made sense if it didn't work correctly in halfscreen mode. It seems it knows to convert this low resolution to its higher resolution. So Audi just didn't program it to know fullscreen. I hope I am wrong though 😅. It would be a shame.

Now, looking at the output, I assume the "A3" is staying in the corner forever, not disappearing anymore, right? 

Please also try commenting-out or deleting the line `commit();` at the end of void setup(). I don't want a serial monitor capture, I just want to know what it does. It should initialise the screen but not display anything.


----------



## MrRNel (17 d ago)

domnulvlad said:


> Another useful test for me would be capturing what is sent when turning the ignition off while running.
> 
> I mean, in the Serial Monitor, with Autoscroll _on_, when you see "Idle" and A3, A1 0F messages coming periodically, switch the ignition off.
> 
> Also, even when screenSize is set to FULLSCREEN and you don't see anything on the DIS, I can see communications still happening. So you can do this "ignition off while running" test there as well.


As requested


----------



## MrRNel (17 d ago)

domnulvlad said:


> Thank you a lot. I have no idea why it is refusing to show anything. Have you surely enabled navigation properly? I suppose you have because otherwise nothing would have worked. Weird.
> 
> Now, looking at the output, I assume the "A3" is staying in the corner forever, not disappearing anymore, right?
> 
> Please also try commenting-out or deleting the line `commit();` at the end of void setup(). I don't want a serial monitor capture, I just want to know what it does. It should initialise the screen but not display anything.


Yes it seems that the A3 is not disappearing anymore.

Sorry about that i missed this one


----------



## domnulvlad (May 22, 2020)

MrRNel said:


> As requested


This is extremely interesting. I was talking with pcbbc and he sent me a capture where he also turned the ignition off at the end, but there it showed something I was not expecting. If you look in your own capture, you can see towards the end the message "1? 00 02". This is the message that is also sent by my very old (year 2000) cluster. For pcbbc, I don't know what year his cluster is, but it is also red monochrome not white and it doesn't send this message. Why exactly I don't know but it is very reassuring that my research is correct. Thank you very much for contributing.


----------



## MrRNel (17 d ago)

domnulvlad said:


> Thank you a lot. I have no idea why it is refusing to show anything. Have you surely enabled navigation properly? I suppose you have because otherwise nothing would have worked. Weird.
> Edit: the way your cluster responds to fullscreen suggests it is not a valid screen size. This "halfscreen" represents the screen starting from X0,Y27 and a size of 64x48 pixels. "Fullscreen" would have meant from X0,Y0 with a size of 64x88 pixels.
> 
> This would have made sense if it didn't work correctly in halfscreen mode. It seems it knows to convert this low resolution to its higher resolution. So Audi just didn't program it to know fullscreen. I hope I am wrong though 😅. It would be a shame.
> ...


 it doesn't initialize the DIS on full screen even if commit is removed


----------



## domnulvlad (May 22, 2020)

MrRNel said:


> Sorry about that i missed this one


No problem, I also have the bad habit of editing messages with new information. All of your help is very much appreciated.


----------



## domnulvlad (May 22, 2020)

MrRNel said:


> it doesn't initialize the DIS on full screen even if commit is removed


That I know, I meant in halfscreen. It should initialize but not show anything between the white lines. (no "A3").


----------



## MrRNel (17 d ago)

Here is an interesting one 

when i open the door and the display is taken over to show the door is open and closed again, the screen is initialized but the A3 is not displayed again, until i reboot the arduino.


----------



## MrRNel (17 d ago)

domnulvlad said:


> That I know, I meant in halfscreen. It should initialize but not show anything between the white lines. (no "A3").


it shows the A3 no matter if commit is present or not


----------



## domnulvlad (May 22, 2020)

MrRNel said:


> it shows the A3 no matter if commit is present or not


Oh, this is even more interesting. This is exactly the same behavior as on my old cluster, it doesn't care about commit messages. But pcbbc tested on his own cluster, that it never displays what it is sent until it receives the commit message. I guess his cluster is special 😂


----------



## domnulvlad (May 22, 2020)

MrRNel said:


> Here is an interesting one
> 
> when i open the door and the display is taken over to show the door is open and closed again, the screen is initialized but the A3 is not displayed again, until i reboot the arduino.


I know it looks weird but this is completely perfect. The sketch I have written for you is very barebones, but if you look at the "annotations", it does detect "STATUS BUSY" and then "STATUS FREE". What is actually happening is that I have not implemented redrawing after the DIS becomes busy. This is a feature of the full library I am developing 😉


----------



## domnulvlad (May 22, 2020)

Also, I have noticed that yours is always busy when starting the sketch, for my cluster the start looks like this:

```
Init
     3 SEND 6C0: 12 20 3B A0 00
     3 RECV 6C1: B3
     2 SEND 6C0: 13 52 05 82 00 1B 40 30
     3 RECV 6C1: B4
    41 RECV 6C1: 11 21 3B A0 00
     3 SEND 6C0: B2
    87 RECV 6C1: 12 53 85 <- look here
     3 SEND 6C0: B3
STATUS OK
Send
     2 SEND 6C0: 14 57 05 02 00 01 41 33
     3 RECV 6C1: B5
     3 SEND 6C0: 15 39
     2 RECV 6C1: B6
Idle
```
My cluster always starts with status 85 a.k.a. "ok". Though I have seen that John's code also has this fact hardcoded. It always expects a status "busy" when starting. But pcbbc's cluster also starts out with "ok"...

Have you done this test: make sure the DIS is on, there is no error or doors opened on it and then reset the Arduino? I think you did, but just making sure. It is very peculiar that it acts busy every time. Not really an issue though.


----------



## MrRNel (17 d ago)

MrRNel said:


> there is no change on the DIS in other words its only displaying the standard information on the DIS as if there is no communication from the arduino to the cluster


Yes, it was apart of the test in this post.

although i can test it again tomorrow and make sure all the conditions are met


----------



## MrRNel (17 d ago)

MrRNel said:


> Yes, it was apart of the test in this post.
> 
> although i can test it again tomorrow and make sure all the conditions are met


although, now that i think about it, once the ignition is switched on i get the service display showing the service is almost due.


----------



## domnulvlad (May 22, 2020)

MrRNel said:


> although, now that i think about it, once the ignition is switched on i get the service display showing the service is almost due.


I was writing to ask exactly this =))

So then this is the answer. Not a problem at all. If you do test it tomorrow (resetting Arduino while DIS is not busy with any message and in halfscreen mode), you should only see "STATUS OK" in the Init stage.


----------



## John949 (Apr 12, 2017)

I haven't played with this for a while but one thing I do remember is that pcbbc could take over the whole display on his Mk 1 but I never managed to do it on my MK 2. I could only ever write to the centre section. There were some thoughts as to whether the Mk 2 has an extra line enabled on the display and hence needed a different initialisation message. but it didn't work for me.
Nice to see someone else taking this further. 

Good Luck


----------



## domnulvlad (May 22, 2020)

John949 said:


> There were some thoughts as to whether the Mk 2 has an extra line enabled on the display


What exactly are you referring to?


----------



## Wilq188 (9 mo ago)

I can help somehow in your project. I have RNS-E (8P0035193G). Send me sketches or tell what to log and maybe I could help.
I have already managed to do for myself an custom screen with UDS protocol on Arduino.


----------



## domnulvlad (May 22, 2020)

Very nice. Check your PM.


----------

