how to set different TxCurrentA for each wifi node?

37 views
Skip to first unread message

13634...@qq.com

unread,
Jun 27, 2018, 10:23:50 AM6/27/18
to ns-3-users
dear  all
i want to set different TxCurrentA for each wifi node based on the distance between nodes.At first I referred to energy-model-example.cc and attempted to call WifiRadioEnergyModel::SetTxCurrentA.But  There is not WifiRadioEnergyModelContainer,only DeviceEnergyModelContainer . what should I do?

/** Energy Model **/
  /***************************************************************************/
  /* energy source */
  BasicEnergySourceHelper basicSourceHelper;
  // configure energy source
  basicSourceHelper.Set ("BasicEnergySourceInitialEnergyJ", DoubleValue (100.0));
  // install source
  EnergySourceContainer sources = basicSourceHelper.Install (c);
  /* device energy model */
  WifiRadioEnergyModelHelper radioEnergyHelper;
  // configure radio energy model
  radioEnergyHelper.Set ("TxCurrentA", DoubleValue (2.0));
  // install device model
  DeviceEnergyModelContainer deviceModels = radioEnergyHelper.Install (devices, sources);



Reply all
Reply to author
Forward
0 new messages