File tree Expand file tree Collapse file tree 3 files changed +14
-42
lines changed Expand file tree Collapse file tree 3 files changed +14
-42
lines changed Original file line number Diff line number Diff line change @@ -35,7 +35,7 @@ var linux = (function () {
3535
3636 if ( DEBUG ) console . log ( "Image resolution: " + res ) ;
3737
38- $ . get ( "assets/python/server/run_server .php" ,
38+ $ . get ( "assets/python/server/starter .php" ,
3939 { resolution : res } ,
4040 function ( data ) {
4141 if ( DEBUG ) console . log ( "AJAX request sent" ) ;
@@ -48,16 +48,19 @@ var linux = (function () {
4848 * 2 - mjpeg streamer process pid
4949 */
5050
51- var numberOfClients = data [ 0 ] ;
51+ // var numberOfClients = data[0];
52+ var numberOfClients = 0 ;
5253 if ( DEBUG ) console . log ( "numberOfClients: " + numberOfClients ) ;
5354
5455 /*
5556 * connect only if there is no more clients connected
5657 * TODO: should be numberOfClients == 0. Does not work properly
5758 */
5859 if ( numberOfClients >= 0 || document . domain . includes ( "localhost" ) ) {
59- serverProcessPID = data [ 1 ] ;
60- mjpegStreamPID = data [ 2 ] ;
60+ serverProcessPID = - 1 ;
61+ mjpegStreamPID = - 1 ;
62+ // serverProcessPID = data[1];
63+ // mjpegStreamPID = data[2];
6164 // if the returned value is numeric (pid of the process) continue with camera
6265 if ( $ . isNumeric ( serverProcessPID ) || $ . isNumeric ( mjpegStreamPID ) ) {
6366 isCameraAvailable = true ;
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 11#! /bin/sh
2+
3+ # restart STM
4+ echo " Restarting STM..."
5+ sudo gpio mode 1 out
6+ sudo gpio write 1 0
7+ sleep 0.25
8+ sudo gpio write 1 1
29exec " sudo" " /usr/bin/python3" " /home/pi/Turtle-Rover-Mission-Control/assets/python/server/server.new.py"
You can’t perform that action at this time.
0 commit comments