Thread: Help a noob plz

    #1
  1. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Oct 2013
    Posts
    1
    Rep Power
    0

    Help a noob plz


    Hi all, this is my first post on the forum!
    Im really new to c-programming, wondered if someone can help me with the following....i want to design a temp controller for a sun heater that will work as follows.....measure water going into the heater and measure water temp going out of the heater, when the water going in is higher than that coming out, a pump relay should stop the water, when the temp outside is higher than the water the pump should start again.

    Ill use a 18f2620, lm35 temp probe.
    Id also like an lcd display to show the temp.

    Any advice will be welcome
    Thanks
  2. #2
  3. Contributed User
    Devshed Specialist (4000 - 4499 posts)

    Join Date
    Jun 2005
    Posts
    4,417
    Rep Power
    1871
    > Ill use a 18f2620
    This is a chip
    This is a devboard

    Do you intend to produce your own hardware?

    Given your question, I'd suggest you start with a board which already has an LCD on it, to save lots of messing about just to get the basics working.

    When it comes to programming, all I can suggest is you make very small steps, and try specific functions in isolation.

    Eg.
    - print a character on the screen.
    - turn a relay on
    - turn a relay off
    - print 'A' if the probe temperature < x
    - print 'B' if the probe temperature > y

    Remember, the typical outcome of writing code on a bare machine is that it either locks up or reboots. Neither is particularly good when it comes to figuring out where you went wrong.

    Getting the LCD working first gives you feedback options.
    Taking small steps means you're never far away from what used to work.
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper

IMN logo majestic logo threadwatch logo seochat tools logo