void init() { publisher_lidar_1 = Net2.Publisher("lidar_1"); publisher_camera_color = Net2.Publisher("camera_color"); subscriber_cmd_vel = Net2.Subscriber("rrs_ros-cmd_vel"); subscriber_cmd_vel.delegateNewData += Subscriber_cmd_vel_delegateNewData; //Sensors //color_camera.delegateCameraDataChanged += Color_camera_delegateCameraDataChanged; lidar.delegateLidarDataChanged += Lidar_delegateLidarDataChanged; }
//Unity Benchamark Report //ROS2 //ROS# void init() { //Initialization publisher_lidar_net2 = Net2.Publisher("lidar"); publisher_camera_rgb_net2 = Net2.Publisher("camera_color"); publisher_camera_depth_net2 = Net2.Publisher("camera_depth"); publisher_imu_net2 = Net2.Publisher("imu"); color_camera.delegateCameraDataChanged += Color_camera_delegateCameraDataChanged; depth_camera.delegateCameraDataChanged += Depth_camera_delegateCameraDataChanged; imu.delegateIMUDataChanged += Imu_delegateIMUDataChanged; lidar.delegateLidarDataChanged += Lidar_delegateLidarDataChanged; }
void init() { initJointsConfig(); d_joints = new float[joint_numbers]; c_joints = new float[joint_numbers]; publisher_joint_state = Net2.Publisher("joint_state"); publisher_lidar_front = Net2.Publisher("lidar_front"); publisher_lidar_rear = Net2.Publisher("lidar_rear"); publisher_camera_color = Net2.Publisher("camera_color"); publisher_camera_info = Net2.Publisher("camera_info"); publisher_camera_depth = Net2.Publisher("camera_depth"); publisher_camera_segment = Net2.Publisher("camera_segment"); publisher_camera_normal = Net2.Publisher("camera_normal"); publisher_groundtruth = Net2.Publisher("groundtruth"); publisher_imu = Net2.Publisher("imu"); publisher_odometry = Net2.Publisher("odometry"); publisher_tf = Net2.Publisher("tf"); subscriber_cmd_vel = Net2.Subscriber("rrs_ros-cmd_vel"); subscriber_cmd_vel.delegateNewData += Subscriber_cmd_vel_delegateNewData; subscriber_planner_viz = Net2.Subscriber("rrs_ros-planner_viz"); subscriber_planner_viz.delegateNewData += Subscriber_planner_viz_delegateNewData; subscriber_rrs_command = Net2.Subscriber("rrs_ros-rrs_command"); subscriber_rrs_command.delegateNewData += Subscriber_rrs_command_delegateNewData; subscriber_rrs_joint_command = Net2.Subscriber("rrs_ros-joint_command"); subscriber_rrs_joint_command.delegateNewData += Subscriber_rrs_joint_command_delegateNewData; //Sensors color_camera.delegateCameraDataChanged += Color_camera_delegateCameraDataChanged; depth_camera.delegateCameraDataChanged += Depth_camera_delegateCameraDataChanged; segment_camera.delegateCameraDataChanged += Segment_camera_delegateCameraDataChanged; normal_camera.delegateCameraDataChanged += Normal_camera_delegateCameraDataChanged; imu.delegateIMUDataChanged += Imu_delegateIMUDataChanged; lidar_front.delegateLidarDataChanged += Lidar_front_delegateLidarDataChanged; lidar_rear.delegateLidarDataChanged += Lidar_rear_delegateLidarDataChanged; }