Setting up data channels for ND2 Miata

There is another thread where people initially were trying to set up non-standard data channels for ND2 Miata, but it quickly turned into a broader discussion about CAN logging, etc.
https://racechrono.com/forum/discussion/1854/can-bus-data-logging-was-custom-obd-ii-channnels-for-miata-nd2/

I figured it would be valuable to start a new thread with all the important information presented in a more beginner-friendly way.

Recommended setup:
OBDLink MX+ in the "Experimental CAN" mode.
It provides refresh rates of ~40 updates per second, which is significantly higher than what you can get using the regular OBD-II mode.
https://github.com/timurrrr/RaceChronoDiyBleDevice/blob/master/can_db/mazda_mx5_nd.md
lists how to set up the most common/important channels.

Comments

  • Some useful custom data channels if you prefer the old school OBD-II protocol:

    Accelerator position (%)
    PID: 0x22032b
    Equation: B/2.0
    (Surprisingly, the standard OBD PIDs for accelerator communicate values in some weird ranges. This PID gives data in a 0–200 range, but at least that looks deliberate)

    Brake position (%)
    OBD-II header: 0x760 (not sure if necessary, what's the default value?)
    PID: 0x222b0d
    Equation: max(0, bytesToInt(raw, 1, 2)) / 2.3
    (You can try other multipliers if you find the number to be too high or too low for you. You can also wrap it with "min(100, ...)" to limit to 100%.)

    Tire pressures, if your Miata has TPMS sensors (I believe earlier model year NDs had indirect TPMS only):
    OBD-II header: 0x720
    PIDs: 0x222a05 (FL), 0x222a07 (FR), 0x222a06 (RL), 0x222a08 (RR)
    Equation: B * 1.373
    You'll probably want to use the PIDs for tire pressures to be set up as "Slow channels". Their values don't change that often, and making them "Fast channels" would consume too much of the limited OBD-II bandwidth, negatively affecting the update rates for the more time-sensitive channels such as pedals.
  • I finally figured out how to decode the brake pressure channel correctly (or at least definitely better than before) and updated https://github.com/timurrrr/RaceChronoDiyBleDevice/blob/master/can_db/mazda_mx5_nd.md accordingly.
  • Hi timurrrr, any luck on finding OBD2 PID for steering angle? :wink:
  • I don't use OBD-II protocol, I strongly suggest using the CAN protocol instead.
    There the CAN mapping for the steering angle is documented on my github.
    (although it might be a little off/buggy, I've seen some interesting data artifacts from NDs on that channel)
  • I'm thinking to buy the "OBDLink MX+" and use the CAN protocol using RaceChrono.

    Question: do I risk to create any permanent damage (or risk some malfunction while driving) when using "OBDLink MX+" + CAN + RaceChrono?
  • I wouldn't want to answer that question in court under an oath, but my best understanding is that OBDLink is a reputable hardware company with a long-ish history and they most likely designed their OBD readers in such a way that it only reads data from the CAN bus when operating with RaceChrono, and should not cause any interference or malfunction.
Sign In or Register to comment.