]> rtime.felk.cvut.cz Git - eurobot/public.git/commitdiff
robofsm: Rename function to use the same style
authorPetr Silhavik <silhavik.p@gmail.com>
Sun, 17 Mar 2013 15:09:16 +0000 (16:09 +0100)
committerPetr Silhavik <silhavik.p@gmail.com>
Sun, 17 Mar 2013 15:09:16 +0000 (16:09 +0100)
src/robofsm/robot.cc
src/robofsm/scheduler.hpp

index 4ccdd3b0f3bc32c24dc2c8cef2596b2afa120834..7b3a54d5a6f91ed819a96b8f358087e93688600a 100644 (file)
@@ -1,3 +1,5 @@
+
+#define _XOPEN_SOURCE 500
 #include <map.h>
 #include <movehelper.h>
 #include <pthread.h>
@@ -277,16 +279,16 @@ float Robot::current_time() {
 
 void Robot::set_state_name(const char* name)
 {
-       sched.getActualHandle()->state_name = name;
+       sched.get_actual_handle()->state_name = name;
        trans_callback();
 }
 
 void Robot::trans_callback()
 {
-       if (MAIN == sched.getActualHandle()) {
+       if (MAIN == sched.get_actual_handle()) {
                strncpy(robot.orte.fsm_main.state_name, MAIN->state_name, sizeof(robot.orte.fsm_main.state_name));
                ORTEPublicationSend(robot.orte.publication_fsm_main);
-       } else if (MOTION == sched.getActualHandle()) {
+       } else if (MOTION == sched.get_actual_handle()) {
                strncpy(robot.orte.fsm_motion.state_name, MOTION->state_name, sizeof(robot.orte.fsm_motion.state_name));
                ORTEPublicationSend(robot.orte.publication_fsm_motion);
        }
index 01dd97c5eaae5023e6fdf65da61f985b37c178fd..bae76e2f4402ca65fcf040788899d3aea1948938 100644 (file)
@@ -126,7 +126,7 @@ public:
                        delete processor_queue_list[i];
                }
        }
-       processor_handle getActualHandle() {
+       processor_handle get_actual_handle() {
                return actual_processor;
        }