56 Commits

Author SHA1 Message Date
77bee57da9 Update .gitignore to include 'example/' directory and adjust movement parameters in task 4 and task 5 for improved control. Comment out a function call in main.py for clarity. 2025-05-31 14:26:58 +00:00
7ee061ffa9 Refactor task execution by standardizing the parameters for the center_on_dual_tracks function across multiple tasks. Enhance movement commands in task 4 for improved control and adjust speed parameters for better responsiveness in task 5. Clean up commented code for clarity. 2025-05-31 14:18:02 +00:00
0979d10415 Refactor main execution flow by enabling task execution based on arrow direction detection. Adjust max_time parameter in centering function for improved responsiveness. Update task 5's movement commands and section handling for clarity and consistency. 2025-05-31 13:53:54 +00:00
4200fb8aeb Refactor main execution flow by adding support for task 3 back functionality and adjusting task 1 and task 2 parameters. Update task 2.5 back execution logic and improve movement commands for better control. Set observe flag in track detection functions for consistency. 2025-05-31 13:40:55 +00:00
e427be6cb9 Refactor calibration logic in Robot_Ctrl class by uncommenting and optimizing the calibration process for odometry data. Ensure proper handling of calibration offset and improve clarity in the msg_handler_o method. 2025-05-31 12:47:36 +00:00
3b2fc33bf7 Refactor main execution flow by enabling task 2.5 with arrow direction detection and adjusting task 3 back execution. Update task 2.5 parameters for distance and speed, and modify task 5's horizontal line movement distance. Set observe flag to False in track detection functions for consistency. 2025-05-31 12:43:11 +00:00
1ce0f9e7bf Update centering functionality in dual track control by adding new parameters for detection height and interval. Adjust message life count handling and improve variable management in task execution. Refactor related functions for enhanced clarity and performance. 2025-05-31 09:46:46 +00:00
87be6b8328 Refactor task execution flow by removing unnecessary return statements and enhancing task 3 with additional centering functionality. Update dual track line detection to improve error handling and variable naming for clarity. 2025-05-31 07:52:19 +00:00
6dfa9101cf Refactor main.py and task_3.py: Re-enable task execution logic by restoring arrow direction handling and task function calls. Update max_iterations in pass_up_down function for improved safety. Add enhanced go_straight_with_enhanced_calibration function in task_4.py for better navigation on stone paths. 2025-05-31 01:28:03 +00:00
ba0994a82b Add go_lateral function for lateral movement control and update task_4.py to utilize it for improved navigation. Cleaned up main.py by removing unnecessary lines and added comments for clarity. 2025-05-30 11:34:56 +00:00
d56b922f6a Refactor main.py and task_4.py: Removed deprecated turn_degree_v2 call in main.py and updated task_4.py to utilize center_on_dual_tracks for improved navigation. Deleted test_center_on_tracks.py and test_offline_centering.py files to streamline the codebase. Enhanced dual track detection capabilities by integrating detect_furthest_horizontal_intersection in move_base_hori_line.py, allowing for more accurate alignment to horizontal lines. 2025-05-28 16:17:53 +00:00
91a6ef0d36 Enhance main.py and task_4: Added go_to_y_v2 function to main.py for improved navigation. Updated go_straight function in go_straight.py to accept additional parameters for mode, gait_id, and step_height, allowing for more flexible movement control. Integrated follow_dual_tracks function in task_4 to enhance task execution by enabling dual track following capabilities. 2025-05-28 13:18:27 +00:00
2bb7558fb1 Refactor main.py and task_4: Updated turning logic in main.py to use turn_degree_v2 with a fixed degree of -90. Adjusted Gait_Params_stoop_full.toml and Gait_Params_stoop.toml to reduce body velocity from 0.2 to 0.15 for smoother movement. Enhanced pass_bar.py to streamline gait file publishing and added step_num variable for better control during the pass_bar function. Updated run_task_4_back to improve task flow and added a pause for standing up after passing the bar. 2025-05-28 12:24:18 +00:00
eb34eeeb3e Enhance main.py and task_5.py: Introduced turn_degree_v2 function for improved turning control in main.py. Updated run_task_5 to accept direction parameter, allowing for dynamic movement towards unloading points based on QR code results. Added logic for moving to horizontal line and unloading sequence, enhancing task execution and robot navigation. 2025-05-28 10:07:44 +00:00
53b04a6a74 Refactor main.py and enhance go_straight_with_qrcode function in go_straight.py. Commented out unused code in main.py for clarity and added QR code scanning functionality to go_straight_with_qrcode, improving robot navigation and task execution. Updated run_task_5 to utilize the new function for better integration of QR code scanning during movement. 2025-05-28 09:56:35 +00:00
477511f291 Merge branch 'task-3' into main 2025-05-28 07:11:49 +00:00
af412c707e Update main.py: refine commented-out sleep statement for clarity in testing context 2025-05-28 05:52:08 +00:00
2e71879c25 refactor(main.py, base_move/turn_degree.py, task_3.py): update rotation functions and task execution flow
- Enabled execution of run_task_3 in main.py by uncommenting the function call.
- Updated turn_degree function to include a new version (turn_degree_v2) for enhanced rotation control.
- Adjusted the stable count threshold in turn_degree for improved stability detection.
- Replaced calls to turn_degree with turn_degree_v2 in task_3.py for better precision during rotations.
- Cleaned up commented-out code in task_3.py to streamline execution flow.
2025-05-28 03:13:48 +00:00
c083798042 Enhance navigation and movement functions in tasks
- Updated main.py to adjust task execution flow and added print statements for debugging.
- Refactored task_2.py to utilize go_to_xy_v2 for improved navigation accuracy and added an xy_flag parameter to run_task_2.
- Introduced go_to_xy_with_correction_v2 and go_to_xy_v2 in go_to_xy.py for enhanced movement control and precision.
- Modified task_2_5.py to incorporate turn_degree_v2 and added go_straight function for better maneuverability.
2025-05-28 03:02:24 +00:00
3f35af954f 更新任务2和任务4,增强箭头检测功能
- 在task_2.py中引入异步箭头检测器,优化箭头方向检测流程,确保在关键路径点进行准确检测。
- 更新run_task_2函数以支持箭头方向的动态检测,并在任务执行中根据检测结果调整后续动作。
- 在task_4.py中添加run_task_4_back函数,确保机器人能够在不同方向的情况下顺利完成任务。
- 在main.py中整合新的任务调用,确保任务执行流程的连贯性和准确性。
2025-05-28 02:23:01 +08:00
8e172759ac 更新任务4,添加直线前进至黄线的功能
- 在task_4.py中引入go_straight_until_hori_line函数,控制机器人直线前进直到检测到黄线并停在指定距离。
- 调整任务4的执行流程,确保机器人能够顺利完成新的移动任务。
- 优化了相关参数设置,以提高任务执行的准确性和稳定性。
2025-05-28 02:12:00 +08:00
bffcd973e0 Refactor task 1 and task 2 to incorporate new turn_degree_v2 function
- Updated task_1.py to replace turn_degree_twice calls with turn_degree_v2 for improved rotation accuracy.
- Modified task_2.py to utilize turn_degree_v2 for enhanced turning capabilities and adjusted movement parameters for better path execution.
- Refined go_to_xy parameters in task_2 to optimize navigation and added additional logging for debugging purposes.
2025-05-27 17:53:11 +00:00
e778530503 Enhance task 2 functionality and add backtracking capability
- Introduced run_task_2_back function to facilitate reverse navigation.
- Updated main.py to include calls to run_task_2_back alongside run_task_2 for improved task execution.
- Adjusted movement parameters in run_task_2 for better path accuracy and control.
- Added new movement functions for enhanced maneuverability in task 2.
2025-05-27 07:00:25 +00:00
c2b29f18f3 重构任务4和任务5,更新任务流程和参数
- 在main.py中注释掉run_task_2函数,确保任务执行流程的简化。
- 在task_4.py中添加go_straight_until_sky_ratio_below函数以实现基于灰色天空比例的直线移动。
- 更新README.md以反映任务4和任务5的最新描述,合并相关内容。
- 删除task_5中的多个不再使用的文件,优化代码结构。
2025-05-27 01:18:10 +08:00
92c6026536 refactor(main, task_2): comment out MarkerRunner and adjust turn_degree call
- Comment out MarkerRunner initialization and execution in main.py to simplify control flow.
- Modify turn_degree call in task_2.py to remove unnecessary observe parameter for cleaner function usage.
- Add a placeholder return statement in place_marker method for future implementation.
2025-05-26 15:45:32 +00:00
a1e9121761 refactor(main, task_2, task_test): update navigation functions and parameters
- Comment out run_go_to_xy_example in main.py to streamline execution flow.
- Adjust target coordinates in run_go_to_xy_example for improved navigation accuracy.
- Refactor run_task_2 to include calls to go_to_xy and turn_degree for enhanced movement control.
2025-05-26 15:32:45 +00:00
55491ae859 Merge branch 'task-2' into main 2025-05-26 15:06:37 +00:00
ce369bf718 refactor(main): integrate go_to_xy_example function for coordinate navigation
- Add run_go_to_xy_example function call in main.py for enhanced navigation capabilities.
- Comment out run_task_1 to streamline task execution flow.
2025-05-26 15:06:08 +00:00
d89aca3b7a refactor(main.py, task_3.py, task_test.py): update task execution flow and enhance control logic
- Commented out run_task_3 in main.py to prevent execution during testing.
- Modified turn_degree function to set precision to True for improved control.
- Removed the unnecessary task_3/main copy.py file.
- Updated run_task_3 in task_3.py to improve gait file handling and control logic.
- Adjusted parameters for stability detection and added checks for descending phases.
- Updated task_test.py to focus on straight movement while commenting out previous commands.
2025-05-26 11:37:50 +00:00
e9ff362b01 refactor(main, base_move, task_1): update task execution and enhance track detection
- Uncomment run_task_1 in main.py to enable task execution.
- Comment out run_task_test in main.py to prevent test execution.
- Introduce turn_degree_twice function in turn_degree.py for improved rotation control.
- Update task_1.py to utilize turn_degree_twice and adjust movement parameters for better task execution.
- Modify detect_func_version in task_2_5.py to use the latest detection algorithm.
- Add detect_horizontal_track_edge_v3 function in detect_track.py for enhanced edge detection capabilities.
2025-05-26 09:34:32 +00:00
401ab3d37f 新增对task_2的支持,调用run_task_2函数并注释掉run_task_test函数,以便于后续测试和功能扩展。 2025-05-26 14:21:05 +08:00
7b106c03dc refactor(task_3): update gait processing and enhance control logic
- Refactored gait processing in main.py to load parameters from Gait_Params_up.toml and publish user gait files.
- Improved control logic in task_3.py to monitor Z-axis speed and detect climbing phases.
- Added functionality for straight movement after task completion.
- Cleaned up commented-out code and ensured consistent message handling.
2025-05-26 06:11:09 +00:00
5ab480d507 重构(main.py): 移除任务4并引入任务3
- 注释掉MarkerRunner相关代码
- 替换任务4为任务3的调用
- 在place_marker函数中添加返回None以避免错误
2025-05-26 01:52:30 +08:00
612256c525 refactor(base_move): adjust parameters and fix issues in left side track following
- Reduce max_time parameter from 30 to 3 in follow_left_side_track function
- Fix side velocity sign in follow_left_side_track function
- Uncomment and update run_task_test in main.py
- Update initial heading in task_left_line.py
2025-05-25 16:51:07 +00:00
e869b4d891 fix(base_move): correct side velocity direction in follow_left_side_track
- Reverse the sign of side_velocity to move in the correct direction
- Uncomment run_task_1 and comment out run_task_test in main.py
- Update task_left_line.py to turn 90 degrees before following the left side track
2025-05-25 16:45:15 +00:00
cb002c5b9f test(left_line): update image saving path and remove unused tasks
- Update image saving path in ImageSubscriber class
- Remove unused imports and code related to task_4 and arrow detection
- Add import for run_task_test
- Comment out run_task_4 and uncomment run_task_test in main function
2025-05-25 11:37:24 +00:00
ea2e5d132a refactor(main): update task execution order and remove unused imports
- Remove imports for task_5 and task_test
- Add import for task_4
- Comment out task_2_5 execution
- Uncomment and execute task_4
2025-05-25 08:45:49 +00:00
85defc7811 feat(base_move): implement version 2 of horizontal line detection
- Add support for two versions of horizontal line detection functions
- Update move_base_hori_line.py to use the selected detection version
- Modify example_robot_log.py and test/main.py to use the new detection version
- Update image saving path in rgb-camera/img-raw-get.py
- Improve logging and error handling in detect_track.py
2025-05-23 06:56:15 +00:00
13f7e30e69 move test files 2025-05-22 05:32:16 +00:00
1d18ec1e56 test(task_1): adjust go_straight parameters and comment out angle correction
- Comment out angle correction logic in go_straight function
- Adjust go_straight parameters in task_1
- Add success message for horizontal line calibration
- Update main function to include task_test
- Modify marker request response format
2025-05-22 04:27:22 +00:00
8782fdc092 refactor(main.py): implement pass flag functionality for MarkerRunner
- Add pass_marker variable to main.py
- Update MarkerRunner initialization in Robot_Ctrl class
- Modify MarkerRunner class to accept pass_flag parameter
- Implement pass flag logic in MarkerRunner's send_request method
- Initialize ROS 2 context in main function
2025-05-19 06:08:30 +00:00
7433c83b9b refactor(base_move): improve arc turn control and distance calculation
- Implement time compensation for different turn angles
- Adjust rotation thresholds and speed factors for better control
- Fix distance calculation and variable naming in go_straight function
- Enhance observation and debugging output
2025-05-18 07:57:15 +00:00
18248d7ad9 删除当前图像文件,优化 main.py 中的恢复站立逻辑,新增 lie_down 和 stand_up 方法到 BaseMsg 类,更新 task_1.py 以使用新的移动和休息功能。 2025-05-17 11:27:39 +08:00
6779c93888 task-1 #5 2025-05-15 16:43:36 +08:00
4135f8c31a refactor(base_move): 优化移动控制逻辑和校准流程
- 修改 move_to_hori_line 函数中的超时设置和停止命令发送方式
- 在主程序中初始化和销毁 ROS 2 上下文
- 增加校准相关变量和逻辑,提高定位精度
- 优化 ImageProcessor 和 MarkerRunner 类的实现
2025-05-15 08:09:59 +00:00
f77cada464 增加 MarkerRunner 支持,优化标记放置功能
- 在 Robot_Ctrl 类中初始化 MarkerRunner,并在运行时调用其方法
- 在移动到横向线的函数中添加标记放置功能,分别在起点和终点放置绿色和红色标记
- 增强错误处理,确保 MarkerRunner 正确销毁
2025-05-15 11:19:24 +08:00
6996a3459f task-1 #3 2025-05-14 14:50:50 +00:00
6be89617e7 重构主程序,移除图像处理器实例化,简化任务1函数参数,删除无用的测试文件,优化代码结构。 2025-05-14 19:35:29 +08:00
aa4621ed55 task-1 #1 2025-05-14 11:25:44 +00:00
9ec783b8b1 更新主程序以启用任务5的执行,并修改turn_degree函数以支持相对角度旋转。 2025-05-13 18:27:47 +08:00