I want to get data from an stand-alone DMM (multimeter) into a log file. There is no direct interface, so I need to take a still image of the reading on the LCD and convert it into a text string. For example, given the image below, I want to write "3.539" into a file, and do this repeatedly every 10 seconds or so.
Apart from getting good enough still frames from a camera, this is basically an OCR (optical character recognition) problem. I gather there is a very powerful, open-source OCR program called Tesseract which is available for Ubuntu, but I'm not sure if anyone has successfully run this on a R-Pi (?) Apparently Tesseract can read entire books, but for this application, I only need to detect digits 0-9 which are each in a fixed location in the frame, so maybe there is a simpler option.
(Note, I know there are DMMs with built-in serial / GPIB / USB ports, and I have some of them, but in this case I want more isolation between the computer and the meter than most of them provide. Also, in one meter I'd like to debug what seems to be an occasional error in the GPIB output.)
I occurs to me that one problem here which you don't have with a book, is the case where the frame is taken with the meter just changing from one reading to another, when the digits may be superimposed. So maybe I also need a "change detection" image algorithm that only presents an image to the OCR which has not changed for the past few frames.
Re: OCR for reading multimeter?
Sounds like a nice fun project. I agree Tesseract is overkill for this application, as the digits are displayed on a standard 7-segment LCD, I'd aim for recognizing the state of the individual segments. I'd make sure the relative geometry between camera and device cannot change, so that the segments are always mapped to the same pixels. Put camera and device into a black box together with a sufficient light source, so that environmental light changes have no effect on your recognition rate.
Searching for 7 segment OCR I find this open source project http://www.unix-ag.uni-kl.de/~auerswal/ssocr/ - you might want to use it.
Searching for 7 segment OCR I find this open source project http://www.unix-ag.uni-kl.de/~auerswal/ssocr/ - you might want to use it.
Re: OCR for reading multimeter?
I am googling for something although not on pi. I wanted to automate reading my RSA FOB key on my ubuntu box.I found this nice tool called ssocr .
http://www.unix-ag.uni-kl.de/~auerswal/ssocr/
You can get some idea from them. I am no way connected with ssocr but just found it nice.
http://www.unix-ag.uni-kl.de/~auerswal/ssocr/
You can get some idea from them. I am no way connected with ssocr but just found it nice.
-
- Posts: 156
- Joined: Fri Jul 06, 2012 8:51 pm
- Location: Taunton, Somerset, UK
Re: OCR for reading multimeter?
While full OCR is the ideal, as long as the camera is fixed & the image has good contrast it may be easier to simply test brightness of each segment at one central pixel.
I'm currently waiting for the PI camera to be released, but checked this method via another language on my PC. I read pixels direct off screen, but you can easily pick pixel data out of the middle of bmp files.

See http://diga.me.uk/sevenSegDecode.html
It's a thought, anyway.
I'm currently waiting for the PI camera to be released, but checked this method via another language on my PC. I read pixels direct off screen, but you can easily pick pixel data out of the middle of bmp files.

See http://diga.me.uk/sevenSegDecode.html
It's a thought, anyway.
-
- Posts: 1
- Joined: Wed Oct 01, 2014 8:03 am
Re: OCR for reading multimeter?
Have you solve this problem.
i am also looking for same solution in vb.net.
plz if you found solution then plz mail me
[MOD removed email address to stop spammers getting it. Please use a PM to contact poster]
Thanks
i am also looking for same solution in vb.net.
plz if you found solution then plz mail me
[MOD removed email address to stop spammers getting it. Please use a PM to contact poster]
Thanks
Re: OCR for reading multimeter?
I did get a program that worked to read the multimeter, see this post:
http://www.raspberrypi.org/forums/viewt ... 58#p434782
http://www.raspberrypi.org/forums/viewt ... 58#p434782
Re: OCR for reading multimeter?
Hi jbeale,
From what I can tell, have implemented the project in the link above. However, I wonder, which webcam did you use and which part of the code access to the camera?
From what I can tell, have implemented the project in the link above. However, I wonder, which webcam did you use and which part of the code access to the camera?