GPIO checked for Raspberry Pi 5B
This commit is contained in:
7
Html/html/public/js/socket.io.min.js
vendored
Normal file
7
Html/html/public/js/socket.io.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
@@ -24,12 +24,14 @@ public class PanTiltController {
|
|||||||
if (comports.length>0){
|
if (comports.length>0){
|
||||||
for (SerialPort port : comports){
|
for (SerialPort port : comports){
|
||||||
Logger.info("Available Serial Port : {}", port.getSystemPortName());
|
Logger.info("Available Serial Port : {}", port.getSystemPortName());
|
||||||
if (port.getSystemPortName().equals(portname)){
|
|
||||||
|
if (portname.contains(port.getSystemPortName())){
|
||||||
Logger.info("Serial Port {} found", portname);
|
Logger.info("Serial Port {} found", portname);
|
||||||
serialPort = port;
|
serialPort = port;
|
||||||
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
if (serialPort!=null){
|
if (serialPort!=null){
|
||||||
serialPort.setBaudRate(baudrate);
|
serialPort.setBaudRate(baudrate);
|
||||||
|
|||||||
@@ -409,10 +409,12 @@ public class Main {
|
|||||||
// ZOOM Related Commands
|
// ZOOM Related Commands
|
||||||
case "GET MAX ZOOM":
|
case "GET MAX ZOOM":
|
||||||
if (vapixProtocol!=null){
|
if (vapixProtocol!=null){
|
||||||
|
Blink(LedIpCamera);
|
||||||
return new WebsocketReply("GET MAX ZOOM", String.valueOf(vapixProtocol.GetPTZMaxZoom()));
|
return new WebsocketReply("GET MAX ZOOM", String.valueOf(vapixProtocol.GetPTZMaxZoom()));
|
||||||
} else return new WebsocketReply("GET MAX ZOOM", "VapixProtocol not initialized");
|
} else return new WebsocketReply("GET MAX ZOOM", "VapixProtocol not initialized");
|
||||||
case "GET ZOOM":
|
case "GET ZOOM":
|
||||||
if (vapixProtocol!=null){
|
if (vapixProtocol!=null){
|
||||||
|
Blink(LedIpCamera);
|
||||||
return new WebsocketReply("GET ZOOM", String.valueOf(vapixProtocol.GetCurrentZoomValue()));
|
return new WebsocketReply("GET ZOOM", String.valueOf(vapixProtocol.GetCurrentZoomValue()));
|
||||||
} else return new WebsocketReply("GET ZOOM", "VapixProtocol not initialized");
|
} else return new WebsocketReply("GET ZOOM", "VapixProtocol not initialized");
|
||||||
case "SET ZOOM":
|
case "SET ZOOM":
|
||||||
@@ -438,6 +440,7 @@ public class Main {
|
|||||||
case "GET RESOLUTION":
|
case "GET RESOLUTION":
|
||||||
if (vapixProtocol!=null){
|
if (vapixProtocol!=null){
|
||||||
int[] res = vapixProtocol.GetCurrentResolution(1);
|
int[] res = vapixProtocol.GetCurrentResolution(1);
|
||||||
|
Blink(LedIpCamera);
|
||||||
return new WebsocketReply("GET RESOLUTION", String.format("%dx%d", res[0], res[1]));
|
return new WebsocketReply("GET RESOLUTION", String.format("%dx%d", res[0], res[1]));
|
||||||
} else return new WebsocketReply("GET RESOLUTION", "VapixProtocol not initialized");
|
} else return new WebsocketReply("GET RESOLUTION", "VapixProtocol not initialized");
|
||||||
case "GET AUDIOFILES":
|
case "GET AUDIOFILES":
|
||||||
|
|||||||
Reference in New Issue
Block a user