Example #1
0
 def planet_move(self, number, off_x = 0, off_y = 0, offcoord = 'HORIZONTAL', hosei = 'hosei_230.txt', lamda=2600, az_rate=12000, el_rate=12000, dcos=0):
     """1.Mercury 2.Venus 3. 4.Mars 5.Jupiter 6.Saturn 7.Uranus 8.Neptune, 9.Pluto, 10.Moon, 11.Sun"""
     msg = Move_mode_msg()
     msg.ntarg = number
     msg.off_x = off_x
     msg.off_y = off_y
     msg.code_mode = "planet"
     msg.hosei = hosei
     msg.offcoord = offcoord
     msg.lamda = lamda
     msg.dcos = dcos
     #mv.az_rate ... no inplementation
     #mv.el_rate ... no inplementation
     rospy.loginfo(msg)
     self.pub10.publish(msg)
     return
Example #2
0
 def pub_planet(self):
     while self.p_flag == 0:
         time.sleep(1)
     else:
         msg = Move_mode_msg()
         while not rospy.is_shutdown():
             msg.ntarg = self.number
             msg.off_x = self.off_x
             msg.off_y = self.off_y
             msg.code_mode = self.code_mode
             msg.hosei = self.hosei
             msg.offcoord = self.offcoord
             msg.lamda = self.lamda
             msg.dcos = self.dcos
             rospy.loginfo(msg)
             self.pub3.publish(msg)
             time.sleep(5)
             continue
     return