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

📄 compat-uitron-interrupt-management-functions.html

📁 有关ecos2。0介绍了实时嵌入式的结构以及线程调度的实现和内存的管理等
💻 HTML
字号:
<!-- Copyright (C) 2003 Red Hat, Inc.                                --><!-- This material may be distributed only subject to the terms      --><!-- and conditions set forth in the Open Publication License, v1.0  --><!-- or later (the latest version is presently available at          --><!-- http://www.opencontent.org/openpub/).                           --><!-- Distribution of the work or derivative of the work in any       --><!-- standard (paper) book form is prohibited unless prior           --><!-- permission is obtained from the copyright holder.               --><HTML><HEAD><TITLE>Interrupt management functions</TITLE><meta name="MSSmartTagsPreventParsing" content="TRUE"><METANAME="GENERATOR"CONTENT="Modular DocBook HTML Stylesheet Version 1.76b+"><LINKREL="HOME"TITLE="eCos Reference Manual"HREF="ecos-ref.html"><LINKREL="UP"TITLE="礗TRON API"HREF="compat-uitron-microitron-api.html"><LINKREL="PREVIOUS"TITLE="Extended Synchronization and Communication Functions"HREF="compat-uitron-extended-sync-comm-functions.html"><LINKREL="NEXT"TITLE="	  Memory pool Management Functions"HREF="compat-uitron-memory-pool-mgmt-functions.html"></HEAD><BODYCLASS="SECT1"BGCOLOR="#FFFFFF"TEXT="#000000"LINK="#0000FF"VLINK="#840084"ALINK="#0000FF"><DIVCLASS="NAVHEADER"><TABLESUMMARY="Header navigation table"WIDTH="100%"BORDER="0"CELLPADDING="0"CELLSPACING="0"><TR><THCOLSPAN="3"ALIGN="center">eCos Reference Manual</TH></TR><TR><TDWIDTH="10%"ALIGN="left"VALIGN="bottom"><AHREF="compat-uitron-extended-sync-comm-functions.html"ACCESSKEY="P">Prev</A></TD><TDWIDTH="80%"ALIGN="center"VALIGN="bottom">Chapter 32. &micro;ITRON API</TD><TDWIDTH="10%"ALIGN="right"VALIGN="bottom"><AHREF="compat-uitron-memory-pool-mgmt-functions.html"ACCESSKEY="N">Next</A></TD></TR></TABLE><HRALIGN="LEFT"WIDTH="100%"></DIV><DIVCLASS="SECT1"><H1CLASS="SECT1"><ANAME="COMPAT-UITRON-INTERRUPT-MANAGEMENT-FUNCTIONS">Interrupt management functions</H1><P>These functions are fully supported in this release:</P><TABLEBORDER="5"BGCOLOR="#E0E0F0"WIDTH="70%"><TR><TD><PRECLASS="PROGRAMLISTING">void	<TTCLASS="FUNCTION"> ret_int</TT>( void )</PRE></TD></TR></TABLE><TABLEBORDER="5"BGCOLOR="#E0E0F0"WIDTH="70%"><TR><TD><PRECLASS="PROGRAMLISTING">ER <TTCLASS="FUNCTION">loc_cpu</TT>( void )</PRE></TD></TR></TABLE><TABLEBORDER="5"BGCOLOR="#E0E0F0"WIDTH="70%"><TR><TD><PRECLASS="PROGRAMLISTING">ER <TTCLASS="FUNCTION">unl_cpu</TT>( void )</PRE></TD></TR></TABLE><TABLEBORDER="5"BGCOLOR="#E0E0F0"WIDTH="70%"><TR><TD><PRECLASS="PROGRAMLISTING">ER <TTCLASS="FUNCTION">dis_int</TT>(     UINT <SPANCLASS="emphasis"><ICLASS="EMPHASIS">eintno</I></SPAN> )</PRE></TD></TR></TABLE><TABLEBORDER="5"BGCOLOR="#E0E0F0"WIDTH="70%"><TR><TD><PRECLASS="PROGRAMLISTING">ER <TTCLASS="FUNCTION">ena_int</TT>(     UINT <SPANCLASS="emphasis"><ICLASS="EMPHASIS">eintno</I></SPAN> )</PRE></TD></TR></TABLE><TABLEBORDER="5"BGCOLOR="#E0E0F0"WIDTH="70%"><TR><TD><PRECLASS="PROGRAMLISTING">void	<TTCLASS="FUNCTION">ret_wup</TT>(     ID <SPANCLASS="emphasis"><ICLASS="EMPHASIS">tskid</I></SPAN> )</PRE></TD></TR></TABLE><TABLEBORDER="5"BGCOLOR="#E0E0F0"WIDTH="70%"><TR><TD><PRECLASS="PROGRAMLISTING">ER <TTCLASS="FUNCTION">iwup_tsk</TT>(     ID <SPANCLASS="emphasis"><ICLASS="EMPHASIS">tskid</I></SPAN> )</PRE></TD></TR></TABLE><TABLEBORDER="5"BGCOLOR="#E0E0F0"WIDTH="70%"><TR><TD><PRECLASS="PROGRAMLISTING">ER <TTCLASS="FUNCTION">isig_sem</TT>(     ID <SPANCLASS="emphasis"><ICLASS="EMPHASIS">semid</I></SPAN> )</PRE></TD></TR></TABLE><TABLEBORDER="5"BGCOLOR="#E0E0F0"WIDTH="70%"><TR><TD><PRECLASS="PROGRAMLISTING">ER <TTCLASS="FUNCTION">iset_flg</TT>(     ID <SPANCLASS="emphasis"><ICLASS="EMPHASIS">flgid ,</I></SPAN>    UID<SPANCLASS="emphasis"><ICLASS="EMPHASIS"> setptn</I></SPAN> )</PRE></TD></TR></TABLE><TABLEBORDER="5"BGCOLOR="#E0E0F0"WIDTH="70%"><TR><TD><PRECLASS="PROGRAMLISTING">ER <TTCLASS="FUNCTION">isend_msg</TT>(     ID <SPANCLASS="emphasis"><ICLASS="EMPHASIS">mbxid ,</I></SPAN>    T_MSG<SPANCLASS="emphasis"><ICLASS="EMPHASIS"> *pk_msg</I></SPAN> )</PRE></TD></TR></TABLE><P>Note that <TTCLASS="FUNCTION">ret_int()</TT> andthe <TTCLASS="FUNCTION">ret_wup()</TT> are  implementedas macros, containing a &#8220;return&#8221; statement.</P><P>Also note that <TTCLASS="FUNCTION">ret_wup()</TT> andthe <TTCLASS="FUNCTION">ixxx_yyy()</TT> style functionswill only work when called from an ISR whose associated DSR is <TTCLASS="FUNCTION">cyg_uitron_dsr()</TT>,as specified in include file <TTCLASS="FILENAME">&lt;cyg/compat/uitron/uit_ifnc.h&gt;</TT>,which defines the <TTCLASS="FUNCTION">ixxx_yyy()</TT> stylefunctions also.</P><P>If you are writing interrupt handlers more in the<SPANCLASS="emphasis"><ICLASS="EMPHASIS">eCos</I></SPAN> style, with separate ISR and DSR routines both ofyour own devising, do not use these special functions from a DSR: use plain<TTCLASS="FUNCTION">xxx_yyy()</TT> style functions (with no &#8216;i&#8217; prefix)instead, and do not call any &micro;ITRON functions from the ISR atall.</P><P>The following functions are not supported in this release: </P><TABLEBORDER="5"BGCOLOR="#E0E0F0"WIDTH="70%"><TR><TD><PRECLASS="PROGRAMLISTING">ER <TTCLASS="FUNCTION">def_int</TT>(     UINT <SPANCLASS="emphasis"><ICLASS="EMPHASIS">dintno,</I></SPAN>  T_DINT *<SPANCLASS="emphasis"><ICLASS="EMPHASIS">pk_dint</I></SPAN> )</PRE></TD></TR></TABLE><TABLEBORDER="5"BGCOLOR="#E0E0F0"WIDTH="70%"><TR><TD><PRECLASS="PROGRAMLISTING">ER <TTCLASS="FUNCTION">chg_iXX</TT>(     UINT <SPANCLASS="emphasis"><ICLASS="EMPHASIS">iXXXX</I></SPAN> )  </PRE></TD></TR></TABLE><TABLEBORDER="5"BGCOLOR="#E0E0F0"WIDTH="70%"><TR><TD><PRECLASS="PROGRAMLISTING">ER <TTCLASS="FUNCTION">ref_iXX</TT>(     UINT * <SPANCLASS="emphasis"><ICLASS="EMPHASIS">p_iXXXX</I></SPAN> )</PRE></TD></TR></TABLE><P>These unsupported functions are all Level C (CPU dependent).Equivalent functionality is available via other <SPANCLASS="emphasis"><ICLASS="EMPHASIS">eCos</I></SPAN>-specificAPIs. </P><DIVCLASS="SECT2"><H2CLASS="SECT2"><ANAME="AEN13831">Error checking</H2><P>The following conditions are only checked for, and only returnerrors if <TTCLASS="LITERAL">CYGSEM_UITRON_BAD_PARAMS_RETURN_ERRORS</TT>is enabled:</P><P></P><UL><LI><P><TTCLASS="FUNCTION">loc/unl_cpu()</TT>: these must only be called in a &micro;ITRON task context, else E_CTX.</P></LI><LI><P><TTCLASS="FUNCTION">dis/ena_int()</TT>: the interrupt number must be in range as specified by the platformHAL in qustion, else E_PAR.</P></LI></UL></DIV></DIV><DIVCLASS="NAVFOOTER"><HRALIGN="LEFT"WIDTH="100%"><TABLESUMMARY="Footer navigation table"WIDTH="100%"BORDER="0"CELLPADDING="0"CELLSPACING="0"><TR><TDWIDTH="33%"ALIGN="left"VALIGN="top"><AHREF="compat-uitron-extended-sync-comm-functions.html"ACCESSKEY="P">Prev</A></TD><TDWIDTH="34%"ALIGN="center"VALIGN="top"><AHREF="ecos-ref.html"ACCESSKEY="H">Home</A></TD><TDWIDTH="33%"ALIGN="right"VALIGN="top"><AHREF="compat-uitron-memory-pool-mgmt-functions.html"ACCESSKEY="N">Next</A></TD></TR><TR><TDWIDTH="33%"ALIGN="left"VALIGN="top">Extended Synchronization and Communication Functions</TD><TDWIDTH="34%"ALIGN="center"VALIGN="top"><AHREF="compat-uitron-microitron-api.html"ACCESSKEY="U">Up</A></TD><TDWIDTH="33%"ALIGN="right"VALIGN="top">Memory pool Management Functions</TD></TR></TABLE></DIV></BODY></HTML>

⌨️ 快捷键说明

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