Show Posts
Pages: [1] 2
1  Forum 2005-2010 (read only) / Troubleshooting / Re: random led blink on: March 18, 2008, 08:02:51 am
Thanks for all the help. I know my posted code was in error. I fixed it but  did not post that fact. Mea culpa.  Graybeard

a note to all - Growing older is mandatory - Growing up is not
2  Forum 2005-2010 (read only) / Troubleshooting / Re: random led blink on: March 15, 2008, 04:42:04 pm
To God Member, After reviewing you suggestions and reworking the compiler it looks like I've solved the problem. Thank you very much. Graybeard
3  Forum 2005-2010 (read only) / Troubleshooting / Re: random led blink on: March 15, 2008, 03:53:46 pm
Hi God Member, Thanks for the suggestions. Unfortunately, I still have sequential blinks- not random.

                                                                  Graybeard

                                                      
4  Forum 2005-2010 (read only) / Troubleshooting / Re: random led blink on: March 14, 2008, 09:20:41 am
I didn't answer the second question. The Arduino and the leds are on a breadboard. I am using a 1K resistor on each. All leds light up but only in sequence. There is no random action.

                                                   graybeard
5  Forum 2005-2010 (read only) / Troubleshooting / Re: random led blink on: March 14, 2008, 09:13:12 am
Simon, Thanks for asking. There are 4 leds connected to the Arduino. Here's the code.

int redPin = 12;
int bluePin = 11;
int whitePin = 10;
int yellowPin = 9;

int val;



void setup () {
  randomSeed(analogRead (1);
  pinMode(redPin, OUTPUT);
  pinMode(bluePin, OUTPUT);
  pinMode(whitePin, OUTPUT);
  pinMode(yellowPin, OUTPUT);
}
 void loop(){
 
 val = random(1,4);
 
     if (val == 1)  
   digitalWrite(redPin, HIGH);
   digitalWrite(bluePin, LOW);
   digitalWrite(whitePin, LOW);
   digitalWrite(yellowPin, LOW);
   delay(1000);
   digitalWrite(redPin, LOW);
  
   delay(1000);
  

    
    if (val == 2)
     digitalWrite(redPin,LOW);
   digitalWrite(bluePin, HIGH);
   digitalWrite(whitePin, LOW);
   digitalWrite(yellowPin, LOW);
   delay(1000);
   digitalWrite(bluePin, LOW);
   delay(1000);
  
     if (val == 3)
   digitalWrite(redPin,LOW);
   digitalWrite(bluePin, LOW);
   digitalWrite(whitePin, HIGH);
   digitalWrite(yellowPin, LOW);
   delay(1000);
   digitalWrite(whitePin, LOW);
   delay(1000);


  
   if (val == 4)
   digitalWrite(redPin,LOW);
   digitalWrite(bluePin, LOW);
   digitalWrite(whitePin, LOW);
   digitalWrite(yellowPin, HIGH);
   delay(1000);
   digitalWrite(yellowPin, LOW);
   delay(1000);
 }
                                              graybeard
 

6  Forum 2005-2010 (read only) / Troubleshooting / random led blink on: March 09, 2008, 04:42:26 pm
Help, I'm trying to get four leds to blink in a random pattern. This should be a trivial job but I haven't succeeded yet. I'm using  int val; and val = random(1,4). Pinmodes and digitalwrite are OK but the leds only blink in sequence rather than randomly. Graybeard
7  Forum 2005-2010 (read only) / Troubleshooting / Re: Programmer not responding on: March 25, 2008, 04:33:58 pm
It looks as if the problem is solved. The reset button may be defective. Another button on the 5V out with a jumper to the ground has given me reset capability. I downloaded a couple of sketches successfully. It doesn't appear that I'm frying any components. Thanks for helping. Graybeard

 Growing older is mandatory - Growing up is optional
8  Forum 2005-2010 (read only) / Troubleshooting / Re: Programmer not responding on: March 25, 2008, 08:28:15 am
2nd part of question. Mac OS is 10.4.11. Arduino is 0010. Graybeard
9  Forum 2005-2010 (read only) / Troubleshooting / Re: Programmer not responding on: March 25, 2008, 08:24:02 am
I"m using a Modern devices board on a Mac. Graybeard
10  Forum 2005-2010 (read only) / Troubleshooting / Programmer not responding on: March 24, 2008, 09:45:38 am
I'm getting a "programmer not responding" message. I compiled a sketch and uploaded it to the board. It worked fine. I modified the sketch, compiled it and tried to upload. Got the error message. Tried several times more and tried a couple of other sketches - same message. Pin 13 led blinks three times after reset is pushed so that seems to be OK. Any suggestions? Graybeard


11  Forum 2005-2010 (read only) / Development / Re: Cost of an Arduino Board for a poor student on: September 28, 2008, 02:20:27 pm
I don't know the cost of the components but here are two sites showing how to set up an Arduino on a breadboard: WWW.Liberlab.net (in French and English. Carlyn Maw's  ITP tutorial at HTTP//ITP.NYU.EDU/physcomp/tutorials/arduinobreadboad.Graybeard

Growing older is mandatory. Growing up is optional.
12  Forum 2005-2010 (read only) / Interfacing / Re: piranha led on: December 22, 2008, 08:40:55 am
Thanks for the suggestions. Turning the led should work. As to future plans - at this time I'm just playing with the devices in order to learn how things work. Graybeard

Growing older is mandatory. Growing up is optional.
13  Forum 2005-2010 (read only) / Interfacing / piranha led on: December 21, 2008, 10:52:52 am
I have some piranha common cathode leds that I would like to use with pwm.  These leds have 4 pins which are arranged in a  square. I'd like to put them on a breadboard but can't figure out how mount them so each pin is separate from the others in the circuit.  Any suggestions? Graybeard

Growing older is mandatory. Growing up is optional.
14  Forum 2005-2010 (read only) / Interfacing / Uzebox on: August 26, 2008, 02:51:09 pm
I see that the Uzebox site shows the 644 chip in use. Would it be possible to use the Sanguino board for this project? Graybeard

Growing older is mandatory. Growing up is optional.
15  Forum 2005-2010 (read only) / Interfacing / Re: rgb driver on: June 27, 2008, 10:19:07 am
Thanks for your help. Here comes the however - My question was where can I get a few ON NCP5623s? A reel of the devices is a budget buster as well as a bench clutterer. Graybeard

When you're up to your a** in alligators, it's hard to remember that your objective was to drain the swamp.
Pages: [1] 2