RTC inside the case?

The one thing that would make the PicoCalc perfect for me would be to have an RTC attached (I have the Pico 2W in mine now). Has anyone looked at doing this? I think I’d have to solder to some of the headers to make it work, which is okay.

4 Likes

I installed the D3231 module. No problems.

12 Likes

Will this automatically be picked up by MMBasic without any code changes ?

MMBASIC includes settings for using the RTC.
If you properly wire the I2C SDA and SCL to the RTC module, you can use the “rtc gettime” and “option rtc auto enable” commands without modifying the source code.

9 Likes

The “option rtc auto enable” command is a setting that automatically executes the “rtc gettime” command at startup. Once set, the setting will remain enabled even if the power is turned off.

2 Likes

Ordered thanks yet couldnt find one without pins already soldered :roll_eyes:. Big shame clockwork didnt include this on the mainboard plus some kind of easy internal access to unused I/O and mounts/slots for additional modules…

The one I used had a pin header, but I removed it.
Also, please note that the battery is a rechargeable LIR2032.

2 Likes

Rechargeable !, good idea :smiling_face_with_sunglasses:

Will this charge in situ or slowly discharge ??

It may be due to the charging circuit of the RTC module, but it seems to charge slowly.

I used the pins on the outside of the Picocalc. Unfortunately, the Picocalc says:“rtc not responding”. But what am I doing wrong?

Which pins did you use?

I used GP2/SDA and GP3/SCL

did you check you get correct power?

Yes of course, the red LED on the RTC is flashing. I also tried another RTC modul but no change

Maybe the ports you are using are configured by software to do something else? Did you try a different SDA / SCL port as it seems there are several? I should have my Pico / RTC soon then I can also try but for now I have only ideas I cannot test…

1 Like

I found out that I2C is set to GP6 and GP7 in the settings. However, they aren’t routed to the external sockets. So, I have to solder them internally after all. I’ll do that tomorrow. You can see it also in the screenshot below

1 Like

Beware many DS3231 modules do NOT charge rechargeable batteries (see DS3231 data sheet that mentions protection from reverse charging of lithium cells). Also a standard lithium.battery should last in the region of ten years in normal use whereas a rechargeable might only last 3 hence little logic in using them in this situ. Older modules had a very crude charging circuit that was dangerous.

1 Like

I mentioned that rechargeable batteries are required because many of the RTC modules available in Japan have built-in charging circuits.
Note that when using a CR2032 battery with an RTC module that has a built-in charging circuit, the diode in the charging circuit must be removed.

1 Like