DS1302 uses Synchronous Serial I/O.

Started by djmaratt February 17, 2005

DS1302 uses Synchronous Serial I/O. So it cannot be directly
connected to the SPI Bus, but there is a way to connect it to SPI
using Tristate buffers.

I found a Bit Banging example of DS1302 interfacing among the files
and was able to get it working.

I hope newer versions of BX24 will include a real time Clock chip
as an integral part as it will help a lot. The bit banging example
has taken away 3 I/O lines. Thanks for help.

Dominic J Maratt


The latest version of the bx-24 have a real time clock
Ii was sort of wondering why you were trying to do this when it alreay had a clock. Now i know ...

From manual vvvv
Real time clock

GetDate Returns the date

GetDayOfWeek Returns the day of week

GetTime Returns the time of day

GetTimestamp Returns the date and time of day

PutDate Sets the date

PutTime Sets the time of day

PutTimestamp Sets the date, day of week and time of day

Timer Returns floating point seconds since midnight -----Original Message-----
From: djmaratt [mailto:]
Sent: Wed 2/16/2005 7:15 PM
To:
Cc:
Subject: [BasicX] DS1302 uses Synchronous Serial I/O. DS1302 uses Synchronous Serial I/O. So it cannot be directly
connected to the SPI Bus, but there is a way to connect it to SPI
using Tristate buffers.

I found a Bit Banging example of DS1302 interfacing among the files
and was able to get it working.

I hope newer versions of BX24 will include a real time Clock chip
as an integral part as it will help a lot. The bit banging example
has taken away 3 I/O lines. Thanks for help.

Dominic J Maratt Yahoo! Groups Links



--- In , "djmaratt" <djmaratt@y...> wrote:
> I hope newer versions of BX24 will include a real time Clock chip
> as an integral part as it will help a lot. The bit banging example
> has taken away 3 I/O lines.

I have successfully used the DS2404S in its 1-wire interface mode.
It has a synchronous serial (3-wire) interface as well. If you were
to use this chip, you'd save not only two I/O lines but also save the
code as well - the System Library 1-wire functions work fine.

Is there a reason why the ShiftIn/ShiftOut wouldn't work with your
chip. I haven't implemented the code but looking at the timing
diagrams (of the DS1302) it looked like that would work.

Don