In line with 4th industrial revolution (Industry 4.0), the mechatronics and related areas are fundamental to boost the developments of industry digitalization. However, it should not be forgotten that artificial intelligence (AI) has a great preponderance on the development of autonomous and intelligent systems incorporating the advances in mechatronics systems. It is common in different industries the need to identify and recognize products or objects for different purposes such as counts, quality control, selection of objects, among others. For these reasons, pattern recognition is increasingly being used in systems on the shop floor, usually implemented in computer vision systems with image processing in real time. This work focuses on automatic detection and text recognition in unstructured images for use on shop floor mechatronic systems with vision systems, to identify and recognize patterns in products. Unstructured images are images that does not have a pre-defined image model or is not organized in a predefined manner. Which means that there is no predefined calibration model, the system must identify and learn by itself to recognize the text patterns. The techniques of character recognition, also known as OCR (Optical Character Reader), are not new in the industry, however the use of machine learning algorithms together with the existing techniques of OCR, allow endow the systems of greater intelligence in the patterns recognition. The results achieved throughout the paper, demonstrates that it is possible to identify and recognize text in objects based on unstructured images with a high level of accuracy and that these algorithms can be used in real time applications.