ntrip, testMode, zed9 gnss modul
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
/**
|
||||
* @file driveManager.cpp
|
||||
* @author Alexander Klein (alex@kleiax.de)
|
||||
* @brief Implemention of the class DriveManager
|
||||
* @brief Implementation of the class DriveManager
|
||||
* @version 0.1
|
||||
* @date 2021-12-14
|
||||
*
|
||||
@@ -15,9 +15,11 @@ Modi& operator++(Modi& m, int) {
|
||||
return m = (m == Modi::TestMode) ? Modi::Off : static_cast<Modi>(static_cast<int>(m)+1);
|
||||
}
|
||||
|
||||
DriveManager::DriveManager(MoveControl *moveControl) {
|
||||
DriveManager::DriveManager(MoveControl *moveControl, bool wifi) {
|
||||
this->moveControl = moveControl;
|
||||
this->navigation = new Navigation();
|
||||
if (wifi)
|
||||
this->navigation->initNtrip(NTRIP_HOST, NTRIP_PORT, NTRIP_MOUNT_POINT, NTRIP_USER, NTRIP_PASSWORD);
|
||||
}
|
||||
|
||||
DriveManager::~DriveManager() {
|
||||
@@ -42,7 +44,7 @@ void DriveManager::changeModus(Modi modus) {
|
||||
delete this->currentModusPtr;
|
||||
|
||||
this->moveControl->setSpeed(0);
|
||||
this->moveControl->setRotationspeed(0);
|
||||
this->moveControl->setRotationSpeed(0);
|
||||
this->moveControl->setDrivingStatus(DrivingStatus::stop);
|
||||
|
||||
switch (modus) {
|
||||
@@ -69,8 +71,9 @@ void DriveManager::changeModus(Modi modus) {
|
||||
this->currentModusPtr = nullptr;
|
||||
break;
|
||||
|
||||
case Modi::TestMode:
|
||||
this->currentModusPtr = nullptr;
|
||||
case Modi::TestMode: {
|
||||
this->currentModusPtr = new TestMode(this->moveControl);
|
||||
}
|
||||
break;
|
||||
|
||||
default:
|
||||
|
||||
Reference in New Issue
Block a user