mirror of
https://github.com/taigrr/arduinolibs
synced 2025-01-18 04:33:12 -08:00
Update docs
This commit is contained in:
@@ -2,29 +2,37 @@
|
||||
<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"/>
|
||||
<title>ArduinoLibs: Hello World for Freetronics LCD</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/search.js"></script>
|
||||
<link href="doxygen.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript">
|
||||
$(document).ready(function() { searchBox.OnSelectItem(0); });
|
||||
</script>
|
||||
<link href="doxygen.css" rel="stylesheet" type="text/css" />
|
||||
</head>
|
||||
<body onload='searchBox.OnSelectItem(0);'>
|
||||
<!-- Generated by Doxygen 1.7.4 -->
|
||||
<script type="text/javascript"><!--
|
||||
var searchBox = new SearchBox("searchBox", "search",false,'Search');
|
||||
--></script>
|
||||
<div id="top">
|
||||
<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 style="padding-left: 0.5em;">
|
||||
<div id="projectname">ArduinoLibs</div>
|
||||
<div id="projectname">ArduinoLibs
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
<!-- end header part -->
|
||||
<!-- Generated by Doxygen 1.8.1.2 -->
|
||||
<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>
|
||||
@@ -32,7 +40,7 @@ var searchBox = new SearchBox("searchBox", "search",false,'Search');
|
||||
<li><a href="modules.html"><span>Modules</span></a></li>
|
||||
<li><a href="annotated.html"><span>Classes</span></a></li>
|
||||
<li><a href="files.html"><span>Files</span></a></li>
|
||||
<li id="searchli">
|
||||
<li>
|
||||
<div id="MSearchBox" class="MSearchBoxInactive">
|
||||
<span class="left">
|
||||
<img id="MSearchSelect" src="search/mag_sel.png"
|
||||
@@ -50,103 +58,12 @@ var searchBox = new SearchBox("searchBox", "search",false,'Search');
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<div class="header">
|
||||
<div class="headertitle">
|
||||
<div class="title">Hello World for Freetronics <a class="el" href="classLCD.html" title="Enhanced library for Freetronics 16x2 LCD shields.">LCD</a> </div> </div>
|
||||
</div>
|
||||
<div class="contents">
|
||||
<div class="textblock"><p>The <a class="el" href="classLCD.html" title="Enhanced library for Freetronics 16x2 LCD shields.">LCD</a> class provides an enhanced version of the standard Arduino <a href="http://arduino.cc/en/Reference/LiquidCrystal">LiquidCrystal</a> library that supports the additional features of the <a href="http://www.freetronics.com/pages/16x2-lcd-shield-quickstart-guide">Freetronics LCD</a> shield; namely the back light and the Up, Down, Left, Right, and Select buttons. This tutorial explains how to use the <a class="el" href="classLCD.html" title="Enhanced library for Freetronics 16x2 LCD shields.">LCD</a> class to perform basic text output and to use the enhanced shield features.</p>
|
||||
<div class="image">
|
||||
<img src="HelloWorld.png" alt="HelloWorld.png"/>
|
||||
</div>
|
||||
<p>We start by including the library and initializing it:</p>
|
||||
<div class="fragment"><pre class="fragment"><span class="preprocessor">#include <LCD.h></span>
|
||||
<a class="code" href="classLCD.html" title="Enhanced library for Freetronics 16x2 LCD shields.">LCD</a> lcd;
|
||||
</pre></div></p>
|
||||
<p>Unlike the LiquidCrystal library we don't normally need to specify the pin assignments for this shield. The one exception is when the shield is used with the USBDroid and the D9 pin is reassigned as described on <a href="http://www.freetronics.com/pages/combining-the-lcd-keypad-shield-and-the-usbdroid">this page</a>. In that case, the initialization sequence would look something like this instead:</p>
|
||||
<div class="fragment"><pre class="fragment"><a class="code" href="classLCD.html" title="Enhanced library for Freetronics 16x2 LCD shields.">LCD</a> lcd(A1);
|
||||
</pre></div><p>The next step is to enable the screen saver and print some text in the <code>setup</code> function:</p>
|
||||
<div class="fragment"><pre class="fragment"><span class="keywordtype">void</span> setup() {
|
||||
lcd.<a class="code" href="classLCD.html#af9a2326d034fa159d384ec16223c924f" title="Enables the screen saver and causes it to activate after timeoutSecs of inactivity on the buttons...">enableScreenSaver</a>();
|
||||
lcd.print(<span class="stringliteral">"hello, world!"</span>);
|
||||
}
|
||||
</pre></div></p>
|
||||
<p>The screen saver is a built-in feature of the <a class="el" href="classLCD.html" title="Enhanced library for Freetronics 16x2 LCD shields.">LCD</a> class that turns off the display and the back light after a specific timeout (the default is 10 seconds). Pressing any of the keys on the shield or calling <a class="el" href="classLCD.html#a5b07cf05e8e5e7c53654f5ca0cf58b89" title="Turns on the display of text on the LCD and the back light.">LCD::display()</a> will wake up the screen again.</p>
|
||||
<p>In the program's <code>loop</code> function we print the number of seconds since startup to the second line of the <a class="el" href="classLCD.html" title="Enhanced library for Freetronics 16x2 LCD shields.">LCD</a> display:</p>
|
||||
<div class="fragment"><pre class="fragment"><span class="keywordtype">void</span> loop() {
|
||||
lcd.setCursor(0, 1);
|
||||
lcd.print(millis() / 1000);
|
||||
</pre></div></p>
|
||||
<p>We then print the name of the button that is currently pressed:</p>
|
||||
<div class="fragment"><pre class="fragment"> lcd.setCursor(8, 1);
|
||||
<span class="keywordtype">int</span> button = lcd.<a class="code" href="classLCD.html#ac1e80e2603bd1cf0276c36092c416292" title="Gets the next button press, release, or idle event.">getButton</a>();
|
||||
<span class="keywordflow">if</span> (button == LCD_BUTTON_LEFT)
|
||||
lcd.print(<span class="stringliteral">"LEFT"</span>);
|
||||
<span class="keywordflow">else</span> <span class="keywordflow">if</span> (button == LCD_BUTTON_RIGHT)
|
||||
lcd.print(<span class="stringliteral">"RIGHT"</span>);
|
||||
<span class="keywordflow">else</span> <span class="keywordflow">if</span> (button == LCD_BUTTON_UP)
|
||||
lcd.print(<span class="stringliteral">"UP"</span>);
|
||||
<span class="keywordflow">else</span> <span class="keywordflow">if</span> (button == LCD_BUTTON_DOWN)
|
||||
lcd.print(<span class="stringliteral">"DOWN"</span>);
|
||||
<span class="keywordflow">else</span> <span class="keywordflow">if</span> (button == LCD_BUTTON_SELECT)
|
||||
lcd.print(<span class="stringliteral">"SELECT"</span>);
|
||||
<span class="keywordflow">else</span> <span class="keywordflow">if</span> (button < 0) <span class="comment">// button release</span>
|
||||
lcd.print(<span class="stringliteral">" "</span>);
|
||||
}
|
||||
</pre></div></p>
|
||||
<p>The <a class="el" href="classLCD.html#ac1e80e2603bd1cf0276c36092c416292" title="Gets the next button press, release, or idle event.">LCD::getButton()</a> function returns the key that has been pressed or released, or LCD_BUTTON_NONE if no key has been pressed or released this time through the loop.</p>
|
||||
<p>The full source code for the example follows:</p>
|
||||
<div class="fragment"><pre class="fragment"><span class="comment">/*</span>
|
||||
<span class="comment">This example demonstrates how to use the LCD library, which extends the</span>
|
||||
<span class="comment">standard LiquidCrystal library to provide support for the Freetronics back light</span>
|
||||
<span class="comment">and Up/Down/Left/Right/Select buttons. More information on the shield here:</span>
|
||||
<span class="comment"></span>
|
||||
<span class="comment">http://www.freetronics.com/pages/16x2-lcd-shield-quickstart-guide</span>
|
||||
<span class="comment"></span>
|
||||
<span class="comment">This example is placed into the public domain.</span>
|
||||
<span class="comment">*/</span>
|
||||
|
||||
<span class="preprocessor">#include <LCD.h></span>
|
||||
<a class="code" href="classLCD.html" title="Enhanced library for Freetronics 16x2 LCD shields.">LCD</a> lcd;
|
||||
|
||||
<span class="comment">// Note: if you are using the USBDroid and have reassigned pin D9 on the LCD shield to some</span>
|
||||
<span class="comment">// other pin (e.g. A1), then you will need to initialize the shield with something like:</span>
|
||||
<span class="comment">// LCD lcd(A1);</span>
|
||||
<span class="comment">// See also: http://www.freetronics.com/pages/combining-the-lcd-keypad-shield-and-the-usbdroid</span>
|
||||
|
||||
<span class="keywordtype">void</span> setup() {
|
||||
lcd.<a class="code" href="classLCD.html#af9a2326d034fa159d384ec16223c924f" title="Enables the screen saver and causes it to activate after timeoutSecs of inactivity on the buttons...">enableScreenSaver</a>();
|
||||
lcd.print(<span class="stringliteral">"hello, world!"</span>);
|
||||
}
|
||||
|
||||
<span class="keywordtype">void</span> loop() {
|
||||
lcd.setCursor(0, 1);
|
||||
lcd.print(millis() / 1000);
|
||||
|
||||
lcd.setCursor(8, 1);
|
||||
<span class="keywordtype">int</span> button = lcd.<a class="code" href="classLCD.html#ac1e80e2603bd1cf0276c36092c416292" title="Gets the next button press, release, or idle event.">getButton</a>();
|
||||
<span class="keywordflow">if</span> (button == LCD_BUTTON_LEFT)
|
||||
lcd.print(<span class="stringliteral">"LEFT"</span>);
|
||||
<span class="keywordflow">else</span> <span class="keywordflow">if</span> (button == LCD_BUTTON_RIGHT)
|
||||
lcd.print(<span class="stringliteral">"RIGHT"</span>);
|
||||
<span class="keywordflow">else</span> <span class="keywordflow">if</span> (button == LCD_BUTTON_UP)
|
||||
lcd.print(<span class="stringliteral">"UP"</span>);
|
||||
<span class="keywordflow">else</span> <span class="keywordflow">if</span> (button == LCD_BUTTON_DOWN)
|
||||
lcd.print(<span class="stringliteral">"DOWN"</span>);
|
||||
<span class="keywordflow">else</span> <span class="keywordflow">if</span> (button == LCD_BUTTON_SELECT)
|
||||
lcd.print(<span class="stringliteral">"SELECT"</span>);
|
||||
<span class="keywordflow">else</span> <span class="keywordflow">if</span> (button < 0) <span class="comment">// button release</span>
|
||||
lcd.print(<span class="stringliteral">" "</span>);
|
||||
}
|
||||
|
||||
</pre></div> </div></div>
|
||||
<!-- window showing the filter options -->
|
||||
<div id="MSearchSelectWindow"
|
||||
onmouseover="return searchBox.OnSearchSelectShow()"
|
||||
onmouseout="return searchBox.OnSearchSelectHide()"
|
||||
onkeydown="return searchBox.OnSearchSelectKey(event)">
|
||||
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark"> </span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark"> </span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark"> </span>Files</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark"> </span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark"> </span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark"> </span>Typedefs</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark"> </span>Enumerations</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(7)"><span class="SelectionMark"> </span>Enumerator</a></div>
|
||||
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark"> </span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark"> </span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark"> </span>Files</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark"> </span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark"> </span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark"> </span>Typedefs</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark"> </span>Enumerations</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(7)"><span class="SelectionMark"> </span>Enumerator</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(8)"><span class="SelectionMark"> </span>Groups</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(9)"><span class="SelectionMark"> </span>Pages</a></div>
|
||||
|
||||
<!-- iframe showing the search results (closed by default) -->
|
||||
<div id="MSearchResultsWindow">
|
||||
@@ -155,8 +72,102 @@ var searchBox = new SearchBox("searchBox", "search",false,'Search');
|
||||
</iframe>
|
||||
</div>
|
||||
|
||||
<hr class="footer"/><address class="footer"><small>Generated on Mon Jun 18 2012 11:02:52 for ArduinoLibs by 
|
||||
<a href="http://www.doxygen.org/index.html">
|
||||
<img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.7.4 </small></address>
|
||||
</div><!-- top -->
|
||||
<div class="header">
|
||||
<div class="headertitle">
|
||||
<div class="title">Hello World for Freetronics <a class="el" href="classLCD.html" title="Enhanced library for Freetronics 16x2 LCD shields.">LCD</a> </div> </div>
|
||||
</div><!--header-->
|
||||
<div class="contents">
|
||||
<div class="textblock"><p>The <a class="el" href="classLCD.html" title="Enhanced library for Freetronics 16x2 LCD shields.">LCD</a> class provides an enhanced version of the standard Arduino <a href="http://arduino.cc/en/Reference/LiquidCrystal">LiquidCrystal</a> library that supports the additional features of the <a href="http://www.freetronics.com/pages/16x2-lcd-shield-quickstart-guide">Freetronics LCD</a> shield; namely the back light and the Up, Down, Left, Right, and Select buttons. This tutorial explains how to use the <a class="el" href="classLCD.html" title="Enhanced library for Freetronics 16x2 LCD shields.">LCD</a> class to perform basic text output and to use the enhanced shield features.</p>
|
||||
<div class="image">
|
||||
<img src="HelloWorld.png" alt="HelloWorld.png"/>
|
||||
</div>
|
||||
<p>We start by including the library and initializing it:</p>
|
||||
<div class="fragment"><div class="line"><span class="preprocessor">#include <LCD.h></span></div>
|
||||
<div class="line"><a class="code" href="classLCD.html" title="Enhanced library for Freetronics 16x2 LCD shields.">LCD</a> lcd;</div>
|
||||
</div><!-- fragment --></p>
|
||||
<p>Unlike the LiquidCrystal library we don't normally need to specify the pin assignments for this shield. The one exception is when the shield is used with the USBDroid and the D9 pin is reassigned as described on <a href="http://www.freetronics.com/pages/combining-the-lcd-keypad-shield-and-the-usbdroid">this page</a>. In that case, the initialization sequence would look something like this instead:</p>
|
||||
<div class="fragment"><div class="line"><a class="code" href="classLCD.html" title="Enhanced library for Freetronics 16x2 LCD shields.">LCD</a> lcd(A1);</div>
|
||||
</div><!-- fragment --><p>The next step is to enable the screen saver and print some text in the <code>setup</code> function:</p>
|
||||
<div class="fragment"><div class="line"><span class="keywordtype">void</span> setup() {</div>
|
||||
<div class="line"> lcd.<a class="code" href="classLCD.html#af9a2326d034fa159d384ec16223c924f" title="Enables the screen saver and causes it to activate after timeoutSecs of inactivity on the buttons...">enableScreenSaver</a>();</div>
|
||||
<div class="line"> lcd.print(<span class="stringliteral">"hello, world!"</span>);</div>
|
||||
<div class="line">}</div>
|
||||
</div><!-- fragment --></p>
|
||||
<p>The screen saver is a built-in feature of the <a class="el" href="classLCD.html" title="Enhanced library for Freetronics 16x2 LCD shields.">LCD</a> class that turns off the display and the back light after a specific timeout (the default is 10 seconds). Pressing any of the keys on the shield or calling <a class="el" href="classLCD.html#a5b07cf05e8e5e7c53654f5ca0cf58b89" title="Turns on the display of text on the LCD and the back light.">LCD::display()</a> will wake up the screen again.</p>
|
||||
<p>In the program's <code>loop</code> function we print the number of seconds since startup to the second line of the <a class="el" href="classLCD.html" title="Enhanced library for Freetronics 16x2 LCD shields.">LCD</a> display:</p>
|
||||
<div class="fragment"><div class="line"><span class="keywordtype">void</span> loop() {</div>
|
||||
<div class="line"> lcd.setCursor(0, 1);</div>
|
||||
<div class="line"> lcd.print(millis() / 1000);</div>
|
||||
</div><!-- fragment --></p>
|
||||
<p>We then print the name of the button that is currently pressed:</p>
|
||||
<div class="fragment"><div class="line"> lcd.setCursor(8, 1);</div>
|
||||
<div class="line"> <span class="keywordtype">int</span> button = lcd.<a class="code" href="classLCD.html#ac1e80e2603bd1cf0276c36092c416292" title="Gets the next button press, release, or idle event.">getButton</a>();</div>
|
||||
<div class="line"> <span class="keywordflow">if</span> (button == LCD_BUTTON_LEFT)</div>
|
||||
<div class="line"> lcd.print(<span class="stringliteral">"LEFT"</span>);</div>
|
||||
<div class="line"> <span class="keywordflow">else</span> <span class="keywordflow">if</span> (button == LCD_BUTTON_RIGHT)</div>
|
||||
<div class="line"> lcd.print(<span class="stringliteral">"RIGHT"</span>);</div>
|
||||
<div class="line"> <span class="keywordflow">else</span> <span class="keywordflow">if</span> (button == LCD_BUTTON_UP)</div>
|
||||
<div class="line"> lcd.print(<span class="stringliteral">"UP"</span>);</div>
|
||||
<div class="line"> <span class="keywordflow">else</span> <span class="keywordflow">if</span> (button == LCD_BUTTON_DOWN)</div>
|
||||
<div class="line"> lcd.print(<span class="stringliteral">"DOWN"</span>);</div>
|
||||
<div class="line"> <span class="keywordflow">else</span> <span class="keywordflow">if</span> (button == LCD_BUTTON_SELECT)</div>
|
||||
<div class="line"> lcd.print(<span class="stringliteral">"SELECT"</span>);</div>
|
||||
<div class="line"> <span class="keywordflow">else</span> <span class="keywordflow">if</span> (button < 0) <span class="comment">// button release</span></div>
|
||||
<div class="line"> lcd.print(<span class="stringliteral">" "</span>);</div>
|
||||
<div class="line">}</div>
|
||||
</div><!-- fragment --></p>
|
||||
<p>The <a class="el" href="classLCD.html#ac1e80e2603bd1cf0276c36092c416292" title="Gets the next button press, release, or idle event.">LCD::getButton()</a> function returns the key that has been pressed or released, or LCD_BUTTON_NONE if no key has been pressed or released this time through the loop.</p>
|
||||
<p>The full source code for the example follows:</p>
|
||||
<div class="fragment"><div class="line"><span class="comment">/*</span></div>
|
||||
<div class="line"><span class="comment">This example demonstrates how to use the LCD library, which extends the</span></div>
|
||||
<div class="line"><span class="comment">standard LiquidCrystal library to provide support for the Freetronics back light</span></div>
|
||||
<div class="line"><span class="comment">and Up/Down/Left/Right/Select buttons. More information on the shield here:</span></div>
|
||||
<div class="line"><span class="comment"></span></div>
|
||||
<div class="line"><span class="comment">http://www.freetronics.com/pages/16x2-lcd-shield-quickstart-guide</span></div>
|
||||
<div class="line"><span class="comment"></span></div>
|
||||
<div class="line"><span class="comment">This example is placed into the public domain.</span></div>
|
||||
<div class="line"><span class="comment">*/</span></div>
|
||||
<div class="line"></div>
|
||||
<div class="line"><span class="preprocessor">#include <LCD.h></span></div>
|
||||
<div class="line"><a class="code" href="classLCD.html" title="Enhanced library for Freetronics 16x2 LCD shields.">LCD</a> lcd;</div>
|
||||
<div class="line"></div>
|
||||
<div class="line"><span class="comment">// Note: if you are using the USBDroid and have reassigned pin D9 on the LCD shield to some</span></div>
|
||||
<div class="line"><span class="comment">// other pin (e.g. A1), then you will need to initialize the shield with something like:</span></div>
|
||||
<div class="line"><span class="comment">// LCD lcd(A1);</span></div>
|
||||
<div class="line"><span class="comment">// See also: http://www.freetronics.com/pages/combining-the-lcd-keypad-shield-and-the-usbdroid</span></div>
|
||||
<div class="line"></div>
|
||||
<div class="line"><span class="keywordtype">void</span> setup() {</div>
|
||||
<div class="line"> lcd.<a class="code" href="classLCD.html#af9a2326d034fa159d384ec16223c924f" title="Enables the screen saver and causes it to activate after timeoutSecs of inactivity on the buttons...">enableScreenSaver</a>();</div>
|
||||
<div class="line"> lcd.print(<span class="stringliteral">"hello, world!"</span>);</div>
|
||||
<div class="line">}</div>
|
||||
<div class="line"></div>
|
||||
<div class="line"><span class="keywordtype">void</span> loop() {</div>
|
||||
<div class="line"> lcd.setCursor(0, 1);</div>
|
||||
<div class="line"> lcd.print(millis() / 1000);</div>
|
||||
<div class="line"></div>
|
||||
<div class="line"> lcd.setCursor(8, 1);</div>
|
||||
<div class="line"> <span class="keywordtype">int</span> button = lcd.<a class="code" href="classLCD.html#ac1e80e2603bd1cf0276c36092c416292" title="Gets the next button press, release, or idle event.">getButton</a>();</div>
|
||||
<div class="line"> <span class="keywordflow">if</span> (button == LCD_BUTTON_LEFT)</div>
|
||||
<div class="line"> lcd.print(<span class="stringliteral">"LEFT"</span>);</div>
|
||||
<div class="line"> <span class="keywordflow">else</span> <span class="keywordflow">if</span> (button == LCD_BUTTON_RIGHT)</div>
|
||||
<div class="line"> lcd.print(<span class="stringliteral">"RIGHT"</span>);</div>
|
||||
<div class="line"> <span class="keywordflow">else</span> <span class="keywordflow">if</span> (button == LCD_BUTTON_UP)</div>
|
||||
<div class="line"> lcd.print(<span class="stringliteral">"UP"</span>);</div>
|
||||
<div class="line"> <span class="keywordflow">else</span> <span class="keywordflow">if</span> (button == LCD_BUTTON_DOWN)</div>
|
||||
<div class="line"> lcd.print(<span class="stringliteral">"DOWN"</span>);</div>
|
||||
<div class="line"> <span class="keywordflow">else</span> <span class="keywordflow">if</span> (button == LCD_BUTTON_SELECT)</div>
|
||||
<div class="line"> lcd.print(<span class="stringliteral">"SELECT"</span>);</div>
|
||||
<div class="line"> <span class="keywordflow">else</span> <span class="keywordflow">if</span> (button < 0) <span class="comment">// button release</span></div>
|
||||
<div class="line"> lcd.print(<span class="stringliteral">" "</span>);</div>
|
||||
<div class="line">}</div>
|
||||
<div class="line"></div>
|
||||
</div><!-- fragment --> </div></div><!-- contents -->
|
||||
<!-- start footer part -->
|
||||
<hr class="footer"/><address class="footer"><small>
|
||||
Generated on Sun Sep 29 2013 09:30:46 for ArduinoLibs by  <a href="http://www.doxygen.org/index.html">
|
||||
<img class="footer" src="doxygen.png" alt="doxygen"/>
|
||||
</a> 1.8.1.2
|
||||
</small></address>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
Reference in New Issue
Block a user