Skip to main content
Visitor II
December 13, 2010
Question

Configurable clock output

  • December 13, 2010
  • 3 replies
  • 819 views
Posted on December 13, 2010 at 20:41

I would like some information on configuring Port E0 to be a clock output of 4Mhz. Is their an example someplace.

charles

    This topic has been closed for replies.

    3 replies

    Visitor II
    December 18, 2010
    Posted on December 18, 2010 at 09:51

    // configures CPU clock @4 MHz

    CLK_HSIPrescalerConfig(CLK_PRESCALER_HSIDIV1);

    (, , );

    (

    );

    ();

    Visitor II
    December 20, 2010
    Posted on December 20, 2010 at 17:10

    Hi brazov,

    I am not sure but I think that the HSI oscillator is set to 16 MHz so we need to do the following config in order to output 4 MHz on CCO pin:

    CLK_HSIPrescalerConfig(CLK_PRESCALER_HSIDIV4);

    instead of

    CLK_HSIPrescalerConfig(CLK_PRESCALER_HSIDIV1);

    What do you think ?

    Regards,

    MCU Lüfter

    Visitor II
    December 21, 2010
    Posted on December 21, 2010 at 15:22

    yes for sure, it was a typo error