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

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
03/16/07 09:46
Read: times


 
#135090 - Sorry - not this time, Jez
Responding to: ???'s previous message
Jez Smith said:
For short delays the overhead for setting up a hardware timer is too much compared to the overall delay time.

Sure - but there are well known techniques to stop 'C' compilers from optimising such loops; eg, see Christoph's post: http://www.8052.com/forumchat/read.phtml?id=135084

And, of course, even if the compiler leaves the loop in place you have absolutely no guarantee whatsoever that the timing will remain the same even between builds.

This dead-horse has been beaten beyond death almost as much as the old 8255...

A man of your calibre should know this!

Anyway i know it is just the way things work but I am right and everyone else is wrong ;P~~~~

Sorry - not this time, Jez




List of 19 messages in thread
TopicAuthorDate
akkkk! stupid compilers, something to watch            01/01/70 00:00      
   ehm, isn't it the user?            01/01/70 00:00      
      Well it might be phooey;- but its pretty common            01/01/70 00:00      
         have you considered using a timer, perhaps... :-)            01/01/70 00:00      
            yep but...            01/01/70 00:00      
               Sorry - not this time, Jez            01/01/70 00:00      
               if it is THAT short...            01/01/70 00:00      
                  Maybe not...            01/01/70 00:00      
                  Beware.            01/01/70 00:00      
   Well, any compiler with half a brain does that.            01/01/70 00:00      
      volatile            01/01/70 00:00      
   use util/delay.h and read the lib documents            01/01/70 00:00      
   optimization = lost control            01/01/70 00:00      
   well that is the first mistake            01/01/70 00:00      
      First mistake is using a HLL            01/01/70 00:00      
   Optimise & kill code            01/01/70 00:00      
      optimizers and NASA            01/01/70 00:00      
   There are many levels in Keil            01/01/70 00:00      
      not always a good idea            01/01/70 00:00      

Back to Subject List