基于MCF52235 的RFID 通用开发平台设计
struct invite_info //PC 主机发送的读卡请求
{ char del_or_add; //主机离开或加入
uint8 type; //卡的类型
uint8 block; //要访问的数据块
uint8 password[6]; //块的密码
};
struct ip_arrays_B //读Type B 卡信息
{ ip_addr ipaddress; //IP 地址
int port; //UDP 端口号
};
struct send_data_type //发送到主机的数据
{ uint8 sn[4]; //序列号
uint8 block; //块号
uint8 data[16]; //16 个字节块数据
uint8 ret; //返回值
};
struct IC_ope //用于消费用途的RFID 应用
{
uint8 block; //总的金额数
float fsub; //每次刷卡扣除的金额数量
uint8 *pass;
};
struct record_info //记录卡信息
{ //此块引用计数,0 表示没有请求读这块数据
uint8 ref; //引用计数

评论