void Start() { rosSocket = GameObject.Find("drone").GetComponent <RosConnector>().RosSocket; droneBody = GameObject.Find("drone").GetComponent <Rigidbody>(); publication_id = rosSocket.Advertize(publishTopic, "sensor_msgs/PointCloud2"); laser = new rayCaster(maxLeftAngle, maxRightAngle, maxTopAngle, maxBottomAngle, verticalIncrement, horizontalIncrement, maxDistance, this, 1 << 8); pcl.createPclCloud(0, 0, true); pc = new SensorPointCloud2(); }
void Start() { Application.targetFrameRate = 60; //ros connection //rosSocket = new RosSocket("ws://192.168.1.10:9090"); rosSocket = transform.GetComponent <RosConnector>().RosSocket; publication_id = rosSocket.Advertize("/drone/pos", "geometry_msgs/Pose"); droneBody = this.GetComponent <Rigidbody>(); c = new droneController(new controlVars(pidVelX), new controlVars(pidVelY), new controlVars(pidVelZ), new controlVars(pidAngVelY), Time.fixedDeltaTime); //cam1.enabled = false; //cam2.enabled = true; }
// Use this for initialization void Start() { rosSocket = GameObject.Find("drone").GetComponent <RosConnector>().RosSocket; droneBody = GameObject.Find("drone").GetComponent <Rigidbody>(); publication_id = rosSocket.Advertize(publishTopic, "sensor_msgs/Imu"); }
// Use this for initialization void Start() { rosSocket = GameObject.Find("drone").GetComponent <RosConnector>().RosSocket; droneBody = GameObject.Find("drone").GetComponent <Rigidbody>(); publication_id = rosSocket.Advertize("drone/gps", "sensor_msgs/NavSatFix"); }