com.openxc.measurements.IgnitionStatus Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of openxc-it Show documentation
Show all versions of openxc-it Show documentation
Instrumentation test suite for OpenXC library
The newest version!
package com.openxc.measurements;
import java.util.Locale;
import com.openxc.units.State;
/**
* The IgnitionStatus is the current status of the vehicle's ignition.
*/
public class IgnitionStatus
extends BaseMeasurement> {
public final static String ID = "ignition_status";
public enum IgnitionPosition {
OFF,
ACCESSORY,
RUN,
START
}
public IgnitionStatus(State value) {
super(value);
}
public IgnitionStatus(IgnitionPosition value) {
this(new State(value));
}
public IgnitionStatus(String value) {
this(IgnitionPosition.valueOf(value.toUpperCase(Locale.US)));
}
@Override
public String getGenericName() {
return ID;
}
}