1. Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.
    Dismiss Notice

Clock Switching in Pic

Discussion in 'Microcontrollers' started by elecLear78, Jun 6, 2017.

  1. elecLear78

    elecLear78 Member

    Joined:
    Jul 16, 2013
    Messages:
    226
    Likes:
    1
    Location:
    india
    Generally i have seen that on power on the controller is powered ON with internal FRC and then switched to external oscillator. Why it is done? Can i directly switch to oscillator mode?
     
  2. Ian Rogers

    Ian Rogers Super Moderator Most Helpful Member

    Joined:
    Mar 28, 2011
    Messages:
    9,152
    Likes:
    907
    Location:
    Rochdale UK
    You need to be more specific.

    If you power up a micro using the internal OSC then you can switch between ext and int crystals ( if it's supported )

    If you power up with the ext crystal you don't need to switch..
     
  3. elecLear78

    elecLear78 Member

    Joined:
    Jul 16, 2013
    Messages:
    226
    Likes:
    1
    Location:
    india
    Thank you for the reply. Sorry i saw some codes where they were switching from internal clock to external oscillator. So i was little confused i also need to do the same way. Now i understood that i can directly configure for external oscillator. General question is when this clock switching will be useful? can you explain me.
     
  4. dave

    Dave New Member

    Joined:
    Jan 12, 1997
    Messages:
    -
    Likes:
    0


     
  5. Pommie

    Pommie Well-Known Member Most Helpful Member

    Joined:
    Mar 18, 2005
    Messages:
    10,011
    Likes:
    317
    Location:
    Brisbane Australia

    I did a project that monitored some parameters. To increase battery life it used the 32k internal oscillator and once per day it switched to an external crystal to send a report via RS232. The internal 32k clock will use a lot less power than the crystal.

    Mike,
     
  6. atferrari

    atferrari Well-Known Member

    Joined:
    Oct 8, 2003
    Messages:
    2,811
    Likes:
    121
    Location:
    Buenos Aires - Argentina
    ONLINE
    You say that you need to do it and then ask if that would be useful!!

    The switching between clock sources has evolved with time. Please tell what micro you have in mind. And RTFM, first of all.
     
  7. OBW0549

    OBW0549 Member

    Joined:
    Apr 26, 2015
    Messages:
    96
    Likes:
    26
    Location:
    Southeast PA, USA
    You can usually find out all you need to know about PIC oscillator configuration from the data sheet of whatever part you're using; it's almost always covered quite thoroughly.
     

Share This Page