programming question help!!!

i am very new to the whole world of programming and all that so i mad something thinking i knew what i was doing but i cant get it right i now my code is pretty messed up. :confused: I am simly trying to make an led blink using a infrared motion sensor, and it worked in the beginning. but the led wasnt on for long enough so i tried some differen things, and i ended up reconstructing so many things that i dont really know where to go from here.

So if anybody would help me with 1 what kind of argument is missing from the code:
while(digitalWrite(ledPin == LOW)) {
if(digitalRead(pirPin) == HIGH);{
digitalWrite(ledPin, HIGH);

And 2: how do you determine for how long the led stays high?
i'll be very greatfull if you'd help me:))

sketch_mar18b.ino (2.81 KB)

 while(digitalWrite(ledPin == LOW)) {

digitalWrite doesn't return a value, but requires two arguments.

if(digitalRead(pirPin) == HIGH);

Lose the semicolon

      }      }    }    }}}}}}}} That should never, ever happen.

This all seems very familiar.

Why did you start another thread ?

im so confused with this whole forum thing, i joined last night and i couldnt find the other one :confused:

ursulafiig11:
im so confused with this whole forum thing, i joined last night and i couldnt find the other one :confused:

One way to find your old posts is to search for your username on the forum. Click the magnifying glass top/right and enter your username in the search box that appears.