亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? portmacro.s90

?? FreeRTOS 2.5源碼
?? S90
字號:
;	FreeRTOS V2.5.0 - Copyright (C) 2003, 2004 Richard Barry.
;
;	This file is part of the FreeRTOS distribution.
;
;	FreeRTOS is free software; you can redistribute it and/or modify
;	it under the terms of the GNU General Public License as published by
;	the Free Software Foundation; either version 2 of the License, or
;	(at your option) any later version.
;
;	FreeRTOS is distributed in the hope that it will be useful,
;	but WITHOUT ANY WARRANTY; without even the implied warranty of
;	MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
;	GNU General Public License for more details.
;
;	You should have received a copy of the GNU General Public License
;	along with FreeRTOS; if not, write to the Free Software
;	Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
;
;	A special exception to the GPL can be applied should you wish to distribute
;	a combined work that includes FreeRTOS, without being obliged to provide
;	the source code for any proprietary components.  See the licensing section 
;	of http://www.FreeRTOS.org for full details of how and when the exception
;	can be applied.
;
;	***************************************************************************
;	See http://www.FreeRTOS.org for documentation, latest information, license 
;	and contact details.  Please ensure to read the configuration and relevant 
;	port sections of the online documentation.
;	***************************************************************************

#include <iom323.h>

; Declare all extern symbols here - including any ISRs that are referenced in
; the vector table.

; ISR functions
; -------------
EXTERN SIG_OUTPUT_COMPARE1A
EXTERN SIG_UART_RECV
EXTERN SIG_UART_DATA


; Functions used by scheduler
; ---------------------------
EXTERN vTaskSwitchContext
EXTERN pxCurrentTCB
EXTERN vTaskIncrementTick

; Functions implemented in this file
; ----------------------------------
PUBLIC vPortYield
PUBLIC vPortYieldFromTick
PUBLIC vPortStart


; Interrupt vector table.
; -----------------------
;
; For simplicity the RTOS tick interrupt routine uses the __task keyword.
; As the IAR compiler does not permit a function to be declared using both
; __task and __interrupt, the use of __task necessitates that the interrupt
; vector table be setup manually.
;
; To write an ISR, implement the ISR function using the __interrupt keyword
; but do not install the interrupt using the "#pragma vector=ABC" method.
; Instead manually place the name of the ISR in the vector table using an
; ORG and jmp instruction as demonstrated below.
; You will also have to add an EXTERN statement at the top of the file.

	ASEG


	ORG TIMER1_COMPA_vect				; Vector address
		jmp SIG_OUTPUT_COMPARE1A		; ISR

	ORG USART_RXC_vect					; Vector address
		jmp SIG_UART_RECV				; ISR

	ORG USART_UDRE_vect					; Vector address
		jmp SIG_UART_DATA				; ISR

	
	RSEG CODE



; Saving and Restoring a Task Context and Task Switching
; ------------------------------------------------------
;
; The IAR compiler does not fully support inline assembler, so saving and
; restoring a task context has to be written in an asm file.  
;
; vPortYield() and vPortYieldFromTick() are usually written in C.  Doing
; so in this case would required calls to be made to portSAVE_CONTEXT() and
; portRESTORE_CONTEXT().  This is dis-advantageous as the context switch 
; function would require two extra jump and return instructions over the 
; WinAVR equivalent.  
;
; To avoid this I have opted to implement both vPortYield() and 
; vPortYieldFromTick() in this assembly file.  For convenience
; portSAVE_CONTEXT and portRESTORE_CONTEXT are implemented as macros.

portSAVE_CONTEXT MACRO
	st	-y, r0			; First save the r0 register - we need to use this.
	in	r0, SREG		; Obtain the SREG value so we can disable interrupts...
	cli					; ... as soon as possible.
	st	-y, r0			; Store the SREG as it was before we disabled interrupts.

	in	r0, SPL			; Next store the hardware stack pointer.  The IAR...
	st	-y, r0			; ... compiler uses the hardware stack as a call stack ...
	in	r0, SPH			; ...  only.
	st	-y, r0

	st	-y, r1			; Now store the rest of the registers.  Dont store the ...
	st	-y, r2			; ... the Y register here as it is used as the software
	st	-y, r3			; stack pointer and will get saved into the TCB.
	st	-y, r4
	st	-y, r5
	st	-y, r6
	st	-y, r7
	st	-y, r8
	st	-y, r9
	st	-y, r10
	st	-y, r11
	st	-y, r12
	st	-y, r13
	st	-y, r14
	st	-y, r15
	st	-y, r16
	st	-y, r17
	st	-y, r18
	st	-y, r19
	st	-y, r20
	st	-y, r21
	st	-y, r22
	st	-y, r23
	st	-y, r24
	st	-y, r25
	st	-y, r26
	st	-y, r27
	st	-y, r30
	st	-y, r31

	lds	r26, pxCurrentTCB		; Finally save the software stack pointer (Y ...
	lds	r27, pxCurrentTCB + 1	; ... register) into the TCB.
	st	x+, r28
	st	x+, r29

	ENDM


portRESTORE_CONTEXT MACRO
	lds	r26, pxCurrentTCB
	lds	r27, pxCurrentTCB + 1	; Restore the software stack pointer from ...
	ld	r28, x+					; the TCB into the software stack pointer (...
	ld	r29, x+					; ... the Y register).

	ld	r31, y+					; Restore the registers down to R0.  The Y
	ld	r30, y+					; register is missing from this list as it
	ld	r27, y+					; has already been restored.
	ld	r26, y+ 
	ld	r25, y+
	ld	r24, y+
	ld	r23, y+
	ld	r22, y+
	ld	r21, y+
	ld	r20, y+
	ld	r19, y+
	ld	r18, y+
	ld	r17, y+
	ld	r16, y+
	ld	r15, y+
	ld	r14, y+
	ld	r13, y+
	ld	r12, y+
	ld	r11, y+
	ld	r10, y+
	ld	r9, y+
	ld	r8, y+
	ld	r7, y+
	ld	r6, y+
	ld	r5, y+
	ld	r4, y+
	ld	r3, y+
	ld	r2, y+
	ld	r1, y+

	ld	r0, y+					; The next thing on the stack is the ...
	out	SPH, r0					; ... hardware stack pointer.
	ld	r0, y+
	out	SPL, r0

	ld	r0, y+					; Next there is the SREG register.
	out SREG, r0

	ld	r0, y+					; Finally we have finished with r0, so restore r0.
	
	ENDM



; vPortYield() and vPortYieldFromTick()
; -------------------------------------
;
; Manual and preemptive context switch functions respectively.  
; The IAR compiler does not fully support inline assembler, 
; so these are implemented here rather than the more usually 
; place of within port.c.

vPortYield:
	portSAVE_CONTEXT			; Save the context of the current task.
	call vTaskSwitchContext		; Call the scheduler.
	portRESTORE_CONTEXT			; Restore the context of whichever task the ...
	ret							; ... scheduler decided should run.

vPortYieldFromTick:
	portSAVE_CONTEXT			; Save the context of the current task.
	call vTaskIncrementTick		; Call the timer tick function.
	call vTaskSwitchContext		; Call the scheduler.
	portRESTORE_CONTEXT			; Restore the context of whichever task the ...
	ret							; ... scheduler decided should run.

; vPortStart()
; ------------
;
; Again due to the lack of inline assembler, this is required
; to get access to the portRESTORE_CONTEXT macro.

vPortStart:
	portRESTORE_CONTEXT
	ret


