-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
74 changed files
with
2,450 additions
and
809 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,208 @@ | ||
<!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.10.0"/> | ||
<meta name="viewport" content="width=device-width, initial-scale=1"/> | ||
<title>PER Firmware: source/pdu/auto_switch/auto_switch.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> | ||
<script type="text/javascript" src="clipboard.js"></script> | ||
<script type="text/javascript" src="cookie.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">PER Firmware | ||
</div> | ||
</td> | ||
</tr> | ||
</tbody> | ||
</table> | ||
</div> | ||
<!-- end header part --> | ||
<!-- Generated by Doxygen 1.10.0 --> | ||
<script type="text/javascript"> | ||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&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&dn=expat.txt MIT */ | ||
$(function() { | ||
initMenu('',true,false,'search.php','Search'); | ||
$(function() { init_search(); }); | ||
}); | ||
/* @license-end */ | ||
</script> | ||
<div id="main-nav"></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"> | ||
<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 id="nav-path" class="navpath"> | ||
<ul> | ||
<li class="navelem"><a class="el" href="dir_b2f33c71d4aa5e7af42a1ca61ff5af1b.html">source</a></li><li class="navelem"><a class="el" href="dir_9d9eb10f0bbaade9ac8f82a0e05a480b.html">pdu</a></li><li class="navelem"><a class="el" href="dir_779b9deccfc03a296e3883562e470c2a.html">auto_switch</a></li> </ul> | ||
</div> | ||
</div><!-- top --> | ||
<div class="header"> | ||
<div class="summary"> | ||
<a href="#func-members">Functions</a> | | ||
<a href="#var-members">Variables</a> </div> | ||
<div class="headertitle"><div class="title">auto_switch.c File Reference</div></div> | ||
</div><!--header--> | ||
<div class="contents"> | ||
<div class="textblock"><code>#include "<a class="el" href="auto__switch_8h_source.html">auto_switch.h</a>"</code><br /> | ||
<code>#include "<a class="el" href="phal__F4__F7_2gpio_2gpio_8h_source.html">common/phal_F4_F7/gpio/gpio.h</a>"</code><br /> | ||
</div><table class="memberdecls"> | ||
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="func-members" name="func-members"></a> | ||
Functions</h2></td></tr> | ||
<tr class="memitem:a8509532d58f56e7044ab6f36a2f17eb5" id="r_a8509532d58f56e7044ab6f36a2f17eb5"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="#a8509532d58f56e7044ab6f36a2f17eb5">setSwitch</a> (<a class="el" href="auto__switch_8h.html#afd674820118f9c76a33b0b8a9b0ff908">switches_t</a> auto_switch_enum, bool state)</td></tr> | ||
<tr class="memdesc:a8509532d58f56e7044ab6f36a2f17eb5"><td class="mdescLeft"> </td><td class="mdescRight">Enable or disable a switch. <br /></td></tr> | ||
<tr class="separator:a8509532d58f56e7044ab6f36a2f17eb5"><td class="memSeparator" colspan="2"> </td></tr> | ||
<tr class="memitem:a9615dad272d72b1eda4edb0eabf3c4ae" id="r_a9615dad272d72b1eda4edb0eabf3c4ae"><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="#a9615dad272d72b1eda4edb0eabf3c4ae">getSwitchStatus</a> (<a class="el" href="auto__switch_8h.html#afd674820118f9c76a33b0b8a9b0ff908">switches_t</a> auto_switch_enum)</td></tr> | ||
<tr class="memdesc:a9615dad272d72b1eda4edb0eabf3c4ae"><td class="mdescLeft"> </td><td class="mdescRight">Check if a switch is enabled. <br /></td></tr> | ||
<tr class="separator:a9615dad272d72b1eda4edb0eabf3c4ae"><td class="memSeparator" colspan="2"> </td></tr> | ||
<tr class="memitem:a467332216958e3faa3f70724fcf10194" id="r_a467332216958e3faa3f70724fcf10194"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="#a467332216958e3faa3f70724fcf10194">autoSwitchPeriodic</a> ()</td></tr> | ||
<tr class="memdesc:a467332216958e3faa3f70724fcf10194"><td class="mdescLeft"> </td><td class="mdescRight">Combined function that calls updateVoltage() and updateCurrent() <br /></td></tr> | ||
<tr class="separator:a467332216958e3faa3f70724fcf10194"><td class="memSeparator" colspan="2"> </td></tr> | ||
</table><table class="memberdecls"> | ||
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="var-members" name="var-members"></a> | ||
Variables</h2></td></tr> | ||
<tr class="memitem:a19dbab87e0ceca06b137d8feb5b2dc90" id="r_a19dbab87e0ceca06b137d8feb5b2dc90"><td class="memItemLeft" align="right" valign="top"><a class="el" href="structauto__switches__t.html">auto_switches_t</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="#a19dbab87e0ceca06b137d8feb5b2dc90">auto_switches</a></td></tr> | ||
<tr class="separator:a19dbab87e0ceca06b137d8feb5b2dc90"><td class="memSeparator" colspan="2"> </td></tr> | ||
</table> | ||
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2> | ||
<div class="textblock"><dl class="section author"><dt>Author</dt><dd>Gavin Zyonse (<a href="#" onclick="location.href='mai'+'lto:'+'gzy'+'on'+'se@'+'pu'+'rdu'+'e.'+'edu'; return false;">gzyon<span class="obfuscator">.nosp@m.</span>se@p<span class="obfuscator">.nosp@m.</span>urdue<span class="obfuscator">.nosp@m.</span>.edu</a>) </dd></dl> | ||
<dl class="section version"><dt>Version</dt><dd>1.0 </dd></dl> | ||
<dl class="section date"><dt>Date</dt><dd>2023-11-09</dd></dl> | ||
<dl class="section copyright"><dt>Copyright</dt><dd>Copyright (c) 2023 </dd></dl> | ||
</div><h2 class="groupheader">Function Documentation</h2> | ||
<a id="a467332216958e3faa3f70724fcf10194" name="a467332216958e3faa3f70724fcf10194"></a> | ||
<h2 class="memtitle"><span class="permalink"><a href="#a467332216958e3faa3f70724fcf10194">◆ </a></span>autoSwitchPeriodic()</h2> | ||
|
||
<div class="memitem"> | ||
<div class="memproto"> | ||
<table class="memname"> | ||
<tr> | ||
<td class="memname">void autoSwitchPeriodic </td> | ||
<td>(</td> | ||
<td class="paramname"><span class="paramname"></span></td><td>)</td> | ||
<td></td> | ||
</tr> | ||
</table> | ||
</div><div class="memdoc"> | ||
|
||
<p>Combined function that calls updateVoltage() and updateCurrent() </p> | ||
<p>Voltage on each rail is stored at: auto_switches.voltage.in_24v auto_switches.voltage.out_5v auto_switches.voltage.out_3v3</p> | ||
<p>Current through each switch is stored at: auto_switches.current[auto_switch_enum] </p> | ||
|
||
</div> | ||
</div> | ||
<a id="a9615dad272d72b1eda4edb0eabf3c4ae" name="a9615dad272d72b1eda4edb0eabf3c4ae"></a> | ||
<h2 class="memtitle"><span class="permalink"><a href="#a9615dad272d72b1eda4edb0eabf3c4ae">◆ </a></span>getSwitchStatus()</h2> | ||
|
||
<div class="memitem"> | ||
<div class="memproto"> | ||
<table class="memname"> | ||
<tr> | ||
<td class="memname">bool getSwitchStatus </td> | ||
<td>(</td> | ||
<td class="paramtype"><a class="el" href="auto__switch_8h.html#afd674820118f9c76a33b0b8a9b0ff908">switches_t</a></td> <td class="paramname"><span class="paramname"><em>auto_switch_enum</em></span></td><td>)</td> | ||
<td></td> | ||
</tr> | ||
</table> | ||
</div><div class="memdoc"> | ||
|
||
<p>Check if a switch is enabled. </p> | ||
<dl class="params"><dt>Parameters</dt><dd> | ||
<table class="params"> | ||
<tr><td class="paramname">auto_switch_enum</td><td>Switch to check </td></tr> | ||
</table> | ||
</dd> | ||
</dl> | ||
<dl class="section return"><dt>Returns</dt><dd>1 if enabled, 0 if disabled </dd></dl> | ||
|
||
</div> | ||
</div> | ||
<a id="a8509532d58f56e7044ab6f36a2f17eb5" name="a8509532d58f56e7044ab6f36a2f17eb5"></a> | ||
<h2 class="memtitle"><span class="permalink"><a href="#a8509532d58f56e7044ab6f36a2f17eb5">◆ </a></span>setSwitch()</h2> | ||
|
||
<div class="memitem"> | ||
<div class="memproto"> | ||
<table class="memname"> | ||
<tr> | ||
<td class="memname">void setSwitch </td> | ||
<td>(</td> | ||
<td class="paramtype"><a class="el" href="auto__switch_8h.html#afd674820118f9c76a33b0b8a9b0ff908">switches_t</a></td> <td class="paramname"><span class="paramname"><em>auto_switch_enum</em>, </span></td> | ||
</tr> | ||
<tr> | ||
<td class="paramkey"></td> | ||
<td></td> | ||
<td class="paramtype">bool</td> <td class="paramname"><span class="paramname"><em>state</em></span> )</td> | ||
</tr> | ||
</table> | ||
</div><div class="memdoc"> | ||
|
||
<p>Enable or disable a switch. </p> | ||
<dl class="params"><dt>Parameters</dt><dd> | ||
<table class="params"> | ||
<tr><td class="paramname">auto_switch_enum</td><td>Switch to enable or disable </td></tr> | ||
<tr><td class="paramname">state</td><td>1 to enable, 0 to disable </td></tr> | ||
</table> | ||
</dd> | ||
</dl> | ||
|
||
</div> | ||
</div> | ||
<h2 class="groupheader">Variable Documentation</h2> | ||
<a id="a19dbab87e0ceca06b137d8feb5b2dc90" name="a19dbab87e0ceca06b137d8feb5b2dc90"></a> | ||
<h2 class="memtitle"><span class="permalink"><a href="#a19dbab87e0ceca06b137d8feb5b2dc90">◆ </a></span>auto_switches</h2> | ||
|
||
<div class="memitem"> | ||
<div class="memproto"> | ||
<table class="memname"> | ||
<tr> | ||
<td class="memname"><a class="el" href="structauto__switches__t.html">auto_switches_t</a> auto_switches</td> | ||
</tr> | ||
</table> | ||
</div><div class="memdoc"> | ||
|
||
</div> | ||
</div> | ||
</div><!-- contents --> | ||
<!-- start footer part --> | ||
<hr class="footer"/><address class="footer"><small> | ||
Generated by <a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.10.0 | ||
</small></address> | ||
</body> | ||
</html> |
Oops, something went wrong.