Files
2018-01-17 21:06:28 +01:00

104 lines
5.4 KiB
HTML

<!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.13"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>Chameleon-Mini: Log functionality</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>
<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">Chameleon-Mini
</div>
</td>
</tr>
</tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.13 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
$(function() {
initMenu('',true,false,'search.php','Search');
$(document).ready(function() { init_search(); });
});
</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">
<iframe src="javascript:void(0)" frameborder="0"
name="MSearchResults" id="MSearchResults">
</iframe>
</div>
<div id="nav-path" class="navpath">
<ul>
<li class="navelem"><a class="el" href="index.html">index</a></li> </ul>
</div>
</div><!-- top -->
<div class="header">
<div class="headertitle">
<div class="title">Log functionality </div> </div>
</div><!--header-->
<div class="contents">
<div class="textblock"><p>The ChameleonMini provides a configurable log functionality. This page describes how to use it.</p>
<h1>Log Entry Format </h1>
<p>The log entries use a TLV (Type Length Value)-like format: </p><table class="doxtable">
<tr>
<th>Name </th><th>Size </th><th>Description </th></tr>
<tr>
<td>Entry type </td><td>1 byte </td><td>See <a class="el" href="_log_8h.html#a34112fbd78128ae58dc7801690dfa6e0">LogEntryEnum</a> </td></tr>
<tr>
<td>Data length </td><td>1 byte </td><td>This is the length of the appended data. </td></tr>
<tr>
<td>Timestamp </td><td>2 bytes </td><td>This is the current systick value. </td></tr>
<tr>
<td>Data </td><td><em>Data length</em> bytes </td><td>It is also possible that no data is appended, then the <code>Data length</code> field is zero. </td></tr>
</table>
<h1>Entry Types </h1>
<p>See <a class="el" href="_log_8h.html#a34112fbd78128ae58dc7801690dfa6e0">LogEntryEnum</a>.</p>
<h1>Log Modes </h1>
<p>Currently there exist three log modes:</p><ul>
<li><code>OFF</code>, which means that nothing is logged.</li>
<li><code>LIVE</code>, which means that log events are written directly to the terminal (untested).</li>
<li><code>MEMORY</code>, where the log events are written to SRAM.</li>
</ul>
<dl class="section note"><dt>Note</dt><dd>If there is not enough log memory, the log mode is automatically set to <code>OFF</code>.</dd></dl>
<dl class="section warning"><dt>Warning</dt><dd>Since the <code>MEMORY</code> log mode writes to SRAM, the log memory is cleared by power off or restarting the Chameleon.</dd></dl>
<h1>Related Commands, Button event and LED functions </h1>
<p>There are various commands to configure the log functionality. See <a class="el" href="_page__command_line.html#Anchor_LogFunctions">Page Command Line</a>. Equivalently to the <code>LOGSTORE</code> command, the buttons are configurable to <code>STORE_LOG</code>, which does the same. Also, there exists a <code>LOGMEM_FULL</code> function for the LEDs, which lights up the LED if the SRAM log memory is full. See also the Pages <a class="el" href="_page__buttons.html">Buttons</a> and <a class="el" href="_page__l_e_d.html">LED functionality</a>. The 'chamlog' Python script in the project (Software folder) automatizes the process of downloading the binary log data, e.g., sending the following command under Windows with a ChameleonMini connected on port COM6 results in downloading the binary log file, clearing the log memory, and setting the log mode to <code>MEMORY</code>: <code>chamlog -p COM6 -c -m MEMORY -v</code>. Repeatedly executing this command always outputs the recently logged commands in user-readable form. Make sure that no other program, e.g., terminal software, is blocking the serial port. </p>
</div></div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated on Wed Jan 17 2018 21:05:32 for Chameleon-Mini by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.13
</small></address>
</body>
</html>