cancel
Showing results for 
Search instead for 
Did you mean: 

Share a single 8Mhz crystal between a 72mhz STM32F3, and 48 mhz STM32F0

bassetteporn11
Associate II
Posted on May 24, 2018 at 08:07

On a board I have stm32f3 and stm32f0, they are close and space is limited, I would like to share a single 8mhz crystal across both mcu, I would like somebody to simply indicate to me proper pinout so I may finish a pcb and debug the software later thank you

I understand that the f3 will have the external crystal connected to it and will drive one of its ouput to a dedicated input pin on the f0, thus the f0 will be receiving a purely digital clock  just as accurate, but wich pins will be involved in this process?

As in this post?

https://electronics.stackexchange.com/questions/15407/whats-the-schematic-to-share-one-crystal-with-two-micros

 
10 REPLIES 10
T J
Lead
Posted on May 24, 2018 at 08:16

this is the recommended way to share a crystal.

0690X0000060KupQAE.png
bassetteporn11
Associate II
Posted on May 24, 2018 at 08:27

Ok I see that my M0 will be receiving something at OSC_IN pin, that covers 1 end of the connection.

But the f3, is it gonna be absolutely 'Master clock output' pin??

T J
Lead
Posted on May 24, 2018 at 08:36

If both processors are on the one PCB,

You could just run one crystal 8MHz on one processor

and from the OSC_out pin, close to the pin, put the 100R-10k resistor feed into the OSC-In on the other processor.

You would better to test the circuit before you lay out the PCB.

only necessary if you have USB peripherals or need the RTC.

Otherwise you don't need either crystal.

bassetteporn11
Associate II
Posted on May 24, 2018 at 08:59

I honestly prefer keeping the crystal circuit intact and just feed from MCO, master clock output, of the correct GPIO pin that performs such a task.

To deal with such and such constraints for the crystal circuit double loading is not what I had in mind.

I already use a 4 PAD SMD passive crystal that is 8mhz and 0.75$.

It seems this is possible and has been done before.

Thus I have contradicting info.

Quote from link

What I have done when I needed to share a clock between micros is to have the crystal drive the oscillator on one micro and then use the oscillator output pin (typically CLKOUT or OSCOUT) from that micro to drive the second micro.

I would expect problems trying to drive two oscillators from the same crystal, if for no other reason than that the capacitance of the long PCB traces required to go between the two processors would cause a malfunction.

________________

Attachments :

cOAQ0.png : https://st--c.eu10.content.force.com/sfc/dist/version/download/?oid=00Db0000000YtG6&ids=0680X000006HxZ0&d=%2Fa%2F0X0000000azv%2FNFvnbcDzINHit8VGEs9PTAmqYNgpboFPxpxK9WIV0kw&asPdf=false
T J
Lead
Posted on May 24, 2018 at 09:15

feed from MCO is the best result

is it divide by two ?

Posted on May 24, 2018 at 08:47

Exactly, I have 2 x usb device across 2x very inexpensive chips. internal oscillator is not accurate enough.

Both MCU's are very close by, a 100r resistor in series is no problem.

OSC out, are you sure?

Posted on May 24, 2018 at 08:54

The loading on OSC_out cannot be capacitive.

a 1k may work just as well, I would try the 1k first.

then lick your finger,

place damp finger on the OscIn of the second processor.

and see if you can stop it easily of not.

The value 100R was recommended in an obscure document.

Posted on May 24, 2018 at 09:46

No, it gives divide by 1.

I just discovered this.

So now, would it be ok to use this mco pin for a 3rd mcu, that is like 4 inches away?

I guess if I run with medium speed rise tme I can use this.

Posted on May 24, 2018 at 09:52

Feeding one MCU from the MCO signal of the other has one disadvantage, as I see it. The second MCU receives it's proper clock signals only when the first has finished it's clock setup. With the ST-Link at the Discoveries/Nucleos, this is usually guaranteed.

This might not pose a problem, though.

Else one could use an external quartz driver chip, to feed both in parallel. Pretty sure those exist (I'm no hardware guy ...)

BTW, 50 is not divisible by 8 without remainder. Just in case you want to use USB or ethernet.