Linux is asking for SocketCAN ISO-TP console connector #4123
This commit is contained in:
parent
f647f47639
commit
97361b6590
|
@ -22,7 +22,7 @@ public class SocketCANSandbox {
|
|||
/*
|
||||
for (int i = 0; i < 17; i++) {
|
||||
String signature = BinaryProtocol.getSignature(tsStream);
|
||||
System.out.println("Got " + i + " " + signature + " signature via PCAN");
|
||||
System.out.println("Got " + i + " " + signature + " signature via SocketCAN");
|
||||
if (signature == null || !signature.startsWith(Fields.PROTOCOL_SIGNATURE_PREFIX))
|
||||
throw new IllegalStateException("Unexpected S " + signature);
|
||||
}
|
||||
|
|
|
@ -1,16 +1,15 @@
|
|||
package com.rusefi.tools;
|
||||
|
||||
import com.rusefi.io.stream.PCanIoStream;
|
||||
import com.rusefi.io.serial.AbstractIoStream;
|
||||
import com.rusefi.io.tcp.BinaryProtocolProxy;
|
||||
import com.rusefi.io.tcp.TcpConnector;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
public class PCANConnectorStartup {
|
||||
public static void start() throws IOException {
|
||||
PCanIoStream tsStream = PCanIoStream.getPCANIoStream();
|
||||
public class CANConnectorStartup {
|
||||
public static void start(AbstractIoStream tsStream) throws IOException {
|
||||
if (tsStream == null)
|
||||
throw new IOException("No PCAN");
|
||||
throw new IOException("Failed to initialise connector");
|
||||
|
||||
BinaryProtocolProxy.createProxy(tsStream, TcpConnector.DEFAULT_PORT, BinaryProtocolProxy.ClientApplicationActivityListener.VOID);
|
||||
|
|
@ -17,6 +17,8 @@ import com.rusefi.io.ConnectionStateListener;
|
|||
import com.rusefi.io.ConnectionStatusLogic;
|
||||
import com.rusefi.io.IoStream;
|
||||
import com.rusefi.io.LinkManager;
|
||||
import com.rusefi.io.stream.PCanIoStream;
|
||||
import com.rusefi.io.stream.SocketCANIoStream;
|
||||
import com.rusefi.io.tcp.BinaryProtocolProxy;
|
||||
import com.rusefi.io.tcp.BinaryProtocolServer;
|
||||
import com.rusefi.io.tcp.ServerSocketReference;
|
||||
|
@ -61,7 +63,8 @@ public class ConsoleTools {
|
|||
registerTool("network_connector", strings -> NetworkConnectorStartup.start(), "Connect your rusEFI ECU to rusEFI Online");
|
||||
registerTool("network_authenticator", strings -> LocalApplicationProxy.start(), "rusEFI Online Authenticator");
|
||||
registerTool("elm327_connector", strings -> Elm327ConnectorStartup.start(), "Connect your rusEFI ECU using ELM327 CAN-bus adapter");
|
||||
registerTool("pcan_connector", strings -> PCANConnectorStartup.start(), "Connect your rusEFI ECU using ELM327 CAN-bus adapter");
|
||||
registerTool("pcan_connector", strings -> CANConnectorStartup.start(PCanIoStream.getPCANIoStream()), "Connect your rusEFI ECU using ELM327 CAN-bus adapter");
|
||||
registerTool("socketcan_connector", strings -> CANConnectorStartup.start(SocketCANIoStream.create()), "Connect your rusEFI ECU using ELM327 CAN-bus adapter");
|
||||
|
||||
registerTool("print_auth_token", args -> printAuthToken(), "Print current rusEFI Online authentication token.");
|
||||
registerTool("print_vehicle_token", args -> printVehicleToken(), "Prints vehicle access token.");
|
||||
|
|
Loading…
Reference in New Issue