Automatic instruction generation for mobile robot in CoppeliaSim from flowcharts for programming learning
Abstract
Flowcharts are widely used in programming and robotics education to represent the logical structure of algorithms, especially for beginners. However, manually translating these diagrams into code is often tedious and error-prone for learners, especially when the task involves instructions to control a mobile robot. While visual tools can support engagement and learning, the complexity of programming-language syntax continues to create barriers to developing algorithmic reasoning. Therefore, this paper presents a system based on computer vision and machine learning techniques to automatically convert hand-drawn linear flowcharts—composed of predefined movement commands, including single-state loops—into executable instructions for the CoppeliaSim simulator to control the Pioneer P3DX mobile robot, representing a significant advancement in programming education. The system was validated through flowchart recognition, kinematic accuracy analysis, and path-efficiency metrics across controlled experimental scenarios with varying environmental complexity. Under these evaluated conditions, the results showed consistent execution performance (CV < 21%) and a high correlation between instruction count and execution time (r > 0.985). The recognition pipeline achieved an accuracy rate of 95.8%, and the ablation study identified adaptive thresholding as the most influential preprocessing component for robustness. In addition, an evaluation with 12 computer science students showed that the system reduced manual coding time by 77% compared with Python programming, while also lowering perceived task difficulty. The mobile robot reached the target in all tested navigation scenarios. These findings support the potential use of the proposed system in introductory robotics education, although its current scope remains limited to the flowchart structures and simulation conditions evaluated in this study.
Keywords
Computer vision; CoppeliaSim; Educational robotics; Flowchart recognition; Hand-drawn diagrams; Mobile robotics; Optical character recognition; Programming education
Full Text:
PDFDOI: http://doi.org/10.11591/ijra.v15i4.pp883-901
Refbacks
- There are currently no refbacks.
Copyright (c) 2026 Junior Gomez-Contreras, Jharold Alonso Mayorga Villena, Andrea López Condori, Yuber Velazco-Paredes, Roxana Flores-Quispez

This work is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.
IAES International Journal of Robotics and Automation (IJRA)
ISSN 2089-4856, e-ISSN 2722-2586
This journal is published by the Institute of Advanced Engineering and Science (IAES) in collaboration with Intelektual Pustaka Media Utama (IPMU).