Part Number: MSP432P401R
Other Parts Discussed in Thread: SYSBIOS
Tool/software: TI-RTOS
G'Day all,
This question is with respect to the attached project.
Its a relatively simple project. The guts of it is a RTOS/Simplelink Timer running with a clock of 1MHz, toggling pin 3.2 every 1.666mSec.
If you load this code into your MSP432 launchpad, connect a scope to pin 3.2 and watch you will see something odd.
Most of the time the pin toggles every 1.666mSec or near enough just as you would expect, but after about 20sec (and every 5sec thereafter) pin 3.2 goes crazy and toggles like mad for about 1.6mSec.
If I break point in testTimer_HWI when everything is working normally, the TAR and TACCR0 registers increment as I expect. For example:
| TAR | TACCR0 |
| 13109 | 14760 |
| 14776 | 16426 |
| 16441 | 18092 |
| 18107 | 19758 |
This makes sense. We are moving on in steps of 1666 counts (1.666mSec on a 1MHz timer). But if I break point when pin3.2 is rapidly toggling I get something more like this
| TAR | TACCR0 |
| 36 | 3322 |
| 98 | 6654 |
| 159 | 9986 |
| 220 | 13318 |
| 282 | 16650 |
| 343 | 19982 |
| 404 | 23314 |
This pattern continues until TACCR0 roles over back to 0, then normal operation resumes. This makes no sense! TACCR0 is incrementing twice as far as it should (3332 instead of 1666) and TAR seems to be moving forward in steps of about 61 instead of 1666.
During this time I also notice in ROV -> Timer(ti.sysbios.family.arm.msp432) -> Device -> Timer_A1 that the "currCount" is negative...
Do you have a suggestion what might be going on here?? You help on this is much appreciated!
Cheers
Julian
/// EDIT - Replaced original project with a simplified one that still exhibits the same problem

