FxMorin / line-us

basic line-us example using php

Home Page:https://fxmorin.github.io/line-us/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

line-us

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

howto

  • clone the repository
  • download the lineUs.php file to your project
  • add the lineUs class to your project by including it include("../path/to/file/lineUs.php");
  • use the php line us class by doing $lineUs->send($gcode);
  • be sure that the php server is running on the same wifi network as the Line-Us Robot

extra

send()

echo $lineUs -> send($gcode,[$addr],[$port]);

Gcode sent as 'String'
Default Address: line-us.local
Default port: 1337
Returns line-us bot output

sendArray()

echo $lineUs -> sendArray($gcode,[$addr],[$port]);

Gcode sent as 'Array'
Default Address: line-us.local
Default port: 1337
Returns line-us bot output

findIp()

echo $lineUs -> findIp([$port]);

return the first ip found with the port Default port: 1337

About

basic line-us example using php

https://fxmorin.github.io/line-us/

License:GNU General Public License v3.0


Languages

Language:JavaScript 70.0%Language:PHP 23.4%Language:CSS 5.0%Language:Python 1.1%Language:HTML 0.3%Language:Hack 0.2%