Python Forum
Help in using Flag pretty please
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Help in using Flag pretty please
#1
Hi all, I am new to Python programming and I being tasked to create codes by my supervisor but I have no clue how to.

I am doing a project on robots for my internship and he asked me to implement flags for different kind of 'modes' on the robot. He told me to add the flags in front line 5 so that the 'modes' can be easily detected. Modes being like 'Manual Driving'.

1. def callback(self, vel):
2. x = format(vel.linear.x, '+.2f')
3 z = format(vel.angular.z, '+.2f')
4. ##############################
5. pck = b':' + x + b',' + z
6. rospy.loginfo("Data Transmitting %s", pck)
7 # Check the number of bytes to fit the format
8 # b':+X.XX,+X.XX' => 12bytes ;)

This is what I am given. Any help would be greatly appreciated! :)
Reply
#2
Can't give proper answer without knowing more about the robot, and it's command set.
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Simple Cryptography Capture the Flag DrEastwood 12 11,550 Oct-12-2016, 11:40 PM
Last Post: ichabod801

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020