- Timestamp:
- Mar 14, 2019, 2:28:37 PM (6 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/demos/CircleFollower/uav/src/CircleFollower.cpp
r263 r311 43 43 44 44 VrpnClient* vrpnclient=new VrpnClient("vrpn", uav->GetDefaultVrpnAddress(),80); 45 uavVrpn = new MetaVrpnObject(uav->ObjectName()); 45 46 if(vrpnclient->ConnectionType()==VrpnClient::Xbee) { 47 uavVrpn = new MetaVrpnObject(uav->ObjectName(),(uint8_t)0); 48 targetVrpn=new MetaVrpnObject("target",1); 49 } else if (vrpnclient->ConnectionType()==VrpnClient::Vrpn) { 50 uavVrpn = new MetaVrpnObject(uav->ObjectName()); 51 targetVrpn=new MetaVrpnObject("target"); 52 } else if (vrpnclient->ConnectionType()==VrpnClient::VrpnLite) { 53 uavVrpn = new MetaVrpnObject(uav->ObjectName(),(uint8_t)0); 54 targetVrpn=new MetaVrpnObject("target",1); 55 } 56 46 57 getFrameworkManager()->AddDeviceToLog(uavVrpn); 47 58 uav->GetAhrs()->YawPlot()->AddCurve(uavVrpn->State()->Element(2),DataPlot::Green); … … 50 61 stopCircle=new PushButton(GetButtonsLayout()->LastRowLastCol(),"stop_circle"); 51 62 positionHold=new PushButton(GetButtonsLayout()->LastRowLastCol(),"position hold"); 52 53 if(vrpnclient->UseXbee()==true) { 54 targetVrpn=new MetaVrpnObject("target",1); 55 } else { 56 targetVrpn=new MetaVrpnObject("target"); 57 } 58 vrpnclient->Start(); 63 64 vrpnclient->Start(); 59 65 60 66 getFrameworkManager()->AddDeviceToLog(targetVrpn);
Note:
See TracChangeset
for help on using the changeset viewer.