basic line-us example using php
basic line-us library/example using php
sends an array of commands to the line-us drawing machine via a Socket connection.
more or less a port of https://github.com/Line-us/Line-us-Programming/blob/master/Python/HelloWorld.py#L1
The line-us github is located at: https://github.com/Line-us/Line-us-Programming
include("../path/to/file/lineUs.php");
$lineUs->send($gcode);
echo $lineUs -> send($gcode,[$addr],[$port]);
Gcode sent as ‘String’
Default Address: line-us.local
Default port: 1337
Returns line-us bot output
echo $lineUs -> sendArray($gcode,[$addr],[$port]);
Gcode sent as ‘Array’
Default Address: line-us.local
Default port: 1337
Returns line-us bot output
echo $lineUs -> findIp([$port]);
return the first ip found with the port Default port: 1337