Thermocouple Project


Item Approx. Cost
PIC16F876 Microcontroller $8
MAX6675 Thermocouple Chip $7.18
LCD Display - Blue $4.99 (+$5.99 shipping from China)
SOIC To DIP Adaptor(for MAX6675) $3
28 Pin Socket $2
20 Mhz Resonator $1
Circuit Board $3.29
10K Ohm Potentiometer $1.50
7805 Voltage Reg $1.59
9v Battery Connector $.50
9v Battery Holder $.50
10uF 35v Caps(x2) $1.00
Blue terminal connector $.50
Micro switch $1.25
Headers, wire, resistors, ect. $3
Total Approx. Cost: $45.31



A rough schematic:

Here is a snippet of BASIC code which reads the data from the chip. Written using MBasic from BasicMicro.com (I do NOT have the HEX file available, or this code written in any other programming language):

'Setup MAX6675 - Thermocouple
MAXData	con c1   ' MAXpin7
MAXcs	con c6	' MAXpin6
MAXClock con c3  ' MAXpin5
MAXResult var word
THC	var word	' degrees Celsius (* power of 10)
THF	var word    'stores degrees F


Main:

  low MAXcs	' select chip
  shiftin MAXData,MAXClock,msbpost,[MAXResult\16]	' get data
  high MAXcs	' start new data capture
   
THC= (MAXResult/32) ' Deg. C

THF= (((THC*18)/10)+32) 'Conversion to Deg. F


lcdwrite b5\b4, portb.nib0,[SCRRAM,clear,"Temperature: ", dec THF, "F"] 'display temp. on LCD

pause 20 'give time between read cycles for MAX6675 to work right

goto Main



Copyright©2006-2011. All rights reserved.