xmodem.h

来自「基于2410的一个iis总线测试程序 声音控制芯片是飞利浦的UTS1341 」· C头文件 代码 · 共 56 行

H
56
字号
//=====================
//file name: xmodem.h
//Discription: provide some xmodem-relative method used by the monitor program
//Author: Decell.Zhou
//Version:
//			0.1|
//=====================
#include <stdlib.h>
#include <string.h>

#include "def.h"
#include "option.h"
#include "2410addr.h"
#include "2410lib.h"
#include "2410slib.h"
#include "config.h"

#define SOH 0x1
#define EOT 0x04   
#define ACK 0x06   
#define NAK 0x15
#define CAN 0x18


//==============[xmodemInit]========
//Discription: make preparation for the xmodem transmit
//Author:Decell.Zhou
//Version:
//pram:none
//return:none
//==================================
//void xmodemInit(unsigned int destination);

//=============[xmodemTransmit]=====
//Discription: transmit data to a sepcified address under the xmodem protocal
//				this method will store the data to the address PROGRAM_RO_BASE
//Author:Decell.Zhou
//Version:
//pram:destination|unsigned int|the destination address to store the data
//return:
//		0|char|transmit successful
//		1|char|transmit fault 
//==================================
char xmodemTransmit(unsigned int destination);

//=============[xmodemJump]=========
//Discription: jump to the  PROGRAM_RO_BASE,exeute the user prgram
//Author:Decell.Zhou
//Version:
//pram:none
//return:none
//==================================
void xmodemJump(void);


⌨️ 快捷键说明

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