follow_color.py 588 Bytes
Newer Older
1
2
#!/usr/bin/env python
from __future__ import print_function, division
Antonin Raffin's avatar
Antonin Raffin committed
3
4

import time
5
import message_filters
Antonin Raffin's avatar
Antonin Raffin committed
6
import rospy
Antonin Raffin's avatar
Antonin Raffin committed
7
import numpy as np
Antonin Raffin's avatar
Antonin Raffin committed
8
from geometry_msgs.msg import Twist
Antonin Raffin's avatar
Antonin Raffin committed
9
from std_msgs.msg import Float32
10

Zhang Xuan's avatar
Zhang Xuan committed
11
12
#   Publisher of velocity
#TODO
13

Zhang Xuan's avatar
Zhang Xuan committed
14
# callback of the Subscriber
Antonin Raffin's avatar
Antonin Raffin committed
15
def turnCallback(data):
Zhang Xuan's avatar
Zhang Xuan committed
16
17
    #TODO
    pass
18

19

Antonin Raffin's avatar
Antonin Raffin committed
20
if __name__ == "__main__":
Antonin Raffin's avatar
Antonin Raffin committed
21
22
    print("Starting follow_color node")
    rospy.init_node('follow_color', anonymous=True)
Zhang Xuan's avatar
Zhang Xuan committed
23
24
    # Declare the Subscriber to center_deviationturn
    #TODO
25
26
27
28
    try:
        rospy.spin()
    except KeyboardInterrupt:
        print("Shutting down")