MCB1700_Welcome/Doxygen/html/_app_board2_buttons_8c.html

338 lines
18 KiB
HTML

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.20"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>Labor04: AppBoard2Buttons.c File Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
<tbody>
<tr style="height: 56px;">
<td id="projectalign" style="padding-left: 0.5em;">
<div id="projectname">Labor04
</div>
</td>
</tr>
</tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.20 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
var searchBox = new SearchBox("searchBox", "search",false,'Search');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(function() {
initMenu('',true,false,'search.php','Search');
$(document).ready(function() { init_search(); });
});
/* @license-end */</script>
<div id="main-nav"></div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
<div id="nav-tree">
<div id="nav-tree-contents">
<div id="nav-sync" class="sync"></div>
</div>
</div>
<div id="splitbar" style="-moz-user-select:none;"
class="ui-resizable-handle">
</div>
</div>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(document).ready(function(){initNavTree('_app_board2_buttons_8c.html',''); initResizable(); });
/* @license-end */
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
onmouseover="return searchBox.OnSearchSelectShow()"
onmouseout="return searchBox.OnSearchSelectHide()"
onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>
<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0"
name="MSearchResults" id="MSearchResults">
</iframe>
</div>
<div class="header">
<div class="summary">
<a href="#func-members">Functions</a> &#124;
<a href="#var-members">Variables</a> </div>
<div class="headertitle">
<div class="title">AppBoard2Buttons.c File Reference</div> </div>
</div><!--header-->
<div class="contents">
<p>Read buttons state from Application Board 2.
<a href="#details">More...</a></p>
<div class="textblock"><code>#include &quot;<a class="el" href="_app_board2_buttons_8h_source.html">AppBoard2Buttons.h</a>&quot;</code><br />
</div><div class="textblock"><div class="dynheader">
Include dependency graph for AppBoard2Buttons.c:</div>
<div class="dyncontent">
<div class="center"><img src="_app_board2_buttons_8c__incl.png" border="0" usemap="#a_app_board2_buttons_8c" alt=""/></div>
<map name="_app_board2_buttons_8c" id="_app_board2_buttons_8c">
<area shape="rect" title="Read buttons state from Application Board 2." alt="" coords="144,5,287,32"/>
<area shape="rect" href="_app_board2_buttons_8h.html" title="Read state of buttons." alt="" coords="144,80,287,107"/>
<area shape="rect" title=" " alt="" coords="5,155,132,181"/>
<area shape="rect" title=" " alt="" coords="157,155,274,181"/>
<area shape="rect" title=" " alt="" coords="299,155,385,181"/>
</map>
</div>
</div><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
Functions</h2></td></tr>
<tr class="memitem:aab5827442758f8170c4aa7190629e321"><td class="memItemLeft" align="right" valign="top">static bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="_app_board2_buttons_8c.html#aab5827442758f8170c4aa7190629e321">u32AppBoard2ButtonsDebounce</a> (uint32_t u32Value)</td></tr>
<tr class="memdesc:aab5827442758f8170c4aa7190629e321"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns true if buttons are debounced. <a href="_app_board2_buttons_8c.html#aab5827442758f8170c4aa7190629e321">More...</a><br /></td></tr>
<tr class="separator:aab5827442758f8170c4aa7190629e321"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a8d4bb8cc3a9b02919eeabd4e7efb691e"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="_app_board2_buttons_8c.html#a8d4bb8cc3a9b02919eeabd4e7efb691e">vAppboard2ButtonsInitialize</a> (void)</td></tr>
<tr class="memdesc:a8d4bb8cc3a9b02919eeabd4e7efb691e"><td class="mdescLeft">&#160;</td><td class="mdescRight">Initialization of all buttons of Application Board 2. <a href="_app_board2_buttons_8c.html#a8d4bb8cc3a9b02919eeabd4e7efb691e">More...</a><br /></td></tr>
<tr class="separator:a8d4bb8cc3a9b02919eeabd4e7efb691e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a47a3f0dd34a93947609f44bee6810eaf"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="_app_board2_buttons_8c.html#a47a3f0dd34a93947609f44bee6810eaf">vAppboard2ButtonsUninitialize</a> (void)</td></tr>
<tr class="memdesc:a47a3f0dd34a93947609f44bee6810eaf"><td class="mdescLeft">&#160;</td><td class="mdescRight">Uninitialization of all buttons of Application Board 2. <a href="_app_board2_buttons_8c.html#a47a3f0dd34a93947609f44bee6810eaf">More...</a><br /></td></tr>
<tr class="separator:a47a3f0dd34a93947609f44bee6810eaf"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:acbd982e9017fcc7828f6ada51d02bcbe"><td class="memItemLeft" align="right" valign="top">uint32_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="_app_board2_buttons_8c.html#acbd982e9017fcc7828f6ada51d02bcbe">u32AppBoard2ButtonsGetState</a> (void)</td></tr>
<tr class="memdesc:acbd982e9017fcc7828f6ada51d02bcbe"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns the pressed Buttons (bit coded see <a class="el" href="_app_board2_buttons_8h.html" title="Read state of buttons.">AppBoard2Buttons.h</a>) <a href="_app_board2_buttons_8c.html#acbd982e9017fcc7828f6ada51d02bcbe">More...</a><br /></td></tr>
<tr class="separator:acbd982e9017fcc7828f6ada51d02bcbe"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="var-members"></a>
Variables</h2></td></tr>
<tr class="memitem:a07d36e2e97b2bf6abeee32863ea7222e"><td class="memItemLeft" align="right" valign="top">GPIO_ID&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="_app_board2_buttons_8c.html#a07d36e2e97b2bf6abeee32863ea7222e">axAppBoard2Buttons</a> [<a class="el" href="_app_board2_buttons_8h.html#a1d54a1a9dab19a3f18d6610bfe529c2c">APPBOARD2_NUMBER_BUTTONS</a>]</td></tr>
<tr class="separator:a07d36e2e97b2bf6abeee32863ea7222e"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>Read buttons state from Application Board 2. </p>
<dl class="section author"><dt>Author</dt><dd>Daniel Fischer (V5.0) - Heinrich Ginter (V1.0) </dd></dl>
<dl class="section version"><dt>Version</dt><dd>V5.0 </dd></dl>
<dl class="section date"><dt>Date</dt><dd>20.10.2019</dd></dl>
<p>This file includes important button functions for Application Board 2 Debouncing is also included (see static function bool <a class="el" href="_app_board2_buttons_8c.html#aab5827442758f8170c4aa7190629e321" title="Returns true if buttons are debounced.">u32AppBoard2ButtonsDebounce(uint32_t u32Value)</a>) </p>
</div><h2 class="groupheader">Function Documentation</h2>
<a id="aab5827442758f8170c4aa7190629e321"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aab5827442758f8170c4aa7190629e321">&#9670;&nbsp;</a></span>u32AppBoard2ButtonsDebounce()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">static bool u32AppBoard2ButtonsDebounce </td>
<td>(</td>
<td class="paramtype">uint32_t&#160;</td>
<td class="paramname"><em>u32Value</em></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns true if buttons are debounced. </p>
<dl class="section author"><dt>Author</dt><dd>Daniel Fischer (V5.0) - Heinrich Ginter (V1.0) </dd></dl>
<dl class="section version"><dt>Version</dt><dd>V5.0 </dd></dl>
<dl class="section date"><dt>Date</dt><dd>20.10.2019 </dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">uint32_t</td><td>Value (Button id) </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>true or false</dd></dl>
<p>Change the two hex constants to accommodate different bounce times and timer rates. In this implementation the the hex constants are appropriate for a call by a timer between 15 and 25 msec </p>
<div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="_app_board2_buttons_8c_aab5827442758f8170c4aa7190629e321_icgraph.png" border="0" usemap="#a_app_board2_buttons_8c_aab5827442758f8170c4aa7190629e321_icgraph" alt=""/></div>
<map name="_app_board2_buttons_8c_aab5827442758f8170c4aa7190629e321_icgraph" id="a_app_board2_buttons_8c_aab5827442758f8170c4aa7190629e321_icgraph">
<area shape="rect" title="Returns true if buttons are debounced." alt="" coords="551,31,761,57"/>
<area shape="rect" href="_app_board2_buttons_8h.html#acbd982e9017fcc7828f6ada51d02bcbe" title="Returns the pressed Buttons (bit coded see AppBoard2Buttons.h)" alt="" coords="299,31,503,57"/>
<area shape="rect" href="_interrupt_8c.html#a5f89e5f7418d3a10f49b2faeab3711dd" title="ISR of timer0, called every 20 millisecond." alt="" coords="104,5,251,32"/>
<area shape="rect" href="_threads_8h.html#ae39d02eea48045356f226692b6f517a3" title="read buttons and store events in queue" alt="" coords="104,56,251,83"/>
<area shape="rect" href="_main_8c.html#a840291bc02cba5474a4cb46a9b9566fe" title="app entry point" alt="" coords="5,56,56,83"/>
</map>
</div>
</div>
</div>
<a id="acbd982e9017fcc7828f6ada51d02bcbe"></a>
<h2 class="memtitle"><span class="permalink"><a href="#acbd982e9017fcc7828f6ada51d02bcbe">&#9670;&nbsp;</a></span>u32AppBoard2ButtonsGetState()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">uint32_t u32AppBoard2ButtonsGetState </td>
<td>(</td>
<td class="paramtype">void&#160;</td>
<td class="paramname"></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns the pressed Buttons (bit coded see <a class="el" href="_app_board2_buttons_8h.html" title="Read state of buttons.">AppBoard2Buttons.h</a>) </p>
<dl class="section author"><dt>Author</dt><dd>Daniel Fischer (V5.0) - Heinrich Ginter (V1.0) </dd></dl>
<dl class="section version"><dt>Version</dt><dd>V5.0 </dd></dl>
<dl class="section date"><dt>Date</dt><dd>20.10.2019 </dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">no</td><td></td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>uint32_t u32PressedButton</dd></dl>
<p>After a pressed button is recognized, the button gets debounced and returned </p>
<div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="_app_board2_buttons_8c_acbd982e9017fcc7828f6ada51d02bcbe_cgraph.png" border="0" usemap="#a_app_board2_buttons_8c_acbd982e9017fcc7828f6ada51d02bcbe_cgraph" alt=""/></div>
<map name="_app_board2_buttons_8c_acbd982e9017fcc7828f6ada51d02bcbe_cgraph" id="_app_board2_buttons_8c_acbd982e9017fcc7828f6ada51d02bcbe_cgraph">
<area shape="rect" title="Returns the pressed Buttons (bit coded see AppBoard2Buttons.h)" alt="" coords="5,5,209,32"/>
<area shape="rect" href="_app_board2_buttons_8c.html#aab5827442758f8170c4aa7190629e321" title="Returns true if buttons are debounced." alt="" coords="257,5,468,32"/>
</map>
</div>
<div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="_app_board2_buttons_8c_acbd982e9017fcc7828f6ada51d02bcbe_icgraph.png" border="0" usemap="#a_app_board2_buttons_8c_acbd982e9017fcc7828f6ada51d02bcbe_icgraph" alt=""/></div>
<map name="_app_board2_buttons_8c_acbd982e9017fcc7828f6ada51d02bcbe_icgraph" id="a_app_board2_buttons_8c_acbd982e9017fcc7828f6ada51d02bcbe_icgraph">
<area shape="rect" title="Returns the pressed Buttons (bit coded see AppBoard2Buttons.h)" alt="" coords="299,31,503,57"/>
<area shape="rect" href="_interrupt_8c.html#a5f89e5f7418d3a10f49b2faeab3711dd" title="ISR of timer0, called every 20 millisecond." alt="" coords="104,5,251,32"/>
<area shape="rect" href="_threads_8h.html#ae39d02eea48045356f226692b6f517a3" title="read buttons and store events in queue" alt="" coords="104,56,251,83"/>
<area shape="rect" href="_main_8c.html#a840291bc02cba5474a4cb46a9b9566fe" title="app entry point" alt="" coords="5,56,56,83"/>
</map>
</div>
</div>
</div>
<a id="a8d4bb8cc3a9b02919eeabd4e7efb691e"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a8d4bb8cc3a9b02919eeabd4e7efb691e">&#9670;&nbsp;</a></span>vAppboard2ButtonsInitialize()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void vAppboard2ButtonsInitialize </td>
<td>(</td>
<td class="paramtype">void&#160;</td>
<td class="paramname"></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Initialization of all buttons of Application Board 2. </p>
<dl class="section author"><dt>Author</dt><dd>Daniel Fischer (V5.0) - Heinrich Ginter (V1.0) </dd></dl>
<dl class="section version"><dt>Version</dt><dd>V5.0 </dd></dl>
<dl class="section date"><dt>Date</dt><dd>20.10.2019 </dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">void</td><td></td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>void </dd></dl>
<div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="_app_board2_buttons_8c_a8d4bb8cc3a9b02919eeabd4e7efb691e_icgraph.png" border="0" usemap="#a_app_board2_buttons_8c_a8d4bb8cc3a9b02919eeabd4e7efb691e_icgraph" alt=""/></div>
<map name="_app_board2_buttons_8c_a8d4bb8cc3a9b02919eeabd4e7efb691e_icgraph" id="_app_board2_buttons_8c_a8d4bb8cc3a9b02919eeabd4e7efb691e_icgraph">
<area shape="rect" title="Initialization of all buttons of Application Board 2." alt="" coords="251,5,435,32"/>
<area shape="rect" href="_main_8c.html#a28f2269e99057d03a06ba743893ce407" title="initialize app" alt="" coords="104,5,203,32"/>
<area shape="rect" href="_main_8c.html#a840291bc02cba5474a4cb46a9b9566fe" title="app entry point" alt="" coords="5,5,56,32"/>
</map>
</div>
</div>
</div>
<a id="a47a3f0dd34a93947609f44bee6810eaf"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a47a3f0dd34a93947609f44bee6810eaf">&#9670;&nbsp;</a></span>vAppboard2ButtonsUninitialize()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void vAppboard2ButtonsUninitialize </td>
<td>(</td>
<td class="paramtype">void&#160;</td>
<td class="paramname"></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Uninitialization of all buttons of Application Board 2. </p>
<dl class="section author"><dt>Author</dt><dd>Daniel Fischer (V5.0) </dd></dl>
<dl class="section version"><dt>Version</dt><dd>V5.0 </dd></dl>
<dl class="section date"><dt>Date</dt><dd>20.10.2019 </dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">void</td><td></td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>void </dd></dl>
</div>
</div>
<h2 class="groupheader">Variable Documentation</h2>
<a id="a07d36e2e97b2bf6abeee32863ea7222e"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a07d36e2e97b2bf6abeee32863ea7222e">&#9670;&nbsp;</a></span>axAppBoard2Buttons</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">GPIO_ID axAppBoard2Buttons[<a class="el" href="_app_board2_buttons_8h.html#a1d54a1a9dab19a3f18d6610bfe529c2c">APPBOARD2_NUMBER_BUTTONS</a>]</td>
</tr>
</table>
</div><div class="memdoc">
<b>Initial value:</b><div class="fragment"><div class="line">= {{2,12},{0,20},</div>
<div class="line"> {0,19},{2,11},</div>
<div class="line"> {2,13},{1,21},</div>
<div class="line"> {3,25},{3,26}</div>
<div class="line">}</div>
</div><!-- fragment -->
</div>
</div>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
<ul>
<li class="navelem"><a class="el" href="_app_board2_buttons_8c.html">AppBoard2Buttons.c</a></li>
<li class="footer">Generated by <a href="http://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.8.20 </li>
</ul>
</div>
</body>
</html>