Code Monkey home page Code Monkey logo

thermistorlibrary's Introduction

DOI Build Status Contributors Forks Stargazers Issues MIT License LinkedIn

Arduino thermistor library

Need help or have a question? Send me an email, email2

Contents

Development Status

Most marlin is applied to calculate the temperature accurately.

  • Supports any number of thermistors, the only thing that limits you is the number of analog inputs your arduino card has
  • The temperature output is in degrees centigrade.

Installation Instructions

Issue/Bug report template

Before reporting an issue, make sure you've searched for similar one that was already created.

Example with ramps schematic

Pin Functions

Supported thermistors

All definitions in src/Configuration.h file.

Example configuration

  • #define TEMP_SENSOR_0 80 // This is thermistor 0
  • #define TEMP_SENSOR_1 0 // This is thermistor 1
  • #define TEMP_SENSOR_2 0 // This is thermistor 2
  • #define TEMP_SENSOR_3 0 // This is thermistor 3
  • #define TEMP_SENSOR_4 0 // This is thermistor 4
  • #define TEMP_SENSOR_BED 80 // This is not used thermistor

At this example we asigned to therm0 80 ( 3950 thermistor 100K - 4k7 Pull up and 10Uf Capacitor )(RAMPS STYLE).
In basic example selected thermistor is PIN A0 and therm0 (thermistor therm1(A0,0)).
therm 1 is an 3950 thermistor connected in A0 pin with 4k7 pullup and 10Uf capacitor to GND.

Temperature sensors available

  • 0 : not used
    
  • 1 : 100k thermistor - best choice for EPCOS 100k (4.7k pullup)
    
  • 2 : 200k thermistor - ATC Semitec 204GT-2 (4.7k pullup)
    
  • 3 : Mendel-parts thermistor (4.7k pullup)
    
  • 4 : 10k thermistor !! do not use it for a hotend. It gives bad resolution at high temp. !!
    
  • 5 : 100K thermistor - ATC Semitec 104GT-2 (Used in ParCan & J-Head) (4.7k pullup)
    
  • 6 : 100k EPCOS - Not as accurate as table 1 (created using a fluke thermocouple) (4.7k pullup)
    
  • 7 : 100k Honeywell thermistor 135-104LAG-J01 (4.7k pullup)
    
  • 71: 100k Honeywell thermistor 135-104LAF-J01 (4.7k pullup)
    
  • 8 : 100k 0603 SMD Vishay NTCS0603E3104FXT (4.7k pullup)
    
  • 9 : 100k GE Sensing AL03006-58.2K-97-G1 (4.7k pullup)
    
  • 10 : 100k RS thermistor 198-961 (4.7k pullup)
    
  • 11 : 100k beta 3950 1% thermistor (4.7k pullup)
    
  • 12 : 100k 0603 SMD Vishay NTCS0603E3104FXT (4.7k pullup) (calibrated for Makibox hot bed)
    
  • 13 : 100k Hisens 3950  1% up to 300°C for hotend "Simple ONE " & "Hotend "All In ONE"
    
  • 20 : the PT100 circuit found in the Ultimainboard V2.x
    
  • 60 : 100k Maker's Tool Works Kapton Bed Thermistor beta=3950
    
  • 66 : 4.7M High Temperature thermistor from Dyze Design
    
  • 70 : the 100K thermistor found in the bq Hephestos 2
    
  • 75 : 100k Generic Silicon Heat Pad with NTC 100K MGB18-104F39050L32 thermistor
    
  • 80 : 3950 thermistor 100K - 4k7 Pull up and 10Uf Capacitor
    
     1k ohm pullup tables - This is atypical, and requires changing out the 4.7k pullup for 1k.
                          (but gives greater accuracy and more stable PID)
    
  • 51 : 100k thermistor - EPCOS (1k pullup)
    
  • 52 : 200k thermistor - ATC Semitec 204GT-2 (1k pullup)
    
  • 55 : 100k thermistor - ATC Semitec 104GT-2 (Used in ParCan & J-Head) (1k pullup)
    
      Use these for Testing or Development purposes. NEVER for production machine.
    
  • 998 : Dummy Table that ALWAYS reads 25°C or the temperature defined below.
    
  • 999 : Dummy Table that ALWAYS reads 100°C or the temperature defined below.
    

