Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Fork of libMiMic by
NyLPC_cIsr.h
00001 /********************************************************************************* 00002 * PROJECT: MiMic 00003 * -------------------------------------------------------------------------------- 00004 * 00005 * This file is part of MiMic 00006 * Copyright (C)2011 Ryo Iizuka 00007 * 00008 * MiMic is free software: you can redistribute it and/or modify 00009 * it under the terms of the GNU Lesser General Public License as published 00010 * by the Free Software Foundation, either version 3 of the License, or 00011 * (at your option) any later version. 00012 * 00013 * This program is distributed in the hope that it will be useful, 00014 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00015 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00016 * GNU General Public License for more details. 00017 * 00018 * You should have received a copy of the GNU Lesser General Public License 00019 * along with this program. If not, see <http://www.gnu.org/licenses/>. 00020 * 00021 * For further information please contact. 00022 * http://nyatla.jp/ 00023 * <airmail(at)ebony.plala.or.jp> or <nyatla(at)nyatla.jp> 00024 * 00025 *********************************************************************************/ 00026 #ifndef NYLPC_CISR_H_ 00027 #define NYLPC_CISR_H_ 00028 //////////////////////////////////////////////////////////////////////////////// 00029 // Include 00030 //////////////////////////////////////////////////////////////////////////////// 00031 #include "NyLPC_stdlib.h" 00032 #if NyLPC_ARCH==NyLPC_ARCH_FREERTOS 00033 #include "FreeRTOS.h" 00034 #include "queue.h" 00035 #include "semphr.h" 00036 #elif NyLPC_ARCH==NyLPC_ARCH_MBEDRTOS 00037 #elif NyLPC_ARCH==NyLPC_ARCH_WIN32 00038 //not work! 00039 #else 00040 #error Bad NyLPC_ARCH! 00041 #endif 00042 /********************************************************************** 00043 * 00044 * NyLPC_cIsr class 00045 * 00046 **********************************************************************/ 00047 00048 #ifdef __cplusplus 00049 extern "C" { 00050 #endif /* __cplusplus */ 00051 00052 typedef void (*NyLPC_cIsr_EventHandler)(unsigned long i_status); 00053 00054 /** 00055 * 全ての割込みとタスクスイッチを停止します。 00056 */ 00057 void NyLPC_cIsr_enterCritical(void); 00058 /** 00059 * 全ての割込みとタスクスイッチを再開します。 00060 */ 00061 void NyLPC_cIsr_exitCritical(void); 00062 /** 00063 * イベントハンドラを登録します。 00064 * @param i_handler 00065 * LPC17xxでは、イベントはISRからコールされます。 00066 */ 00067 void NyLPC_cIsr_setEnetISR(NyLPC_cIsr_EventHandler i_handler); 00068 00069 00070 #ifdef __cplusplus 00071 } 00072 #endif /* __cplusplus */ 00073 00074 #endif /* NYLPC_CISR_H_ */ 00075
Generated on Tue Jul 12 2022 16:22:57 by
