AbstractUSBSource

abstract class AbstractUSBSource(val name: String, detectors: List<USBDetector> = listOf(), val debug: Boolean = false) : MeterSourceBase

Inheritors

Constructors

Link copied to clipboard
constructor(name: String, detectors: List<USBDetector> = listOf(), debug: Boolean = false)

Properties

Link copied to clipboard
Link copied to clipboard
open override val name: String

Name of the source

Functions

Link copied to clipboard
open override fun close()
Link copied to clipboard
open override fun countMeters(): Int

Returns the number of discovered meters.

Link copied to clipboard
Link copied to clipboard
open override fun findMeters(): List<MeterConstructor>

Returns a list of meter constructors for the meters discovered by this source. The constructors have a field for querying the specifications of the meters and another method for constructing the handler for that specific meter.

Link copied to clipboard
open override fun init()

Initialize the meter source.

Link copied to clipboard
abstract fun initImpl()
Link copied to clipboard
open override fun recognizedTypes(): <Error class: unknown class>

Each type of meter has a unique id string. Returns the list of meters recognized by this source.

Link copied to clipboard
open override fun status(): String

Meter source status