repo for the hardware chat for the demo prototype Punk Prism Power. Connects 2 BLE beans using seperate terminal window processes to a chat client to talk to Unity.
Follow the instructions on how to get the LightBlue Bean up and running: https://punchthrough.com/bean/getting-started-osx/ </br />
Download and install node: https://nodejs.org/download/
Download and install noble: https://www.npmjs.com/package/noble
Download and install ble-bean: https://www.npmjs.com/package/ble-bean
Navigate to the folder where the scripts are kept...
- Run: node tcpserver.js (this will start the chat server) in one terminal window
- Launch a new terminal tab (apple + t) and run: findPlayers2.js (node findPlayers.js)
--> You should now have 2 terminal windows running. 1 server and one client process
--> To test server, you can also telnet into your host and port - On the unity side: Make sure you have the socketScript.cs and TCPConnection.cs running
- Run unity and click connect to server.
--> You should see a broadcast message when each client connects.
Start Chattin' !
http://www.hacksparrow.com/tcp-socket-programming-in-node-js.html
https://gist.github.com/creationix/707146
http://bildr.org/2011/04/sensing-orientation-with-the-adxl335-arduino/</br />
There is some extra TCP Garble coming through that I can't currently figure out. You'll have to write a filter on the other side.