本文整理汇总了Java中com.github.pires.obd.commands.protocol.ObdResetCommand类的典型用法代码示例。如果您正苦于以下问题:Java ObdResetCommand类的具体用法?Java ObdResetCommand怎么用?Java ObdResetCommand使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
ObdResetCommand类属于com.github.pires.obd.commands.protocol包,在下文中一共展示了ObdResetCommand类的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: startService
import com.github.pires.obd.commands.protocol.ObdResetCommand; //导入依赖的package包/类
public void startService(final String remoteDevice) {
Log.d(TAG, "Starting " + this.getClass().getName() + " service..");
// Let's configure the connection.
Log.d(TAG, "Queing jobs for connection configuration..");
queueJob(new ObdCommandJob(new ObdResetCommand()));
queueJob(new ObdCommandJob(new EchoOffCommand()));
/*
* Will send second-time based on tests.
*
* TODO this can be done w/o having to queue jobs by just issuing
* command.run(), command.getResult() and validate the result.
*/
queueJob(new ObdCommandJob(new EchoOffCommand()));
queueJob(new ObdCommandJob(new LineFeedOffCommand()));
queueJob(new ObdCommandJob(new TimeoutCommand(62)));
// For now set protocol to AUTO
queueJob(new ObdCommandJob(new SelectProtocolCommand(ObdProtocols.AUTO)));
// Job for returning dummy data
queueJob(new ObdCommandJob(new AmbientAirTemperatureCommand()));
queueCounter = 0L;
Log.d(TAG, "Initialization jobs queued.");
isRunning = true;
}
示例2: resetObd
import com.github.pires.obd.commands.protocol.ObdResetCommand; //导入依赖的package包/类
public void resetObd() {
queueJob(new ObdResetCommand());
}