当前位置:网站首页>QT基于RFID管理系统(可应用于大多数RFID管理系统)
QT基于RFID管理系统(可应用于大多数RFID管理系统)
2022-06-29 00:59:00 【比物理简单】
本系统由QT编译,可应用于大多数基于RFID的管理系统,可进行端口设置,进出系统物品查询等基本功能!
此课题全部说明书以及程序包已打包!需要的私信取!
系统实现:
将RFID技术引入柜台贵重物品管理系统,为贵重的柜台商品绑定RFID标签,结合安装在柜台上的RFID识别设备用来监测、控制和跟踪贴标的贵重物品,实现快速盘点、实时跟踪及销售的智能管理。从而对柜台贵重物品产品的进出和销售过程进行全方位的跟踪和记录,用自动化和准确高效的新方法取代了繁琐和低效的人工管理和条码扫描模式。并能做到短距离离开柜台(3~5米)报警,未能取得授权情况下,破坏或解除RFID标签与贵重物品的绑定报警。
1. 总体方案设计(论证)
2. RFID卡设计
(1) 射频识别技术;(2) 电子标签的选择。
3. RFID读写器硬件设计
(1) MCU;(2) 射频模块;(3) 天线;(4) 通信接口;(5) 人机界面;(6) 电源电路。
4. RFID读写器软件设计
(1) 系统初始化程序;(2) 对卡操作程序;(3) 液晶显示程序。
部分实现程序:
widget.cpp:
#include <QDebug>
#include "views/widget.h"
#include "ui_widget.h"
Widget::Widget(QWidget *parent) :
QWidget(parent),
ui(new Ui::Widget)
{
ui->setupUi(this);
QTextCodec *codec = QTextCodec::codecForName("utf8"); //GBK gbk
QTextCodec::setCodecForLocale(codec);
this->setWindowTitle(QString::fromLocal8Bit("基于RFID的柜台贵重物品管理系统"));
setWidgetbackground(this,QPixmap(":/rcs/jjo.jpg")); //主界面
//setButtonbackground(ui->navButton,QPixmap(":/rcs/homeButton.png"));
setButtonbackground(ui->setButton,QPixmap(":/rcs/setButton.png")); setButtonbackground(ui->recordButton,QPixmap(":/rcs/widgetButton.png"));
_serialThread = new QThread(this);
_serialConnection = new SerialConnection();
navWidget = new homeForm(); //设备界面
setDialog = new setting(); //配置界面
m_cAlarmRecord = new CAlarmRecord(); //历史记录界面
//connect(ui->navButton,SIGNAL(clicked()),navWidget,SLOT(show()));
connect(ui->setButton,SIGNAL(clicked()),setDialog,SLOT(show())); connect(ui->recordButton,SIGNAL(clicked()),m_cAlarmRecord,SLOT(show()));
connect(navWidget,SIGNAL(Record_Signal(int,quint8)),m_cAlarmRecord,SLOT(AddRecord(int,quint8))); //历史数据存储
connect(navWidget,SIGNAL(DispSensor1_Signal(QString)),this,SLOT(DispSensor1_Slot(QString))); //主界面显示
connect(navWidget,SIGNAL(DispSensor2_Signal(QString)),this,SLOT(DispSensor2_Slot(QString))); //主界面显示
connect(navWidget,SIGNAL(DispSensor3_Signal(QString)),this,SLOT(DispSensor3_Slot(QString))); //主界面显示
/*串口连接*/
connect(_serialThread, SIGNAL(started()),_serialConnection, SLOT(readData()));
connect(_serialThread, SIGNAL(finished()), _serialConnection, SLOT(deleteLater()));
connect(_serialConnection,SIGNAL(sendnewdata(QByteArray)),navWidget,SLOT(RecvSensorData(QByteArray)));
connect(navWidget,SIGNAL(sensorCtrol(QByteArray)),_serialConnection,SLOT(SendCmdData(QByteArray)));
connect(_serialConnection,SIGNAL(connectionStateChanged(int)),setDialog,SLOT(DispConnectState_Slot(int)));
connect(setDialog,SIGNAL(StartUartDev_Signal(int)),_serialConnection,SLOT(openConnection(int)));
connect(setDialog,SIGNAL(CloseUartDev_Signal()),_serialConnection,SLOT(closeConnection()));
_serialConnection->moveToThread(_serialThread);
_serialThread->start();
/* 状态更新定时器 */
m_tmDate = new QTimer(this);
connect(m_tmDate,SIGNAL(timeout()),this, SLOT(DispDate_Slot()));
m_tmDate->start(1000); //1s
}
Widget::~Widget()
{
if (_serialThread)
{
if (_serialThread->isRunning())
{
_serialThread->quit();
_serialThread->wait();
}
delete _serialThread;
_serialThread = NULL;
}
delete ui;
}
//设置窗体背景
void Widget::setWidgetbackground(QWidget *widget,QPixmap image)
{
QPalette palette;
palette.setBrush(backgroundRole(),QBrush(image));
widget->setPalette(palette);
}
//设置按钮背景
void Widget::setButtonbackground(QPushButton *button,QPixmap picturepath)
{
button->setFixedSize(picturepath.width(),picturepath.height());
button->setIcon(QIcon(picturepath));
button->setFlat(true); button->setIconSize(QSize(picturepath.width(),picturepath.height()));
button->setToolTip("");
}
void Widget::DispSensor1_Slot(QString _strValue)
{
ui->m_DispValue_1->setText(_strValue);
}
void Widget::DispSensor2_Slot(QString _strValue)
{
ui->m_DispValue_2->setText(_strValue);
}
void Widget::DispSensor3_Slot(QString _strValue)
{
ui->m_DispValue_3->setText(_strValue);
}
/*显示日期*/
void Widget::DispDate_Slot(void)
{
QDateTime dateTime(QDateTime::currentDateTime());
ui->m_DispDate->setText(dateTime.toString("yyyy-MM-dd hh:mm:ss ddd"));
}
Setting.cpp
#include "views/setting.h"
#include "ui_setting.h"
#include "views/widget.h"
setting::setting(QWidget *parent) :
QDialog(parent),
ui(new Ui::setting)
{
ui->setupUi(this);
QTextCodec *codec = QTextCodec::codecForName("utf8"); //GBK gbk
QTextCodec::setCodecForLocale(codec);
this->setWindowTitle(QString::fromLocal8Bit("设置"));
this->setWindowOpacity(0.9); //背景和元素都设置透明效果
this->setModal(true); //设置为模态界面
}
setting::~setting()
{
delete ui;
}
void setting::on_m_ExeConnectUART_clicked()
{
int com;
com = ui->m_GetComPort->currentIndex();
if(ui->m_ExeConnectUART->text() == "连接")
{
emit StartUartDev_Signal(com); //连接串口信号
}
else
{
emit CloseUartDev_Signal(); //断开串口信号
ui->m_ExeConnectUART->setText(QString::fromLocal8Bit("连接"));
ui->m_DispComState->setText(QString::fromLocal8Bit("断开"));
}
}
void setting::DispConnectState_Slot(int state)
{
switch (state)
{
case 0: //Disconnected
ui->m_DispComState->setText(QString::fromLocal8Bit("连接已断开"));
break;
case 1:
ui->m_DispComState->setText(QString::fromLocal8Bit("正在连接"));
break;
case 2:
ui->m_ExeConnectUART->setText(QString::fromLocal8Bit("断开"));
ui->m_DispComState->setText(QString::fromLocal8Bit("连接成功"));
break;
case 3:
ui->m_DispComState->setText(QString::fromLocal8Bit("连接失败"));
break;
default:
break;
}
}
int setting::updateDeviceList()
{
int count = ui->m_GetComPort->count();
while(ui->m_GetComPort->count())
{
ui->m_GetComPort->removeItem(0);
}
serial.findSerialDevices();
ui->m_GetComPort->addItems(serial.portsList());
qDebug() << count;
return count;
}
边栏推荐
- 用户登录(记住用户)&用户注册(验证码) [运用Cookie Session技术]
- Structure of the actual combat battalion | module 5
- 狼人杀休闲游戏微信小程序模板源码/微信小游戏源码
- [MCU club] design of blind water cup based on MCU [simulation design]
- 华泰证券安全吗
- 滑环电机是如何工作的
- 【leetcode】17. Letter combination of telephone number
- 滑环的基本结构及工作原理分析
- Analysis Framework -- establishment of user experience measurement data system
- If you can play these four we media operation tools, the sideline income of 6000+ is very easy
猜你喜欢

