solar pump switch

This is a discussion on solar pump switch within the C Programming forums, part of the General Programming Boards category; I'm doing a project on solar panel water pump.I need to use C programming to automatically activate the water pump ...

  1. #1
    Registered User
    Join Date
    Jul 2011
    Posts
    3

    solar pump switch

    I'm doing a project on solar panel water pump.I need to use C programming to automatically activate the water pump battery from 6pm to 6am for a 4 digit 7-Segment LED.
    Here are the codes from my previous project codes for Count Down Timer for AT89C5131 board. So how do I edit from it?
    Attached Files Attached Files
    • File Type: c m.c (1.8 KB, 40 views)

  2. #2
    ATH0 quzah's Avatar
    Join Date
    Oct 2001
    Posts
    14,826
    Personally, I'd use some kind of text editor.

    See also: Homework policy, How to ask smart questions.


    Quzah.
    Hope is the first step on the road to disappointment.

  3. #3
    Registered User manasij7479's Avatar
    Join Date
    Feb 2011
    Location
    Kolkata@India
    Posts
    2,498
    Did you hope for new answers to the same question ?

    btw..If you wrote the code in the file you attached, this shouldn't be much different !
    Manasij Mukherjee | gcc-4.8.2 @Arch Linux
    Slow and Steady wins the race... if and only if :
    1.None of the other participants are fast and steady.
    2.The fast and unsteady suddenly falls asleep while running !



  4. #4
    and the hat of wrongness Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    32,541
    > I need to use C programming to automatically activate the water pump battery from 6pm to 6am for a 4 digit 7-Segment LED.
    In order to know when 6pm is, you need to know what time it is "now", in order to know when 6pm is actually 6pm.

    The MCU you quote doesn't have a real time clock, so does the board you're supplied with have such a clock?

    Mind you, the whole "solar" thing is a give-away.
    Perhaps all you need to do is put one of these across a couple of I/O pins in order to determine that it is in fact just "dark" outside.
    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.
    I support http://www.ukip.org/ as the first necessary step to a free Europe.

  5. #5
    Banned
    Join Date
    Aug 2010
    Location
    Ontario Canada
    Posts
    9,547
    Actually for the original inquiry... I would follow an already suggested route of using a photocell on an analog input. It's smarter than a timer since it can also account for cloud cover, enormous forest fires, volcanic ash, eclipses, massive solar flares and blue moons.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. message pump code for COM STA
    By George2 in forum Windows Programming
    Replies: 0
    Last Post: 04-10-2008, 08:19 PM
  2. COM message pump
    By George2 in forum Windows Programming
    Replies: 2
    Last Post: 03-29-2008, 02:52 AM
  3. Don't Pump Gas on May 15th
    By Queatrix in forum A Brief History of Cprogramming.com
    Replies: 30
    Last Post: 05-04-2007, 04:28 PM
  4. 3D Solar System - web demo
    By Jeremy G in forum Game Programming
    Replies: 5
    Last Post: 12-02-2004, 07:41 AM
  5. Solar Eclipse tonight.
    By sean in forum A Brief History of Cprogramming.com
    Replies: 1
    Last Post: 06-10-2002, 12:57 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21