<5>“LCD”模块相对比较简单,主要是把液晶模块初始化好,写好画点等函数就可以了,函数如下:
extern void LCD_Show3216Char(unsigned int x,unsigned int y );
extern void LCD_Show6432Char(unsigned int x,unsigned int y );
extern void LCD_ShowCypressLogoPicture( unsigned int x0,unsigned int x1, unsigned int y0,unsigned int y1 );
extern voidLCD_ShowCypressLogoASCII(unsigned int x,unsigned int y );
extern voidLCD_Show4832Number(unsigned int x,unsigned int y,unsigned int num );
extern voidLCD_Show_Loading_Char(unsigned int x,unsigned int y );
extern voidLCD_Show3216xindian(unsigned int x,unsigned int y );
extern voidLCD_Show3216xuayang(unsigned int x,unsigned int y );
extern voidLCD_Show3216xuaya(unsigned int x,unsigned int y );
extern void LCD_Show_Picture(void);
extern void showimage(void);
extern void LCD_MainDisplayInit(void);
extern voidLCDBackLightControl_Bright(void);
extern voidLCDBackLightControl_Dark(void);
extern void Display_Grid(void);
extern voidLCD_DrawFrame(void);
<6>“Printer”打印机模块应用于心电,脉搏波形打印,全局函数如下:
extern void Printer_Init(void); //打印机初始化
extern void MCU_SendCMD( unsigned char CMD ); //把数据发送给打印机
extern void ECGWavePrint_Stop(void); //停止打印
extern void DelayUs( unsigned int Cunter );
<7>“PSystemFlash”系统滴答工作指示灯,全局函数如下:
extern void PSystemFlash_Init(void); //系统工作指示灯初始化
<8>“NIBPPro”血压测量模块,气泵和气阀控制,气压传感器信号采集处理等,软件设计扩展中,全局函数如下:
extern void NIBPProInit(void);
<9>“Micro_SDCard”SD卡存储模块,心电数据,脉搏血氧数据,血压数据等存储,软件设计扩展中,全局函数如下:
extern void SPI_WriteData( unsigned char Data8 );
extern unsigned char SPI_ReadData( void );
extern unsigned char SD_Response(void);
extern void SD_CMD( unsigned char CMD, unsigned long Argument, unsigned char CRC );
extern unsigned char SD_Init(void);
extern unsigned char SD_Block_Write( unsigned char *Block, unsigned long address, unsigned int len );
extern unsigned char*SD_Block_Read( unsigned long address, unsigned int len );
<10>“SPo2WavePro”脉搏血氧饱和度信号处理模块,全局函数如下:
extern void MyPWM_Init(void); //PWM初始化
extern void SPo2WaveProInit(void); //血氧波形处理初始化
extern void SPo2WavePrint(void); //开始打印SPo2波形
extern voidSPo2WaveSendToPC(void); //把血氧波形数据发送到PC
extern void SPo2WaveDraw(void); //血氧电波形
<11>“UartMster”串口蓝牙模块,实现心电,脉搏血氧,血氧信息无线传输功能,全局函数如下:
extern void WaveProc_EcgWaveSned( uint16 ecgData ); //根据协议发送心电数据包
extern void WaveProc_SPo2WaveSned( uint16 SPo2Data ); //根据协议发送血氧数据包
extern void UartMaster_Init(void); //Uart初始化
<10>剩下的文件就是PSOC系统自生成的源代码了,相关的API函数和宏定义等都可以到里面找。
图(10).系统生成源码