changed ths script to spawn in the index.js
[VSoRC/.git] / src / routes / index.js
index 8e13ede275f2315ef15f049046ff6dd8251db56b..70758258231c1c6092ebfaeed0b650927854249a 100644 (file)
@@ -71,4 +71,17 @@ router.get('/gettopo', (req, res) => {
   });
 });
 
+router.get('/startcontroller', (req, res) => {
+  var sys = require('sys')
+  var exec = require('child_process').spawn;
+  var child;
+  chlid = spawn('python', ['-f','./../pypy.py']);
+
+    pyProg.stdout.on('data', function(data) {
+
+        console.log(data.toString());
+        res.write(data);
+        res.end('end');
+  });
+});
 module.exports = router;