Would this work for you? (I havnt tested it, but the concept seems right to me)
void RTC_TimeZoneUpdate(DATE_STRUCT date, int_32 Adjustment){ TIME_STRUCT time; RTC_TIME_STRUCT time_rtc; _time_from_date(&date, &time); //Get the MQX time from the date i.e. convert current date to seconds elapsed since 1971 time.SECONDS += Adjustment; //Timezone offset now in seconds
_rtc_time_from_mqx_time(&time,&time_rtc); //Convert to RTC time format _rtc_set_time (&time_rtc); //Update RTC} Then, you can just get your date and time, convert the timezone to seconds (Hours * 60) and call this unction and your RTC will update to the adjusted time.
With my application I need to reboot my processor to sync MQX time to the RTC (I think). If you need a function to reboot MQX, let me know.