ADD: added functionality to show the position in a simtrack of a connected ship

This commit is contained in:
Henry Winkel
2023-08-10 17:18:10 +02:00
parent 5739585b90
commit bbf4be8108
4 changed files with 125 additions and 28 deletions

View File

@@ -2,6 +2,9 @@
#define __SIMCONTROL__
#include "DirectCommunicationClient.hpp"
#include "SimCore/Identifier.hpp"
#include "crossguid/guid.hpp"
#include "kubecontrol/PodController.hpp"
#include <iostream>
@@ -9,6 +12,7 @@
#include <cstdint>
#include <memory>
#include <string>
#include <sys/types.h>
#include <thread>
#include <mutex>
#include <queue>
@@ -22,15 +26,23 @@ namespace SimControl {
class SimControl{
public:
SimControl( std::string addr, ushort port);
SimControl(ushort CommandPort);
~SimControl();
void stop();
private:
const SimCore::Identifier ID_;
ushort CommandPort_;
void MainFunction_();
void HandleMessage(std::string msg);
std::unique_ptr<kubecontrol::PodController> PodController_;
std::thread MainThread_;
std::atomic<bool> stopMainThread_ = false;
std::unique_ptr<DirectCommunication::DirectCommunicationClient> TCPClient_;