ATBUpdateTool/common/include/System.h

56 lines
1.2 KiB
C++

#ifndef SYSTEM_H
#define SYSTEM_H
#include <QObject>
class System : public QObject
{
Q_OBJECT
private:
explicit System(QObject *parent = 0);
static QString errorMsg;
public:
static bool checkForSDCard();
static bool umountSDCard();
static bool checkForUSBStick();
static QString getUSBMountPath();
static QString getUSBDeviceName();
static bool umountUSBStick();
static bool test_mount(const QString& dev, const QString &mountpoint);
static bool test_dir(const QString& dir);
static quint32 getFreeDiskSpace(const QString& dev);
static quint32 getFreeDiskSpaceSDCard();
static bool isSDCardWritable();
static quint32 getFreeDiskSpaceUSBStick();
static bool isUSBStickWritable();
static quint8 createLogFileBackup(const QString & targzfile, const QString &filelistfile = "");
static QString getSDCardMountPath();
static QString getSDCardDeviceName();
static QString getUniqueDeviceId();
static QString getErrorMessage();
static QString readStringFromFile(const QString & filename);
static int readIntFromFile(const QString & filename);
static QString getPTU4SerialNumber();
static QString getPTU4MACAddress();
};
#endif // SYSTEM_H