TI E2E Community
Tiva™ ARM® Microcontrollers
Tiva™ ARM® C Series Microcontrollers Forum
Please can someone with experience with watchdog1(using PIOSC) assist me?
I am using watchdog0 and watchdog1 with a NMI in my application for added safety. I can easily get watchdog0 to run, but watchdog1 hangs the micro during the initialisation code. The odd thing is that when I run this code with the debugger connected, both watchdogs are initialised and run correctly, without the debugger the code gets stuck (and neither watchdog causes a reset). I have tested and know for sure that watchdog1 is being the bad dog here.
Below is my initialisation code for watchdog1. What have I missed here, do I need to do anything else special with PIOSC clock settings?
LM4F232H5QC @50MHz (system clock)
while(!HWREGBITW(&WATCHDOG1_CTL_R, 31)); //wait for WRC to clear
I'm sorry for the delay in answering your question. It slipped through the cracks somehow.
I'm not totally sure what is going on, but my guess is it has something to do with the check for the write complete (as you don't use that for watchdog 0 and watchdog 0 works fine).
Along those lines, I have some thoughts:
What a great responding post! (believe you got it - but great even w/possible hiccup) Happy Easter...
Thanks for the response.
To answer your questions:
Hi Sue, I have tried the last two suggestions and I still haven't had any luck getting watchdog1 to properly work without the debugger. I'm stumped
I spoke to one of the software engineers, and he believes that when you are using StellarisWare APIs to run the watchdog, you don't need to check the WRC bit because there is enough delay built into the calls. Try removing the lines that check this bit and see what happens.
Hi Sue, I just tried that now, still no luck...
I just took the watchdog example that comes with the EK-LM4F232 board and I modified it to use watchdog 1 instead of watchdog 0. I also changed the clock to 50 MHz instead of 16 MHz. The software works on my board without using the debugger. Please try this experiment yourself on your EK and let me know what your results are.
I have another test for you to try. Using your original software, try enabling ADC0 or SSI0 using SysCtlPeripheralEnable function prior to configuring watchdog 1. Please let me know what your results are.
Ok I just tried enableing ADC0 and now Watchdog1 is working! Is this a silicon errata? Please can you explain why this made it work and what the implications are.
Yes, I believe you have discovered a silicon erratum. We are investigating and I expect this issue to be included in the next errata release. Basically, in order to use watchdog 1, you have to enable the clock to another module that can use the PIOSC as a clock (UART, SSI, ADC). I'm sorry for your difficulties.
Thanks for the help and feedback,much appreciated!
Is there anyways you could give me a heads up or email me the new Errata sheet as soon as it is available?
There is a link on the product page (http://www.ti.com/product/lm4f230e5qr) that you can use to set up alerts anytime the information on the page is updated:
All content and materials on this site are provided "as is". TI and its respective suppliers and providers of content make no representations about the suitability of these materials for any purpose and disclaim all warranties and conditions with regard to these materials, including but not limited to all implied warranties and conditions of merchantability, fitness for a particular purpose, title and non-infringement of any third party intellectual property right. TI and its respective suppliers and providers of content make no representations about the suitability of these materials for any purpose and disclaim all warranties and conditions with respect to these materials. No license, either express or implied, by estoppel or otherwise, is granted by TI. Use of the information on this site may require a license from a third party, or a license from TI.
TI is a global semiconductor design and manufacturing company. Innovate with 100,000+ analog ICs andembedded processors, along with software, tools and the industry’s largest sales/support staff.