Author Topic: testing MC146818  (Read 2448 times)

0 Members and 1 Guest are viewing this topic.

Offline WawavounTopic starter

  • Regular Contributor
  • *
  • Posts: 81
  • Country: fr
  • Someday I'll get you, Red Baron !
testing MC146818
« on: December 03, 2021, 08:45:53 pm »
Hello there,

I have a MC146818 RTC which did not work !

With a HC49-S 32.768 KHz crystal I have no oscillations on pin 3 and on pin 21 (should be 31.768/4 if pin 22 FS is grounded).

My purpose is to find if the problem come from the chip or from the quartz ???

I have other and different crystals (cylindrical 3x8) and want to test everything on a breadboard to be more sure from where the problem come...

What is the minimal connections to do to get the MC146818 alive with clock output to pin 21 ? VSS, VCC, FS, CE, crystal circuit to pin 2-3 are sufficient ?

Regards.
Philippe
 

Offline srb1954

  • Super Contributor
  • ***
  • Posts: 1091
  • Country: nz
  • Retired Electronics Design Engineer
Re: testing MC146818
« Reply #1 on: December 04, 2021, 07:15:51 am »
Hello there,

I have a MC146818 RTC which did not work !

With a HC49-S 32.768 KHz crystal I have no oscillations on pin 3 and on pin 21 (should be 31.768/4 if pin 22 FS is grounded).

My purpose is to find if the problem come from the chip or from the quartz ???

I have other and different crystals (cylindrical 3x8) and want to test everything on a breadboard to be more sure from where the problem come...

What is the minimal connections to do to get the MC146818 alive with clock output to pin 21 ? VSS, VCC, FS, CE, crystal circuit to pin 2-3 are sufficient ?

Regards.
Philippe
Checking the operation in a breadboard may not be all that successful as the the stray capacitances inherent in breadboards may upset the sensitive oscillator circuitry. Generally is is advisable that all other tracks be kept well away from the crystal and its associated components. In any case strictly follow the recommended circuit configuration in the data sheet and ensure that the crystal load capacitances are as specified by the crystal manufacturer.

The CE, CKFS and RESET pins should be tied high and other input pins AS, DS, R/W, PS and AD0-7 should be tied low for basic oscillator operation producing a 32768Hz signal on CKOUT. The SQW output will not be activated until the chip registers have been suitably programmed.
 

Offline Benta

  • Super Contributor
  • ***
  • Posts: 5869
  • Country: de
Re: testing MC146818
« Reply #2 on: December 04, 2021, 04:57:01 pm »
First time I've heard about a 32.768 kHz crystal in HC49.
Are you sure it's not 32.768 MHz?
 

Offline WawavounTopic starter

  • Regular Contributor
  • *
  • Posts: 81
  • Country: fr
  • Someday I'll get you, Red Baron !
Re: testing MC146818
« Reply #3 on: December 04, 2021, 05:39:49 pm »
Hi,

I have also think to that... I will test the quartz with a simple double 74ls04 gate and see...

 

Online SiliconWizard

  • Super Contributor
  • ***
  • Posts: 14438
  • Country: fr
Re: testing MC146818
« Reply #4 on: December 04, 2021, 05:41:48 pm »
First time I've heard about a 32.768 kHz crystal in HC49.
Are you sure it's not 32.768 MHz?

I second that. I find this fishy. And if it's indeed a 32.768 MHz crystal, that would explain why the MC146818 doesn't oscillate at all.
 

Offline Benta

  • Super Contributor
  • ***
  • Posts: 5869
  • Country: de
Re: testing MC146818
« Reply #5 on: December 04, 2021, 06:45:04 pm »
To add to the above:
I've worked several times with the 146818 using the small tubular 32.768 kHz crystals, and it always worked reliably.
What you need to watch is load capacitance (some crystals need 7.5 pF, others 12 pF), but that's only an issue concerning accuracy, not about oscillator operation.
 

Offline WawavounTopic starter

  • Regular Contributor
  • *
  • Posts: 81
  • Country: fr
  • Someday I'll get you, Red Baron !
Re: testing MC146818
« Reply #6 on: December 04, 2021, 08:22:52 pm »
I made a test (function generator - quartz - oscilloscope connected in serial).

The small tubular quartz show a strong resonance at 32,768 KHz. The HC49-S marked 32.768 show... nothing at this frequency.

So I change the quartz for this one on my assembly but again no clock signal to pin 21 (CKOUT) and the 146818 seems not store correct value in his ram...

Looking at the block diagram CKOUT is only subjected to CKFS state (gnd in my case) pin so whatever is on the bus etc... this clock should be there.

I think now I have to buy and test another 146818.

Regards.
Philippe
 

Offline Benta

  • Super Contributor
  • ***
  • Posts: 5869
  • Country: de
Re: testing MC146818
« Reply #7 on: December 04, 2021, 08:43:13 pm »
Erm... I hope you realise that the oscillator needs external feedback and power limiting resistors?
Like shown on p.9: https://www.nxp.com/docs/en/data-sheet/MC146818.pdf

Drive power for tubular 32 kHz crystals must be <1 uW (yes, that's microwatt).



« Last Edit: December 04, 2021, 08:45:36 pm by Benta »
 

Offline WawavounTopic starter

  • Regular Contributor
  • *
  • Posts: 81
  • Country: fr
  • Someday I'll get you, Red Baron !
Re: testing MC146818
« Reply #8 on: December 04, 2021, 09:09:58 pm »
This is the oscillator assembly :

 

Offline Benta

  • Super Contributor
  • ***
  • Posts: 5869
  • Country: de
Re: testing MC146818
« Reply #9 on: December 04, 2021, 09:24:30 pm »
Why don't you just use the values from the data sheet? I do not see your circuit as "better" in any way. And your resistor values are too low. And the feedback resistor is in the wrong place.

What's so difficult about reading a data sheet?




« Last Edit: December 04, 2021, 09:48:27 pm by Benta »
 

Offline floobydust

  • Super Contributor
  • ***
  • Posts: 6958
  • Country: ca
Re: testing MC146818
« Reply #10 on: December 04, 2021, 09:56:14 pm »
That circuit and values are from the Hitachi HD146818 datasheet, and the circuit looks strange. Output OSC2 with a capacitor CL to GND is for another pole or something  :-//
There is also a MC146818A but I don't know the difference. This RTC chip never performed well in IBM PC-AT, poor accuracy as I recall.
 

Offline Benta

  • Super Contributor
  • ***
  • Posts: 5869
  • Country: de
Re: testing MC146818
« Reply #11 on: December 04, 2021, 10:10:09 pm »
What Hitachi did there is a mystery to me.
I only ever worked with the original Motorola parts.
But it sure looks strange...

 

Offline WawavounTopic starter

  • Regular Contributor
  • *
  • Posts: 81
  • Country: fr
  • Someday I'll get you, Red Baron !
Re: testing MC146818
« Reply #12 on: December 12, 2021, 07:31:53 pm »
Hi there !

Finally I got a new HD146618 and a new MC146818.

Both works well directly at the same place so the crystal circuit etc... is good.
Read and write in memory is also okay.

I just receive a bad rtc chip the first time.

I use the small cylindrical crystal.

Regards and thanks for the help.
Philippe
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf