Skip to content
Snippets Groups Projects
Commit d6f88f48 authored by Franz Bethke's avatar Franz Bethke
Browse files

Add configuration folder

parent bf97840a
No related merge requests found
/home/bethke/Repositories/Semesterprojekt/Gruppe-A-intern/modules/CarConfig/
\ No newline at end of file
// Numbers on name representing indicies
// current car state
x1: 0
x2: 0
// covariance matrix
p11: 10
p22: 10
// dynamic model
f11: 1
f12: 0.001
f21: 0
f22: 1
// process error
q11: 1
q22: 1
// measure vector
h1: 1
h2: 0
// measurement error
r: 5
VehicleId: 1 use 1,2 or 3 here depending on the position of the car in platoon; 1 = LEADER
BroadCast: 10.255.255.255
...@@ -39,7 +39,7 @@ void Environment::readConfigFile() ...@@ -39,7 +39,7 @@ void Environment::readConfigFile()
// open config file // open config file
std::string userHome = getenv("HOME"); std::string userHome = getenv("HOME");
std::ifstream configFile; std::ifstream configFile;
configFile.open(userHome + "/.CarConfig/environment.config", std::ifstream::in); configFile.open(userHome + "/CarConfig/environment.config", std::ifstream::in);
if (!configFile.is_open()) { throw FileNotFound(); } if (!configFile.is_open()) { throw FileNotFound(); }
// desired parameters // desired parameters
......
...@@ -24,7 +24,7 @@ platoonProtocol::NetworkInfo readNetworkInfo() { ...@@ -24,7 +24,7 @@ platoonProtocol::NetworkInfo readNetworkInfo() {
// open config file // open config file
std::string userHome = getenv("HOME"); std::string userHome = getenv("HOME");
std::ifstream configFile; std::ifstream configFile;
configFile.open(userHome + "/.CarConfig/platoon.config", std::ifstream::in); configFile.open(userHome + "/CarConfig/platoon.config", std::ifstream::in);
if (!configFile.is_open()) { throw FileNotFound(); } if (!configFile.is_open()) { throw FileNotFound(); }
// desired parameters // desired parameters
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment