Connect with us

Temperature Sensor

Discussion in 'Microcontrollers, Programming and IoT' started by DeadReanimation, May 4, 2010.

Scroll to continue with content
  1. DeadReanimation


    May 4, 2010
    hello. im trying to make a temperature control system that uses a PIC16F627 with assembler code.
    The attachment show is my circuit. using a voltage regulator to keep the LCD display at +5 volts.
    When it his the temperature desired it turns on a fan (next to the relay and the transistor).
    when booted up initially i want it to start at 30 degrees Celsius for the temp of turn on. but the two switches with plus and minus on them to vary the thermostat control.
    the voltage and current at 40 degrees is 2.54v & 482 uA. (u = micro)
    while at 6 degrees it's: 4v & 124 uA

    my system was based on the circuit that was on the website below. my system however uses a thermistor. but it appears it has been replaced with a dual temp sensor and no thermostat control so figure two is the diagram that used to be there

    i would appreciate it if people gave me help on how to do the code in assembler as im a novice in code.

    Attached Files:

    Last edited: May 4, 2010
  2. (*steve*)

    (*steve*) ¡sǝpodᴉʇuɐ ǝɥʇ ɹɐǝɥd Moderator

    Jan 21, 2010
    I presume you already have the programming hardware available. If not, be prepared for that expense.

    I would recommend you look for a compiler for a high level language (C or even BASIC) for your PIC. Your task does not seem to be one that required assembler programming on the PIC, and if you're learning, a high level language is far easier.

    There are some open source tools available, and some of the closed source tools have basic versions (generally limited to a few PICs or in some other way) available as trial versions.

    As for the design.

    1) I would question why you don't use an 8 bit interface to the LCD. It's easier, and you appear to have outputs to burn.

    2) You should have pull-up resistors on the switches.

    3) you need a diode across the relay coil or your transistor will fail in very short order.

    4) the DS1820 is non-trivial to code for. The thermistor, on the other hand is far simpler. I hope you have access to code samples.
  3. DeadReanimation


    May 4, 2010
    thank you for your help
  4. 55pilot


    Feb 23, 2010
    I am confused. Are you using the DS18S20 or are you using the thermistor? If you are using the thermistor, how do you plan to convert the analog voltage to a digital voltage? Hint: That PIC does not have a built in ADC.

    This is in addition to all the issues Steve has already brought up.

Ask a Question
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.
Electronics Point Logo
Continue to site
Quote of the day