Inverse kinematics for a 2R planar robot based on a neural network with synthetic data through a model ensemble approach
DOI:
https://doi.org/10.24054/rcta.v2i46.3583Keywords:
2R robot, Raspberry Pi, computer vision, neural networks, roboticsAbstract
This article presents the development of a neural network-based model, trained with synthetic data, to replace the geometric inverse kinematics of a 2R planar robot. This approach aims to simplify the implementation of kinematics, reducing development time and computational resource usage. The model was created in Google Colab (Python) using TensorFlow/Keras, which facilitated its creation and training. Furthermore, the system integrates real-time image processing to recognize and follow contours, which the robot subsequently traces. A linear and vertical motion was implemented using a rack-and-pinion mechanism, enabling discontinuous tracing between contours of an image. The results, averaging three neural network models, show high accuracy in predicting the angles of the robot's first two joints, with an RMSE of 0.2293 and 0.0739 compared to the geometric inverse kinematics.
Downloads
References
J. L. Sarmiento-Ramos, “Aplicaciones de las redes neuronales y el deep learning a la ingeniería biomédica,” Revista UIS Ingenierías, vol. 19, no. 4, 2020, doi: 10.18273/revuin.v19n4-2020001.
J. F. Cortes Zarta, Y. A. Giraldo Tique, and C. F. Vergara Ramirez, “Red neuronal convolucional para la percepción espacial del robot InMoov a través de visión estereoscópica como tecnología de asistencia,” Enfoque UTE, vol. 12, no. 4, 2021, doi: 10.29019/enfoqueute.776.
Y. He et al., “Dynamic Modeling, Simulation, and Experimental Verification of a Wafer Handling SCARA Robot with Decoupling Servo Control,” IEEE Access, vol. 7, pp. 47143–47153, 2019, doi: 10.1109/ACCESS.2019.2909657.
A. Visioli and G. Legnani, “On the trajectory tracking control of industrial SCARA robot manipulators,” IEEE Transactions on Industrial Electronics, vol. 49, no. 1, 2002, doi: 10.1109/41.982266.
K. S. Mohamed Sahari, K. H. Weng, Y. W. Han, A. Anuar, M. Z. Baharuddin, and S. S. K. Mohideen, “Design and development of A 4-dof SCARA robot for educational purposes,” Jurnal Teknologi (Sciences and Engineering), vol. 54, pp. 193–215, 2011, doi: 10.11113/jt.v54.810.
A. Kotani and S. Tellex, “Teaching robots to draw,” in Proceedings - IEEE International Conference on Robotics and Automation, 2019. doi: 10.1109/ICRA.2019.8793484.
L. H. Ríos González, M. Bueno López, and S. Sánchez A., “Generación de trayectorias para un robot móvil empleando redes neuronal,” Scientia et Technica, vol. 2, pp. 94–99, 2008. [Online]. Available: https://dialnet.unirioja.es/servlet/articulo?codigo=4742539
J. G. C. Yufra Torres and K. De La Torre Muña, “Diseño de un robot móvil recolector y compactador de botellas de plástico utilizando redes neuronales en playas con arena fina,” Universidad Ricardo Palma - URP, 2020, [Online]. Available: https://hdl.handle.net/20.500.14138/3529
J. Hernández Díaz, M. Iparraguirre Monzón, C. Montenegro Castro, J. Alva Alcántara, and E. Manzano Ramos, “MODELADO NO PARAMÉTRICO DE ROBOT SCARA 3-GDL UTILIZANDO REDES NEURONALES RECURRENTES,” Revista de Investigaciones, vol. 10, no. 4, pp. 379–390, Dec. 2021, doi: 10.26788/riepg.v10i4.3502.
M. X. González, A. M. Brugiati, D. H. Cornejo, and C. I. Pinzón, “Prototipo de mano robótica controlada mediante el procesamiento de señales cerebrales utilizando redes neuronales recurrentes,” Revista de Iniciación Científica, vol. 6, 2021, doi: 10.33412/rev-ric.v6.0.3154.
A.-V. Duka, “Neural Network based Inverse Kinematics Solution for Trajectory Tracking of a Robotic Arm,” Procedia Technology, vol. 12, 2014, doi: 10.1016/j.protcy.2013.12.451.
N. Cobanoglu, E. Tatlicioglu, and E. Zergeroglu, “Neural network based repetitive learning control of robot manipulators,” in Proceedings of the American Control Conference, 2017. doi: 10.23919/ACC.2017.7963781.
A. De Luca, R. Mattone, and G. Oriolo, “Control of underactuated mechanical systems: Application to the planar 2R robot,” in Proceedings of the IEEE Conference on Decision and Control, 1996. doi: 10.1109/cdc.1996.572718.
J. J. Sprockel, A. Fandiño, W. G. Chaves, C. O. Benavides, and J. J. Diaztagle, “Ensamble de redes neuronales artificiales ponderado mediante características operativas para el pronóstico de la insuficiencia cardiaca aguda,” Revista Colombiana de Cardiología, vol. 30, no. 5, 2023, doi: 10.24875/rccar.22000065.
Raspberry Pi Ltd, “Raspberry Pi 4 Model B Datasheet,” 2024
NXP Semiconductors, “PCA9685 16-channel, 12-bit PWM Fm+ I2C-bus LED controller,” NXP Semiconductors N.V, no. April, 2015.
M. J. Delgado-Gutiérrez, D. F. Herrera-Guillén, L. M. Medina-Barragán, and J. P. Corredor Gómez, “Implementación de un sistema de procesamiento de imágenes integrado con Raspberry PI 2B para reconocimiento y recolección de fresas maduras,” Revista Politécnica, vol. 13, no. 25, 2017, doi: 10.33571/rpolitec.v13n25a6.
G. I. Viera Maza, “Procesamiento de imágenes usando OpenCV aplicado en Raspberry Pi para la clasificación del cacao,” Thesis, 2017.
G. Viera, “Procesamiento de imágenes usando OpenCV aplicado en Raspberry Pi para la clasificación del cacao,” Thesis, 2017.
C. R. Arroyo Flores and F. J. Triveño Vargas, “Modelamiento y simulación de un robot SCARA de tres grados de libertad empleando SolidWorks y Matlab/Simulink,” SciELO Analytics, vol. 10, Mar. 2022, [Online]. Available: http://www.scielo.org.bo/scielo.php?script=sci_arttext&pid=S1683-07892022000100318
S. Kucuk and Z. Bingul, “Robot Kinematics: Forward and Inverse Kinematics,” in Industrial Robotics: Theory, Modelling and Control, 2006. doi: 10.5772/5015.
Downloads
Published
How to Cite
Issue
Section
License
Copyright (c) 2025 Angie Paola Mancipe García, Nicolás David Barrera Fonseca, Jorge Eduardo Cote Ballesteros, Jhon Edisson Rodríguez Castellanos, Fabián Barrera Prieto

This work is licensed under a Creative Commons Attribution-NonCommercial 4.0 International License.