¿ªÔÆÌåÓý

Re: sBITX 64Bit Pi Image Available #sBitx


 

On Fri, Mar 22, 2024 at 12:21 AM, Peter VK3PYE wrote:
After entering "\utc 2023 05 01 05:00:00"?into the command box, it did change the date/time in the title bar, but no change after a restart, and I2C is enabled.

Thanks for what you have done so far JJ.? If it's not fun, then take a break, that's what I'm going to do this weekend.?

Have a good one with your family JJ.

This code expects the I2C bus to be kernel I2C interface. Make sure you have one of the dtoverlays in /boot/firmware/config.txt

For loading the I2C Bit-Banged (BB) driver in the appropriate sBitx pins, with kernel RTC clock driver loaded (for use as system clock, this is what I use):

dtoverlay=i2c-rtc-gpio,ds1307,bus=2,i2c_gpio_sda=13,i2c_gpio_scl=6

----------------------------- sbitx_gtk.c 3353:3359 ----------------------------------------------

time_t tjulian = mktime(&t);
?? ?
?? ?tzname[0] = tzname[1] = "GMT";
?? ?timezone = 0;
?? ?daylight = 0;
?? ?setenv("TZ", "UTC", 1);???
?? ?gm_now = mktime(&t);

----------------------------------------------------------------------------------------------------

change UTC to local utc (UTC1 UTC2 UTC3)
setenv("TZ", "UTC1", 1);

Join [email protected] to automatically receive all group messages.