Open severin-lemaignan opened 10 years ago
The state machine is now being used to ensure that the robot and tablet are both connected before proceeding to publish shape messages. I.e. neither device should write without the other now. Also therefore the structure is implemented now for the robot to do some stalling behaviour while in the waiting_for_tablet_to_connect state for extended period of time, if appropriate. https://github.com/chili-epfl/nao_ros_cowriter/commit/c225f067913da032a215d4d9659a731fb6fa70ba
Example output where both devices are connected: ------------------------------------------ waiting_for_robot_to_connect ------------------------------------------ STARTING_INTERACTION ------------------------------------------ WAITING_FOR_WORD ------------------------------------------ RESPONDING_TO_NEW_WORD making new 'n' shape making new 'a' shape making new 'o' shape ------------------------------------------ waiting_for_robot_to_connect ------------------------------------------ waiting_for_tablet_to_connect ------------------------------------------ PUBLISHING_LETTER publishing 'n' ------------------------------------------ WAITING_FOR_LETTER_TO_FINISH ------------------------------------------ waiting_for_robot_to_connect ------------------------------------------ waiting_for_tablet_to_connect ------------------------------------------ PUBLISHING_LETTER publishing 'a' ------------------------------------------ WAITING_FOR_LETTER_TO_FINISH ------------------------------------------ waiting_for_robot_to_connect ------------------------------------------ waiting_for_tablet_to_connect ------------------------------------------ PUBLISHING_LETTER publishing 'o' ------------------------------------------ WAITING_FOR_LETTER_TO_FINISH ------------------------------------------ WAITING_FOR_FEEDBACK received feedback for 'o' ------------------------------------------ waiting_for_robot_to_connect ------------------------------------------ RESPONDING_TO_FEEDBACK modifying 'o' shape ------------------------------------------ waiting_for_robot_to_connect ------------------------------------------ waiting_for_tablet_to_connect ------------------------------------------ PUBLISHING_LETTER publishing 'o' ------------------------------------------ WAITING_FOR_LETTER_TO_FINISH ------------------------------------------ WAITING_FOR_FEEDBACK
If robot disconnect, tablet stop writing If tablet disconnect, robot looks embarassed...