|
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437 |
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://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.10"/>
- <title>SdFat: DigitalPin< PinNumber > Class Template 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="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>
- <script type="text/javascript">
- $(document).ready(function() { init_search(); });
- </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">SdFat
- </div>
- </td>
- </tr>
- </tbody>
- </table>
- </div>
- <!-- end header part -->
- <!-- Generated by Doxygen 1.8.10 -->
- <script type="text/javascript">
- var searchBox = new SearchBox("searchBox", "search",false,'Search');
- </script>
- <div id="navrow1" class="tabs">
- <ul class="tablist">
- <li><a href="index.html"><span>Main Page</span></a></li>
- <li><a href="modules.html"><span>Modules</span></a></li>
- <li class="current"><a href="annotated.html"><span>Classes</span></a></li>
- <li><a href="files.html"><span>Files</span></a></li>
- <li>
- <div id="MSearchBox" class="MSearchBoxInactive">
- <span class="left">
- <img id="MSearchSelect" src="search/mag_sel.png"
- onmouseover="return searchBox.OnSearchSelectShow()"
- onmouseout="return searchBox.OnSearchSelectHide()"
- alt=""/>
- <input type="text" id="MSearchField" value="Search" accesskey="S"
- onfocus="searchBox.OnSearchFieldFocus(true)"
- onblur="searchBox.OnSearchFieldFocus(false)"
- onkeyup="searchBox.OnSearchFieldChange(event)"/>
- </span><span class="right">
- <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
- </span>
- </div>
- </li>
- </ul>
- </div>
- <div id="navrow2" class="tabs2">
- <ul class="tablist">
- <li><a href="annotated.html"><span>Class List</span></a></li>
- <li><a href="inherits.html"><span>Class Hierarchy</span></a></li>
- <li><a href="functions.html"><span>Class Members</span></a></li>
- </ul>
- </div>
- <!-- 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><!-- top -->
- <div class="header">
- <div class="summary">
- <a href="#pub-methods">Public Member Functions</a> |
- <a href="class_digital_pin-members.html">List of all members</a> </div>
- <div class="headertitle">
- <div class="title">DigitalPin< PinNumber > Class Template Reference<div class="ingroups"><a class="el" href="group__digital_pin.html">Fast Pin I/O</a></div></div> </div>
- </div><!--header-->
- <div class="contents">
-
- <p>Fast digital port I/O.
- <a href="class_digital_pin.html#details">More...</a></p>
-
- <p><code>#include <DigitalPin.h></code></p>
- <table class="memberdecls">
- <tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
- Public Member Functions</h2></td></tr>
- <tr class="memitem:aa6e07eea6e152d47c6f0d232bed9c45e"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_digital_pin.html#aa6e07eea6e152d47c6f0d232bed9c45e">config</a> (uint8_t <a class="el" href="class_digital_pin.html#afe1550df47980934061d5578ec1fd644">mode</a>, bool level)</td></tr>
- <tr class="separator:aa6e07eea6e152d47c6f0d232bed9c45e"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:ab68480b09df5c4794c95cdf2230d4c55"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="class_digital_pin.html#ab68480b09df5c4794c95cdf2230d4c55">DigitalPin</a> ()</td></tr>
- <tr class="separator:ab68480b09df5c4794c95cdf2230d4c55"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:add1677ecf4c7dc3c12effd39c1db34ed"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_digital_pin.html#add1677ecf4c7dc3c12effd39c1db34ed">high</a> ()</td></tr>
- <tr class="separator:add1677ecf4c7dc3c12effd39c1db34ed"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:aeb6a3f66fb3f9fb9ec8233bdb18aa6eb"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_digital_pin.html#aeb6a3f66fb3f9fb9ec8233bdb18aa6eb">low</a> ()</td></tr>
- <tr class="separator:aeb6a3f66fb3f9fb9ec8233bdb18aa6eb"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:afe1550df47980934061d5578ec1fd644"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_digital_pin.html#afe1550df47980934061d5578ec1fd644">mode</a> (uint8_t mode)</td></tr>
- <tr class="separator:afe1550df47980934061d5578ec1fd644"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:ab609c911b4a672e4d382260fc1fdd266"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="class_digital_pin.html#ab609c911b4a672e4d382260fc1fdd266">operator bool</a> () const </td></tr>
- <tr class="separator:ab609c911b4a672e4d382260fc1fdd266"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:adbc9c84602246497a1dbe011e9339cc0"><td class="memItemLeft" align="right" valign="top"><a class="el" href="class_digital_pin.html">DigitalPin</a> & </td><td class="memItemRight" valign="bottom"><a class="el" href="class_digital_pin.html#adbc9c84602246497a1dbe011e9339cc0">operator=</a> (bool value)</td></tr>
- <tr class="separator:adbc9c84602246497a1dbe011e9339cc0"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a55e344551ca86f8acd489aac277c9961"><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="class_digital_pin.html#a55e344551ca86f8acd489aac277c9961">read</a> () const </td></tr>
- <tr class="separator:a55e344551ca86f8acd489aac277c9961"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:ab2109c522836448cd6dfd576c1b5a5a0"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_digital_pin.html#ab2109c522836448cd6dfd576c1b5a5a0">toggle</a> ()</td></tr>
- <tr class="separator:ab2109c522836448cd6dfd576c1b5a5a0"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a08b7eee5165c5055bd0bbbda491bdfff"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_digital_pin.html#a08b7eee5165c5055bd0bbbda491bdfff">write</a> (bool value)</td></tr>
- <tr class="separator:a08b7eee5165c5055bd0bbbda491bdfff"><td class="memSeparator" colspan="2"> </td></tr>
- </table>
- <a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
- <div class="textblock"><h3>template<uint8_t PinNumber><br />
- class DigitalPin< PinNumber ></h3>
-
- <p>Fast digital port I/O. </p>
- </div><h2 class="groupheader">Constructor & Destructor Documentation</h2>
- <a class="anchor" id="ab68480b09df5c4794c95cdf2230d4c55"></a>
- <div class="memitem">
- <div class="memproto">
- <div class="memtemplate">
- template<uint8_t PinNumber> </div>
- <table class="mlabels">
- <tr>
- <td class="mlabels-left">
- <table class="memname">
- <tr>
- <td class="memname"><a class="el" href="class_digital_pin.html">DigitalPin</a>< PinNumber >::<a class="el" href="class_digital_pin.html">DigitalPin</a> </td>
- <td>(</td>
- <td class="paramname"></td><td>)</td>
- <td></td>
- </tr>
- </table>
- </td>
- <td class="mlabels-right">
- <span class="mlabels"><span class="mlabel">inline</span></span> </td>
- </tr>
- </table>
- </div><div class="memdoc">
- <p>Constructor </p>
-
- </div>
- </div>
- <h2 class="groupheader">Member Function Documentation</h2>
- <a class="anchor" id="aa6e07eea6e152d47c6f0d232bed9c45e"></a>
- <div class="memitem">
- <div class="memproto">
- <div class="memtemplate">
- template<uint8_t PinNumber> </div>
- <table class="mlabels">
- <tr>
- <td class="mlabels-left">
- <table class="memname">
- <tr>
- <td class="memname">void <a class="el" href="class_digital_pin.html">DigitalPin</a>< PinNumber >::config </td>
- <td>(</td>
- <td class="paramtype">uint8_t </td>
- <td class="paramname"><em>mode</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype">bool </td>
- <td class="paramname"><em>level</em> </td>
- </tr>
- <tr>
- <td></td>
- <td>)</td>
- <td></td><td></td>
- </tr>
- </table>
- </td>
- <td class="mlabels-right">
- <span class="mlabels"><span class="mlabel">inline</span></span> </td>
- </tr>
- </table>
- </div><div class="memdoc">
- <p>Set pin configuration. </p><dl class="params"><dt>Parameters</dt><dd>
- <table class="params">
- <tr><td class="paramdir">[in]</td><td class="paramname">mode</td><td>INPUT or OUTPUT. </td></tr>
- <tr><td class="paramdir">[in]</td><td class="paramname">level</td><td>If mode is OUTPUT, set level high/low. If mode is INPUT, enable or disable the pin's 20K pullup. </td></tr>
- </table>
- </dd>
- </dl>
-
- </div>
- </div>
- <a class="anchor" id="add1677ecf4c7dc3c12effd39c1db34ed"></a>
- <div class="memitem">
- <div class="memproto">
- <div class="memtemplate">
- template<uint8_t PinNumber> </div>
- <table class="mlabels">
- <tr>
- <td class="mlabels-left">
- <table class="memname">
- <tr>
- <td class="memname">void <a class="el" href="class_digital_pin.html">DigitalPin</a>< PinNumber >::high </td>
- <td>(</td>
- <td class="paramname"></td><td>)</td>
- <td></td>
- </tr>
- </table>
- </td>
- <td class="mlabels-right">
- <span class="mlabels"><span class="mlabel">inline</span></span> </td>
- </tr>
- </table>
- </div><div class="memdoc">
- <p>Set pin level high if output mode or enable 20K pullup if input mode. </p>
-
- </div>
- </div>
- <a class="anchor" id="aeb6a3f66fb3f9fb9ec8233bdb18aa6eb"></a>
- <div class="memitem">
- <div class="memproto">
- <div class="memtemplate">
- template<uint8_t PinNumber> </div>
- <table class="mlabels">
- <tr>
- <td class="mlabels-left">
- <table class="memname">
- <tr>
- <td class="memname">void <a class="el" href="class_digital_pin.html">DigitalPin</a>< PinNumber >::low </td>
- <td>(</td>
- <td class="paramname"></td><td>)</td>
- <td></td>
- </tr>
- </table>
- </td>
- <td class="mlabels-right">
- <span class="mlabels"><span class="mlabel">inline</span></span> </td>
- </tr>
- </table>
- </div><div class="memdoc">
- <p>Set pin level low if output mode or disable 20K pullup if input mode. </p>
-
- </div>
- </div>
- <a class="anchor" id="afe1550df47980934061d5578ec1fd644"></a>
- <div class="memitem">
- <div class="memproto">
- <div class="memtemplate">
- template<uint8_t PinNumber> </div>
- <table class="mlabels">
- <tr>
- <td class="mlabels-left">
- <table class="memname">
- <tr>
- <td class="memname">void <a class="el" href="class_digital_pin.html">DigitalPin</a>< PinNumber >::mode </td>
- <td>(</td>
- <td class="paramtype">uint8_t </td>
- <td class="paramname"><em>mode</em></td><td>)</td>
- <td></td>
- </tr>
- </table>
- </td>
- <td class="mlabels-right">
- <span class="mlabels"><span class="mlabel">inline</span></span> </td>
- </tr>
- </table>
- </div><div class="memdoc">
- <p>Set pin mode. </p><dl class="params"><dt>Parameters</dt><dd>
- <table class="params">
- <tr><td class="paramdir">[in]</td><td class="paramname">mode</td><td>INPUT, OUTPUT, or INPUT_PULLUP.</td></tr>
- </table>
- </dd>
- </dl>
- <p>The internal pullup resistors will be enabled if mode is INPUT_PULLUP and disabled if the mode is INPUT. </p>
-
- </div>
- </div>
- <a class="anchor" id="ab609c911b4a672e4d382260fc1fdd266"></a>
- <div class="memitem">
- <div class="memproto">
- <div class="memtemplate">
- template<uint8_t PinNumber> </div>
- <table class="mlabels">
- <tr>
- <td class="mlabels-left">
- <table class="memname">
- <tr>
- <td class="memname"><a class="el" href="class_digital_pin.html">DigitalPin</a>< PinNumber >::operator bool </td>
- <td>(</td>
- <td class="paramname"></td><td>)</td>
- <td> const</td>
- </tr>
- </table>
- </td>
- <td class="mlabels-right">
- <span class="mlabels"><span class="mlabel">inline</span></span> </td>
- </tr>
- </table>
- </div><div class="memdoc">
- <p>Parenthesis operator. </p><dl class="section return"><dt>Returns</dt><dd>Pin's level </dd></dl>
-
- </div>
- </div>
- <a class="anchor" id="adbc9c84602246497a1dbe011e9339cc0"></a>
- <div class="memitem">
- <div class="memproto">
- <div class="memtemplate">
- template<uint8_t PinNumber> </div>
- <table class="mlabels">
- <tr>
- <td class="mlabels-left">
- <table class="memname">
- <tr>
- <td class="memname"><a class="el" href="class_digital_pin.html">DigitalPin</a>& <a class="el" href="class_digital_pin.html">DigitalPin</a>< PinNumber >::operator= </td>
- <td>(</td>
- <td class="paramtype">bool </td>
- <td class="paramname"><em>value</em></td><td>)</td>
- <td></td>
- </tr>
- </table>
- </td>
- <td class="mlabels-right">
- <span class="mlabels"><span class="mlabel">inline</span></span> </td>
- </tr>
- </table>
- </div><div class="memdoc">
- <p>Asignment operator. </p><dl class="params"><dt>Parameters</dt><dd>
- <table class="params">
- <tr><td class="paramdir">[in]</td><td class="paramname">value</td><td>If true set the pin's level high else set the pin's level low.</td></tr>
- </table>
- </dd>
- </dl>
- <dl class="section return"><dt>Returns</dt><dd>This <a class="el" href="class_digital_pin.html" title="Fast digital port I/O. ">DigitalPin</a> instance. </dd></dl>
-
- </div>
- </div>
- <a class="anchor" id="a55e344551ca86f8acd489aac277c9961"></a>
- <div class="memitem">
- <div class="memproto">
- <div class="memtemplate">
- template<uint8_t PinNumber> </div>
- <table class="mlabels">
- <tr>
- <td class="mlabels-left">
- <table class="memname">
- <tr>
- <td class="memname">bool <a class="el" href="class_digital_pin.html">DigitalPin</a>< PinNumber >::read </td>
- <td>(</td>
- <td class="paramname"></td><td>)</td>
- <td> const</td>
- </tr>
- </table>
- </td>
- <td class="mlabels-right">
- <span class="mlabels"><span class="mlabel">inline</span></span> </td>
- </tr>
- </table>
- </div><div class="memdoc">
- <dl class="section return"><dt>Returns</dt><dd>Pin's level. </dd></dl>
-
- </div>
- </div>
- <a class="anchor" id="ab2109c522836448cd6dfd576c1b5a5a0"></a>
- <div class="memitem">
- <div class="memproto">
- <div class="memtemplate">
- template<uint8_t PinNumber> </div>
- <table class="mlabels">
- <tr>
- <td class="mlabels-left">
- <table class="memname">
- <tr>
- <td class="memname">void <a class="el" href="class_digital_pin.html">DigitalPin</a>< PinNumber >::toggle </td>
- <td>(</td>
- <td class="paramname"></td><td>)</td>
- <td></td>
- </tr>
- </table>
- </td>
- <td class="mlabels-right">
- <span class="mlabels"><span class="mlabel">inline</span></span> </td>
- </tr>
- </table>
- </div><div class="memdoc">
- <p>Toggle a pin.</p>
- <p>If the pin is in output mode toggle the pin's level. If the pin is in input mode toggle the state of the 20K pullup. </p>
-
- </div>
- </div>
- <a class="anchor" id="a08b7eee5165c5055bd0bbbda491bdfff"></a>
- <div class="memitem">
- <div class="memproto">
- <div class="memtemplate">
- template<uint8_t PinNumber> </div>
- <table class="mlabels">
- <tr>
- <td class="mlabels-left">
- <table class="memname">
- <tr>
- <td class="memname">void <a class="el" href="class_digital_pin.html">DigitalPin</a>< PinNumber >::write </td>
- <td>(</td>
- <td class="paramtype">bool </td>
- <td class="paramname"><em>value</em></td><td>)</td>
- <td></td>
- </tr>
- </table>
- </td>
- <td class="mlabels-right">
- <span class="mlabels"><span class="mlabel">inline</span></span> </td>
- </tr>
- </table>
- </div><div class="memdoc">
- <p>Write the pin's level. </p><dl class="params"><dt>Parameters</dt><dd>
- <table class="params">
- <tr><td class="paramdir">[in]</td><td class="paramname">value</td><td>If true set the pin's level high else set the pin's level low. </td></tr>
- </table>
- </dd>
- </dl>
-
- </div>
- </div>
- <hr/>The documentation for this class was generated from the following file:<ul>
- <li>Arduino/libraries/SdFat/src/SdSpiCard/<a class="el" href="_digital_pin_8h.html">DigitalPin.h</a></li>
- </ul>
- </div><!-- contents -->
- <!-- start footer part -->
- <hr class="footer"/><address class="footer"><small>
- Generated on Fri Feb 12 2016 13:43:49 for SdFat by  <a href="http://www.doxygen.org/index.html">
- <img class="footer" src="doxygen.png" alt="doxygen"/>
- </a> 1.8.10
- </small></address>
- </body>
- </html>
|