Guys, I'm new to Tiva C and was playing around with the hibernation mode to a point where I can't program my board again.
Both CCS and LM Flash Programmer give the same error: Cannot Find Target Device!
Is there any way of doing a hardware reset?
Here's the last code I downloaded into the uC:
#include <stdint.h> #include <stdbool.h> #include "utils/ustdlib.h" #include "inc/hw_types.h" #include "inc/hw_memmap.h" #include "driverlib/sysctl.h" #include "driverlib/gpio.h" #include "driverlib/timer.h" #include "driverlib/pin_map.h" #include "driverlib/debug.h" #include "driverlib/hibernate.h" //***************************************************************************** // // The error routine that is called if the driver library encounters an error. // //***************************************************************************** #ifdef DEBUG void __error__(char *pcFilename, uint32_t ui32Line) { } #endif //***************************************************************************** // // Main 'C' Language entry point. Hibernation Mode in TivaC. // //***************************************************************************** int main(void){ uint32_t ui32SysClock; // // Run from the PLL at 120 MHz. // ui32SysClock = SysCtlClockFreqSet((SYSCTL_XTAL_25MHZ | SYSCTL_OSC_MAIN | SYSCTL_USE_PLL | SYSCTL_CFG_VCO_480), 120000000); SysCtlPeripheralEnable(SYSCTL_PERIPH_GPION); while(!SysCtlPeripheralReady(SYSCTL_PERIPH_GPION)) { } GPIOPinTypeGPIOOutput(GPIO_PORTN_BASE, GPIO_PIN_1); GPIOPinWrite(GPIO_PORTN_BASE, GPIO_PIN_1, 0x02); SysCtlPeripheralEnable(SYSCTL_PERIPH_HIBERNATE); while(!SysCtlPeripheralReady(SYSCTL_PERIPH_HIBERNATE)) { } HibernateEnableExpClk(SysCtlClockGet()); HibernateGPIORetentionEnable(); SysCtlDelay(1200000000); HibernateWakeSet(HIBERNATE_WAKE_PIN); GPIOPinWrite(GPIO_PORTN_BASE, GPIO_PIN_1, 0x00); //HibernateRequest(); while(1){ } }