To start, the follow the steps:
- Connect Augmented Ney to arduino
- Connect Arduino to Computer
- Upload Arduino code to Board
- Test Serial Port
- Close Serial Port
- Check Serial Port ID
- Open 140504InterafacingArduinoofxSimpleSerial
- Edit
serial.setup("/dev/cu.usbmodemfd121", 9600);
- Open and start server JackPilot
- Check out the port that SuperCollider is listening (57120 or 57121))
- Open REACTTheGodArticle SuperCollider standalone application
- Open 140324TheGodArticle to test OSC messages
- Run the folling code to SuperCollider
( ~arduinoData.remove; ~arduinoData = OSCresponderNode(nil, '/arduinoData', { arg time, responder, msg; //[time, responder, msg].postln; ~arduinoArray = msg.asString.split($,).postln; NetAddr("127.0.0.1", 12345).sendMsg("/Arduino/Hole1",~arduinoArray[1].asFloat.linlin (0 , 60, 0.001, 0.999)); NetAddr("127.0.0.1", 12345).sendMsg("/Arduino/Hole2",~arduinoArray[2].asFloat.linlin(0, 60, 0.001, 0.999)); NetAddr("127.0.0.1", 12345).sendMsg("/Arduino/Hole3",~arduinoArray[3].asFloat.linlin(0, 60, 0.001, 0.999)); NetAddr("127.0.0.1", 12345).sendMsg("/Arduino/Hole4",~arduinoArray[4].asFloat.linlin(30, 60, 0.001, 0.999)); NetAddr("127.0.0.1", 12345).sendMsg("/Arduino/Hole5",~arduinoArray[5].asFloat.linlin(30, 60, 0.001, 0.999)); NetAddr("127.0.0.1", 12345).sendMsg("/Arduino/Hole6",~arduinoArray[6].asFloat.linlin(0, 35, 0.001, 0.999)); NetAddr("127.0.0.1", 12345).sendMsg("/Arduino/Hole7",~arduinoArray[7].asFloat.linlin(0, 50, 0.001, 0.999)); NetAddr("127.0.0.1", 12345).sendMsg("/Arduino/Pressure",~arduinoArray[8].asFloat.linlin(37, 70, 0.001, 0.999)); }).add; )
- Open The God ArticleDebug