mirror of https://github.com/rusefi/rusefi-1.git
auto-sync
This commit is contained in:
parent
95371713b9
commit
0694ad8358
|
@ -110,13 +110,16 @@ public class BinaryProtocolServer {
|
||||||
short page = dis.readShort();
|
short page = dis.readShort();
|
||||||
short offset = swap16(dis.readShort());
|
short offset = swap16(dis.readShort());
|
||||||
short count = swap16(dis.readShort());
|
short count = swap16(dis.readShort());
|
||||||
System.out.println("read " + page + "/" + offset + "/" + count);
|
if (count <= 0) {
|
||||||
BinaryProtocol bp = BinaryProtocol.instance;
|
FileLog.MAIN.logLine("Error: negative read request " + offset + "/" + count);
|
||||||
|
} else {
|
||||||
byte[] response = new byte[1 + count];
|
System.out.println("read " + page + "/" + offset + "/" + count);
|
||||||
response[0] = (byte) TS_OK.charAt(0);
|
BinaryProtocol bp = BinaryProtocol.instance;
|
||||||
System.arraycopy(bp.getController().getContent(), offset, response, 1, count);
|
byte[] response = new byte[1 + count];
|
||||||
BinaryProtocol.sendCrcPacket(response, FileLog.LOGGER, stream);
|
response[0] = (byte) TS_OK.charAt(0);
|
||||||
|
System.arraycopy(bp.getController().getContent(), offset, response, 1, count);
|
||||||
|
BinaryProtocol.sendCrcPacket(response, FileLog.LOGGER, stream);
|
||||||
|
}
|
||||||
} else if (command == BinaryProtocol.COMMAND_OUTPUTS) {
|
} else if (command == BinaryProtocol.COMMAND_OUTPUTS) {
|
||||||
|
|
||||||
byte[] response = new byte[1 + BinaryProtocol.OUTPUT_CHANNELS_SIZE];
|
byte[] response = new byte[1 + BinaryProtocol.OUTPUT_CHANNELS_SIZE];
|
||||||
|
|
|
@ -32,7 +32,7 @@ import static com.rusefi.ui.storage.PersistentConfiguration.getConfig;
|
||||||
* @see EngineSnifferPanel
|
* @see EngineSnifferPanel
|
||||||
*/
|
*/
|
||||||
public class Launcher {
|
public class Launcher {
|
||||||
public static final int CONSOLE_VERSION = 20151224;
|
public static final int CONSOLE_VERSION = 20151226;
|
||||||
public static final boolean SHOW_STIMULATOR = false;
|
public static final boolean SHOW_STIMULATOR = false;
|
||||||
private static final String TAB_INDEX = "main_tab";
|
private static final String TAB_INDEX = "main_tab";
|
||||||
protected static final String PORT_KEY = "port";
|
protected static final String PORT_KEY = "port";
|
||||||
|
|
Loading…
Reference in New Issue