Skip to content

Automatically offset car exhaust using Particle.io and Wren.co

License

Notifications You must be signed in to change notification settings

rootvc/AutoOffset

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

34 Commits
 
 
 
 
 
 

Repository files navigation

AutoOffset

AutoOffset uses a Particle Photon and Carloop OBDII adapter to automatically offset carbon emissions from vehicles using the Wren.co API.

This code integrates speed readouts from OBDII to calculate distance and emissions. While some cars have fuel-level PIDs, it is not standard across vehicles and years the way speed PIDs are, and I wanted to make this compatible with as many vehicles as possible.

This app could also be implemented with GPS and cellular instead of OBDII readouts and WiFi, but I wanted to make an app that didn't require tracking or persistent data. Let me know if you make the more sophisticated version!

Getting Started

Dependencies

Installing

{"tons":{{{PARTICLE_EVENT_VALUE}}},"note":"tons carbon offset","dryRun":true}
  • Configure the MPG variable in the source code to match your car's (line 17 in AutoOffset.ino)

Executing program

  • With the Photon setup, install it in your car's OBDII port
  • The app should run automatically and publish to the Particle Webhook when the Particle connects to internet in test mode (i.e. does not charge your Wren account)
  • When you are done testing, the dryRun flag in Particle Webhook body can be set to false to start buying offsets

Help

Please help me refine this project. What I'd like to implement:

  • Deep sleep the Particle when car is off in a broadly compatible way (RPM detect? CAN traffic?)
  • Fork a version to use GPS instead of OBDII
  • General code refinement

Authors

@kane

License

This project is licensed under the Creative Commons Zero v1.0 Universal License - see the LICENSE.md file for details

Acknowledgments

Thanks for the help: