diff --git a/rootfs/etc/udev/rules.d/11-usb-hotplug.rules b/rootfs/etc/udev/rules.d/11-usb-hotplug.rules
index c597353..79ea19d 100644
--- a/rootfs/etc/udev/rules.d/11-usb-hotplug.rules
+++ b/rootfs/etc/udev/rules.d/11-usb-hotplug.rules
@@ -1,6 +1,7 @@
ATTRS{idVendor}=="12d1", ATTRS{idProduct}=="1f01", RUN+="/etc/udev/usb4g.sh"
ATTRS{idVendor}=="0bda", ATTRS{idProduct}=="1a2b", RUN+="/etc/udev/usbWiFi.sh"
SUBSYSTEM=="net", ATTRS{idVendor}=="12d1", ATTRS{idProduct}=="14db", KERNEL=="eth*", RUN+="/etc/udev/usbUp.sh %k"
+SUBSYSTEM=="net", KERNEL=="usb*", RUN+="/etc/udev/usbUp.sh %k"
ACTION=="add", KERNEL=="sd*", SUBSYSTEM=="block", RUN+="/link/shell/mountUsb.sh"
ACTION=="remove",KERNEL=="sd*", SUBSYSTEM=="block", RUN+="/etc/udev/autounmount.sh"
diff --git a/rootfs/link/bin/Encoder b/rootfs/link/bin/Encoder
index 4712b44..cde4911 100644
Binary files a/rootfs/link/bin/Encoder and b/rootfs/link/bin/Encoder differ
diff --git a/rootfs/link/bin/Monitor b/rootfs/link/bin/Monitor
new file mode 100644
index 0000000..492f616
Binary files /dev/null and b/rootfs/link/bin/Monitor differ
diff --git a/rootfs/link/bin/PTZ b/rootfs/link/bin/PTZ
index 5b2c423..621d75a 100644
Binary files a/rootfs/link/bin/PTZ and b/rootfs/link/bin/PTZ differ
diff --git a/rootfs/link/bin/mqtt b/rootfs/link/bin/mqtt
new file mode 100644
index 0000000..9496347
Binary files /dev/null and b/rootfs/link/bin/mqtt differ
diff --git a/rootfs/link/config/misc/remote/remfea.json b/rootfs/link/config/misc/remote/remfea.json
new file mode 100644
index 0000000..7b887e0
--- /dev/null
+++ b/rootfs/link/config/misc/remote/remfea.json
@@ -0,0 +1,314 @@
+[
+ {
+ "id": 1,
+ "nameCH": "方案 1",
+ "nameEN": "project 1",
+ "used": true,
+ "btns": [
+ {
+ "icon": "fa-power-off",
+ "code": 3944021760,
+ "tapCH": "关闭 Hdmi/Vga",
+ "tapEN": "Close Hdmi/Vga",
+ "pressCH": "开启 Hdmi/Vga",
+ "pressEN": "Open Hdmi/Vga"
+ },
+ {
+ "icon": "fa-bars",
+ "code": 3960733440,
+ "tapCH": "开启 Hdmi/Vga",
+ "tapEN": "Open Hdmi/Vga",
+ "pressCH": "关闭 Hdmi/Vga",
+ "pressEN": "Close Hdmi/Vga"
+ },
+ {
+ "icon": "fa-caret-up",
+ "code": 4228120320,
+ "tapCH": "开启全平台推流",
+ "tapEN": "Stop Platform Push",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-caret-down",
+ "code": 4244832000,
+ "tapCH": "关闭全平台推流",
+ "tapEN": "Stop Platform Push",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-caret-left",
+ "code": 4044291840,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-caret-right",
+ "code": 3843751680,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "my-ok",
+ "code": 4161273600,
+ "tapCH": "开启录制",
+ "tapEN": "Start Record",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-volume-down",
+ "code": 2807627520,
+ "tapCH": "开启 Dhcp",
+ "tapEN": "Open Dhcp",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-clone",
+ "code": 2740780800,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-volume-up",
+ "code": 4094426880,
+ "tapCH": "关闭 Dhcp",
+ "tapEN": "Close Dhcp",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-reply",
+ "code": 4261543680,
+ "tapCH": "关闭录制",
+ "tapEN": "Stop Record",
+ "pressCH": "重启机器",
+ "pressEN": "Restart"
+ },
+ {
+ "icon": "fa-home",
+ "code": 3075014400,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "恢复出厂设置",
+ "pressEN": "Factory Data Reset"
+ }
+ ]
+ },
+ {
+ "id": 2,
+ "nameCH": "方案 2",
+ "nameEN": "project 2",
+ "used": false,
+ "btns": [
+ {
+ "icon": "fa-power-off",
+ "code": 3944021760,
+ "tapCH": "开启Mix直播",
+ "tapEN": "Start Mix Live",
+ "pressCH": "关闭Mix直播",
+ "pressEN": "Stop Mix Live"
+ },
+ {
+ "icon": "fa-bars",
+ "code": 3960733440,
+ "tapCH": "关闭全平台推流",
+ "tapEN": "Stop Platform Push",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-caret-up",
+ "code": 4228120320,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-caret-down",
+ "code": 4244832000,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-caret-left",
+ "code": 4044291840,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-caret-right",
+ "code": 3843751680,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "my-ok",
+ "code": 4161273600,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-volume-down",
+ "code": 2807627520,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-clone",
+ "code": 2740780800,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-volume-up",
+ "code": 4094426880,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-reply",
+ "code": 4261543680,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-home",
+ "code": 3075014400,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ }
+ ]
+ },
+ {
+ "id": 3,
+ "nameCH": "方案 3",
+ "nameEN": "project 3",
+ "used": false,
+ "btns": [
+ {
+ "icon": "fa-power-off",
+ "code": 3944021760,
+ "tapCH": "开启Mix直播",
+ "tapEN": "Start Mix Live",
+ "pressCH": "关闭Mix直播",
+ "pressEN": "Stop Mix Live"
+ },
+ {
+ "icon": "fa-bars",
+ "code": 3960733440,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-caret-up",
+ "code": 4228120320,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-caret-down",
+ "code": 4244832000,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-caret-left",
+ "code": 4044291840,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-caret-right",
+ "code": 3843751680,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "my-ok",
+ "code": 4161273600,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-volume-down",
+ "code": 2807627520,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-clone",
+ "code": 2740780800,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-volume-up",
+ "code": 4094426880,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-reply",
+ "code": 4261543680,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-home",
+ "code": 3075014400,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ }
+ ]
+ }
+]
\ No newline at end of file
diff --git a/rootfs/link/config/misc/remote/remods.json b/rootfs/link/config/misc/remote/remods.json
new file mode 100644
index 0000000..2284959
--- /dev/null
+++ b/rootfs/link/config/misc/remote/remods.json
@@ -0,0 +1,92 @@
+{
+ "mods1":[
+ {
+ "titleCH":"录播模块",
+ "titleEN":"Broadcast",
+ "func":[
+ {
+ "ch":"开启Mix直播",
+ "en":"Start Mix Live"
+ },
+ {
+ "ch":"关闭Mix直播",
+ "en":"Stop Mix Live"
+ },
+ {
+ "ch":"开启Mix推流",
+ "en":"Start Mix Push"
+ },
+ {
+ "ch":"关闭Mix推流",
+ "en":"Stop Mix Push"
+ },
+ {
+ "ch":"开启录制",
+ "en":"Start Record"
+ },
+ {
+ "ch":"关闭录制",
+ "en":"Stop Record"
+ },
+ {
+ "ch":"开启全平台推流",
+ "en":"Stop Platform Push"
+ },
+ {
+ "ch":"关闭全平台推流",
+ "en":"Stop Platform Push"
+ }
+ ]
+ }
+ ],
+ "mods2":[
+ {
+ "titleCH":"系统模块",
+ "titleEN":"Network",
+ "func":[
+ {
+ "ch":"开启 Dhcp",
+ "en":"Open Dhcp"
+ },
+ {
+ "ch":"关闭 Dhcp",
+ "en":"Close Dhcp"
+ },
+ {
+ "ch":"重启机器",
+ "en":"Restart"
+ },
+ {
+ "ch":"恢复出厂设置",
+ "en":"Factory Data Reset"
+ }
+
+ ]
+ },
+ {
+ "titleCH":"输出模块",
+ "titleEN":"Output",
+ "func":[
+ {
+ "ch":"开启 Hdmi/Vga",
+ "en":"Open Hdmi/Vga"
+ },
+ {
+ "ch":"关闭 Hdmi/Vga",
+ "en":"Close Hdmi/Vga"
+ }
+ ]
+ },
+ {
+ "titleCH":"",
+ "titleEN":"",
+ "func":[
+ {
+ "ch":"未启用",
+ "en":"None"
+ }
+ ]
+ }
+
+ ]
+}
\ No newline at end of file
diff --git a/rootfs/link/config/misc/remote/remote.json b/rootfs/link/config/misc/remote/remote.json
new file mode 100644
index 0000000..6e1bbac
--- /dev/null
+++ b/rootfs/link/config/misc/remote/remote.json
@@ -0,0 +1,86 @@
+[
+ {
+ "btnId": 1,
+ "remoteCode": 3944021760,
+ "btnNameCN": "按键1",
+ "btnNameEN": "Button1",
+ "icon": "fa-power-off"
+ },
+ {
+ "btnId": 2,
+ "remoteCode": 3960733440,
+ "btnNameCN": "按键 2",
+ "btnNameEN": "Button 2",
+ "icon": "fa-bars"
+ },
+ {
+ "btnId": 3,
+ "remoteCode": 4228120320,
+ "btnNameCN": "按键 3",
+ "btnNameEN": "Button 3",
+ "icon": "fa-caret-up"
+ },
+ {
+ "btnId": 4,
+ "remoteCode": 4244832000,
+ "btnNameCN": "按键 4",
+ "btnNameEN": "Button 4",
+ "icon": "fa-caret-down"
+ },
+ {
+ "btnId": 5,
+ "remoteCode": 4044291840,
+ "btnNameCN": "按键 5",
+ "btnNameEN": "Button 5",
+ "icon": "fa-caret-left"
+ },
+ {
+ "btnId": 6,
+ "remoteCode": 3843751680,
+ "btnNameCN": "按键 6",
+ "btnNameEN": "Button 6",
+ "icon": "fa-caret-right"
+ },
+ {
+ "btnId": 7,
+ "remoteCode": 4161273600,
+ "btnNameCN": "按键 7",
+ "btnNameEN": "Button 7",
+ "icon": "my-ok"
+ },
+ {
+ "btnId": 8,
+ "remoteCode": 2807627520,
+ "btnNameCN": "按键 8",
+ "btnNameEN": "Button 8",
+ "icon": "fa-volume-down"
+ },
+ {
+ "btnId": 9,
+ "remoteCode": 2740780800,
+ "btnNameCN": "按键 9",
+ "btnNameEN": "Button 9",
+ "icon": "fa-clone"
+ },
+ {
+ "btnId": 10,
+ "remoteCode": 4094426880,
+ "btnNameCN": "按键 10",
+ "btnNameEN": "Button 10",
+ "icon": "fa-volume-up"
+ },
+ {
+ "btnId": 11,
+ "remoteCode": 4261543680,
+ "btnNameCN": "按键 11",
+ "btnNameEN": "Button 11",
+ "icon": "fa-reply"
+ },
+ {
+ "btnId": 12,
+ "remoteCode": 3075014400,
+ "btnNameCN": "按键 12",
+ "btnNameEN": "Button 12",
+ "icon": "fa-home"
+ }
+]
\ No newline at end of file
diff --git a/rootfs/link/config/verLogs.json b/rootfs/link/config/verLogs.json
index c5e215a..f9d614d 100644
--- a/rootfs/link/config/verLogs.json
+++ b/rootfs/link/config/verLogs.json
@@ -1,4 +1,18 @@
[
+ {
+ "version": "2.2.0 build 20230531",
+ "logs": [
+ "全平台直播新增定时开启/关闭推流功能",
+ "优化部分机型Onvif PTZ功能",
+ "优化集成通信功能",
+ "优化设备内存占用",
+ "调整首页端口状态显示逻辑",
+ "修正roi设置功能",
+ "修正开启推流后,更改系统时间导致的推流时长显示不准确的问题",
+ "修正ENC1机型按键小概率不触发问题",
+ "支持全新基于互联网的微信小程序,不在依赖局域网,真正做到的随时随地查看"
+ ]
+ },
{
"version": "2.1.0 build 20230426",
"logs": [
diff --git a/rootfs/link/config/version.json b/rootfs/link/config/version.json
index 3241538..1baf278 100644
--- a/rootfs/link/config/version.json
+++ b/rootfs/link/config/version.json
@@ -1,5 +1,5 @@
{
"app": "2.0.0 build 20220512_869",
"sdk": "2.0.0 build 20220518_20716",
- "sys": "2.1.0 build 20230426"
+ "sys": "2.2.0 build 20230531"
}
diff --git a/rootfs/link/fac/EX2/bin/Monitor b/rootfs/link/fac/EX2/bin/Monitor
new file mode 100644
index 0000000..492f616
Binary files /dev/null and b/rootfs/link/fac/EX2/bin/Monitor differ
diff --git a/rootfs/link/fac/EX2/config/.hardware.json.swo b/rootfs/link/fac/EX2/config/.hardware.json.swo
new file mode 100644
index 0000000..c041816
Binary files /dev/null and b/rootfs/link/fac/EX2/config/.hardware.json.swo differ
diff --git a/rootfs/link/fac/EX2/config/.hardware.json.swp b/rootfs/link/fac/EX2/config/.hardware.json.swp
new file mode 100644
index 0000000..33eabdd
Binary files /dev/null and b/rootfs/link/fac/EX2/config/.hardware.json.swp differ
diff --git a/rootfs/link/fac/EX2/config/gpio.json b/rootfs/link/fac/EX2/config/gpio.json
new file mode 100644
index 0000000..ce800d9
--- /dev/null
+++ b/rootfs/link/fac/EX2/config/gpio.json
@@ -0,0 +1,4 @@
+[
+ {"name":"GPIO0_0","addr":"12150000","offset": 0,"irq":89},
+ {"name":"GPIO0_1","addr":"12150000","offset": 1,"irq":89}
+]
diff --git a/rootfs/link/fac/EX2/gpio.sh b/rootfs/link/fac/EX2/gpio.sh
new file mode 100644
index 0000000..b238c0a
--- /dev/null
+++ b/rootfs/link/fac/EX2/gpio.sh
@@ -0,0 +1,63 @@
+. /link/shell/util/hardware.sh
+count=0
+type=`jget gpio.type`
+himmGPIO()
+{
+ gpioName=`jget gpio.name`
+ gpioAddr=`jget gpio.addr`
+ eval "`jget gpio.mux` > /dev/null"
+ eval "`jget gpio.dir` > /dev/null"
+
+ echo "Init $gpioName($gpioAddr) done."
+
+ while [ true ]
+ do
+ ret=`himd.l $gpioAddr 1 | awk 'NR==4{print $2}'`
+ if [ "$ret" == "00000000" ]; then
+ count=$(($count+1))
+ echo "keyDown $count"
+ if [ "$count" == "5" ]; then
+ echo "reset default config"
+ /link/shell/reset.sh
+ fi
+ else
+ count=0
+ fi
+ sleep 1
+ done
+}
+
+sysfsGPIO()
+{
+ gpioName=`jget gpio.name`
+ gpioIndex=`jget gpio.index`
+ eval "`jget gpio.mux` > /dev/null"
+ if [ ! -d "/sys/class/gpio/gpio$gpioIndex" ];then
+ echo $gpioIndex > /sys/class/gpio/export
+ fi
+ echo "in" > /sys/class/gpio/gpio$gpioIndex/direction
+
+ echo "Init $gpioName($gpioIndex) done."
+
+ while [ true ]
+ do
+ ret=`cat /sys/class/gpio/gpio$gpioIndex/value`
+ if [ "$ret" == "0" ]; then
+ count=$(($count+1))
+ echo "keyDown $count"
+ if [ "$count" == "5" ]; then
+ echo "reset default config"
+ /link/shell/reset.sh
+ fi
+ else
+ count=0
+ fi
+ sleep 1
+ done
+}
+
+if [ "$type" == "himm" ]; then
+ himmGPIO
+elif [ "$type" == "sysfs" ]; then
+ sysfsGPIO
+fi
diff --git a/rootfs/link/fac/EX2/shell/monitor.sh b/rootfs/link/fac/EX2/shell/monitor.sh
new file mode 100644
index 0000000..1d33a08
--- /dev/null
+++ b/rootfs/link/fac/EX2/shell/monitor.sh
@@ -0,0 +1,5 @@
+while [ true ]
+do
+/link/bin/Monitor
+sleep 1
+done
diff --git a/rootfs/link/fac/V2/bin/Monitor b/rootfs/link/fac/V2/bin/Monitor
new file mode 100644
index 0000000..492f616
Binary files /dev/null and b/rootfs/link/fac/V2/bin/Monitor differ
diff --git a/rootfs/link/fac/V2/config/misc/remote/remfea.json b/rootfs/link/fac/V2/config/misc/remote/remfea.json
new file mode 100644
index 0000000..7b887e0
--- /dev/null
+++ b/rootfs/link/fac/V2/config/misc/remote/remfea.json
@@ -0,0 +1,314 @@
+[
+ {
+ "id": 1,
+ "nameCH": "方案 1",
+ "nameEN": "project 1",
+ "used": true,
+ "btns": [
+ {
+ "icon": "fa-power-off",
+ "code": 3944021760,
+ "tapCH": "关闭 Hdmi/Vga",
+ "tapEN": "Close Hdmi/Vga",
+ "pressCH": "开启 Hdmi/Vga",
+ "pressEN": "Open Hdmi/Vga"
+ },
+ {
+ "icon": "fa-bars",
+ "code": 3960733440,
+ "tapCH": "开启 Hdmi/Vga",
+ "tapEN": "Open Hdmi/Vga",
+ "pressCH": "关闭 Hdmi/Vga",
+ "pressEN": "Close Hdmi/Vga"
+ },
+ {
+ "icon": "fa-caret-up",
+ "code": 4228120320,
+ "tapCH": "开启全平台推流",
+ "tapEN": "Stop Platform Push",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-caret-down",
+ "code": 4244832000,
+ "tapCH": "关闭全平台推流",
+ "tapEN": "Stop Platform Push",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-caret-left",
+ "code": 4044291840,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-caret-right",
+ "code": 3843751680,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "my-ok",
+ "code": 4161273600,
+ "tapCH": "开启录制",
+ "tapEN": "Start Record",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-volume-down",
+ "code": 2807627520,
+ "tapCH": "开启 Dhcp",
+ "tapEN": "Open Dhcp",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-clone",
+ "code": 2740780800,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-volume-up",
+ "code": 4094426880,
+ "tapCH": "关闭 Dhcp",
+ "tapEN": "Close Dhcp",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-reply",
+ "code": 4261543680,
+ "tapCH": "关闭录制",
+ "tapEN": "Stop Record",
+ "pressCH": "重启机器",
+ "pressEN": "Restart"
+ },
+ {
+ "icon": "fa-home",
+ "code": 3075014400,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "恢复出厂设置",
+ "pressEN": "Factory Data Reset"
+ }
+ ]
+ },
+ {
+ "id": 2,
+ "nameCH": "方案 2",
+ "nameEN": "project 2",
+ "used": false,
+ "btns": [
+ {
+ "icon": "fa-power-off",
+ "code": 3944021760,
+ "tapCH": "开启Mix直播",
+ "tapEN": "Start Mix Live",
+ "pressCH": "关闭Mix直播",
+ "pressEN": "Stop Mix Live"
+ },
+ {
+ "icon": "fa-bars",
+ "code": 3960733440,
+ "tapCH": "关闭全平台推流",
+ "tapEN": "Stop Platform Push",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-caret-up",
+ "code": 4228120320,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-caret-down",
+ "code": 4244832000,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-caret-left",
+ "code": 4044291840,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-caret-right",
+ "code": 3843751680,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "my-ok",
+ "code": 4161273600,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-volume-down",
+ "code": 2807627520,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-clone",
+ "code": 2740780800,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-volume-up",
+ "code": 4094426880,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-reply",
+ "code": 4261543680,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-home",
+ "code": 3075014400,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ }
+ ]
+ },
+ {
+ "id": 3,
+ "nameCH": "方案 3",
+ "nameEN": "project 3",
+ "used": false,
+ "btns": [
+ {
+ "icon": "fa-power-off",
+ "code": 3944021760,
+ "tapCH": "开启Mix直播",
+ "tapEN": "Start Mix Live",
+ "pressCH": "关闭Mix直播",
+ "pressEN": "Stop Mix Live"
+ },
+ {
+ "icon": "fa-bars",
+ "code": 3960733440,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-caret-up",
+ "code": 4228120320,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-caret-down",
+ "code": 4244832000,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-caret-left",
+ "code": 4044291840,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-caret-right",
+ "code": 3843751680,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "my-ok",
+ "code": 4161273600,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-volume-down",
+ "code": 2807627520,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-clone",
+ "code": 2740780800,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-volume-up",
+ "code": 4094426880,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-reply",
+ "code": 4261543680,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ },
+ {
+ "icon": "fa-home",
+ "code": 3075014400,
+ "tapCH": "未启用",
+ "tapEN": "None",
+ "pressCH": "未启用",
+ "pressEN": "None"
+ }
+ ]
+ }
+]
\ No newline at end of file
diff --git a/rootfs/link/fac/V2/config/misc/remote/remods.json b/rootfs/link/fac/V2/config/misc/remote/remods.json
new file mode 100644
index 0000000..2284959
--- /dev/null
+++ b/rootfs/link/fac/V2/config/misc/remote/remods.json
@@ -0,0 +1,92 @@
+{
+ "mods1":[
+ {
+ "titleCH":"录播模块",
+ "titleEN":"Broadcast",
+ "func":[
+ {
+ "ch":"开启Mix直播",
+ "en":"Start Mix Live"
+ },
+ {
+ "ch":"关闭Mix直播",
+ "en":"Stop Mix Live"
+ },
+ {
+ "ch":"开启Mix推流",
+ "en":"Start Mix Push"
+ },
+ {
+ "ch":"关闭Mix推流",
+ "en":"Stop Mix Push"
+ },
+ {
+ "ch":"开启录制",
+ "en":"Start Record"
+ },
+ {
+ "ch":"关闭录制",
+ "en":"Stop Record"
+ },
+ {
+ "ch":"开启全平台推流",
+ "en":"Stop Platform Push"
+ },
+ {
+ "ch":"关闭全平台推流",
+ "en":"Stop Platform Push"
+ }
+ ]
+ }
+ ],
+ "mods2":[
+ {
+ "titleCH":"系统模块",
+ "titleEN":"Network",
+ "func":[
+ {
+ "ch":"开启 Dhcp",
+ "en":"Open Dhcp"
+ },
+ {
+ "ch":"关闭 Dhcp",
+ "en":"Close Dhcp"
+ },
+ {
+ "ch":"重启机器",
+ "en":"Restart"
+ },
+ {
+ "ch":"恢复出厂设置",
+ "en":"Factory Data Reset"
+ }
+
+ ]
+ },
+ {
+ "titleCH":"输出模块",
+ "titleEN":"Output",
+ "func":[
+ {
+ "ch":"开启 Hdmi/Vga",
+ "en":"Open Hdmi/Vga"
+ },
+ {
+ "ch":"关闭 Hdmi/Vga",
+ "en":"Close Hdmi/Vga"
+ }
+ ]
+ },
+ {
+ "titleCH":"",
+ "titleEN":"",
+ "func":[
+ {
+ "ch":"未启用",
+ "en":"None"
+ }
+ ]
+ }
+
+ ]
+}
\ No newline at end of file
diff --git a/rootfs/link/fac/V2/config/misc/remote/remote.json b/rootfs/link/fac/V2/config/misc/remote/remote.json
new file mode 100644
index 0000000..6e1bbac
--- /dev/null
+++ b/rootfs/link/fac/V2/config/misc/remote/remote.json
@@ -0,0 +1,86 @@
+[
+ {
+ "btnId": 1,
+ "remoteCode": 3944021760,
+ "btnNameCN": "按键1",
+ "btnNameEN": "Button1",
+ "icon": "fa-power-off"
+ },
+ {
+ "btnId": 2,
+ "remoteCode": 3960733440,
+ "btnNameCN": "按键 2",
+ "btnNameEN": "Button 2",
+ "icon": "fa-bars"
+ },
+ {
+ "btnId": 3,
+ "remoteCode": 4228120320,
+ "btnNameCN": "按键 3",
+ "btnNameEN": "Button 3",
+ "icon": "fa-caret-up"
+ },
+ {
+ "btnId": 4,
+ "remoteCode": 4244832000,
+ "btnNameCN": "按键 4",
+ "btnNameEN": "Button 4",
+ "icon": "fa-caret-down"
+ },
+ {
+ "btnId": 5,
+ "remoteCode": 4044291840,
+ "btnNameCN": "按键 5",
+ "btnNameEN": "Button 5",
+ "icon": "fa-caret-left"
+ },
+ {
+ "btnId": 6,
+ "remoteCode": 3843751680,
+ "btnNameCN": "按键 6",
+ "btnNameEN": "Button 6",
+ "icon": "fa-caret-right"
+ },
+ {
+ "btnId": 7,
+ "remoteCode": 4161273600,
+ "btnNameCN": "按键 7",
+ "btnNameEN": "Button 7",
+ "icon": "my-ok"
+ },
+ {
+ "btnId": 8,
+ "remoteCode": 2807627520,
+ "btnNameCN": "按键 8",
+ "btnNameEN": "Button 8",
+ "icon": "fa-volume-down"
+ },
+ {
+ "btnId": 9,
+ "remoteCode": 2740780800,
+ "btnNameCN": "按键 9",
+ "btnNameEN": "Button 9",
+ "icon": "fa-clone"
+ },
+ {
+ "btnId": 10,
+ "remoteCode": 4094426880,
+ "btnNameCN": "按键 10",
+ "btnNameEN": "Button 10",
+ "icon": "fa-volume-up"
+ },
+ {
+ "btnId": 11,
+ "remoteCode": 4261543680,
+ "btnNameCN": "按键 11",
+ "btnNameEN": "Button 11",
+ "icon": "fa-reply"
+ },
+ {
+ "btnId": 12,
+ "remoteCode": 3075014400,
+ "btnNameCN": "按键 12",
+ "btnNameEN": "Button 12",
+ "icon": "fa-home"
+ }
+]
\ No newline at end of file
diff --git a/rootfs/link/fac/V2/shell/monitor.sh b/rootfs/link/fac/V2/shell/monitor.sh
new file mode 100644
index 0000000..1d33a08
--- /dev/null
+++ b/rootfs/link/fac/V2/shell/monitor.sh
@@ -0,0 +1,5 @@
+while [ true ]
+do
+/link/bin/Monitor
+sleep 1
+done
diff --git a/rootfs/link/shell/.fusb.sh.swp b/rootfs/link/shell/.fusb.sh.swp
new file mode 100644
index 0000000..cbb5665
Binary files /dev/null and b/rootfs/link/shell/.fusb.sh.swp differ
diff --git a/rootfs/link/shell/app.sh b/rootfs/link/shell/app.sh
index 981d6bd..58ac629 100644
--- a/rootfs/link/shell/app.sh
+++ b/rootfs/link/shell/app.sh
@@ -9,3 +9,10 @@ if [ -f /link/shell/ptz.sh ] ;then
/link/shell/ptz.sh &
fi
+if [ -f /link/bin/mqtt ] ;then
+/link/bin/mqtt &
+fi
+
+if [ -f /link/bin/Monitor ];then
+/link/shell/monitor.sh &
+fi
diff --git a/rootfs/link/shell/enc.sh b/rootfs/link/shell/enc.sh
index a2b0a85..af8e399 100644
--- a/rootfs/link/shell/enc.sh
+++ b/rootfs/link/shell/enc.sh
@@ -2,7 +2,7 @@
/link/shell/trans.sh &
while [ true ]
do
-pkill OLED
+pkill Monitor
/link/bin/Encoder
sleep 2
done
diff --git a/rootfs/link/shell/fusb.sh b/rootfs/link/shell/fusb.sh
index b8d7747..2d0deda 100644
--- a/rootfs/link/shell/fusb.sh
+++ b/rootfs/link/shell/fusb.sh
@@ -16,9 +16,15 @@ umount_usb(){
umount_usb
if [ $1 == "ext4" ];then
- echo -e "\ny" | mkfs.ext4 -T largefile /dev/sda1
- sleep 1
- mount -t ext4 /dev/sda1 /root/usb
+ if [ -b /dev/sda1 ];then
+ echo -e "\ny" | mkfs.ext4 -T largefile /dev/sda1
+ sleep 1
+ mount -t ext4 /dev/sda1 /root/usb
+ elif [ -b /dev/mmcblk0p6 ];then
+ echo -e "\ny" | mkfs.ext4 -T largefile /dev/mmcblk0p6
+ sleep 1
+ mount -o rw,sync,barrier=0 /dev/mmcblk0p6 /root/usb
+ fi
else
mkfs.vfat -F 32 /dev/sda1
sleep 1
diff --git a/rootfs/link/shell/init/filesystem.sh b/rootfs/link/shell/init/filesystem.sh
index 2b0733a..9255c0c 100644
--- a/rootfs/link/shell/init/filesystem.sh
+++ b/rootfs/link/shell/init/filesystem.sh
@@ -11,6 +11,17 @@ if [ -b /dev/mmcblk0p5 ]; then
fi
if [ -b /dev/mmcblk0p6 ]; then
-/bin/mount -o rw,sync,barrier=0 /dev/mmcblk0p6 /root/usb
+ /bin/mount -o rw,sync,barrier=0 /dev/mmcblk0p6 /root/usb
+ mnt=`df -h | grep /dev/mmcblk0p6 | wc -l`
+ if [ "$mnt" == "1" ] && [ ! -d /root/usb/lost+found ];then
+ umount -f /root/usb/
+ mnt=`df -h | grep /dev/mmcblk0p6 | wc -l`
+ if [ "$mnt" == "0" ];then
+ echo -e "\ny" | mkfs.ext4 -T largefile /dev/mmcblk0p6
+ if [ ! -b /dev/sda1 ];then
+ /bin/mount -o rw,sync,barrier=0 /dev/mmcblk0p6 /root/usb
+ fi
+ fi
+ fi
fi
diff --git a/rootfs/link/shell/init/service.sh b/rootfs/link/shell/init/service.sh
index ffd8014..95f2cb0 100644
--- a/rootfs/link/shell/init/service.sh
+++ b/rootfs/link/shell/init/service.sh
@@ -22,6 +22,13 @@ if [ `jget nginx` == "true" ]; then
fi
if [ `jget crond` == "true" ]; then
+if [ ! -f /var/spool/cron/crontabs/root ];then
+ touch /var/spool/cron/crontabs/root
+ echo "" >> /var/spool/cron/crontabs/root
+ echo "" >> /var/spool/cron/crontabs/root
+ echo "" >> /var/spool/cron/crontabs/root
+fi
+chown -R root:root /var/spool
/usr/sbin/crond -d 8
fi
diff --git a/rootfs/link/shell/monitor.sh b/rootfs/link/shell/monitor.sh
new file mode 100644
index 0000000..1d33a08
--- /dev/null
+++ b/rootfs/link/shell/monitor.sh
@@ -0,0 +1,5 @@
+while [ true ]
+do
+/link/bin/Monitor
+sleep 1
+done
diff --git a/rootfs/link/shell/update.sh b/rootfs/link/shell/update.sh
index 9f28ffa..cb65493 100644
--- a/rootfs/link/shell/update.sh
+++ b/rootfs/link/shell/update.sh
@@ -1,6 +1,6 @@
if [ ! -z "$(ls -A /link/update)" ]; then
mv /link/update/* /link/update/update.tar
- tar -xf /link/update/update.tar -C /
+ tar -xof /link/update/update.tar -C /
sleep 1
if [ -c "/dev/mtd1" ]; then
diff --git a/rootfs/link/web/dashboard.php b/rootfs/link/web/dashboard.php
index 399429b..e9cc524 100644
--- a/rootfs/link/web/dashboard.php
+++ b/rootfs/link/web/dashboard.php
@@ -303,9 +303,6 @@ include("head.php");
}
-
-
-
function update() {
rpc( "enc.getSysState", null, function ( data ) {
try {
@@ -356,10 +353,6 @@ include("head.php");
}
- for( var i = hdmi.length; i < $( ".hdmi" ).length; i++ ){
- $( ".hdmi" ).eq( i ).hide();
- }
-
for ( var i = 0; i < sdi.length; i++ ) {
if ( sdi[ i ].avalible ) {
$( ".sdi" ).eq( i ).removeClass( "disable" );
@@ -371,11 +364,6 @@ include("head.php");
}
}
-
- for( var i = sdi.length; i < $( ".sdi" ).length; i++ ){
- $( ".sdi" ).eq( i ).hide();
- }
-
} );
setTimeout( update, 3000 );
diff --git a/rootfs/link/web/func.php b/rootfs/link/web/func.php
index 25553ff..e0985ce 100644
--- a/rootfs/link/web/func.php
+++ b/rootfs/link/web/func.php
@@ -116,19 +116,65 @@ function setCron() {
if ( isset( $_POST[ 'day' ] ) && isset( $_POST[ 'time' ] ) ) {
if ( $_POST[ 'day' ] == "x" )
{
- exec( 'echo "" | crontab -u root -' );
+ exec("sed -i '1s/.*/ /' /var/spool/cron/crontabs/root");
+ exec("cp -a /var/spool/cron/crontabs/root /link/config/auto/root.cron");
}
else {
- exec( 'echo "0 ' . $_POST[ 'time' ] . ' * * ' . $_POST[ 'day' ] . ' /link/shell/reboot.sh" | crontab -u root -' );
+ $cron = '0 ' . $_POST[ 'time' ] . ' * * ' . $_POST[ 'day' ];
+ exec("sed -i '1s/.*/".$cron." \/link\/shell\/reboot.sh/' /var/spool/cron/crontabs/root");
exec("cp -a /var/spool/cron/crontabs/root /link/config/auto/root.cron");
}
$result->result = "OK";
} else {
- $result->result = shell_exec( 'crontab -u root -l' );
+ $result->result = shell_exec( 'crontab -u root -l | grep /link/shell/reboot.sh' );
}
}
+function setPushCron() {
+ global $result;
+ $start = $_POST['start'];
+ if ( isset( $start[ 'day' ] ) && isset( $start[ 'time' ] ) ) {
+ if ( $start[ 'day' ] == "x" )
+ {
+ exec("sed -i '2s/.*/ /' /var/spool/cron/crontabs/root");
+ exec("cp -a /var/spool/cron/crontabs/root /link/config/auto/root.cron");
+ }
+ else {
+ $tm = explode(":", $start[ 'time' ]);
+ $cron = intval($tm[1]).' ' . intval($tm[0]) . ' * * ' . $start[ 'day' ];
+ exec("sed -i '2s/.*/".$cron." \/usr\/php\/bin\/php \/link\/web\/link\/timer\/autoPush.php start/' /var/spool/cron/crontabs/root");
+ exec("cp -a /var/spool/cron/crontabs/root /link/config/auto/root.cron");
+ }
+ }
+
+ $stop = $_POST['stop'];
+ if ( isset( $stop[ 'day' ] ) && isset( $stop[ 'time' ] ) ) {
+ if ( $stop[ 'day' ] == "x" )
+ {
+ exec("sed -i '3s/.*/ /' /var/spool/cron/crontabs/root");
+ exec("cp -a /var/spool/cron/crontabs/root /link/config/auto/root.cron");
+ }
+ else {
+ $tm = explode(":", $stop[ 'time' ]);
+ $cron = intval($tm[1]).' ' . intval($tm[0]) . ' * * ' . $stop[ 'day' ];
+ exec("sed -i '3s/.*/".$cron." \/usr\/php\/bin\/php \/link\/web\/link\/timer\/autoPush.php stop/' /var/spool/cron/crontabs/root");
+ exec("cp -a /var/spool/cron/crontabs/root /link/config/auto/root.cron");
+ }
+ }
+ $result->result = "OK";
+}
+
+function getPushCron() {
+ global $result;
+ exec( "crontab -u root -l | grep '/link/web/link/timer/autoPush.php start'",$output1);
+ exec( "crontab -u root -l | grep '/link/web/link/timer/autoPush.php stop'",$output2);
+ $result->result = [
+ 'start'=>$output1[0],
+ 'stop'=>$output2[0]
+ ];
+}
+
function startHelp() {
global $result;
global $hardware;
diff --git a/rootfs/link/web/head.php b/rootfs/link/web/head.php
index 6ea9315..5050545 100644
--- a/rootfs/link/web/head.php
+++ b/rootfs/link/web/head.php
@@ -84,14 +84,22 @@ include("headhead.php");
'); + } + + aHTML.push(' |