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

clock configuration of xmc4100

Greetings,

               sir/madam i am working on xmc4100 after reading the reference manual i am tried to configure the clock (CCU) which was present under system control unit (SCU). my external crystal is 12mhz, i didn't get proper clock at the output. may i know the correct procedure to configure the clock???

Thanks and Regards,

Harshan.

  • I've not worked with XMC4100, but normally when I configure the clock, I do things in this order:

    1. Switch to using the internal clock crystal (so we can work with the external crystal).
    2. Start up the external clock crystal.
    3. Wait until the external clock crystal is ready (a bit is usually set in a hardware register)
    4. Configure the PLL and set the external clock crystal as PLL input clock.
    5. Wait for the PLL to be ready (again a bit is usually set in a hardware register)
    6. Configure the flash wait states; approximately 1 wait-state per 24 MHz (check your reference manual regarding this)
    7. Switch the CPU clock to use the PLL output as input clock.

    That's approximately it. I generally go through all the hardware registers regarding the clock configuration, and ensure that their values are correct.