h6. [[RTC]] h6(. » [[RTC SWI Calls|SWI Calls]] h6((. » RTC_Write h2. RTC_Write h5. (SWI &594C2) |_<^{width:4em}. Entry | | |<^. R0 |<^. Pointer to [[rtctime]] structure | |_<^{width:4em}. Exit | | |<^. R0 |<^. Error pointer (on failure), preserved (on success) | |<^. - |<^. All other registers preserved | h4. Use The purpose of this call is to write a time value to the hardware RTC h4. Notes By initialising certain members of the rtctime struct to 255, it is possible to do a partial update of the date/time. The supported combinations are: * Full time update – all the rtctime members are valid and are expected to be written to the RTC * Time update – The DayOfMonth, Month, YearLO and YearHI members will be set to 255. Only the time portion of the RTC will be updated. * Date update – The Centiseconds, Seconds, Minutes and Hours members will be set to 255. Only the date portion of the RTC will be updated. Other combinations are invalid and should not be used. The year bytes held in CMOS may be updated by this operation. If the RTC was previously stopped, this call will start it running. Rather than writing time to the RTC directly, most software should use a SWI such as [[Territory_SetTime]] to update both the RTC and the soft copy. h4. See also * [[RTC_Read]] * [[Territory_SetTime]]