This repository has been archived on 2024-01-25. You can view files and clone it, but cannot push or open issues or pull requests.
Solar-Panel/html/adc_8h_source.html
2023-03-15 12:55:57 +01:00

192 lines
21 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" lang="en-US">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=11"/>
<meta name="generator" content="Doxygen 1.9.6"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>Solar panel: mcc_generated_files/adc.h Source File</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 id="projectrow">
<td id="projectalign">
<div id="projectname">Solar panel
</div>
</td>
</tr>
</tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.9.6 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
var searchBox = new SearchBox("searchBox", "search/",'.html');
/* @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:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
$(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:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
$(document).ready(function(){initNavTree('adc_8h_source.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">
<div id="MSearchResults">
<div class="SRPage">
<div id="SRIndex">
<div id="SRResults"></div>
<div class="SRStatus" id="Loading">Loading...</div>
<div class="SRStatus" id="Searching">Searching...</div>
<div class="SRStatus" id="NoMatches">No Matches</div>
</div>
</div>
</div>
</div>
<div class="header">
<div class="headertitle"><div class="title">adc.h</div></div>
</div><!--header-->
<div class="contents">
<a href="adc_8h.html">Go to the documentation of this file.</a><div class="fragment"><div class="line"><a id="l00001" name="l00001"></a><span class="lineno"> 1</span> </div>
<div class="line"><a id="l00024" name="l00024"></a><span class="lineno"> 24</span><span class="comment">/*</span></div>
<div class="line"><a id="l00025" name="l00025"></a><span class="lineno"> 25</span><span class="comment"> (c) 2018 Microchip Technology Inc. and its subsidiaries. </span></div>
<div class="line"><a id="l00026" name="l00026"></a><span class="lineno"> 26</span><span class="comment"> </span></div>
<div class="line"><a id="l00027" name="l00027"></a><span class="lineno"> 27</span><span class="comment"> Subject to your compliance with these terms, you may use Microchip software and any </span></div>
<div class="line"><a id="l00028" name="l00028"></a><span class="lineno"> 28</span><span class="comment"> derivatives exclusively with Microchip products. It is your responsibility to comply with third party </span></div>
<div class="line"><a id="l00029" name="l00029"></a><span class="lineno"> 29</span><span class="comment"> license terms applicable to your use of third party software (including open source software) that </span></div>
<div class="line"><a id="l00030" name="l00030"></a><span class="lineno"> 30</span><span class="comment"> may accompany Microchip software.</span></div>
<div class="line"><a id="l00031" name="l00031"></a><span class="lineno"> 31</span><span class="comment"> </span></div>
<div class="line"><a id="l00032" name="l00032"></a><span class="lineno"> 32</span><span class="comment"> THIS SOFTWARE IS SUPPLIED BY MICROCHIP &quot;AS IS&quot;. NO WARRANTIES, WHETHER </span></div>
<div class="line"><a id="l00033" name="l00033"></a><span class="lineno"> 33</span><span class="comment"> EXPRESS, IMPLIED OR STATUTORY, APPLY TO THIS SOFTWARE, INCLUDING ANY </span></div>
<div class="line"><a id="l00034" name="l00034"></a><span class="lineno"> 34</span><span class="comment"> IMPLIED WARRANTIES OF NON-INFRINGEMENT, MERCHANTABILITY, AND FITNESS </span></div>
<div class="line"><a id="l00035" name="l00035"></a><span class="lineno"> 35</span><span class="comment"> FOR A PARTICULAR PURPOSE.</span></div>
<div class="line"><a id="l00036" name="l00036"></a><span class="lineno"> 36</span><span class="comment"> </span></div>
<div class="line"><a id="l00037" name="l00037"></a><span class="lineno"> 37</span><span class="comment"> IN NO EVENT WILL MICROCHIP BE LIABLE FOR ANY INDIRECT, SPECIAL, PUNITIVE, </span></div>
<div class="line"><a id="l00038" name="l00038"></a><span class="lineno"> 38</span><span class="comment"> INCIDENTAL OR CONSEQUENTIAL LOSS, DAMAGE, COST OR EXPENSE OF ANY KIND </span></div>
<div class="line"><a id="l00039" name="l00039"></a><span class="lineno"> 39</span><span class="comment"> WHATSOEVER RELATED TO THE SOFTWARE, HOWEVER CAUSED, EVEN IF MICROCHIP </span></div>
<div class="line"><a id="l00040" name="l00040"></a><span class="lineno"> 40</span><span class="comment"> HAS BEEN ADVISED OF THE POSSIBILITY OR THE DAMAGES ARE FORESEEABLE. TO </span></div>
<div class="line"><a id="l00041" name="l00041"></a><span class="lineno"> 41</span><span class="comment"> THE FULLEST EXTENT ALLOWED BY LAW, MICROCHIP&#39;S TOTAL LIABILITY ON ALL </span></div>
<div class="line"><a id="l00042" name="l00042"></a><span class="lineno"> 42</span><span class="comment"> CLAIMS IN ANY WAY RELATED TO THIS SOFTWARE WILL NOT EXCEED THE AMOUNT </span></div>
<div class="line"><a id="l00043" name="l00043"></a><span class="lineno"> 43</span><span class="comment"> OF FEES, IF ANY, THAT YOU HAVE PAID DIRECTLY TO MICROCHIP FOR THIS </span></div>
<div class="line"><a id="l00044" name="l00044"></a><span class="lineno"> 44</span><span class="comment"> SOFTWARE.</span></div>
<div class="line"><a id="l00045" name="l00045"></a><span class="lineno"> 45</span><span class="comment">*/</span></div>
<div class="line"><a id="l00046" name="l00046"></a><span class="lineno"> 46</span> </div>
<div class="line"><a id="l00047" name="l00047"></a><span class="lineno"> 47</span><span class="preprocessor">#ifndef ADC_H</span></div>
<div class="line"><a id="l00048" name="l00048"></a><span class="lineno"> 48</span><span class="preprocessor">#define ADC_H</span></div>
<div class="line"><a id="l00049" name="l00049"></a><span class="lineno"> 49</span> </div>
<div class="line"><a id="l00054" name="l00054"></a><span class="lineno"> 54</span><span class="preprocessor">#include &lt;xc.h&gt;</span></div>
<div class="line"><a id="l00055" name="l00055"></a><span class="lineno"> 55</span><span class="preprocessor">#include &lt;stdint.h&gt;</span></div>
<div class="line"><a id="l00056" name="l00056"></a><span class="lineno"> 56</span><span class="preprocessor">#include &lt;stdbool.h&gt;</span></div>
<div class="line"><a id="l00057" name="l00057"></a><span class="lineno"> 57</span> </div>
<div class="line"><a id="l00058" name="l00058"></a><span class="lineno"> 58</span><span class="preprocessor">#ifdef __cplusplus </span><span class="comment">// Provide C++ Compatibility</span></div>
<div class="line"><a id="l00059" name="l00059"></a><span class="lineno"> 59</span> </div>
<div class="line"><a id="l00060" name="l00060"></a><span class="lineno"> 60</span> <span class="keyword">extern</span> <span class="stringliteral">&quot;C&quot;</span> {</div>
<div class="line"><a id="l00061" name="l00061"></a><span class="lineno"> 61</span> </div>
<div class="line"><a id="l00062" name="l00062"></a><span class="lineno"> 62</span><span class="preprocessor">#endif</span></div>
<div class="line"><a id="l00063" name="l00063"></a><span class="lineno"> 63</span> </div>
<div class="line"><a id="l00072" name="l00072"></a><span class="lineno"><a class="line" href="adc_8h.html#ac5362ae65441a5027b4b9b1bf1b573aa"> 72</a></span><span class="keyword">typedef</span> uint16_t <a class="code hl_typedef" href="adc_8h.html#ac5362ae65441a5027b4b9b1bf1b573aa">adc_result_t</a>;</div>
<div class="line"><a id="l00073" name="l00073"></a><span class="lineno"> 73</span> </div>
<div class="line"><a id="l00077" name="l00077"></a><span class="lineno"><a class="line" href="structadc__sync__double__result__t.html"> 77</a></span><span class="keyword">typedef</span> <span class="keyword">struct</span></div>
<div class="line"><a id="l00078" name="l00078"></a><span class="lineno"> 78</span>{</div>
<div class="line"><a id="l00079" name="l00079"></a><span class="lineno"><a class="line" href="structadc__sync__double__result__t.html#af8e1cac59f7562513545cc68e1e10386"> 79</a></span> <a class="code hl_typedef" href="adc_8h.html#ac5362ae65441a5027b4b9b1bf1b573aa">adc_result_t</a> <a class="code hl_variable" href="structadc__sync__double__result__t.html#af8e1cac59f7562513545cc68e1e10386">adcResult1</a>;</div>
<div class="line"><a id="l00080" name="l00080"></a><span class="lineno"><a class="line" href="structadc__sync__double__result__t.html#a816f0d43b8ee50c539734d97ff87e394"> 80</a></span> <a class="code hl_typedef" href="adc_8h.html#ac5362ae65441a5027b4b9b1bf1b573aa">adc_result_t</a> <a class="code hl_variable" href="structadc__sync__double__result__t.html#a816f0d43b8ee50c539734d97ff87e394">adcResult2</a>;</div>
<div class="line"><a id="l00081" name="l00081"></a><span class="lineno"> 81</span>} <a class="code hl_struct" href="structadc__sync__double__result__t.html">adc_sync_double_result_t</a>;</div>
<div class="line"><a id="l00082" name="l00082"></a><span class="lineno"> 82</span> </div>
<div class="line"><a id="l00095" name="l00095"></a><span class="lineno"><a class="line" href="adc_8h.html#aafc4060027875f8fe46242b0656d7814"> 95</a></span><span class="keyword">typedef</span> <span class="keyword">enum</span></div>
<div class="line"><a id="l00096" name="l00096"></a><span class="lineno"> 96</span>{</div>
<div class="line"><a id="l00097" name="l00097"></a><span class="lineno"><a class="line" href="adc_8h.html#aafc4060027875f8fe46242b0656d7814a20d31653fb88a46098aad34f773a827c"> 97</a></span> <a class="code hl_enumvalue" href="adc_8h.html#aafc4060027875f8fe46242b0656d7814a20d31653fb88a46098aad34f773a827c">voltage</a> = 0x5,</div>
<div class="line"><a id="l00098" name="l00098"></a><span class="lineno"> 98</span> <a class="code hl_enumvalue" href="adc_8h.html#aafc4060027875f8fe46242b0656d7814a8225bfb34b5298eb7529ec580a4d178e">current</a> = 0x6</div>
<div class="line"><a id="l00099" name="l00099"></a><span class="lineno"><a class="line" href="adc_8h.html#aafc4060027875f8fe46242b0656d7814a8225bfb34b5298eb7529ec580a4d178e"> 99</a></span>} <a class="code hl_enumeration" href="adc_8h.html#aafc4060027875f8fe46242b0656d7814">adc_channel_t</a>;</div>
<div class="line"><a id="l00100" name="l00100"></a><span class="lineno"> 100</span> </div>
<div class="line"><a id="l00134" name="l00134"></a><span class="lineno"> 134</span><span class="keywordtype">void</span> <a class="code hl_function" href="adc_8h.html#ab0e0ea1662a8e789547210a2d33127e1">ADC_Initialize</a>(<span class="keywordtype">void</span>);</div>
<div class="line"><a id="l00135" name="l00135"></a><span class="lineno"> 135</span> </div>
<div class="line"><a id="l00164" name="l00164"></a><span class="lineno"> 164</span><span class="keywordtype">void</span> <a class="code hl_function" href="adc_8h.html#a25c0a0a9fe2bdba070f9945ca641b5e0">ADC_SelectChannel</a>(<a class="code hl_enumeration" href="adc_8h.html#aafc4060027875f8fe46242b0656d7814">adc_channel_t</a> channel);</div>
<div class="line"><a id="l00165" name="l00165"></a><span class="lineno"> 165</span> </div>
<div class="line"><a id="l00191" name="l00191"></a><span class="lineno"> 191</span><span class="keywordtype">void</span> <a class="code hl_function" href="adc_8h.html#af96ee69b063edcebc656d0ca0450c12c">ADC_StartConversion</a>(<span class="keywordtype">void</span>);</div>
<div class="line"><a id="l00192" name="l00192"></a><span class="lineno"> 192</span> </div>
<div class="line"><a id="l00223" name="l00223"></a><span class="lineno"> 223</span><span class="keywordtype">bool</span> <a class="code hl_function" href="adc_8h.html#ad5c10c1709aeacf08e783c3ea174463b">ADC_IsConversionDone</a>(<span class="keywordtype">void</span>);</div>
<div class="line"><a id="l00224" name="l00224"></a><span class="lineno"> 224</span> </div>
<div class="line"><a id="l00256" name="l00256"></a><span class="lineno"> 256</span><a class="code hl_typedef" href="adc_8h.html#ac5362ae65441a5027b4b9b1bf1b573aa">adc_result_t</a> <a class="code hl_function" href="adc_8h.html#a9650956bd92194e1b9f0bfd5bb2d73dd">ADC_GetConversionResult</a>(<span class="keywordtype">void</span>);</div>
<div class="line"><a id="l00257" name="l00257"></a><span class="lineno"> 257</span> </div>
<div class="line"><a id="l00286" name="l00286"></a><span class="lineno"> 286</span><a class="code hl_typedef" href="adc_8h.html#ac5362ae65441a5027b4b9b1bf1b573aa">adc_result_t</a> <a class="code hl_function" href="adc_8h.html#a81501f9b96aa9bb8dbe63b49d0f8e909">ADC_GetConversion</a>(<a class="code hl_enumeration" href="adc_8h.html#aafc4060027875f8fe46242b0656d7814">adc_channel_t</a> channel);</div>
<div class="line"><a id="l00287" name="l00287"></a><span class="lineno"> 287</span> </div>
<div class="line"><a id="l00314" name="l00314"></a><span class="lineno"> 314</span><span class="keywordtype">void</span> <a class="code hl_function" href="adc_8h.html#a46bdd78f96c668432d4ff33115c9dcd9">ADC_TemperatureAcquisitionDelay</a>(<span class="keywordtype">void</span>);</div>
<div class="line"><a id="l00315" name="l00315"></a><span class="lineno"> 315</span> </div>
<div class="line"><a id="l00316" name="l00316"></a><span class="lineno"> 316</span><span class="preprocessor">#ifdef __cplusplus </span><span class="comment">// Provide C++ Compatibility</span></div>
<div class="line"><a id="l00317" name="l00317"></a><span class="lineno"> 317</span> </div>
<div class="line"><a id="l00318" name="l00318"></a><span class="lineno"> 318</span> }</div>
<div class="line"><a id="l00319" name="l00319"></a><span class="lineno"> 319</span> </div>
<div class="line"><a id="l00320" name="l00320"></a><span class="lineno"> 320</span><span class="preprocessor">#endif</span></div>
<div class="line"><a id="l00321" name="l00321"></a><span class="lineno"> 321</span> </div>
<div class="line"><a id="l00322" name="l00322"></a><span class="lineno"> 322</span><span class="preprocessor">#endif </span><span class="comment">//ADC_H</span></div>
<div class="ttc" id="aadc_8h_html_a25c0a0a9fe2bdba070f9945ca641b5e0"><div class="ttname"><a href="adc_8h.html#a25c0a0a9fe2bdba070f9945ca641b5e0">ADC_SelectChannel</a></div><div class="ttdeci">void ADC_SelectChannel(adc_channel_t channel)</div><div class="ttdef"><b>Definition:</b> <a href="adc_8c_source.html#l00082">adc.c:82</a></div></div>
<div class="ttc" id="aadc_8h_html_a46bdd78f96c668432d4ff33115c9dcd9"><div class="ttname"><a href="adc_8h.html#a46bdd78f96c668432d4ff33115c9dcd9">ADC_TemperatureAcquisitionDelay</a></div><div class="ttdeci">void ADC_TemperatureAcquisitionDelay(void)</div><div class="ttdef"><b>Definition:</b> <a href="adc_8c_source.html#l00129">adc.c:129</a></div></div>
<div class="ttc" id="aadc_8h_html_a81501f9b96aa9bb8dbe63b49d0f8e909"><div class="ttname"><a href="adc_8h.html#a81501f9b96aa9bb8dbe63b49d0f8e909">ADC_GetConversion</a></div><div class="ttdeci">adc_result_t ADC_GetConversion(adc_channel_t channel)</div><div class="ttdef"><b>Definition:</b> <a href="adc_8c_source.html#l00109">adc.c:109</a></div></div>
<div class="ttc" id="aadc_8h_html_a9650956bd92194e1b9f0bfd5bb2d73dd"><div class="ttname"><a href="adc_8h.html#a9650956bd92194e1b9f0bfd5bb2d73dd">ADC_GetConversionResult</a></div><div class="ttdeci">adc_result_t ADC_GetConversionResult(void)</div><div class="ttdef"><b>Definition:</b> <a href="adc_8c_source.html#l00103">adc.c:103</a></div></div>
<div class="ttc" id="aadc_8h_html_aafc4060027875f8fe46242b0656d7814"><div class="ttname"><a href="adc_8h.html#aafc4060027875f8fe46242b0656d7814">adc_channel_t</a></div><div class="ttdeci">adc_channel_t</div><div class="ttdef"><b>Definition:</b> <a href="adc_8h_source.html#l00095">adc.h:96</a></div></div>
<div class="ttc" id="aadc_8h_html_aafc4060027875f8fe46242b0656d7814a20d31653fb88a46098aad34f773a827c"><div class="ttname"><a href="adc_8h.html#aafc4060027875f8fe46242b0656d7814a20d31653fb88a46098aad34f773a827c">voltage</a></div><div class="ttdeci">@ voltage</div><div class="ttdef"><b>Definition:</b> <a href="adc_8h_source.html#l00097">adc.h:97</a></div></div>
<div class="ttc" id="aadc_8h_html_aafc4060027875f8fe46242b0656d7814a8225bfb34b5298eb7529ec580a4d178e"><div class="ttname"><a href="adc_8h.html#aafc4060027875f8fe46242b0656d7814a8225bfb34b5298eb7529ec580a4d178e">current</a></div><div class="ttdeci">@ current</div><div class="ttdef"><b>Definition:</b> <a href="adc_8h_source.html#l00099">adc.h:98</a></div></div>
<div class="ttc" id="aadc_8h_html_ab0e0ea1662a8e789547210a2d33127e1"><div class="ttname"><a href="adc_8h.html#ab0e0ea1662a8e789547210a2d33127e1">ADC_Initialize</a></div><div class="ttdeci">void ADC_Initialize(void)</div><div class="ttdef"><b>Definition:</b> <a href="adc_8c_source.html#l00061">adc.c:61</a></div></div>
<div class="ttc" id="aadc_8h_html_ac5362ae65441a5027b4b9b1bf1b573aa"><div class="ttname"><a href="adc_8h.html#ac5362ae65441a5027b4b9b1bf1b573aa">adc_result_t</a></div><div class="ttdeci">uint16_t adc_result_t</div><div class="ttdef"><b>Definition:</b> <a href="adc_8h_source.html#l00072">adc.h:72</a></div></div>
<div class="ttc" id="aadc_8h_html_ad5c10c1709aeacf08e783c3ea174463b"><div class="ttname"><a href="adc_8h.html#ad5c10c1709aeacf08e783c3ea174463b">ADC_IsConversionDone</a></div><div class="ttdeci">bool ADC_IsConversionDone(void)</div><div class="ttdef"><b>Definition:</b> <a href="adc_8c_source.html#l00097">adc.c:97</a></div></div>
<div class="ttc" id="aadc_8h_html_af96ee69b063edcebc656d0ca0450c12c"><div class="ttname"><a href="adc_8h.html#af96ee69b063edcebc656d0ca0450c12c">ADC_StartConversion</a></div><div class="ttdeci">void ADC_StartConversion(void)</div><div class="ttdef"><b>Definition:</b> <a href="adc_8c_source.html#l00090">adc.c:90</a></div></div>
<div class="ttc" id="astructadc__sync__double__result__t_html"><div class="ttname"><a href="structadc__sync__double__result__t.html">adc_sync_double_result_t</a></div><div class="ttdef"><b>Definition:</b> <a href="adc_8h_source.html#l00077">adc.h:78</a></div></div>
<div class="ttc" id="astructadc__sync__double__result__t_html_a816f0d43b8ee50c539734d97ff87e394"><div class="ttname"><a href="structadc__sync__double__result__t.html#a816f0d43b8ee50c539734d97ff87e394">adc_sync_double_result_t::adcResult2</a></div><div class="ttdeci">adc_result_t adcResult2</div><div class="ttdef"><b>Definition:</b> <a href="adc_8h_source.html#l00080">adc.h:80</a></div></div>
<div class="ttc" id="astructadc__sync__double__result__t_html_af8e1cac59f7562513545cc68e1e10386"><div class="ttname"><a href="structadc__sync__double__result__t.html#af8e1cac59f7562513545cc68e1e10386">adc_sync_double_result_t::adcResult1</a></div><div class="ttdeci">adc_result_t adcResult1</div><div class="ttdef"><b>Definition:</b> <a href="adc_8h_source.html#l00079">adc.h:79</a></div></div>
</div><!-- fragment --></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="dir_0ad8aa10ae8c15a00cc43e117933779f.html">mcc_generated_files</a></li><li class="navelem"><a class="el" href="adc_8h.html">adc.h</a></li>
<li class="footer">Generated by <a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.9.6 </li>
</ul>
</div>
</body>
</html>