Shop OBEX P1 Docs P2 Docs Learn Events
Why can't you use the PLL when using the XINPUT instead of XTAL ? — Parallax Forums

Why can't you use the PLL when using the XINPUT instead of XTAL ?

BeanBean Posts: 8,129
edited 2012-11-16 16:08 in Propeller 1
We have a 5MHz atomic clock standard at work that I want to use to clock the propeller.

When I specify XINPUT I can't use the PLL to get 80MHz. Is there a reason why this was done ?

For now I am just using XTAL1 even though I am inputting a sine wave into the "XI" pin. It seems to work. Is there anything wrong with doing this ?

Bean

Comments

  • kuronekokuroneko Posts: 3,623
    edited 2012-11-16 05:01
    Bean wrote: »
    When I specify XINPUT I can't use the PLL to get 80MHz. Is there a reason why this was done ?
    IIRC XINPUT|PLL16X ($67) is a valid clock mode. Are you saying it doesn't work in reality?
  • BeanBean Posts: 8,129
    edited 2012-11-16 05:28
    No it doesn't work. Unless I did something wrong... When I get the chance I'll try it again.

    Bean
  • Mike GreenMike Green Posts: 23,101
    edited 2012-11-16 05:39
    XINPUT is designed as a "straight through" mode that bypasses the PLL. As such, it allows clock frequencies from DC to over 80MHz. The PLL modes connect XIN to the PLL, then select a tap on the PLL's divider to use as the system clock. In this case, the maximum input frequency is about 10MHz since the PLL is always running internally at 16x and gets divided down to produce the system clock frequencies and the PLL is good to around 160MHz (although the rest of the Prop is not, so you have to use an appropriate PLL divider tap).

    If you look at the Propeller datasheet, it's quite explicit about using XIN as the input to the PLL from an external oscillator in the PLL modes. You have to use one of the XTALn modes plus a PLL mode (like XTAL1 + PLL16x). If you use XINPUT, you won't be able to use the PLL. You just have to leave XOUT unconnected and, as you've done, connect your external clock to XIN.
  • John80John80 Posts: 4
    edited 2012-11-16 05:46
    I am new to the forum, so I hope I am approaching this the right by replying to your comment.
    I want to incorporate Date and Time into my prop project/device. But it must hold the the data and time for months and years. The device will be battery operated so, I will use a coin cell to hold power when batteries go low or are being replaced, but I don't want time to be lost. Therefore I will need the prop to enter low power mode when turned off. I understand that if I reduce the clock frequency I will reduce power consumption. But if I normally run s 5.00MHz crystal when the device is on how can I suddenly switch to say a 32KHz crystal for low power mode. I cannot use the internal osc as it is not accurate enough... I am trying to avoid having to use an external RTC chip.
  • Mike GreenMike Green Posts: 23,101
    edited 2012-11-16 06:12
    It's against forum rules to post the same message / question in more than one thread. It's also bad form to "hijack" another thread for a different question. Please do not do it again.
  • John80John80 Posts: 4
    edited 2012-11-16 08:37
    My apologies, this was not my intention. I will be more careful in the future.
  • kuronekokuroneko Posts: 3,623
    edited 2012-11-16 16:08
    @Bean: FWIW, according to [thread=127983]this thread[/thread] you should be able to use XINPUT|PLL16X. In this case all slave chips are fed with a 5MHz square wave which is probably your problem as you mentioned a sine wave being used. HTH
Sign In or Register to comment.