GithubHelp home page GithubHelp logo

iq-scm / k11consult Goto Github PK

View Code? Open in Web Editor NEW

This project forked from fridlington/k11consult

0.0 0.0 0.0 1.07 MB

Python pyserial Interface to Nissan vehicles Using Nissan Consult Protocol

Home Page: http://eilidh.fridlington.com

License: GNU General Public License v3.0

Shell 0.05% Python 99.95%

k11consult's Introduction

K11Consult

A python project that uses pyserial to interact with the ECU of Nissan vehicles that utilise the Nissan Consult protocol.

The protocol reads and writes hex via a serial connection, with dashboard.py sending the commands and reading in realtime the resultant data stream from the ECU. The script is essentially in two parts; a non blocking deamonised thread that interacts with the ECU, and a gui using pygame that displays the data in the style of a dashboard. There are no external images used as I've written this for minimal CPU usage and to show what's possible using the inbuilt drawing functions of pygame. A YouTube video can be found here of the program running in both windowed and fullscreen modes.

Update

The youtube video shows it running in Ubuntu - I've since switched to Debian as Ubuntu has a long-running bug that makes the keyboard unresponsive with applications that use fullscreen. So if you want to run this then don't use Ubuntu or Ubuntu-based distros.

To make it work in realtime (Debian):

$ sudo apt-get install cutecom socat pygame python-serial

$ sudo gpasswd --add $USER dialout

Then logout / reboot

$ socat -d -d pty,raw,echo=0 pty,raw,echo=0

This will give you the two virtual serial port addresses. Set PORT in dashboard.py to one, and in cutecom the other. Also, in cutecom -> baud rate -> 9600.

$ python dashboard.py

In cutecom you should see FF FF EF - reply with 10 and the dashboard.py window should come to life. cutecom -> send file -> test_data.hex file.

Currently the data displayed is MPH, RPM (large centre arcs), AAC, MAF, temperature and battery voltage. The script is actually streaming 14 data values but these are the most useful to display. Pressing f will make it go fullscreen, w will make it revert back to windowed mode.

k11consult's People

Contributors

fridlington avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.