Giter VIP home page Giter VIP logo

thermometer's Introduction

Digital thermometer with ATTINY85/4X and Nokia 5110 LCD module with low power consumption on 2xAA batteries (C) Adam Loboda 2018

to see how it works - look here https://www.youtube.com/watch?v=r6nF1iJ2r-M

Bill of Materials :

  1. ATTINY85 (or ATTINY45, the code is less than 2048 byte long).
  2. Analogue themperature sensor LM36/TMP36 (temp range is -50 - 100st C degrees) or LM35 (range is 0-100st C)
  3. Arduino module LCD Nokia 5510/3110 ( resolution 84x48, chip PCD 8544)
  4. Capacitors 100nF + 10 uF (optional)

Features :

  • powered by 2 x battery AA (LR6). LCD module requires 3.3V power
  • current consumption is 2-2.5 mA
  • ATTINY goes into deep sleep - Power Saving Mode - after measurement is done and screen updated on LCD Nokia
  • works longer than 1 month on ordinary AA batteries
  • Measurements are done once per 4 seconds
  • Fonts can be edited in PROGMEM
  • If using TMP36 temperature sensors shows also negative temperatures (check the code !!!)

LCD Nokia 5110/3110 code borrowed from : https://blog.thegaragelab.com/nokia-5110-lcd-displays-on-the-attiny/ TMP36/LM35 code borrowed from : http://blog.podkalicki.com/100-projects-on-attiny13/

How to connect :
MCU ATTINY13/85/4X PINs :

1 (ADC0) PB5 - Not Connected

2 (ADC3) PB3 - to Vout of sensor LM35 / TMP36

3 PB4 - to CLK pin of Nokia 5110 LCD

4 GND - to "-" of 2x AA battery pack

5 PB0 - to RST/RESET of Nokia 5110 LCD

6 PB1 - to DC pin of Nokia 5110 LCD

7 PB2 - to DIN / DATA IN pin of Nokia 5110 LCD

8 VCC - to "+" of 2x AA battery pack

To pins #4 and pin#8 of MCU optionaly attach capacitors 100nF/10uF


Analogue temperature sensor LM35 / TMP36 pins :

VSS - to "+" of 2xAA battery pack

Vout - to pin #2 of ATTINY

GND - to "-" of 2xAA battery pack


LCD Nokia 5110 pins :

CS - to "-" of 2xAA battery pack

BL - to "-" of 2xAA battery pack

DC - to pin #6 of attiny

RESET / RST- to pin #5 of attiny

DIN/DATA IN - to pin #7 of attiny

CLK - to pin #3 of attiny

VCC - to "+" of 2xAA battery pack

GND - to "-" of 2xAA battery pack

COMPILATION ON LINUX PC :

To upload program code to the chip using cheapest USBASP programmer (less than 2 USD on eBay/Aliexpress) look at this page : http://riteshkhanna.com/2016/04/20/programming-attiny45attiny85-with-a-usbasp-avr-programmer/

The script attached in repository ( "compileattiny.txt") can be used to upload data to the chip if you have Linux machine with following packages : "gcc-avr", "binutils-avr" (or sometimes just "binutils"), "avr-libc", "avrdude" and optionally "gdb-avr"(debugger only if you really need it) . For example in Ubuntu download these packages using command : "sudo apt-get install gcc-avr binutils-avr avr-libc gdb-avr avrdude". After doing it you will be able to run compilation the script from the directory you have downloaded github files by commands:

"sudo chmod +rx compileattiny.txt" and "sudo ./compileattiny.txt"

COMPILATION ON WINDOWS 10 PC :

If you have Windows 10 machine - follow this tutorial to download and install full AVR-GCC environment : http://fab.cba.mit.edu/classes/863.16/doc/projects/ftsmin/windows_avr.html and use "compileattiny.bat" files for compilaton in the directory where you have downloaded mainX.c files. You have to be logged as Windows Administrator and run "cmd" from search window to do that. Then use commands like "cd XXXXX" to change working directory to get to downloaded source files.

thermometer's People

Contributors

mcore1976 avatar

Stargazers

5l1v3r1 avatar  avatar  avatar

Forkers

5l1v3r1

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.