• AVR Freaks

Hot!Microchip Datasheets and the Intenal RC Clock Frequency?

Author
arigead
Super Member
  • Total Posts : 445
  • Reward points : 0
  • Joined: 2011/02/07 06:58:31
  • Location: 0
  • Status: offline
2020/09/18 03:55:22 (permalink)
0

Microchip Datasheets and the Intenal RC Clock Frequency?

This is general to all Microchip Datasheets. Perhaps it's just me but where, and why, is the frequency of the Internal RC oscillator hidden in the datasheet.
Various micro-controller interfaces need accurate timings, even if it's just UART comms to enable some sort of serial logging with a printf function. There's a whole chapter in the datasheets about the oscillators and their configuration, PLLs, types of oscillator which can be connected, configuration bits.... But when you just spin up a Micorcontroller on a bread board to test it out and want to simply use the internal RC for the moment. What is it's frequency?
 
#pragma config FNOSC = FRC
 
So the datasheet never generally says so what's the best way of finding out? Time a Nop()? Then how long is a Nop(), in terms of instruction cycles? Be a whole lot simpler if Data sheet just said what frequency the internal RC was.
#1

11 Replies Related Threads

    arigead
    Super Member
    • Total Posts : 445
    • Reward points : 0
    • Joined: 2011/02/07 06:58:31
    • Location: 0
    • Status: offline
    Re: Microchip Datasheets and the Intenal RC Clock Frequency? 2020/09/18 04:17:35 (permalink)
    0
    Think I calculated it with the UART as 7,600,000 Hz or 7.6MHz so sorted, but be handy if Datasheet said.
    #2
    JPortici
    Super Member
    • Total Posts : 1174
    • Reward points : 0
    • Joined: 2012/11/17 06:27:45
    • Location: Grappaland
    • Status: offline
    Re: Microchip Datasheets and the Intenal RC Clock Frequency? 2020/09/18 04:30:07 (permalink)
    0
    arigead
    Perhaps it's just me



    It's you.
     
    which part?
     
    for example: dsPIC33EV256GM106. Datasheet revision G (current at the time of writing). You will see the internal FRC frequency and/or accuracy mentioned at least in these places:
    -Front Page, Clock management (mid page).
    -Chapter 9, Register 9-4 OSCTUN
    -Electrical Characteristics, Table 30-19 and 30-20
     
    From memory:
    dsPIC30F, 4MHz FRC
    dsPIC33E/dsPIC33F 7.37 MHz - don't remember the reason
    dsPIC33C 8MHz
    post edited by JPortici - 2020/09/18 04:34:24
    #3
    ric
    Super Member
    • Total Posts : 28660
    • Reward points : 0
    • Joined: 2003/11/07 12:41:26
    • Location: Australia, Melbourne
    • Status: online
    Re: Microchip Datasheets and the Intenal RC Clock Frequency? 2020/09/18 04:53:04 (permalink)
    0
    arigead
    So the datasheet never generally says so what's the best way of finding out? Time a Nop()? Then how long is a Nop(), in terms of instruction cycles? Be a whole lot simpler if Data sheet just said what frequency the internal RC was.

    Maybe it does, but if you won't reveal which PIC => which datasheet, how can anyone help you find it?
     

    I also post at: PicForum
    Links to useful PIC information: http://picforum.ric323.co...opic.php?f=59&t=15
    NEW USERS: Posting images, links and code - workaround for restrictions.
    To get a useful answer, always state which PIC you are using!
    #4
    du00000001
    Just Some Member
    • Total Posts : 3978
    • Reward points : 0
    • Joined: 2016/05/03 13:52:42
    • Location: Germany
    • Status: offline
    Re: Microchip Datasheets and the Intenal RC Clock Frequency? 2020/09/18 08:36:04 (permalink)
    0
    All datasheets I used until now state the frequency as well as the tolerance.
     
    If your English is not the best, you can still search for "MHz"  :)

    PEBKAC / EBKAC / POBCAK / PICNIC (eventually see en.wikipedia.org)
    #5
    T Yorky
    Super (Thick) Member
    • Total Posts : 569
    • Reward points : 0
    • Joined: 2012/08/28 02:07:35
    • Location: UK
    • Status: offline
    Re: Microchip Datasheets and the Intenal RC Clock Frequency? 2020/09/18 15:02:05 (permalink)
    0
    @ JPortici, the 7.37 MHz is actually around 7.373 which is an integer multiple for creating BAUD rates 9600, 19200 and so on.
    T Yorky.
    #6
    du00000001
    Just Some Member
    • Total Posts : 3978
    • Reward points : 0
    • Joined: 2016/05/03 13:52:42
    • Location: Germany
    • Status: offline
    Re: Microchip Datasheets and the Intenal RC Clock Frequency? 2020/09/18 16:07:06 (permalink)
    0
    Whether 7.37, 7.373 or 7.3728 MHz hardly matters considering a 1 % tolerance margin.
    UART communication has a tolerance margin of 5 %, so this doesn't really matter.

    PEBKAC / EBKAC / POBCAK / PICNIC (eventually see en.wikipedia.org)
    #7
    arigead
    Super Member
    • Total Posts : 445
    • Reward points : 0
    • Joined: 2011/02/07 06:58:31
    • Location: 0
    • Status: offline
    Re: Microchip Datasheets and the Intenal RC Clock Frequency? 2020/09/19 09:46:40 (permalink)
    0
    As I said in the follow up email that I'd reverse engineered the Internal RC by configuring a UART and calculating the frequency, of the Internal RC. So I figured it out. Another response, from Jack_M listed all the places the information is, including the first page of the datasheet. For the dsPIC33EP128GS702 datasheet, (DS70005258C) it's not there, but the suggestion on Register 9-4 OSCTUN is a good one. I'll have to remember that one.
     
    I'd consider that almost buried in the document. I'd expect it at least in the introduction to the Oscillator Configuration section. It's probably not important info as everyone would use a crystal. It's just because I was prototyping on a bread board that I went chasing it.
     
    Thanks for the pointers to the info.
    #8
    arigead
    Super Member
    • Total Posts : 445
    • Reward points : 0
    • Joined: 2011/02/07 06:58:31
    • Location: 0
    • Status: offline
    Re: Microchip Datasheets and the Intenal RC Clock Frequency? 2020/09/19 09:47:03 (permalink)
    0
    As I said in the follow up email that I'd reverse engineered the Internal RC by configuring a UART and calculating the frequency, of the Internal RC. So I figured it out. Another response, from Jack_M listed all the places the information is, including the first page of the datasheet. For the dsPIC33EP128GS702 datasheet, (DS70005258C) it's not there, but the suggestion on Register 9-4 OSCTUN is a good one. I'll have to remember that one.
     
    I'd consider that almost buried in the document. I'd expect it at least in the introduction to the Oscillator Configuration section. It's probably not important info as everyone would use a crystal. It's just because I was prototyping on a bread board that I went chasing it.
     
    Thanks for the pointers to the info.
    #9
    arigead
    Super Member
    • Total Posts : 445
    • Reward points : 0
    • Joined: 2011/02/07 06:58:31
    • Location: 0
    • Status: offline
    Re: Microchip Datasheets and the Intenal RC Clock Frequency? 2020/09/19 09:47:13 (permalink)
    0
    As I said in the follow up email that I'd reverse engineered the Internal RC by configuring a UART and calculating the frequency, of the Internal RC. So I figured it out. Another response, from Jack_M listed all the places the information is, including the first page of the datasheet. For the dsPIC33EP128GS702 datasheet, (DS70005258C) it's not there, but the suggestion on Register 9-4 OSCTUN is a good one. I'll have to remember that one.
     
    I'd consider that almost buried in the document. I'd expect it at least in the introduction to the Oscillator Configuration section. It's probably not important info as everyone would use a crystal. It's just because I was prototyping on a bread board that I went chasing it.
     
    Thanks for the pointers to the info.
    #10
    arigead
    Super Member
    • Total Posts : 445
    • Reward points : 0
    • Joined: 2011/02/07 06:58:31
    • Location: 0
    • Status: offline
    Re: Microchip Datasheets and the Intenal RC Clock Frequency? 2020/09/19 09:50:13 (permalink)
    0
    Thank you all for the responses, as I said in the follow up email, I managed to work out the Internal RC by configuring a UART and calculating the frequency. So I figured it out. Another response, from Jack_M listed all the places the information is, including the first page of the datasheet. For the dsPIC33EP128GS702 datasheet, (DS70005258C) it's not there, but the suggestion on Register 9-4 OSCTUN is a good one. I'll have to remember that one.
     
    I'd consider that almost buried in the document. I'd expect it at least in the introduction to the Oscillator Configuration section. It's probably not important info as everyone would use a crystal. It's just because I was prototyping on a bread board that I went chasing it.
     
    Thanks for the pointers to the info.
    #11
    ric
    Super Member
    • Total Posts : 28660
    • Reward points : 0
    • Joined: 2003/11/07 12:41:26
    • Location: Australia, Melbourne
    • Status: online
    Re: Microchip Datasheets and the Intenal RC Clock Frequency? 2020/09/19 16:14:40 (permalink)
    4 (1)
    If I wanted to know the FRC speed and accuracy, the FIRST place I would look would be in the "Electrical Specifications" chapter, under "AC specifications.".
     http://ww1.microchip.com/downloads/en/DeviceDoc/dsPIC33EPXXXGS70X-80X-Family-Data-Sheet-DS70005258C.pdf#page=394 

    Funnily enough that's where I found it, under "TABLE 30-20: INTERNAL FRC ACCURACY" on page # 394.
     

    I also post at: PicForum
    Links to useful PIC information: http://picforum.ric323.co...opic.php?f=59&t=15
    NEW USERS: Posting images, links and code - workaround for restrictions.
    To get a useful answer, always state which PIC you are using!
    #12
    Jump to:
    © 2020 APG vNext Commercial Version 4.5