1<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> 2<html> 3 4<head> 5<META http-equiv="Content-Type" content="text/html; charset=windows-1252"> 6<META name="GENERATOR" content="IBM WebSphere Studio Homepage Builder Version 7.0.0.0 for Windows"> 7<META http-equiv="Content-Style-Type" content="text/css"> 8<title>RTC_SetDateTimeAsync</title> 9<LINK rel="stylesheet" href="../css/nitro.css" type="text/css"> 10</head> 11 12<body> 13 14<h1 align="left">RTC_SetDateTimeAsync <img src="../image/NTR.gif" align="middle"><img src="../image/TWL.gif" align="middle"></h1> 15 16<h2>Syntax</h2> 17 18<dl> 19 <dd> 20<CODE>#include <nitro/rtc.h></CODE><BR> 21 <PRE><CODE><A href="RTCResult.html">RTCResult</A> RTC_SetDateTimeAsync( 22 const <A href="RTCDate.html">RTCDate</A>* date, 23 const <A href="RTCTime.html">RTCTime</A>* time, 24 <A href="RTCCallback.html">RTCCallback</A> callback, 25 void* arg );</CODE></PRE> 26 </dd> 27 28</dl><h2>Arguments</h2> 29<TABLE border="1" width="100%"> 30 <TBODY> 31 <TR> 32<TD width="300"><em><strong><font face="Courier New">date</font></strong></em></TD> 33<TD width="700">Pointer to the buffer storing date data.</TD> 34 </TR> 35 <TR> 36<TD><em><strong><font face="Courier New">time</font></strong></em></TD> 37<TD>Pointer to the buffer storing time data.</TD> 38 </TR> 39 <TR> 40<TD><em><strong><font face="Courier New">callback</font></strong></em></TD> 41<TD>Pointer to the callback function. This callback is called from within the interrupt handler.</TD> 42 </TR> 43 <TR> 44<TD><em><strong><font face="Courier New">arg</font></strong></em></TD> 45<TD>Argument to pass to the callback function.</TD> 46 </TR> 47 </TBODY> 48</TABLE> 49 50<h2>Return Values</h2> 51<P>If the request succeeds, it returns 0. If the request fails, it returns a numeric value other than 0.</P> 52 53<H2>Description</H2> 54<P>This function asynchronously writes date and time data to the real-time clock. It sends date and time data to ARM7 and returns the process result without waiting for a response from the processor. To get the result from the processor, you must use the <em><strong><code>result</code></strong></em> argument. If this function fails, no operation is performed and no user callback function is called.</P> 55 56<h2>Note</h2> 57<P><FONT color=red>Do not define parameter values of nonexistent years, months, or days. However, you may specify a day of the week that does not match the actual calendar. This function requires a PXI interrupt for synchronization. Values are written to the variables specified by the <SPAN class="argument">date</SPAN> and <SPAN class="argument">time</SPAN> arguments asynchronously with respect to the function.</FONT><BR><FONT color=red>Because applications cannot change the date, use this API only for debugging during development.<br /> In FINALROM builds, this function always fails and <CODE>RTC_RESULT_INVALID_COMMAND</CODE> is returned.</FONT></P> 58 59<h2>See Also</h2> 60<P><code><a href="RTC_SetDateTime.html">RTC_SetDateTime</a><br /> <a href="RTC_GetDateTime.html">RTC_GetDateTime</a><br /> <a href="RTC_GetDateTimeAsync.html">RTC_GetDateTimeAsync</a><br /> <a href="RTCResult.html">RTCResult</a><br /> <a href="RTCDate.html">RTCDate</a><br /> <a href="RTCTime.html">RTCTime</a><br /> <a href="RTCCallback.html">RTCCallback</a></code></P> 61 62<H2>Revision History</H2> 63<P> 642009/07/29 Explained that the time setting command always fails in FINALROM builds.<br /> 65 2005/06/27 Added additional text indicating that callbacks are called from interrupt handlers. <br> 2004/07/01 Updated descriptions to standardize the time notation.<BR> 2004/05/18 Initial version.</P> 66<hr><p>CONFIDENTIAL</p></body> 67</html> 68