第一次提交
This commit is contained in:
43
app/app_dependence.cpp
Normal file
43
app/app_dependence.cpp
Normal file
@@ -0,0 +1,43 @@
|
||||
#include "app_dependence.h"
|
||||
#include <QDateTime>
|
||||
|
||||
// 添加Qt相关头文件
|
||||
#include <QDateTime>
|
||||
|
||||
UnCanFault can_fault_info;
|
||||
UnEthernetFault ethernet_fault_Info;
|
||||
|
||||
unsigned int wrbyte_24c02(unsigned int addr, unsigned char data)
|
||||
{
|
||||
(void)addr;
|
||||
(void)data;
|
||||
return 0;
|
||||
}
|
||||
|
||||
unsigned char rdbyte_24c02(unsigned int addr)
|
||||
{
|
||||
(void)addr;
|
||||
return 0;
|
||||
}
|
||||
|
||||
void feedWatchdog(void)
|
||||
{
|
||||
}
|
||||
|
||||
void udelay(uint32_t t )
|
||||
{
|
||||
(void)t;
|
||||
}
|
||||
|
||||
extern "C" {
|
||||
uint32_t getCurrentTime(void)
|
||||
{
|
||||
// 获取当前时间
|
||||
QDateTime current = QDateTime::currentDateTime();
|
||||
// 转换为毫秒级时间戳
|
||||
uint32_t timestamp = static_cast<uint32_t>(current.toMSecsSinceEpoch());
|
||||
|
||||
return timestamp;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user