|
@@ -15,3 +15,35 @@
|
|
|
```
|
|
```
|
|
|
1. node index.js
|
|
1. node index.js
|
|
|
```
|
|
```
|
|
|
|
|
+
|
|
|
|
|
+## 服务启动
|
|
|
|
|
+```
|
|
|
|
|
+[Unit]
|
|
|
|
|
+Description=Car-server
|
|
|
|
|
+After=network.target
|
|
|
|
|
+
|
|
|
|
|
+[Service]
|
|
|
|
|
+Type=simple
|
|
|
|
|
+User=root
|
|
|
|
|
+ExecStart=/usr/bin/node /var/www/socket/index.js &
|
|
|
|
|
+Restart=always
|
|
|
|
|
+RestartSec=3s
|
|
|
|
|
+
|
|
|
|
|
+[Install]
|
|
|
|
|
+WantedBy=multi-user.target
|
|
|
|
|
+
|
|
|
|
|
+```
|
|
|
|
|
+
|
|
|
|
|
+## 桌面端浏览器全屏
|
|
|
|
|
+```
|
|
|
|
|
+1. nano /etc/xdg/lxsession/LXDE-pi/autostart
|
|
|
|
|
+2. add 模式
|
|
|
|
|
+ kiosk模式
|
|
|
|
|
+ @chromium-browser --kiosk /home/pi/index.html
|
|
|
|
|
+
|
|
|
|
|
+ 全屏模式
|
|
|
|
|
+ @chromium-browser --start-fullscreen www.raspberrypi.org
|
|
|
|
|
+
|
|
|
|
|
+ 最大化
|
|
|
|
|
+ @chromium-browser --start-maximized www.raspberrypi.org
|
|
|
|
|
+```
|