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

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
11/24/05 14:45
Read: times


 
#104125 - Debug suggestions
Responding to: ???'s previous message
Hi James,
I have not checked your code but here are some suggestions which you may have already tried.

The DC motor will produce quite high noise spikes, so try de-coupling the DC motor power from the micro and measurement circuits.
Display the signal from your magnetic pulse generator on a cathode ray oscilloscope and look for narrow spikes. If there are spikes filter the signal to get rid of them.

Try reducing the source impedence of the signal from the pulse generator to make it less susceptible to electrical noise.

A simple check to identify what pulses the micro sees is to toggle an I/O pin of the 2051 every time it sees a pulse from your pulse generator. You can now display both these signals on a CRO and there should be a 1:1 relationship.

Make sure that the interrupt is edge triggered and not level triggered.

I suspect you have noise on your signal and the micro is actually counting these and jumping out of the loop prematurely.

Good luck,
Tony


List of 26 messages in thread
TopicAuthorDate
C2051 & Magnetic pulse generator            01/01/70 00:00      
   either i or o            01/01/70 00:00      
      hmmm..but            01/01/70 00:00      
   Debug suggestions            01/01/70 00:00      
   Software Debounce            01/01/70 00:00      
   magnetic pick up tachometers experiences            01/01/70 00:00      
      RE: magnetic pickup tachometer            01/01/70 00:00      
         RS482 - Typo?            01/01/70 00:00      
            darn thumbs            01/01/70 00:00      
         This could be the reason...            01/01/70 00:00      
         bufer amp            01/01/70 00:00      
            why the UG?            01/01/70 00:00      
         pc scopes            01/01/70 00:00      
         could you            01/01/70 00:00      
   What tells the oscilloscope?            01/01/70 00:00      
   Build simple test tools to fix your unit            01/01/70 00:00      
   Excessive rise times during startup?            01/01/70 00:00      
      Good, but even better would be            01/01/70 00:00      
         Full story            01/01/70 00:00      
         thanks, so can I...            01/01/70 00:00      
            yes, if and only if the channel A            01/01/70 00:00      
               cheerz            01/01/70 00:00      
            Time bomb..            01/01/70 00:00      
         Perhaps a little explanation?            01/01/70 00:00      
            setting the hysteresis            01/01/70 00:00      
               Thank, Erik!            01/01/70 00:00      

Back to Subject List