Home
JAQForum Ver 24.01
Log In or Join  
Active Topics
Local Time 02:22 17 Aug 2025 Privacy Policy
Jump to

Notice. New forum software under development. It's going to miss a few functions and look a bit ugly for a while, but I'm working on it full time now as the old forum was too unstable. Couple days, all good. If you notice any issues, please contact me.

Forum Index : Microcontroller and PC projects : CMM2G2 won't remember time/date...

Author Message
Grogster

Admin Group

Joined: 31/12/2012
Location: New Zealand
Posts: 9626
Posted: 01:59am 14 Aug 2025
Copy link to clipboard 
Print this post

Hi all - anyone heard of this?
DS3231 chip installed.

I put a CR2032 in the battery holder.
Did "option ds3231 on"
It always asks me for date and time on any restart.
Date and time is not correct on display.
Any idea what is wrong?

Perhaps I am missing something, but I thought all you had to do, was tell the G2 that it had the RTC chip, and provided you plopped a battery in the holder, it would always update the RTC at power-on.

Have I missed another command perhaps?
Smoke makes things work. When the smoke gets out, it stops!
 
vegipete

Guru

Joined: 29/01/2013
Location: Canada
Posts: 1138
Posted: 03:37am 14 Aug 2025
Copy link to clipboard 
Print this post

Odd, the CMM2G2s I've been preparing recently have needed no extra setup commands, other than the keyboard, time and date requests that happen automajically the first time the device boots. That is with firmware version 5.07.02b11 and G2 PCB version 2.1.

If the board has no 2032 installed, I get the keyboard/time/date request everytime it powers on. Maybe you have a battery circuit fault?
Visit Vegipete's *Mite Library for cool programs.
 
Volhout
Guru

Joined: 05/03/2018
Location: Netherlands
Posts: 5138
Posted: 05:54am 14 Aug 2025
Copy link to clipboard 
Print this post

Or… the rtc chip is dus, or solderend in upside down..

Volhout
PicomiteVGA PETSCII ROBOTS
 
Grogster

Admin Group

Joined: 31/12/2012
Location: New Zealand
Posts: 9626
Posted: 06:30am 14 Aug 2025
Copy link to clipboard 
Print this post

So.....can the members confirm that I have NOT missed an important command or step, and that it SHOULD be working based on what I have done?

I'm expecting another batch of boards any day now, so I will see if those have any problem.

CR2032 battery voltage is 3.10v, so I don't think that is the problem.
Smoke makes things work. When the smoke gets out, it stops!
 
PhenixRising
Guru

Joined: 07/11/2023
Location: United Kingdom
Posts: 1437
Posted: 08:48am 14 Aug 2025
Copy link to clipboard 
Print this post

Don't have a G2 but my G1 works fine.

The problem that I have is that; I haven't found a way to switch-off the prompts for time, date, KB, etc. when there is no/dead battery.
 
Mixtel90

Guru

Joined: 05/10/2019
Location: United Kingdom
Posts: 7997
Posted: 09:10am 14 Aug 2025
Copy link to clipboard 
Print this post

I don't think you can. It assumes that you will need a RTC to time stamp files so it prompts you when you boot up and uses the on-chip clock. MSDOS does the same IIRC. That makes sense if you are thinking of the CMM2 as a computer rather than a controller.
.
Edited 2025-08-14 19:11 by Mixtel90
Mick

Zilog Inside! nascom.info for Nascom & Gemini
Preliminary MMBasic docs & my PCB designs
 
PhenixRising
Guru

Joined: 07/11/2023
Location: United Kingdom
Posts: 1437
Posted: 10:07am 14 Aug 2025
Copy link to clipboard 
Print this post

  Mixtel90 said  MSDOS does the same IIRC. That makes sense if you are thinking of the CMM2 as a computer rather than a controller.
.


Autoexec.bat suppresses it and I thought that I'd achieved similar on the CMM2. IIRC, my program ran but the prompts showed-up later.

Hmmm I need to test again because maybe I can live with that.
 
Mixtel90

Guru

Joined: 05/10/2019
Location: United Kingdom
Posts: 7997
Posted: 10:20am 14 Aug 2025
Copy link to clipboard 
Print this post

I often get confused now. I'm more used to the PicoMite than the CMM2 and I tend to forget what's possible. Also, my CMM2 manual is way out of date! The two machines, although sharing a lot of commands now, are entirely different hardware and work very differently in most cases.

