Giter Club home page Giter Club logo

vocore2-max6675's Introduction

Vocore 2 max6675 thermocouple module library

This is an Arduino inspired library for interfacing between Vocore2 and the module max6675 for thermocouples.

Made by Bryan Barbosa from Federal University of Juiz de Fora and CREA - University of California, Berkeley.

Importing

The library can be used simply by importing the Python file to your project.

import max6675

Or, for an easier usage and more Arduino-like, you can import it like this:

from max6675 import *

Usage

The usage of the library is simple. Follow the steps:

  1. Define variables for the pins where the 6675 module is connected.
  2. Create an instance of the max6675 passing the three variables as parameteres.
  3. Get the temperature readings by calling the functions ".read_[...]", that can return values in Celsius, Fahrenheit and Kelvin.

Here's a code example:

from max6675 import *
from vocoreGPIO import *

#1. Defining pins
sclk = 39
cs = 40
miso = 41

#2. Creating an instance of the max6675 class
t = max6675(sclk, cs, miso)

while(1):
    c = t.read_celsius() #Getting reading in Celsius
    f = t.read_fahrenheit() #Getting reading in Fahrenheit
    k = t.read_kelvin() #Getting reading in Kelvin

    print("C:", c, "   F:", f, "   K:", k)
    delay(15000)

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure to update tests as appropriate.

License

MIT

vocore2-max6675's People

Contributors

bryancmbarbosa avatar

Watchers

James Cloos avatar  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.