Show Posts
Pages: 1 2 [3] 4 5 ... 3083
31  Using Arduino / Programming Questions / Re: Arducam-F REV.C and Arduino Uno R3 - Empty Image in SD card on: Today at 05:51:18 am
Quote
And I change OV2640 for 5 and it's upload. But give me a empty image.
Say what?

Quote
I am doing a thesis and it is important for me.
What's your thesis topic? Obfuscation? How to be clueless? How to get others to do your work for you without even a clue?
32  Using Arduino / Programming Questions / Re: Accelerometers and LCD Display on: Today at 05:45:31 am
Quote
2- TWO triple access accelerometer breakouts
Are they anything like triple axis accelerometers?

Quote
Here's what I want to do:
Sounds easy. What have you actually accomplished?
33  Using Arduino / Programming Questions / Re: Making a DC motor wait for conditions on: Today at 05:39:08 am
So, it sounds like you have a limit switch for one direction, but not for the other. Is that right?

Why not start the motor, delay() for 10 seconds, and then stop the motor? I don't understand why you aren't willing to do that.

Or, use the blink without delay philosophy and start the motor running and record when that happened. On a later pass through loop, if the motor is running, and has been running for 10 seconds, turn it off and clear the started time.
34  Using Arduino / Programming Questions / Re: Programming Arduino Uno to play specific WAV based off input voltages on: Today at 05:36:12 am
Code:
void playfile(char *name) {
  // see if the wave object is currently doing something
  if (wave.isplaying) {// already playing something, so stop it!
    wave.stop(); // stop it
  }
}
If not, God forbid that we should actually do something with the name that was entered.
35  Using Arduino / Programming Questions / Re: WaveHC: Filenames from SD in array on: Today at 05:33:36 am
Quote
"I'm trying to put the first 8 characters of the filenames from SD card into an array"
So, if the file name is fart.wav, you want to save all 8 of them in the array. Later, then, you'll try to replay fart.wav.wav. I get it now.
36  Using Arduino / Programming Questions / Re: Button interrupts - arduino uno - help on: Today at 05:30:10 am
Quote
I am very new to arduino and programming in general.
Then, you have NO business trying to use interrupts.

Quote
I have both buttons connected with an individual 10k pull up resistor to the ground.
A wiring diagram would be useful, as would using proper terminology. A pull UP resistor pulls the pin UP to 5V. A pull DOWN resistor pulls the pin DOWN to ground.

The Arduino has built-in pullup resistors, so the simplest way to connect a SWITCH is to connect one leg to ground and the other the digital pin, and then turn on the internal pullup resistor.

Code:
const double precision = 0.3; //.5 degrees precision
If you are going to have useless comments that state the obvious, they MUST be correct.

You need to delete all the stuff dealing with interrupts. There is nothing in your code that needs to respond IMMEDIATELY to a change in button state. Reading the pin once per pass through loop() is good enough. There is nothing that is going to matter if you are a few nanoseconds late reading the switch state.

Code:
delay(startup_time); //allow lcd to be initialized first
Bullshit. If your LCD is so lazy that it needs a rest on EVERY pass through loop, throw it away and get one that can work harder.

Read, understand, and embrace the blink without delay philosophy and get rid of EVERY delay(). You do not need them. AT ALL.
37  Using Arduino / Programming Questions / Re: WaveHC: Filenames from SD in array on: Today at 05:08:47 am
Quote
The filenames in dirBuf.name are without the dot
But there are not always 8 characters.
38  Using Arduino / Programming Questions / Re: Help with motion activated servo please. on: Today at 04:58:23 am
The page that you link to says
Quote
The regular value without movement is above 1021, upon detecting it, it goes low to 17 - 18.
so your test for greater than 1000 is a bit too close for my liking.  What sort of values do you get for alarmValue using your program ?

Sounds like some idiot using a digital sensor like an analog sensor to me. Use digitalRead(). Get HIGH when there is no movement; get LOW when there is.
39  Using Arduino / Programming Questions / Re: Driver for Diving Flashlite on: Today at 04:55:42 am
What is this crap?
Code:
  {      TIMER = millis();     if(reading == HIGH && previous == LOW) //button pressed, pulled low
Get your enter key fixed or bang it more often.
40  Using Arduino / Programming Questions / Re: Compiling Error for my Project on: Today at 04:51:50 am
Code:
     (Serial.read() == 'P'){
What is this supposed to do? Compare the value of the character just read to 'P', and then throw away the result. How is that useful?

Every { belongs on a new line. Use Tools + Auto Format to properly indent that mess.

Code:
     (Serial.print('K');
(Why (is (there (an (open (parenthesis (there (?

Code:
     if digitalRead(SENSOR1, HIGH){
Wrong. The digitalRead() function only takes one argument.
41  Using Arduino / Programming Questions / Re: random note player on: Today at 04:42:12 am
Quote
would it simply be something like

pseudo code
Not quite. You don't need to choose a new random value unless it is time

Code:
unsigned long now = millis();
if(now - then > noteDuration)
{
   byte choice = random(3);
   // Choose new note and corresponding duration
   // Start note playing for new duration
   noteDuration = duration[choice];
   then = now;
}
42  Using Arduino / Programming Questions / Re: Time checking on reset on: Today at 04:34:45 am
Did you fix this?
Code:
  V1 +1;
43  Using Arduino / Programming Questions / Re: Help with motion activated servo please. on: April 23, 2014, 06:25:19 pm
A PIR sensor detects, or doesn't detect, motion. Why are you reading a digital device using an analog pin?

In any case, you want the change from no motion to motion to trigger the servo, not the presence of motion. Look at the state change detection example.
44  Using Arduino / Programming Questions / Re: Idle does not work with Timer0 on: April 23, 2014, 06:20:41 pm
Quote
Is there a way to tell time.h to work with timer1?
No, because time.h doesn't do anything directly with timers. It relies on millis() operating correctly.
45  Using Arduino / Programming Questions / Re: Arduino GPS Shield by iteadstudio.com on: April 23, 2014, 06:18:36 pm
You could also have swapped the wires.
Pages: 1 2 [3] 4 5 ... 3083