Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MeterConfig ¶
type MeterConfig struct {
Source string
Rotate float64
lcd.LcdConfig `yaml:",inline"`
Range []struct {
Key string
Min float64
Max float64
}
BadImage string // Save bad image to this file.
Timeout int // Timeout in seconds
Sample int // Sample interval in milliseconds
History int // Size of moving average cache
MaxLevels int // Size of calibration level map
SavedLevels int // Number of levels saved
Recalibrate bool // Recalibrate
Calibration string // Calibration save file
RecalibrateInterval int // Recalibrate interval in seconds
}
type Reader ¶
type Reader struct {
// contains filtered or unexported fields
}
Reader is a meter specific reader.
func (*Reader) GoodScan ¶
func (r *Reader) GoodScan(res *lcd.DecodeResult)
The image was successfully scanned and decoded, at least within the heuristics that are possible. There is no guarantee that the decode was completely correct e.g it is possible to misread one or more digits such as mistaking a 1 for a 7. Given that this is considered a successful decode, use the levels that were sampled in this image to adjust the calibration levels being used in the decoder. This allows the decoder to dynamically adjust to changing image conditions.
func (*Reader) Recalibrate ¶
func (r *Reader) Recalibrate()
If enabled, save the calibration data and recalibrate.
Click to show internal directories.
Click to hide internal directories.