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

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
01/21/10 18:32
Modified:
  01/21/10 18:35

Read: times


 
#172644 - Have you tried doing this in ASM?
Responding to: ???'s previous message
If you break the code into segments, each having the function as desired, but not as the compiler does it, perhaps you can isolate the fault. If the ASM code works as desired, yet the compiled code doesn't then it's likely that the compiler is broken (probably setup). OTOH, if it fails to function as it should when written in ASM, I'd say it points to broken hardware.

I can't imagine a healthy MCU failing to generate the correct sequence in a loop such as yours, but it's not clear what else may be going on that could modify the value of your index. If you take out the loop and rewrite it in ASM, then both simulate and run the thing on an MCU as naked as can actually test your function, that will certainly shed some light. Of course, a 'scope/logic analyzer might help, too. It's all about "divide and conquer." This is, of course, as much about confidence-building as about debugging.

RE




List of 30 messages in thread
TopicAuthorDate
Simulation vs. Embedded Discrepancy            01/01/70 00:00      
   Hardware fault?            01/01/70 00:00      
      Responding to: Andy Neil's previous message            01/01/70 00:00      
   illustration of edge difference?            01/01/70 00:00      
      SPI Phase/Polarity            01/01/70 00:00      
         address instead of value            01/01/70 00:00      
            Doesn't seem coincidental            01/01/70 00:00      
               MOVX command fails            01/01/70 00:00      
                  Definitely sounds like a hardware fault!            01/01/70 00:00      
                  Have you tried doing this in ASM?            01/01/70 00:00      
                     The loop in ASM            01/01/70 00:00      
                        I think...            01/01/70 00:00      
                        Sounds like hardware again            01/01/70 00:00      
                           If this were reduced to the essentials ...            01/01/70 00:00      
                              Oh Richard            01/01/70 00:00      
                        What I was after ...            01/01/70 00:00      
                           Reducing to Essentials            01/01/70 00:00      
                              RE: Magic Switch On The Compiler            01/01/70 00:00      
                                 Emulator trace            01/01/70 00:00      
                                    Yes            01/01/70 00:00      
                                       SOLVED            01/01/70 00:00      
                                          A bit ocnfused            01/01/70 00:00      
                                             Emulator and AUXR            01/01/70 00:00      
                                                Things do tend to work best...            01/01/70 00:00      
   one guess with a question            01/01/70 00:00      
      Memory has plenty of gaps            01/01/70 00:00      
         That doesn't make sense!            01/01/70 00:00      
            Sloppy language on my part            01/01/70 00:00      
      Am I missing something            01/01/70 00:00      
      questions/request            01/01/70 00:00      

Back to Subject List