If you are using a CMM2 as a controller then on boot it will have to load your program from SD card, tokenize it then run it, it's not already there in flash. I can't remember how this is automated though. I'm pretty certain that testing for a RTC happens first though, so the system will pause until the time and date is valid. That might be necessary in order to get the latest version of the program from the SD card.

Sorry, my memory on this is *very* patchy now. :)
Mick

Zilog Inside! nascom.info for Nascom & Gemini
Preliminary MMBasic docs & my PCB designs
 
zeitfest
Guru

Joined: 31/07/2019
Location: Australia
Posts: 588
Posted: 10:51am 14 Aug 2025
Copy link to clipboard 
Print this post

  Quote  Date and time is not correct on display.



Is it setting/reading the chip OK ? Maybe check the I2C has
a good connection. If you can set and read the time OK at least once
it points to a bad backup battery connection. But if the displayed
time is always corrupt I'd think it is a I2C problem.

edit - Of course, check the 3231 pins, eg the backup cell pin for the 3v and also the two I2C pins for being held high.
Edited 2025-08-14 20:57 by zeitfest
 
PhenixRising
Guru

Joined: 07/11/2023
Location: United Kingdom
Posts: 1437
Posted: 11:04am 14 Aug 2025
Copy link to clipboard 
Print this post

  Mixtel90 said  
If you are using a CMM2 as a controller then on boot it will have to load your program from SD card, tokenize it then run it, it's not already there in flash.



This is something else that had me scratching my head:


 
Mixtel90

Guru

Joined: 05/10/2019
Location: United Kingdom
Posts: 7997
Posted: 12:28pm 14 Aug 2025
Copy link to clipboard 
Print this post

I'd completely forgotten that. :)  Yes, definitely a possibility for a controller. With OPTION AUTORUN ON, once you've debugged it a bit. You have to tell it how much flash you are going to need, so develop your program in RAM first, then you can find its size.
Mick

Zilog Inside! nascom.info for Nascom & Gemini
Preliminary MMBasic docs & my PCB designs
 
PhenixRising
Guru

Joined: 07/11/2023
Location: United Kingdom
Posts: 1437
Posted: 12:46pm 14 Aug 2025
Copy link to clipboard 
Print this post

  Mixtel90 said  I'd completely forgotten that. :)  Yes, definitely a possibility for a controller. With OPTION AUTORUN ON, once you've debugged it a bit. You have to tell it how much flash you are going to need, so develop your program in RAM first, then you can find its size.


Pretty sure I tried all that but it still insisted on having the SD card inserted. Might be typing through my posterior...I'll rig it up again to see what's up.
 
Grogster

Admin Group

Joined: 31/12/2012
Location: New Zealand
Posts: 9626
Posted: 01:22am 15 Aug 2025
Copy link to clipboard 
Print this post

  Mixtel90 said  I often get confused now. I'm more used to the PicoMite than the CMM2 and I tend to forget what's possible. Also, my CMM2 manual is way out of date! The two machines, although sharing a lot of commands now, are entirely different hardware and work very differently in most cases.


Yes, that is my problem exactly!  
I use the PM or PM VGA for most things now - not really even had TIME to have a decent tinker with the PM2 based on the 2350 chip!

I still sell plenty of CMM2G2's on my website, but I just load the FM and a graphic demo program, and test that is going OK.  Haven't USED a G2 for ages, as the PM does all I need, cos I tend to want embedded controllers more then anything else.
Smoke makes things work. When the smoke gets out, it stops!
 
Volhout
Guru

Joined: 05/03/2018
Location: Netherlands
Posts: 5138
Posted: 07:15am 15 Aug 2025
Copy link to clipboard 
Print this post

Greg,

Is it resolved, or do you still need support ? I am unsure.

Volhout
PicomiteVGA PETSCII ROBOTS
 
zeitfest
Guru

Joined: 31/07/2019
Location: Australia
Posts: 588
Posted: 04:32am 16 Aug 2025
Copy link to clipboard 
Print this post

Time flies like an arrow...
Fruit flies like a banana...
.
.
.
.
 
Volhout
Guru

Joined: 05/03/2018
Location: Netherlands
Posts: 5138
Posted: 06:29am 16 Aug 2025
Copy link to clipboard 
Print this post


PicomiteVGA PETSCII ROBOTS
 
Print this page


To reply to this topic, you need to log in.

The Back Shed's forum code is written, and hosted, in Australia.
© JAQ Software 2025