[En-Nut-Discussion] TWI / I2C and DS1307

Henrik Maier henrik at focus-sw.com
Wed Feb 2 12:42:53 CET 2005


Douglas,

I have some working code which was developed independently of NutOS. I 
am using it with an Ethernut 1 compatible hardware containing a DS1307 
RTC. Maybe at some stage I convert it into a NutOS driver and contribute 
it to the Ethernut project. If you are interested, I can send you the 
current files.

Henrik

Douglas Pearless wrote:
> Hi People,
> 
> I have been trying to get a DS1307 on the Ethernut v2 going using the code
> from the TWI project.
> 
> If I send the wrong slave address I get a rc 4 (which is correct)
> 
> When I send the correct slave address I always get a rc=0 for reads and
> writes, BUT they never seem to alter the registers or the RAM correctly.
> 
> I always get the same garbage.
> 
> I use TWInit first, and I have tried setting the speed, and not setting the
> speed.
> 
> Before I tear my remaining hair out, does anyone have some working TWI code
> for a RTC (or anything) that works that they would share?
> 
> Cheers Douglas.
> 



More information about the En-Nut-Discussion mailing list