⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 ker3.htm

📁 ST20 Embedded Toolset R2.0.5用于开发基于ST20芯片机顶盒软件的开发平台,2.0.5版本,国内找不到的.在国外论坛上花了N天才找到!
💻 HTM
字号:
<html>

<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<meta name="GENERATOR" content="Quadralay WebWorks Publisher Professional Edition 6.0.5">
<meta name="TEMPLATEBASE" content="book_html">
<meta name="LASTUPDATED" content="12/01/03 14:14:30">
<title>3.2 Optional debug features</title>

<STYLE TYPE="text/css">
<!--
	span.Signal { text-transform: uppercase; font-family: Verdana }
-->
</STYLE>

</head>

<body link="#3366CC" vlink="#9999CC" text="#000000" alink="#0000CC" bgcolor="#FFFFFF"
background="images/backgrnd.gif">

<p><img src="images/stlogo.gif" width="106" height="83" align="left"
alt="logo here!"> </p>

<table width="331" border="0" align="right" cellpadding="0" cellspacing="0">
  <tr>
    <td><a href="os20toc.htm"><img src="images/navtoc.gif" width="84" height="23"
    border="0" alt="TOC"> </a></td>
    <td><a href="ker2.htm"><img src="images/navprev.gif" width="80" height="23"
    border="0" alt="PREV"> </a></td>
    <td><a href="ker4.htm"><img src="images/navnext.gif" width="83" height="23"
    border="0" alt="NEXT"> </a></td>
    <td><a href="os20ix.htm"><img src="images/navidx.gif" width="84" height="23"
    border="0" alt="INDEX"> </a></td>
  </tr>
</table>

<p><br clear="all">
</p>

<hr align="left">

<blockquote>
<h2>
  <a name="1204451"> </a><font color="#003366"  face="Verdana, Arial, Helvetica, sans-serif">3.2 	 Optional debug features</font>
</h2><hr>


<p>
  <a name="1205910"> </a><font size=2  face="Verdana, Arial, Helvetica, sans-serif">The STLite/OS20 kernel is supplied in two forms, the deployment kernel and the debug kernel. The debug kernel contains extra features designed to find bugs and assist with performance tuning.</font>
</p>


<p>
  <a name="1205914"> </a><font size=2 face="Verdana, Arial, Helvetica, sans-serif"><em>Note:	 All features in the debug kernel are slightly intrusive. This may subtly alter the real-time performance of the system being debugged, however, in most cases the difference in performance should be negligible.</em></font>
</p>

<h3>
  <a name="1205918"> </a><font color="#003366"  face="Verdana, Arial, Helvetica, sans-serif">3.2.1 	 Assertion checking</font>
</h3>


<p>
  <a name="1205920"> </a><font size=2  face="Verdana, Arial, Helvetica, sans-serif">The debug kernel performs assertion checks on entry to every STLite/OS20 library call. These assertions catch a number of illegal calling conditions that can lead to a variety of difficult to debug scheduling failures. Specifically the assertions will be triggered if the application illegally:</font>
</p>

<ul>
<p>  <font size=2  face="Verdana, Arial, Helvetica, sans-serif"><li ><a name="1205926"> </a>passes a NULL pointer argument,</font></p>
<p>  <font size=2  face="Verdana, Arial, Helvetica, sans-serif"><li ><a name="1205927"> </a>calls a function from an interrupt handler,</font></p>
<p>  <font size=2  face="Verdana, Arial, Helvetica, sans-serif"><li ><a name="1205928"> </a>calls a function from a high priority process (ST20-C2 only),</font></p>
<p>  <font size=2  face="Verdana, Arial, Helvetica, sans-serif"><li ><a name="1205929"> </a>calls a function while interrupts are locked.</font></p>
</ul>

<p>
  <a name="1205931"> </a><font size=2  face="Verdana, Arial, Helvetica, sans-serif">When an assertion is triggered a message is displayed identifying the failure and the machine will stop in the debugger at the point of failure. If a debugger is not connected then the machine will enter a busy loop until a debugger is connected at which point it will display the message and stop the machine.</font>
</p>


<h3>
  <a name="1205937"> </a><font color="#003366"  face="Verdana, Arial, Helvetica, sans-serif">3.2.2 	 Time logging</font>
</h3>


<p>
  <a name="1205939"> </a><font size=2  face="Verdana, Arial, Helvetica, sans-serif">For targets with an ST20-C2 core the debug kernel is also configured to maintain a record of the amount of time each task and interrupt spends executing. This facility is not available on ST20-C1 cores.</font>
</p>


<p>
  <a name="1205943"> </a><font size=2  face="Verdana, Arial, Helvetica, sans-serif">The following information is available in the debug kernel.</font>
</p>

<ul>
<p>  <font size=2  face="Verdana, Arial, Helvetica, sans-serif"><li ><a name="1205945"> </a><strong>Task time logging</strong> maintains a record of the amount of time each task spends running on the processor. The data collected can be accessed using the <font size=2 face=Courier><strong>task_status</strong></font> function.</font></p>
<p>  <font size=2  face="Verdana, Arial, Helvetica, sans-serif"><li ><a name="1205949"> </a><strong>Interrupt time logging</strong> maintains a record of the amount of time spent servicing each interrupt and the number of times the interrupt has been called. The functions <font size=2 face=Courier><strong>interrupt_status</strong></font> and <font size=2 face=Courier><strong>interrupt_status_number</strong></font> are used to return this information.</font></p>
<p>  <font size=2  face="Verdana, Arial, Helvetica, sans-serif"><li ><a name="1205954"> </a>The functions <font size=2 face=Courier><strong>kernel_idle</strong></font> and <font size=2 face=Courier><strong>kernel_time</strong></font> return the time spent idle and the total up-time respectively. The total up-time being the time elapsed since the kernel started.</font></p>
</ul>

<p>
  <a name="1206125"> </a><font size=2  face="Verdana, Arial, Helvetica, sans-serif"><a href="libs.htm#1214476"><font  color="#0000ff" face="Verdana, Arial, Helvetica, sans-serif"><i>Chapter

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -