hybridgroup / artoo-sphero

Artoo adaptor for the Sphero robot.
http://artoo.io
Other
24 stars 11 forks source link

undefined method `configure_collision_detection' #3

Closed whoisjake closed 11 years ago

whoisjake commented 11 years ago

Exception: undefined method `configure_collision_detection' for #Celluloid::WebSocket::Client::Connection:0x007fb3fb89fad8

I'm assuming with celluloid in the call stack that this is the correct repo :)

$ artoo connect socat 4560 tty.Sphero-RRB
         run  socat -d -d FILE:/dev/tty.Sphero-RRB,nonblock,raw,echo=0 TCP-LISTEN:4560,fork from "."
2013/08/26 15:27:53 socat[10071] N opening character device "/dev/tty.Sphero-RRB" for reading and writing
2013/08/26 15:27:55 socat[10071] N listening on LEN=16 AF=2 0.0.0.0:4560

In another tab, I run: https://gist.github.com/whoisjake/6e93cbd45a515d000d35

and

I get this: https://gist.github.com/whoisjake/5edbace26a33fd1bafc9

whoisjake commented 11 years ago

Also:

$ gem list | grep -E "sphero|hybrid|artoo"
artoo (1.0.0)
artoo-leapmotion (0.1.2)
artoo-roomba (1.0.0)
artoo-sphero (1.0.0)
hybridgroup-celluloid-websocket-client (0.0.3)
hybridgroup-serialport (1.2.1)
sphero (1.4.1)
deadprogram commented 11 years ago

Your problem is that since you want to use 2 different connections at the same time, you need to specify which connection each device uses. Modifying your example, that would be:

connection :leapmotion, :adaptor => :leapmotion, :port => '127.0.0.1:6437'
device :leapmotion, :driver => :leapmotion, :connection => :leapmotion

connection :sphero, adaptor: :sphero, port: '4560'
device :sphero, driver: :sphero, connection: :sphero

Hope that helps! Closing this since not a bug, please reopen if you disagree.