Acknowledgements

More information

Authors

thermistorlibrary's People

Contributors

alextrical avatar bwanafr avatar jjsch-dev avatar miguel5612 avatar ondrejnovakcvut avatar per1234 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

thermistorlibrary's Issues

Error compiling for ESP8266

I tried to compile this for an ESP8266 and get the following errors.

WARNING: library ThermistorLibrary-master claims to run on (avr) architecture(s) and may be incompatible with your current board which runs on (esp8266) architecture(s).
C:\Arduino\libraries\ThermistorLibrary-master\src\thermistor.cpp: In member function 'float thermistor::analog2temp()':

C:\Arduino\libraries\ThermistorLibrary-master\src\thermistor.cpp:41:38: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]

 for (i = 1; i < heater_ttbl_map[e]; i++) {

Any sugestions as to how to fix this?

Otherwise the library works a treat on the NANO, however i need to report the temperature back via WiFi and the ESP seemed to be the easier option for this.

What is sensor 80?

Hi,

what is the meaning of sensor 80 in:

#define TEMP_SENSOR_0 80 // This is thermistor 0

in Configuration.h?

The number 80 is not on the list.

library.properties version is outdated

Hi,

The Arduino Library Manager installs version 1.0.3 dated Aug 2019. Can you please update library.properties with the current 1.0.4 version?

Thanks!

Duplicated files

There is a lot of duplicate files in src and src/tables directories. Why is that? Would be worth merging.

How to implement?

I am able to read temp with Arduino but how to pass this information to marlin, what are the connections of Arduino with the 3d printer motherboard and what changes do I need to do in marlin except for configuration changes?

Error compiling basicExample for STM32

Arduino: 1.8.9 (Windows 10), Board: "Generic STM32F103C series, STM32F103C8 (20k RAM. 64k Flash), STM32duino bootloader, 72Mhz (Normal), Smallest (default)"

F:\Libraries\Documents\Arduino\libraries\Arduino-ThermistorLibrary-master\thermistor.cpp: In member function 'float thermistor::analog2temp()':

F:\Libraries\Documents\Arduino\libraries\Arduino-ThermistorLibrary-master\thermistor.cpp:41:38: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]

 for (i = 1; i < heater_ttbl_map[e]; i++) {

                                  ^

exit status 1
Error compiling for board Generic STM32F103C series.

This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.

I am trying to compile the example for my STM32F103C but I get this error. I am simply using the example. works perfectly with Arduino Uno

Maximum number of sensors?

There is a note:

Supports any number of thermistors, the only thing that limits you is the number of analog inputs your arduino card has

However, by looking at Configuration.h, Conditionals.h and Thermistortables.h it seems as only 4 thermistors can be used without changing the code?

Thermistor table for dummy 999 is wrong

When using the dummy thermistor 999 it should tell 100º and is telling 25º, the same as dummy 998. I've checked it and the table is wrong.
Please update the table,

All sensors use table for TEMP_SENSOR_0

As the title says all sensors are using the table defined as TEMP_SENSOR_0

I changed the definition in configuration.h to:
#define TEMP_SENSOR_0 80 // This is thermistor 0
#define TEMP_SENSOR_1 4 // This is thermistor 1

My definitions in my sketch are:
thermistor therm1(A7,0); //Connect thermistor on A7, 0 represents TEMP_SENSOR_0 ( configuration.h for more)
thermistor therm2(A3,1); //Connect thermistor on A3, 1 represents TEMP_SENSOR_1 ( configuration.h for more)

and I'm calling:
temp1 = (int)round(therm1.analog2temp()); // read temperature
temp2 = (int)round(therm2.analog2temp()); // read temperature

I've tried 2 and 3 for the second thermistor and changing the table for the corresponding TEMP_SENSOR_X but no luck. When I call thermX.analog2temp() it always returns using the TEMP_SENSOR_0 table. I'm using both a 10K Ohm 3950 and 100K Ohm 3950 so I'm hoping to have two tables, but for now I'm going to just use 100K for both

Setting TEMP_SENSOR_0 to 998 or 999 returns the dummy table 25C/100C for both sensors. Calling it with it set to 80 gives me the correct value on therm1(100K) and a very high value on therm2(10K)

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.