This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

resetting an STM32F

I'm looking for a way to do a soft reset on a STM32F207. I'm not able to find or compile any of the watch dog examples, I can jump to absolution location but not execute, and most other code samples I find are missing the supporting functions. What is a simple method to reset the chip?

Parents
  • I net reference. Yes should be core_cm3

    but I still get the same errors

    C:\Keil_v5\ARM\PACK\ARM\CMSIS\5.0.1\CMSIS\Include\core_cm3.h(1496): error: #20: identifier "IRQn_Type" is undefined

    _STATIC_INLINE void __NVIC_EnableIRQ(IRQn_Type IRQn)
    C:\Keil_v5\ARM\PACK\ARM\CMSIS\5.0.1\CMSIS\Include\core_cm3.h(1513): error: #20: identifier "IRQn_Type" is undefined

    _STATIC_INLINE uint32_t __NVIC_GetEnableIRQ(IRQn_Type IRQn)
    C:\Keil_v5\ARM\PACK\ARM\CMSIS\5.0.1\CMSIS\Include\core_cm3.h(1532): error: #20: identifier "IRQn_Type" is undefined

    _STATIC_INLINE void __NVIC_DisableIRQ(IRQn_Type IRQn)
    C:\Keil_v5\ARM\PACK\ARM\CMSIS\5.0.1\CMSIS\Include\core_cm3.h(1551): error: #20: identifier "IRQn_Type" is undefined

    _STATIC_INLINE uint32_t __NVIC_GetPendingIRQ(IRQn_Type IRQn)
    C:\Keil_v5\ARM\PACK\ARM\CMSIS\5.0.1\CMSIS\Include\core_cm3.h(1570): error: #20: identifier "IRQn_Type" is undefined

    _STATIC_INLINE void __NVIC_SetPendingIRQ(IRQn_Type IRQn)
    C:\Keil_v5\ARM\PACK\ARM\CMSIS\5.0.1\CMSIS\Include\core_cm3.h(1585): error: #20: identifier "IRQn_Type" is undefined

    _STATIC_INLINE void __NVIC_ClearPendingIRQ(IRQn_Type IRQn)
    C:\Keil_v5\ARM\PACK\ARM\CMSIS\5.0.1\CMSIS\Include\core_cm3.h(1602): error: #20: identifier "IRQn_Type" is undefined

    _STATIC_INLINE uint32_t __NVIC_GetActive(IRQn_Type IRQn)
    C:\Keil_v5\ARM\PACK\ARM\CMSIS\5.0.1\CMSIS\Include\core_cm3.h(1624): error: #20: identifier "IRQn_Type" is undefined

    _STATIC_INLINE void __NVIC_SetPriority(IRQn_Type IRQn, uint32_t priority)
    C:\Keil_v5\ARM\PACK\ARM\CMSIS\5.0.1\CMSIS\Include\core_cm3.h(1628): error: #20: identifier "__NVIC_PRIO_BITS" is undefined

    VIC->IP[((uint32_t)(int32_t)IRQn)] = (uint8_t)((priority << (8U - __NVIC_PRIO_BITS)) & (uint32_t)0xFFUL);
    C:\Keil_v5\ARM\PACK\ARM\CMSIS\5.0.1\CMSIS\Include\core_cm3.h(1632): error: #20: identifier "__NVIC_PRIO_BITS" is undefined

    CB->SHP[(((uint32_t)(int32_t)IRQn) & 0xFUL)-4UL] = (uint8_t)((priority << (8U - __NVIC_PRIO_BITS)) & (uint32_t)0xFFUL);
    C:\Keil_v5\ARM\PACK\ARM\CMSIS\5.0.1\CMSIS\Include\core_cm3.h(1646): error: #20: identifier "IRQn_Type" is undefined

    _STATIC_INLINE uint32_t __NVIC_GetPriority(IRQn_Type IRQn)
    C:\Keil_v5\ARM\PACK\ARM\CMSIS\5.0.1\CMSIS\Include\core_cm3.h(1651): error: #20: identifier "__NVIC_PRIO_BITS" is undefined return(((uint32_t)
    VIC->IP[((uint32_t)(int32_t)IRQn)] >> (8U - __NVIC_PRIO_BITS)));
    C:\Keil_v5\ARM\PACK\ARM\CMSIS\5.0.1\CMSIS\Include\core_cm3.h(1655): error: #20: identifier "__NVIC_PRIO_BITS" is undefined return(((uint32_t)
    CB->SHP[(((uint32_t)(int32_t)IRQn) & 0xFUL)-4UL] >> (8U - __NVIC_PRIO_BITS)));
    C:\Keil_v5\ARM\PACK\ARM\CMSIS\5.0.1\CMSIS\Include\core_cm3.h(1677): error: #20: identifier "__NVIC_PRIO_BITS" is undefined PreemptPriorityBits = ((7UL - PriorityGroupTmp) > (uint32_t)(__NVIC_PRIO_BITS)) ? (uint32_t)(__NVIC_PRIO_BITS) : (uint32_t)(7UL - PriorityGroupTmp);
    C:\Keil_v5\ARM\PACK\ARM\CMSIS\5.0.1\CMSIS\Include\core_cm3.h(1704): error: #20: identifier "__NVIC_PRIO_BITS" is undefined PreemptPriorityBits = ((7UL - PriorityGroupTmp) > (uint32_t)(__NVIC_PRIO_BITS)) ? (uint32_t)(__NVIC_PRIO_BITS) : (uint32_t)(7UL - PriorityGroupTmp);
    C:\Keil_v5\ARM\PACK\ARM\CMSIS\5.0.1\CMSIS\Include\core_cm3.h(1721): error: #20: identifier "IRQn_Type" is undefined

    _STATIC_INLINE void __NVIC_SetVector(IRQn_Type IRQn, uint32_t vector)
    C:\Keil_v5\ARM\PACK\ARM\CMSIS\5.0.1\CMSIS\Include\core_cm3.h(1736): error: #20: identifier "IRQn_Type" is undefined

