Stopwatch with Pause/Lap  6 digit 7 seg LED. HELP!

Warren,
I don't think display speed will be a problem. Electricity moves fast! And you are only switching 20mA. If you read the datasheet, time is not mentioned anywhere. The 100's will be a blur, you may be able to make out the tenth' as they change at 10 times a second.

What have you ended up with for a power source?

I don't think display speed will be a problem. Electricity moves fast! And you are only switching 20mA. If you read the datasheet, time is not mentioned anywhere. The 100's will be a blur, you may be able to make out the tenth' as they change at 10 times a second.

Display speed wont be a problem.. when I said "they need to be read at fast speeds" I was referring to the digit size as they will be in pause mode when being read by the rider/driver.

What have you ended up with for a power source?

I haven't sourced one yet.. I am going to use a power drill battery like you suggested before until I can find a good one. I want something slim so I can place it in the middle of the unit and try to keep everything balanced. :slight_smile:
I am going to download your zip now and report back shortly. :slight_smile:

That link isn't working..?? Taking me to "Page Not Found"??? :-/

Hello Warren, please use right mouse button and click on Save target as... The file is all right.

Robert, thank you for your support. Idea is clear at this time. I am ready go up with accuracy - I need 0,001 in my aplication.

Repair: after downloading windows spoke to me that archive is either in unknow format or damage, I use for it WinRar, which have not problem with Zip. Robert which program you are used for it? All package has 1 252 bytes.

David,
http://www.crossroadsfencing.com/stopwatch_22Jan/stopwatch_22Jan.zip

With windows vista, going to this link prompts me to open/save the file. What happens for you?

David,
Should be doable - I use 100uS for my time check intervals:

unsigned long currentMicros = 0; // start of loop interval timer
unsigned long previousMicros = 0; // end of interval?
unsigned long hundred_uS_interval = 100; // = 0.1mS, use 1000 for 1mS
:
:
// ********************************************************************************
// start timing interval
// ********************************************************************************

currentMicros = micros(); // sample the time
if (currentMicros - previousMicros >= hundred_uS_interval) // more than our interval?
{
// save the last time we okayed time updates
previousMicros = currentMicros; // save the current time for next comparison
toggle = 1-toggle; // -> 1-1, 1-0, 1-1, 1-0, results in 0 1 0 1 ...

// do stuff on 0.1mS intervals, 1mS intervals, ets.

I zipped it with this http://www.7-zip.org/

Hi Robert, I got it with this link;
http://www.crossroadsfencing.com/stopwatch_22Jan/stopwatch_22Jan.zip
but not this one;
http://www.crossroadsfencing.com/stopwatch_22Jan.zip

Repair: after downloading windows spoke to me that archive is either in unknow format or damage

I have downloaded and extracted the files fine this time using the new link address from Robert.

I will run it now and let you know how it works.
Warren

Yes, need the whole path :slight_smile:

Thank you Robert. I is running. So I will a little bit change code - output to LCD display and outputs to 485 net. I suppose, that I will not have problem. I suppose, that I will have also next parts for improovements - RTC, temperature.... So thanks again.

Robert... have I ever told you..
Your A STAR!!! [smiley=dankk2.gif]
That is working fantastically!!!! brilliant!
As you can imagine, I am over the moon!

The recall of the memory is working great. I will now have to add another button for 'memory_down' and then write something that will clear the memory when both buttons are pressed together.

You're very welcome Warren.

Why go down? Just hit reset and start readout from 0 again.

Well, if you must go down, replace the top of the memory_read code:

Lap# address1 address2 address3 address4 address5 address6
1 0 1 2 3 4 5
2 6 7 8 9 10 11
3 12 13 14 15 16 17
: : : : : : :
83 492 493 494 495 496 497
84 498 499 500 501 502 503
85 504 505 506 507 508 509
86 510 511 512 513 514 515
// adjust reset # in EEPROM_writing to be 516, from 512

//Memory
//Memory Up Button Here

memory_up_button_state = digitalRead (memory_up_button);

if ((memory_up_button_state == 0 && running == 0)|| EEPROM_reading_up == 1){ // not running - button pushed, or already reading
  if (EEPROM_reading_up == 0){
    EEPROM_reading_up = 1; // enable reading
    //Serial.println ("EEPROM reading up enabled ");
    delay (300); // or set up something with millis() to keep from double reads
  }
}
//Memory Down Button Here (new code)

if ((memory_down_button_state == 0 && running == 0)|| EEPROM_reading_down== 1){ // not running - button pushed, or already reading
  if (EEPROM_reading_down == 0){
    EEPROM_reading_down = 1; // enable reading
    //Serial.println ("EEPROM reading down enabled ");
    delay (300); // or set up something with millis() to keep from double reads

    if (EEPROM_address == 6){
EEPROM_address = 510:
    }
    else{
      EEPROM_address = EEPROM_address -12;
    }

  }
}


if (EEPROM_reading_up == 1 || EEPROM_reading_down == 1){
  switch (byte_to_read){

continue with exisitng EEPROM reading code

If you want to write ( 255? ) to clear the memory with double button press & hold, then will have to come up with something like the pause button with case statements, add in code to read the EEPROM to know when to stop writing, etc.
I was just thinking it would be neat to have the memory up or down button require 2 presses - 1st would display lap number (calculated from the start address being read), 2nd would display the time.

You have to update EEPROM_reading to
EEPROM_reading_up & EEPROM_reading_down in presetup & in the stop/reset area as well, assign new pin #, etc.

Test reply.

That's not supposed to happen!

To make the situation truly annoying, a few days ago I removed some spam from the "read only" area.

:smiley:

Wow - how'd this thread get pulled oved from the old forum?

Let's continue here...
http://arduino.cc/forum/index.php/topic,77658.msg586626.html#msg586626

Good idea - it's a bit spooky in here. XD