7-segment LCD Display Reader icon

7-segment LCD Display Reader

1.0 for Android
3.0 | 10,000+ Installations

Luiz Miguel Ferreira Lessa

La description de 7-segment LCD Display Reader

This is an OCR reader based on OpenCV. It can be used for recognizing 7-segments digitals (one line) on LCD display, such as calculator and electric meter. Compared with normal image, the LCD screen has a lower contrast and special processing solution is quite necessary for successful recognition.
I tested it under different lighting conditions and devices. The code can be checked out from following link and you can find more details in the comments.
https://github.com/yuyang551003/OpenCV_OCR_demo
NOTE: before running my apk, please install “OpenCV Manager” first. It can be found in Google Play.
1. Overview
The OCR process has three main steps:
1) Use edge detection algorithm to get the contours in the image.
2) Locate the digitals using vertical projection information.
3) Recognize the digitals based on their structure characteristics through a traversal method.
2. Details
2.1 Edge detection
I use Canny detection algorithm to get the contour information and the result looks very good.
2.2 Vertical projection
After getting the contours information, I scan vertically to get the vertical projection of the image in the “locating box”. The box is used to help locate digital area approximately (the user only need to put the digitals in the box when scanning). The projection value is actually the number of white points in vertical direction. Obviously, the projection value between two digitals is lower. Thus, based on the information, we can locate every digital.
2.3 Traversal method
After finding the positions of the digitals, we will traverse every digital from three different directions and then recognize them based the traversal results. See the example of digital “3” in the last figure. When we traverse the digital along line a, b and c, the number of passed segments should be 3, 1 and 1 respectively. Thus the recognition code of “3” is “311”. That is, for an unknown digital, if its code is “311”, it might be digital “3”.

Informations

  • Catégories:
    Outils
  • Dernière version:
    1.0
  • Mise à jour:
    2014-07-31
  • Taille:
    408.7KB
  • Exigences:
    Android 2.3.3 or later
  • Développeur:
    Luiz Miguel Ferreira Lessa
  • ID:
    com.yuyang.opencvtest