Reply
  • I net reference. Yes should be core_cm3

    but I still get the same errors

    C:\Keil_v5\ARM\PACK\ARM\CMSIS\5.0.1\CMSIS\Include\core_cm3.h(1496): error: #20: identifier "IRQn_Type" is undefined

    _STATIC_INLINE void __NVIC_EnableIRQ(IRQn_Type IRQn)
    C:\Keil_v5\ARM\PACK\ARM\CMSIS\5.0.1\CMSIS\Include\core_cm3.h(1513): error: #20: identifier "IRQn_Type" is undefined

    _STATIC_INLINE uint32_t __NVIC_GetEnableIRQ(IRQn_Type IRQn)
    C:\Keil_v5\ARM\PACK\ARM\CMSIS\5.0.1\CMSIS\Include\core_cm3.h(1532): error: #20: identifier "IRQn_Type" is undefined

    _STATIC_INLINE void __NVIC_DisableIRQ(IRQn_Type IRQn)
    C:\Keil_v5\ARM\PACK\ARM\CMSIS\5.0.1\CMSIS\Include\core_cm3.h(1551): error: #20: identifier "IRQn_Type" is undefined

    _STATIC_INLINE uint32_t __NVIC_GetPendingIRQ(IRQn_Type IRQn)
    C:\Keil_v5\ARM\PACK\ARM\CMSIS\5.0.1\CMSIS\Include\core_cm3.h(1570): error: #20: identifier "IRQn_Type" is undefined

    _STATIC_INLINE void __NVIC_SetPendingIRQ(IRQn_Type IRQn)
    C:\Keil_v5\ARM\PACK\ARM\CMSIS\5.0.1\CMSIS\Include\core_cm3.h(1585): error: #20: identifier "IRQn_Type" is undefined

    _STATIC_INLINE void __NVIC_ClearPendingIRQ(IRQn_Type IRQn)
    C:\Keil_v5\ARM\PACK\ARM\CMSIS\5.0.1\CMSIS\Include\core_cm3.h(1602): error: #20: identifier "IRQn_Type" is undefined

    _STATIC_INLINE uint32_t __NVIC_GetActive(IRQn_Type IRQn)
    C:\Keil_v5\ARM\PACK\ARM\CMSIS\5.0.1\CMSIS\Include\core_cm3.h(1624): error: #20: identifier "IRQn_Type" is undefined

    _STATIC_INLINE void __NVIC_SetPriority(IRQn_Type IRQn, uint32_t priority)
    C:\Keil_v5\ARM\PACK\ARM\CMSIS\5.0.1\CMSIS\Include\core_cm3.h(1628): error: #20: identifier "__NVIC_PRIO_BITS" is undefined

    VIC->IP[((uint32_t)(int32_t)IRQn)] = (uint8_t)((priority << (8U - __NVIC_PRIO_BITS)) & (uint32_t)0xFFUL);
    C:\Keil_v5\ARM\PACK\ARM\CMSIS\5.0.1\CMSIS\Include\core_cm3.h(1632): error: #20: identifier "__NVIC_PRIO_BITS" is undefined

    CB->SHP[(((uint32_t)(int32_t)IRQn) & 0xFUL)-4UL] = (uint8_t)((priority << (8U - __NVIC_PRIO_BITS)) & (uint32_t)0xFFUL);
    C:\Keil_v5\ARM\PACK\ARM\CMSIS\5.0.1\CMSIS\Include\core_cm3.h(1646): error: #20: identifier "IRQn_Type" is undefined

    _STATIC_INLINE uint32_t __NVIC_GetPriority(IRQn_Type IRQn)
    C:\Keil_v5\ARM\PACK\ARM\CMSIS\5.0.1\CMSIS\Include\core_cm3.h(1651): error: #20: identifier "__NVIC_PRIO_BITS" is undefined return(((uint32_t)
    VIC->IP[((uint32_t)(int32_t)IRQn)] >> (8U - __NVIC_PRIO_BITS)));
    C:\Keil_v5\ARM\PACK\ARM\CMSIS\5.0.1\CMSIS\Include\core_cm3.h(1655): error: #20: identifier "__NVIC_PRIO_BITS" is undefined return(((uint32_t)
    CB->SHP[(((uint32_t)(int32_t)IRQn) & 0xFUL)-4UL] >> (8U - __NVIC_PRIO_BITS)));
    C:\Keil_v5\ARM\PACK\ARM\CMSIS\5.0.1\CMSIS\Include\core_cm3.h(1677): error: #20: identifier "__NVIC_PRIO_BITS" is undefined PreemptPriorityBits = ((7UL - PriorityGroupTmp) > (uint32_t)(__NVIC_PRIO_BITS)) ? (uint32_t)(__NVIC_PRIO_BITS) : (uint32_t)(7UL - PriorityGroupTmp);
    C:\Keil_v5\ARM\PACK\ARM\CMSIS\5.0.1\CMSIS\Include\core_cm3.h(1704): error: #20: identifier "__NVIC_PRIO_BITS" is undefined PreemptPriorityBits = ((7UL - PriorityGroupTmp) > (uint32_t)(__NVIC_PRIO_BITS)) ? (uint32_t)(__NVIC_PRIO_BITS) : (uint32_t)(7UL - PriorityGroupTmp);
    C:\Keil_v5\ARM\PACK\ARM\CMSIS\5.0.1\CMSIS\Include\core_cm3.h(1721): error: #20: identifier "IRQn_Type" is undefined

    _STATIC_INLINE void __NVIC_SetVector(IRQn_Type IRQn, uint32_t vector)
    C:\Keil_v5\ARM\PACK\ARM\CMSIS\5.0.1\CMSIS\Include\core_cm3.h(1736): error: #20: identifier "IRQn_Type" is undefined

Children