sat-generic-launcher.cc
Go to the documentation of this file.
1 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
2 /*
3  * Copyright (c) 2018 CNES
4  *
5  * This program is free software; you can redistribute it and/or modify
6  * it under the terms of the GNU General Public License version 2 as
7  * published by the Free Software Foundation;
8  *
9  * This program is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12  * GNU General Public License for more details.
13  *
14  * You should have received a copy of the GNU General Public License
15  * along with this program; if not, write to the Free Software
16  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17  *
18  * Author: Mathias Ettinger <mettinger@toulouse.viveris.fr>
19  *
20  */
21 
22 #include "ns3/config-store-module.h"
23 #include "ns3/core-module.h"
24 #include "ns3/internet-module.h"
25 #include "ns3/network-module.h"
26 #include "ns3/satellite-module.h"
27 #include "ns3/traffic-module.h"
28 
29 using namespace ns3;
30 
41 NS_LOG_COMPONENT_DEFINE("sat-generic-launcher");
42 
43 int
44 main(int argc, char* argv[])
45 {
46  std::string inputFileNameWithPath =
47  Singleton<SatEnvVariables>::Get()->LocateDirectory("contrib/satellite/examples") +
48  "/generic-input-attributes.xml";
49 
50  Ptr<SimulationHelper> simulationHelper = CreateObject<SimulationHelper>("generic-launcher");
51  simulationHelper->DisableAllCapacityAssignmentCategories();
52  simulationHelper->EnableCrdsa();
53 
54  CommandLine cmd;
55  simulationHelper->AddDefaultUiArguments(cmd, inputFileNameWithPath);
56  cmd.Parse(argc, argv);
57 
58  simulationHelper->ConfigureAttributesFromFile(inputFileNameWithPath);
59  simulationHelper->StoreAttributesToFile("parametersUsed.xml");
60  simulationHelper->RunSimulation();
61 }
SatArqSequenceNumber is handling the sequence numbers for the ARQ process.