; Just a filler for unused interrupt vectors.
vNoISR:
	reti


	END

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
久久久久久久综合色一本| 日韩黄色一级片| 亚洲va欧美va天堂v国产综合| 久久精品国产77777蜜臀| 9久草视频在线视频精品| 欧美一级黄色大片| 一区二区三区在线不卡| 国产91精品欧美| 日韩精品一区二区在线| 亚洲国产精品欧美一二99| 成人一区二区视频| 精品第一国产综合精品aⅴ| 亚洲一区二区av电影| av电影一区二区| 国产日韩欧美精品一区| 麻豆91在线看| 日韩一区二区精品在线观看| 亚洲高清一区二区三区| 日本韩国欧美在线| 国产精品福利影院| 国产成人av在线影院| 久久只精品国产| 狠狠狠色丁香婷婷综合激情| 日韩欧美一级二级三级久久久| 亚洲国产精品久久一线不卡| 欧美午夜精品电影| 亚洲一区二区在线免费看| 色婷婷av一区二区| 亚洲日韩欧美一区二区在线| 99久久精品国产观看| 中文字幕在线观看不卡| 不卡av电影在线播放| 国产精品家庭影院| 91蜜桃免费观看视频| 亚洲日本青草视频在线怡红院| 99久久综合精品| 亚洲男人都懂的| 欧美丝袜自拍制服另类| 五月天激情综合网| 欧美一级黄色录像| 国精品**一区二区三区在线蜜桃| 欧美精品一区二区三区视频 | 亚洲一区二区三区四区中文字幕 | 专区另类欧美日韩| 成人aa视频在线观看| 亚洲激情在线播放| 欧美日韩视频在线第一区| 日韩影视精彩在线| 精品人伦一区二区色婷婷| 国产一区二区三区精品欧美日韩一区二区三区 | 精品国产123| 成人亚洲一区二区一| 亚洲日本丝袜连裤袜办公室| 欧美系列亚洲系列| 美腿丝袜亚洲综合| 中文字幕av一区二区三区高| 99久久99久久免费精品蜜臀| 亚洲电影一区二区三区| 欧美一卡2卡3卡4卡| 国产精品88av| 亚洲午夜视频在线观看| 精品欧美一区二区久久| 成人h精品动漫一区二区三区| 亚洲综合在线第一页| 欧美成人一级视频| 99久久综合狠狠综合久久| 天使萌一区二区三区免费观看| 久久综合一区二区| 欧美午夜精品理论片a级按摩| 韩国成人精品a∨在线观看| 综合电影一区二区三区 | 亚洲欧洲日本在线| 51午夜精品国产| 成人夜色视频网站在线观看| 午夜精品在线看| 亚洲国产高清在线观看视频| 4438亚洲最大| 99久久er热在这里只有精品15| 蜜臀a∨国产成人精品| 亚洲人妖av一区二区| 日韩欧美国产电影| 99v久久综合狠狠综合久久| 久久国产人妖系列| 亚洲综合精品自拍| 中文字幕亚洲一区二区av在线| 91精品国模一区二区三区| 99视频一区二区| 国产99久久久精品| 麻豆国产精品官网| 午夜伊人狠狠久久| 一区2区3区在线看| 日韩理论片在线| 欧美激情中文字幕| 精品福利在线导航| 欧美mv日韩mv亚洲| 4438x亚洲最大成人网| 91精品福利在线| 91麻豆精品在线观看| 成人精品视频一区| 国产成人综合网| 国产福利精品一区二区| 精品亚洲成a人| 麻豆精品精品国产自在97香蕉| 日韩一区精品字幕| 日本伊人色综合网| 日韩国产欧美视频| 日韩在线a电影| 午夜激情综合网| 日韩精品电影一区亚洲| 亚欧色一区w666天堂| 亚洲成人精品在线观看| 亚洲国产精品久久久男人的天堂| 亚洲欧美福利一区二区| 一区二区三区在线观看网站| 亚洲欧洲综合另类| 亚洲尤物视频在线| 天天综合网 天天综合色| 轻轻草成人在线| 免费观看日韩电影| 国产麻豆精品95视频| 国产成人精品亚洲午夜麻豆| 福利一区二区在线| 99久久精品国产毛片| 欧美日韩精品一区二区在线播放| 欧美视频在线一区二区三区| 欧美一区二区黄| 国产午夜精品一区二区三区四区| 中文字幕免费观看一区| 亚洲少妇最新在线视频| 亚洲www啪成人一区二区麻豆| 三级亚洲高清视频| 韩国成人在线视频| 97久久精品人人做人人爽50路| 在线观看一区二区精品视频| 91精品国产综合久久国产大片| 26uuu色噜噜精品一区| 国产精品久久久久影院色老大| 一区二区三区免费在线观看| 日本午夜精品一区二区三区电影| 精品系列免费在线观看| 成人国产亚洲欧美成人综合网| 欧美日韩国产欧美日美国产精品| 日韩小视频在线观看专区| 中文字幕乱码久久午夜不卡 | 麻豆精品在线播放| 成人久久18免费网站麻豆 | 日本一区二区三区高清不卡| 亚洲欧美在线视频观看| 日韩黄色免费电影| 高清国产一区二区| 欧美综合一区二区| 久久只精品国产| 亚洲mv大片欧洲mv大片精品| 国产福利一区二区三区视频在线 | 91精品国产91综合久久蜜臀| 国产日本一区二区| 日精品一区二区| 成人爱爱电影网址| 日韩免费高清视频| 亚洲午夜久久久久| 丰满少妇在线播放bd日韩电影| 欧美日韩国产不卡| 国产精品久久久久久久岛一牛影视| 亚洲成人福利片| 成人av资源在线观看| 日韩欧美亚洲一区二区| 一区二区三区久久久| 国产精品1区2区3区| 91精品国产综合久久香蕉的特点| 国产精品午夜在线观看| 蜜桃视频第一区免费观看| 欧美性感一类影片在线播放| 国产亚洲欧美中文| 男男成人高潮片免费网站| 在线这里只有精品| 中文字幕av一区二区三区| 精品写真视频在线观看| 日韩一级视频免费观看在线| 亚洲精品v日韩精品| 成人免费观看视频| 欧美mv日韩mv国产| 麻豆国产一区二区| 日韩欧美一区二区三区在线| 午夜成人免费电影| 欧美喷水一区二区| 亚洲国产一区视频| 一本色道久久综合亚洲aⅴ蜜桃| 中文字幕第一区综合| 国产一区二区按摩在线观看| 日韩视频一区二区在线观看| 日本特黄久久久高潮| 欧美日韩亚洲另类| 亚洲一区二区视频在线观看| 色94色欧美sute亚洲线路一久| ㊣最新国产の精品bt伙计久久| 成人黄色小视频| 亚洲视频一二三| 欧美视频精品在线| 亚洲高清不卡在线观看| 欧美日韩美少妇|