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

📄 strings.inc

📁 PKE(被动无钥门禁系统
💻 INC
字号:
;---------------------------------------------------------------------------------------------------------
; Strings.inc                     
;
;	Jan Ornter
;
;	DATE:	11-9-2005
;	VER.:	1.0


	extern String.ReadFromPGM, String.Hex2ASCII, String.HexArray2String, String.GetLength, String.Char2String, String.Append, String.Copy

;/*
;	This function reads a String from the program memory to a RAM buffer.
;	
;	ATTENTION, the buffer has to be at least big enough for the string.
;	This function will write the complete string to ram, regardless of the buffer size!
;	
;	@param Prog The start address in the program memory
;	@param RAM The start address of the buffer to write
;
;	@stacklevel 1 /*/String.Hex2ASCII
;	@resgisters FSR1 FSR2 /*/String.Hex2ASCII
;	@calls String.Hex2ASCII /*/String.Hex2ASCII
;
;	@example
;		String.ReadPGM2RAM ExString,BufferADR
;
;	...	...		...
;
;	ExString
;		DE	"Example\0"
;	@ex-desc
;		This will copy the string "Example" to BufferADR in RAM.
;
;	@status Tested
;
;*/
String.ReadPGM2RAM	macro	Prog, RAM
	movlw	upper Prog
	movwf	TBLPTRU
	movlw	high Prog
	movwf	TBLPTRH
	movlw	low Prog
	movwf	TBLPTRL
	lfsr	FSR2,RAM
	movlw	high RAM
	call	String.ReadFromPGM
	endm

⌨️ 快捷键说明

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