Arduino

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #581
    laurent
    Member

    hello Mickael

    I would like to know if it is very there that I have to modify the 10 seconds by default of the countdown.

    The part in red

    And I would like to know the tension of functioning of the buzzer? it’s 2v ?

    The time is good in milliseconds?? 1 secondes = 1000 ??

    thank you..
    **********************************************************************************

    // Reset back to the last second boundary so we can start the countdown
    // immediately and so that the first second isn’t truncated
    TCNT1 = TIMER1_SECOND_START;

    beep(3800, 30);
    digitalWrite(LED_DET, ledCurrentState);
    while ((countdownSeconds > 0) && (!defused)) {
    for(int i=0;i<10000;i++) { //10000 represent 10 seconds?
    // get input
    if (digitalRead(defusePin) == HIGH) {
    defused = true;
    break;
    }
    if (digitalRead(detPin) == HIGH) {
    countdownSeconds = 0;
    break;
    }
    }
    delay(20);
    if (ledCounter++ > ledCounterThreshold) {
    ledCounter = 0;
    if (ledCurrentState == HIGH) {
    ledCurrentState = LOW;
    } else {
    ledCurrentState = HIGH;
    }
    digitalWrite(LED_DET, ledCurrentState);
    }
    }
    digitalWrite(LED_DET, LOW);
    countdownRunning = false;
    if (!defused) {
    detonate();
    } else {
    beep(4500, 80);
    delay(2000);
    displayCountdown = false;
    }

    #1312
    Michael
    Keymaster

    Laurent,

    The default countdown of 10 seconds is defined here:

    #define COUNTDOWN_DURATION 10

    You can change that.

    The buzzer is driven by a 5V PWM square wave.

    #1313
    laurent
    Member

    thank you …mickael…

    I finished my 1st version of my “bomb”

    I would make another “bomb” soon, even more beautiful..

    Merry christmas and good year Mickael

    #1314
    Michael
    Keymaster

    Merry Christmas and Happy New Year, Laurent. Your project looks wonderful! Great job.

    #2155
    arham
    Member

    yep, we started calling it the burrito because as we were building it, everyone kept calling it the “bomb” and I didn’t want any extra “attention” called to us (as i am sure you have experienced). I dont have it with me right now, but hopefully later on this week or next I can get a good picture for you.

    Thanks again for making this open source!

    __________________
    http://www.solitairecardgame.info

Viewing 5 posts - 1 through 5 (of 5 total)
  • You must be logged in to reply to this topic.