Post by yamada on Jan 14, 2019 1:29:57 GMT
Videos you are reading
In this time, I tried to read the numbers displayed on the screen of the device and export them to CSV.
For details, collect the numerical value displayed on the movie of about 3 hours at intervals of 10 seconds.
First of all, take three hours video.
Next, extract numbers from 0 to 9 from this movie and make it a file.
Like this
For details, collect the numerical value displayed on the movie of about 3 hours at intervals of 10 seconds.
First of all, take three hours video.
Next, extract numbers from 0 to 9 from this movie and make it a file.
Like this

Save numerical image in grayscale
By using AutoMainPNG software you can easily create such an image.
By using AutoMainPNG software you can easily create such an image.

Next, the video screen is here

I tried doing the import with the iPhone Autotouch! I can not recognize the numerical value at all.
Abandoning the iPhone ...
Next, I tried it with AnkuLua of Android. This is wonderful!
I will digitize every 10 seconds
The program looks something like this
Abandoning the iPhone ...
Next, I tried it with AnkuLua of Android. This is wonderful!
I will digitize every 10 seconds
The program looks something like this
-----------------------------------
localPath = scriptPath()
local e = Region(444,1281,500,154)
local r = Region(444,986,500,150)
doloopB = true
-- Main Loop
Settings:set("MinSimilarity", 0.9)
ssend = os.time()-11
left = Region(650, (1980 - 620) / 2 , 500 , 120)
left:highlight("瞬時電力 : 0\n予測電力 : 0")
while doloopB do
if os.time() - ssend >= 10 then
ssend = os.time()
local p = numberOCR(r,"power")
local q = numberOCR(e,"power")
left:highlightOff()
left:highlight("瞬時電力 : "..(p/10).."\n予測電力 : "..(q/10))
f=io.open(localPath.."/IDCH.csv","a+");
f:write((p/10)..","..(q/10).."\n");
f:close();
end
end
-----------------------------------Briefly explaining
local r = Region (467, 988, 469, 150)
To capture the instantaneous power of 20.7 which is the recognition range of the numerical value, we set the white frame to the range.
This range setting is easy to find with AutoMainPNG findoColor
local r = Region (467, 988, 469, 150)
To capture the instantaneous power of 20.7 which is the recognition range of the numerical value, we set the white frame to the range.
This range setting is easy to find with AutoMainPNG findoColor

Numbers are recognized using OCR function exclusively for numbers.
local p = number OCR (r, "power")
local p = number OCR (r, "power")
The application of AutoMainPNG is English-compatible.