Email: Password: Remember Me | Create Account (Free)

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
Erik Malund
08/03/05 11:20
Read: 1139 times
Mt Airy, Nc
USA


 
#98778 - 1) no it is not the weekly puzzle, that
Responding to: Craig Steiner's previous message
1) no it is not the weekly puzzle, that is on hold till when and if Craig establishes a format for everybody to submit puzzles.

2) what is wrong is that it will very likely hang you, the solution (sketched in C - same principle should be in asm)
for (timeout = some high number; timeout !=0 ; timeout--)
{
  if (RI) break;
}
if (!RI) timeout_error(HERE); // this routine does not return
else
{
RI = 0;
...
...
}

// this routine does not return
// it reports the error and times the watchdog out to reset the processor
void timeout_error(U8 where){
...
...
Erik

PS note the neat use of the "break" instead of packing all conditions into the for loop. It makes the program soooo much more readable.

List of 39 messages in thread
TopicAuthorDate
Coding competition idea      Craig Steiner      08/01/05 09:26      
   YES!      Jan Waclawek      08/01/05 09:29      
      That would be      Craig Steiner      08/01/05 09:43      
   In progress      Craig Steiner      08/01/05 22:16      
      I have a few, but      Erik Malund      08/02/05 07:19      
         Last post      Steve M. Taylor      08/02/05 08:38      
            C-illiteracy      Jan Waclawek      08/02/05 09:09      
               C-illiterate (non) anonymous      Steve M. Taylor      08/02/05 09:56      
                  Where can I get it?      Ian Bell      08/06/05 08:55      
                     8051, AVR, (ARM ? ) and Rabbit      Steve M. Taylor      08/06/05 10:06      
                        Embedded Pascal et al      Ian Bell      08/07/05 10:20      
                           Modula      Steve M. Taylor      08/07/05 15:05      
         same thing here      Jon Ledbetter      08/02/05 09:06      
         <10k, ???      Jon Ledbetter      08/02/05 09:08      
            not a html tag proble      Erik Malund      08/02/05 14:49      
               Quote problem      Jon Ledbetter      08/02/05 15:12      
                  Escape sequence      Craig Steiner      08/02/05 15:30      
         Derivatives, languages, and voting      Craig Steiner      08/02/05 14:59      
         derivatives      Jan Waclawek      08/02/05 16:25      
            Derivatives      Steve M. Taylor      08/03/05 04:02      
               this is it!      Jan Waclawek      08/03/05 05:50      
                  I can't      Erik Malund      08/03/05 06:51      
               Issues with C challenges      Craig Steiner      08/03/05 06:55      
                  an example      Erik Malund      08/03/05 07:00      
                     I was wrong on both points      Erik Malund      08/03/05 07:13      
                        answer      Jacob Boyce      08/03/05 12:39      
                           actually I do not because ...      Erik Malund      08/03/05 13:20      
                     puzzle?      Jan Waclawek      08/03/05 07:25      
                        Wondering same thhong      Craig Steiner      08/03/05 08:04      
                           1) no it is not the weekly puzzle, that      Erik Malund      08/03/05 11:20      
                              depends on usage      Jan Waclawek      08/03/05 11:40      
                                 yes, but not forever      Erik Malund      08/03/05 12:04      
                                    wait forever      Jan Waclawek      08/03/05 16:09      
                                       Behave people.      Steve M. Taylor      08/03/05 16:15      
                                          That's the good thing      Craig Steiner      08/03/05 17:58      
                     C challenges      Craig Steiner      08/03/05 08:06      
                     Hardware problems      Craig Steiner      08/03/05 14:39      
                  the answer is what gets "marked"      Jan Waclawek      08/03/05 07:22      
                  Null points...      Donald Catto      08/03/05 10:49      

Back to Subject List