Obd can to analog converter

Have a good idea for a new product for SFE or Olimex? Let us know!

Moderator: phalanx

Post Reply
Jchidley
Posts: 1
Joined: Mon Apr 10, 2017 11:31 pm

Obd can to analog converter

Post by Jchidley » Mon Apr 10, 2017 11:38 pm

Using the can shield, how does one do this? I would like to pull some data and convert it to voltage for some gauges.

darrellg
Posts: 321
Joined: Fri Oct 17, 2014 10:02 am
Location: Southern California

Re: Obd can to analog converter

Post by darrellg » Mon Apr 17, 2017 10:57 am

Read the value from the CAN bus, then use analogWrite() to PWM the gauge. In between, you can use the map() function to scale the value.

https://www.arduino.cc/en/Reference/AnalogWrite
https://www.arduino.cc/en/Reference/Map

Post Reply