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

📄 config.c

📁 智能水表程序 来着互联网
💻 C
字号:
//-----------------------------------------------------------------------------
// config.c
//-----------------------------------------------------------------------------
/*
//-----------------------------------------------------------------------------
// Includes
//-----------------------------------------------------------------------------
#include <reg52.h>
#include <string.h>
#include "main/main.h"
#include "cpu/cpu.h"
#include "ext/x5045.h"
#include "ext/bc7281.h"
#include "ext/ds1307.h"
#include "rfid/card.h"
#include "comm/gsm.h"
#include "other/other.h"
#include "other/general.h"
#include "config/config.h"
//-----------------------------------------------------------------------------
// DS1307 Debug Routine
//-----------------------------------------------------------------------------
void ds1307_Debug (void)
{
		STDS1307 data t = { 0x50, 0x30, 0x12, 0x00, 0x20, 0x04, 0x07 };

		bRtc = ds1307_Initial ();
		if ( bRtc == I2C_NACK ) ds1307_Warn_i2c;
		Delay ( 0x03FAFA);
		if ( ds1307_Write ((char *) &t ) == I2C_NACK )  Speaker_Beep ();
		Delay ( 0x03FAFA);
		ds1307_Read ((char *) &t );
		bc7281_Display_Dig ( CodeH |((long) t.Year << 24 )|( (long) t.Month  << 12 )| t.Date ); // (long) supply buffer
		Delay ( 0x03FAFA);
		bc7281_Display_Dig ( CodeH |((long) t.Hour << 24 )|( (long) t.Minute << 12 )| t.Second );
		//	cpu_LED = OFF;	// Speaker_Beep (); // bc7281_Display_Dig ( Code4 );
}
//-----------------------------------------------------------------------------
// x5045 Debug Routine
//-----------------------------------------------------------------------------
void x5045_Debug (void)
{
	while (1)
	{
		x5045_Write_Enable ();
	    x5045_Write ( stFlow_memAddr, (char*) &f, 6 );
//		Delay ( 0x0FFA );
	    x5045_Read ( stFlow_memAddr, (char*) &f, sizeof( STFlow ));
//  	memcpy ( f.City, City_Well, 6 );

		bc7281_Set ();
	    bc7281_Flash_Digital ( FLASH_OFF );
	    bc7281_Column1_OnOff ( OFF );
		bc7281_Display_Dig ( CodeG | ArrayThreeToLong ( f.City ));
		Delay ( 0x030FFA );
		f.City[2]++;
	}
}
*/

⌨️ 快捷键说明

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