Breadth first search to catch cattle

Reference materials in the process of using Excel

What is the reason why easycvr can't watch the device video when it is connected to the home protocol?

Ensemble de données sur les visages masqués et méthode de génération des visages masqués
![[image registration] SAR image registration based on particle swarm optimization Improved SIFT with matlab code](/img/b5/02979b50db885f0606dce455182ac4.jpg)
[image registration] SAR image registration based on particle swarm optimization Improved SIFT with matlab code

Accessories and working process of machine vision system

pinhole camera model

机器视觉系统的配件及工作过程

Précautions d'installation et d'utilisation des joints rotatifs

be based on. NETCORE development blog project starblog - (13) add friendship link function
随机推荐
[MCU club] design of blind water cup based on MCU [physical design]
User login (remember the user) & user registration (verification code) [using cookie session technology]
EasyCVR集群版本替换成老数据库造成的服务崩溃是什么原因?
盘点 6 月 yyds 的开源项目!
Excel使用过程中的参考资料
Notes on the infrastructure of large websites
Daily English articles, reading accumulation
[image processing] image curve adjustment system based on MATLAB
Program environment and pretreatment
Esmm reading notes
Nodejs installation and download
XML and other file contents in idea cannot be highlighted, and the file becomes gray
统计字符串中不同回文子序列的个数
Accessories and working process of machine vision system
Check the open source projects of yyds in June!
一条update语句到底加了多少锁?带你深入理解底层原理
[communication] wide band source DOA estimation method based on incoherent signal subspace (ISM)
Drawing ECG curve with WPF
Document management.
手下两个应届生:一个踏实喜欢加班,一个技术强挑活,怎么选??