This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

UCD3138: Reset operation in EMC noise environment

Part Number: UCD3138
The output of the DCDC converter stopped and the UCD3138 reset during use in a EMC noisy environment. When I checked the register of SYSESR after reboot, it was 0x0000.
According to Technical Reference 11.20 System Fault Recovery Basics, "if a reset occurs and none of the bits are set, then the cause is the watchdog timer."
However, because the register Watchdog Control (WDCTRL) is set to Default *), reset by watch dog timer should not work.

 

1.  Even if the register Watchdog Control (WDCTRL) is set to Default *), does Reset by the Watchdog timer occur?

2. If the register Watchdog Control (WDCTRL) is set to Default *), may there be a reset that causes SYSESR to be 0x0000?

3. If you have a concrete example, please advise.

4. If the register Watchdog Control (WDCTRL) is set to Default*) and the CPU freezes, can the peripheral, DPWM module continue operating?

 *) CPU_RESET_EN: 0: Watchdog Reset does not reset CPU.

  • Normally you should see a 1 in the bit for power on reset, because this gets set on the first power up of the device.  

    You should see this bit set unless you are clearing it.  

    To clear these bits, you write a 0 to the bit.  

    Are you clearing the bits?  

    If you are not clearing the power on reset bit, something strange is happening.  Maybe you are not reading the right address somehow?  

    Are you using the memory debugger or JTAG?  I've seen the memory debugger read the incorrect location on 064, and 128 devices because of bad conversion of code from the base 3138, but I've never seen it go wrong with the 3138.  

    I assume that since you are reading the system register that you are in ROM mode?  Generally the memory debugger doesn't read the SYSESR register in program flash mode?

    It's possible that the value is really a zero, although I've never seen it.  It's not really possible to predict what noise will do to the logic.  

    Please check my other suggestions first.  

  • Thank you for your reply.


    The value of SYSESR register is copied to RAM after power ON reset.
    The RAM value is written in Flash to remain the startup log. In order to reproduce the situation 0x0000, the following reproduction was performed with the evaluation board (UCD3138PSFBEVM-027).

    I ran the program with a debugger, entered suspend in the middle, wrote 0x00000000 to the whole area of ​​RAM, and when I started it again,

    Then, software jumped to the start vector and confirmed that the log of SYSESR was 0x0000. Is it possible to jump to the start vector by forcibly writing 0x00000000 to the RAM value?

  • If you suspend the program in the middle of execution and then clear all the RAM, you will effectively set all of the stack to zero.  Often when you are running, you will be in an interrupt and/or a function, both of which are called and have their return addresses stored in RAM on the stack.  Whenever those programs return, they will use the stack value to return to.  So if you have written all zeroes to the stack, they will certainly go to location 0, which is the start vector.  The stack is also used for temporary variables, and to store other values pushed from higher level functions which have called lower level function.  And, of course things like all the variables used by the current function are also stored in RAM

    So it is impossible to predict what will happen when you do what you describe.  It's not a good debugging technique.  It's a very good way to get confused.  

  • Its been a week since I replied to your last question, so I'm going to assume this is resolved.  If you have more questions, please open a new thread.