Next version 'Nixie' is coming soon !

Help us to get ready with MyRobotLab version Nixie: try it !

MRL runs on a JVM and can communication to the Arduino micro-controller through a serial port.  MRL controls the Arduino through a serial protocol.  

MRL to Arduino uses a 3 byte command set

msg[0] = METHOD
msg[1] = PARAM1
msg[2] = PARAM2

The Motor service gui is being updated.  It has been designed to support multiple motor controllers. This is nice, since there can be a little complexity in attaching a motor to a motor controller.

For example an Arduino can directly drive a simple 2 bit H-bridge connected to a DC motor.  Or a motor shield can be used, which has its own motor port configuration.  Other shields and bridges might have different configuration.

Javadoc link
Example code (from branch develop):
#########################################
# AdafruitMotorShield.py
# description: motor control
# categories: motor control
# more info @: http://myrobotlab.org/service/AdafruitMotorShield
#########################################
# virtual = True
port = "COM99"
 
# virtual hardware
if ('virtual' in globals() and virtual):
    virtualArduino = runtime.start("virtualArduino", "VirtualArduino")
    virtualArduino.connect(port)
 
# The AFMotor API is supported through Jython
fruity = runtime.start("fruity","AdafruitMotorShield")
 
# connect the arduino to serial com port 3
fruity.connect(port)
 
# create a motor on port 4 of the AdaFruit board
motor1 = fruity.createDCMotor(4)
 
# move forward at 40% power
motor1.move(0.4)
 
sleep(1)
 
# move reverse at 50% power
motor1.move(-0.5)
 
sleep(1)
 
# stops motor
motor1.stop()
 
# stops motor and locks it so it can not
# be moved until it is unlocked
# motor1.stopAndLock()
 
# unlocks motor
# motor1.unlock()
 
# sets max power regardles of move command
# this will allow the motor to go at max 90%
# full power forward or reverse
# motor1.setMaxPower(0.9)

The  Adafruit Motor Shield is a service which will create a number of sub services.  It will create 4 Motor, 2 Servo, and 1 Arduino service.  This shield uses its own library, so MRLComm.ino will need to be modified.
Fortunately, the Arduino service will have the modified MRLComm.ino pre loaded in its editor.  This will need to be compiled & uploaded into the Arduino.

Here's a portion of a screencap I made while trying to sort out some driver/hardware issues.

Basically, it's a matrix of versions of the same software arranged by where they were procured from.  But first, a little explanation might be in order.

Quiet computer's USB powering the RasPi

Noisy computer's USB powering the RasPi

2012.10.04 
WooHoo ! - This is a picture of data streaming from an Arduino connected to the Raspberry Pi (running MRL  instance RasPi) connected to my PC (running MRL instance MRL76732)

Finally... Yay !

This morning I finally got this work end to end with a streaming 3D point cloud.  It was slow, but it worked !  The kinect is fast but the display is painfully slow.  If a robot was using the 3D cloud, it wouldn't need a display anyway and there is probably display acceleration software I could be using like JOGL, but its a start !