⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 timer_8c.html

📁 cypress公司PROC开发源码(cywusb6953)
💻 HTML
📖 第 1 页 / 共 2 页
字号:
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Description: To delay 10 Usec by running through the cycles for these instructions and 58 iterations of the delay_msec_loop routine<p>
Inputs: Void<p>
Returns: Void     </td>
  </tr>
</table>
<a class="anchor" name="a9" doxytag="timer.c::timer_delay_msec"></a><p>
<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top">void timer_delay_msec           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="md" nowrap valign="top"><a class="el" href="cypdef_8h.html#a2">UINT16</a>&nbsp;</td>
          <td class="mdname1" valign="top" nowrap> <em>num_milliseconds</em>          </td>
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
          <td class="md" nowrap></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Description: Delays the number of milliseconds specified by the num_milliseconds parameter. First it takes a time stamp and adds the number of milliseconds to delay (num_milliseconds). Then it enters a while loop where each iteration puts the PSoC in sleep mode and is equivalent to one millisecond<p>
Inputs:<ul>
<li>num_milliseconds - Number of milliseconds to delay</li></ul>
<p>
Returns: Void     </td>
  </tr>
</table>

<p>
Here is the call graph for this function:<p><center><img src="timer_8c_a9_cgraph.png" border="0" usemap="#timer_8c_a9_cgraph_map" alt=""></center>
<map name="timer_8c_a9_cgraph_map">
<area href="timer_8c.html#a5" shape="rect" coords="189,7,304,34" alt="">
<area href="timer_8c.html#a4" shape="rect" coords="190,58,302,85" alt="">
</map>
<a class="anchor" name="a10" doxytag="timer.c::timer_countdown_start"></a><p>
<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top">void timer_countdown_start           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="md" nowrap valign="top"><a class="el" href="cypdef_8h.html#a2">UINT16</a>&nbsp;</td>
          <td class="mdname1" valign="top" nowrap> <em>num_milliseconds</em>          </td>
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
          <td class="md" nowrap></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Description: Starts the countdown timer.<p>
Inputs:<ul>
<li>num_milliseconds - Number of milliseconds to countdown from</li></ul>
<p>
Returns: Void     </td>
  </tr>
</table>

<p>
Here is the call graph for this function:<p><center><img src="timer_8c_a10_cgraph.png" border="0" usemap="#timer_8c_a10_cgraph_map" alt=""></center>
<map name="timer_8c_a10_cgraph_map">
<area href="timer_8c.html#a5" shape="rect" coords="216,7,330,34" alt="">
<area href="timer_8c.html#a4" shape="rect" coords="217,58,329,85" alt="">
</map>
<a class="anchor" name="a11" doxytag="timer.c::timer_countdown_expired"></a><p>
<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top"><a class="el" href="cypdef_8h.html#a1">UINT8</a> timer_countdown_expired           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="md" nowrap valign="top">void&nbsp;</td>
          <td class="mdname1" valign="top" nowrap>          </td>
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
          <td class="md" nowrap></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Description: Check if the countdown timer has expired<p>
Inputs: Void<p>
Returns:<ul>
<li>TRUE - If countdown has expired</li><li>FALSE - If countdown has not expired </li></ul>
    </td>
  </tr>
</table>
<a class="anchor" name="a12" doxytag="timer.c::timer_get_time_stamp"></a><p>
<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top"><a class="el" href="timer_8h.html#a3">TIME_STAMP</a> timer_get_time_stamp           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="md" nowrap valign="top">void&nbsp;</td>
          <td class="mdname1" valign="top" nowrap>          </td>
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
          <td class="md" nowrap></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Description: Returns the number of ticks the timer has gone through<p>
Inputs: Void<p>
Returns:<ul>
<li>tick - Number of ticks </li></ul>
    </td>
  </tr>
</table>
<a class="anchor" name="a13" doxytag="timer.c::timer_time_elapsed"></a><p>
<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top">BOOL timer_time_elapsed           </td>
          <td class="md" valign="top">(&nbsp;</td>
          <td class="md" nowrap valign="top"><a class="el" href="timer_8h.html#a3">TIME_STAMP</a>&nbsp;</td>
          <td class="mdname" nowrap> <em>from_timestamp</em>, </td>
        </tr>
        <tr>
          <td class="md" nowrap align="right"></td>
          <td class="md"></td>
          <td class="md" nowrap><a class="el" href="cypdef_8h.html#a2">UINT16</a>&nbsp;</td>
          <td class="mdname" nowrap> <em>elapsed_time_ms</em></td>
        </tr>
        <tr>
          <td class="md"></td>
          <td class="md">)&nbsp;</td>
          <td class="md" colspan="2"></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Description: Another kind of delay that is generally called within a conditional statement (i.e. while(!timer_time_elapsed(current_time, MFG_RX_TIMEOUT) ); )<p>
Inputs:<ul>
<li>from_timestamp - number of milliseconds to start with</li><li>elapsed_time_ms - number of milliseconds needed to reach the elapsed time</li></ul>
<p>
Returns:<ul>
<li>True - If elapsed time has been reached</li><li>False - If elapsed time has NOT been reached </li></ul>
    </td>
  </tr>
</table>
<hr><h2>Variable Documentation</h2>
<a class="anchor" name="a0" doxytag="timer.c::tick"></a><p>
<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
  <tr>
    <td class="mdRow">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td class="md" nowrap valign="top"><a class="el" href="timer_8h.html#a3">TIME_STAMP</a> <a class="el" href="timer_8c.html#a0">tick</a>          </td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
System tick, updated every Tick ISR ( See Tick_ISR in tickint.asm and tick_ISR() )     </td>
  </tr>
</table>
<html>

<head>
<meta http-equiv=Content-Type content="text/html; charset=windows-1252">
<meta name=Generator content="Microsoft Word 10 (filtered)">
<title>Cypress Semiconductor Corporation</title>

<style>
<!--
 /* Font Definitions */
 @font-face
	{font-family:"MS Mincho";
	panose-1:2 2 6 9 4 2 5 8 3 4;}
@font-face
	{font-family:"\@MS Mincho";
	panose-1:2 2 6 9 4 2 5 8 3 4;}
 /* Style Definitions */
 p.MsoNormal, li.MsoNormal, div.MsoNormal
	{margin:0in;
	margin-bottom:.0001pt;
	font-size:12.0pt;
	font-family:"Times New Roman";}
a:link, span.MsoHyperlink
	{color:#1A419D;
	text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
	{color:#1A419D;
	text-decoration:underline;}
@page Section1
	{size:8.5in 11.0in;
	margin:1.0in 1.25in 1.0in 1.25in;}
div.Section1
	{page:Section1;}
-->
</style>

</head>

<body lang=EN-US link="#1A419D" vlink="#1A419D">

<div class=Section1>

<div>

<div align=center>

<table class=MsoNormalTable border=1 cellspacing=0 cellpadding=0 width="100%"
 style='width:100.0%;border-collapse:collapse;border:none'>
 <tr>
  <td width="100%" style='width:100.0%;border:none;border-top:solid windowtext 1.0pt;
  padding:0in 5.4pt 0in 5.4pt'>
  <p class=MsoNormal align=center style='text-align:center'><b><span
  style='font-size:13.0pt;font-family:Arial;color:blue'><a
  href="http://www.cypress.com/">Cypress Semiconductor Corporation</a></span></b><b><span
  style='font-size:13.0pt;font-family:Arial'>牋 </span></b><b><span
  style='font-size:16.0pt;font-family:Symbol'>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -