As Brett mentioned you need to figure out the load caps for the Xtal including the parasitic capacitance of the board which should be around 4-6 pF as a rule of thumb.
So if you took 5pF as your parasitic capacitance then you get 26pF for the caps for an 18pF xtal.
Is there any difference in performance that you are aware ofā? Running out of footprint room on my PCB so the smaller the better (device housing canāt change).
@Justin How strenuous would it be to power one of those RTC ICās as well as the RAM on the G30? Even though I may get an IC to keep more accurate track of the time, I still need RAM for my cycle counter buffer.
what does ppm mean? how do you get 52 seconds from that? So every month the time will lose 52 seconds of accuracy? That is more than enough I thinkā¦in 5 years it will only be about an hour offā¦I just need it accurate to a couple days.
Ok thank you I have never seen ppm used with time before always just in chemistry, makes sense though thank you. I think Iāll go with that little bitty guy you suggested.
You could use the DS3232M, it comes in a SO8 SMD-package. I have a clock running with that a DS3232M for nearly two years now and the time-deviation is less than 1 second compared to a similar clock that updates itself via NTP, so that should be accurate enough. But the conditions are good, so in my case there are no large temperatur-differences since they are in a room with always about 20Ā°C.
But I think itās pretty hard to protect such a warranty-keeping-system against manipulation. E.g. what happens when the battery is removed or empty (intentionally, accidentally or by mistake so the RTC is reset when the device is powered off)? I think, Iād just store the first power-on-date on the EEPROM (and if it has been powered on before, so the MCU knows, if it has to set the date) and increase the number of power-ons also on the EEPROM. In that case it wouldnāt be tragic if the time has been reset or the RTC is not accurate (so you could use a cheaper one).
The G30 (the underlaying F401) has an 96bit-unique-ID (I donāt know if it can be used with NETFM or TinyCLR) that could be used to identify the device if someone scraped away your serialnumber. Or you could maybe use something like an Microchip 24AA025E64 EEPROM for identification (an extra-chip would maybe be easier to read, if the device is not functional anymore).
When I think about it, itās kind of exiting, what things could be used to safely identify a device and its parameters if there are people, that want to unidentify it ā¦