Hotwheels-Cluster 1.2
Creation of Cluster APP for SEA:ME project.
 
Loading...
Searching...
No Matches
ControlsManager.hpp
Go to the documentation of this file.
1
14
15#ifndef CONTROLSMANAGER_HPP
16#define CONTROLSMANAGER_HPP
17
18#include "EngineController.hpp"
20#include "../ZeroC/ClientThread.hpp"
21#include "../ZeroC/CarDataI.hpp"
22#include <QObject>
23#include <QThread>
24#include <QProcess>
25
30class ControlsManager : public QObject {
31 Q_OBJECT
32
33private:
39
45
46 std::atomic<bool> m_threadRunning;
47
48public:
49 explicit ControlsManager(int argc, char **argv, QObject *parent = nullptr);
51
52 void setMode(DrivingMode mode);
53 void readJoystickEnable();
54 bool isProcessRunning(const QString &processName);
55 //bool isServiceRunning(const QString &serviceName);
56};
57
58#endif // CONTROLSMANAGER_HPP
File containing the EngineController class.
File containing the JoysticksController class.
DrivingMode
Enum class for the driving mode.
Definition enums.hpp:24
Class for the client thread.
void readJoystickEnable()
Reads joystick enable status.
DrivingMode m_currentMode
QThread * m_processMonitorThread
Data::CarDataI * m_carDataObject
QThread * m_joystickControlThread
bool isProcessRunning(const QString &processName)
Check if a process is running.
JoysticksController * m_manualController
void setMode(DrivingMode mode)
Sets the driving mode.
~ControlsManager()
Destructor for the ControlsManager class.
QThread * m_manualControllerThread
ControlsManager(int argc, char **argv, QObject *parent=nullptr)
Constructs a ControlsManager object.
ClientThread * m_clientObject
std::atomic< bool > m_threadRunning
EngineController m_engineController
QThread * m_carDataThread
Class for the car data.
Definition CarDataI.hpp:38
The EngineController class.
The JoysticksController class.