Light mode project

Post here about your Arduino projects, get help - for Adafruit customers!

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Locked
sasuto
 
Posts: 37
Joined: Sun May 10, 2009 8:36 pm

Light mode project

Post by sasuto »

Hi,

I'm doing a new project and it require to change mode every time you press the switch button.
The project is basically pressing the switch button and the lights change from one mode to another then turned off.

What is the code for the switch button?

User avatar
Franklin97355
 
Posts: 23911
Joined: Mon Apr 21, 2008 2:33 pm

Re: Light mode project

Post by Franklin97355 »

The code depends on how you have your circuit wired. Could you post a schematic of your circuit and a complete and precise description of what you want to happen?

mtbf0
 
Posts: 1645
Joined: Sat Nov 10, 2007 12:59 am

Re: Light mode project

Post by mtbf0 »


sasuto
 
Posts: 37
Joined: Sun May 10, 2009 8:36 pm

Re: Light mode project

Post by sasuto »

I'm planning on know how to code the switch first because I don't have a schematic right now..

User avatar
adafruit_support_bill
 
Posts: 88093
Joined: Sat Feb 07, 2009 10:11 am

Re: Light mode project

Post by adafruit_support_bill »

Tutorial #5 as suggested above by mbtf0 is the best place to start. It explains reading and debouncing button presses, as well as pullup/pulldown resistors.

Locked
Please be positive and constructive with your questions and comments.

Return to “Arduino”