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

📄 main.cpp

📁 嵌入式LINUX的智能家居系统源码
💻 CPP
字号:
#include"can.h"#include"cmd.h"#include"BT_ser.h"#include"sql.h"#include<qapplication.h>#include"home_terminel_form.h"int main(int argc,char ** argv){	QApplication app(argc,argv);	Can can;	can.init();	ker_cmd cmd;		home_terminel_Form w;		BT_ser bt;	sql s;	s.link_db();	s.changeTBL();       //connect can and cmd first from can to cmd, and then from cmd to can	app.connect(&can,SIGNAL(sig_cmd(int)),&cmd,SLOT(center_cmd_proxy(int)));	app.connect(&cmd,SIGNAL(sig_cmd_home(int,char)),&can,SLOT(write_cmd(int,char)));	app.connect(&cmd,SIGNAL(sig_cmd_door(int,char)),&can,SLOT(write_cmd(int,char)));//connect window and cmd	app.connect(&w,SIGNAL(sig_cmd(int)),&cmd,SLOT(ker_cmd_proxy(int)));	app.connect(&cmd,SIGNAL(sig_cmd_local_ui(int)),&w,SLOT(switcher(int)));//connect BT and window	app.connect( &w, SIGNAL( sig_cmd(int) ), &bt, SLOT( write_BT(int) ) );    	app.connect( &bt, SIGNAL( sig_cmd(int) ), &w, SLOT( switcher(int) ) );//connect BT and cmd	app.connect( &bt, SIGNAL( sig_cmd(int ) ), &cmd, SLOT( ker_cmd_proxy(int)));	app.connect( &cmd, SIGNAL( sig_cmd_local_bt(int) ), &bt, SLOT( switcher(int )));	app.connect( &cmd, SIGNAL( sig_cmd_pda(int ) ), &bt, SLOT( write_BT(int )));//connect sql and window	app.connect( &w, SIGNAL( sig_get_log(char *) ), &s, SLOT( request_db(char * )));	app.connect( &s, SIGNAL( sig_log(char *,int ) ), &w, SLOT( treatLog(char *,int )));//connect sql and center cmd	app.connect( &cmd,SIGNAL(sig_log(int)),&s,SLOT(logger(int)));	//connect app and window	app.connect( &app, SIGNAL( lastWindowClosed() ), &app, SLOT( quit() ) );	w.show();	w.getenviron();	bt.init();	return (app.exec());}

⌨️ 快捷键说明

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