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

📄 mian.c

📁 无线通信的
💻 C
字号:
/*********************************************************************************************
* File:	main.c
* Author:	embest
* Desc:	c main entry
* History:	
*********************************************************************************************/

/*--- include files ---*/
#include "44blib.h"
#include "44b.h"

/*--- function code ---*/

/*********************************************************************************************
* name:		main
* func:		c code entry
* para:		none
* ret:		none
* modify:
* comment:		
*********************************************************************************************/
void Main(void)
{
	int i;
	sys_init();										// Initial 44B0X's Interrupt,Port and UART 

	// initialize the 8led-function first of ZLG7290 (more to see ZLG7290.pdf)
	// present the invalid sign generated while keyboard-function
	// Initialize iic
	// Enable interrupt
	iic_init();
	for(i=0; i<8; i++)
	{
		iic_write(0x70, 0x10+i, 0xFF);		// write data to DpRam0~DpRam7(Register of ZLG7290)
		delay(5);
	}

	// user interface 
	uart_printf("\n Embest Arm EduKit II Evaluation Board\n");
	uart_printf(" GPS Test Example\n");
	
	gprs_test();

}

void eled_disp(char cWhichS,char cWhichE,char uChar)
{
	int i;
	
	iic_init();
	if(cWhichS <= cWhichE)
	{
    	for(i=cWhichS-1;i<=cWhichE-1;i++)
			iic_write(0x70, 0x10+i, uChar);
	}
	else
	{
    	for(i=cWhichS-1;i>=cWhichE-1;i--)
			iic_write(0x70, 0x10+i, uChar);
	}
}

⌨️ 快捷键说明

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