{{onText}}
 
 
 
 
 
 
 
 
Security
Home
    

MrlComm.ino is a catch all phrase for the Arduino sketch that runs as part of MyRobotLab.
It is bundled with each build of myrobotlab.
You can locate the MrlComm.ino in resource/Arduino/MrlComm/MrlComm.ino .
Normally you would copy &paste the MRLComm.ino into the arduino IDE for upload to
the Arduino board.

Serial service is a way to send and receive serial data into and out of MRL

MORE INFO SEE PYTHON SCRIPT
          
The Servo service is used to control hobby servos through a Servo Controller. This could be a Raspberry pi, micro-controller such as an Arduino, or other I2C servo controller.
The Servo service allows control of position, speed, and limits of the servo actuator.
Would you like to use real or virtual hardware ?


A servo must be wired with its own power supply.
Its not recommended to use the 5v power supply from the Arduino.
You can do this with a 4 battery pack which will produce 6 volts for the servo.

For the controller to communicate with MyRobotLab, it is necessary to upload a script on the controller.
You can follow the quick arduino tutorial .

JMonkey simulation service is used to do a 3d simulation of the servo using the same Servo service for control.
    

The Servo needs a controller in order to operate.
In this tutorial MRL has already setup a controller called arduino. Define your board type and choose the COM port according to your board. Open Windows device manager/port COM to know which COM port and rate to use.
For Linux and Mac arduino.connect("/dev/ttyUSB0").
Then press "Connect"

The Servo needs a virtual controller in order to operate.
In this tutorial MRL has already setup a controller called arduino.
Select a port or add COM3 and click connect.

    

In the Control Tab, select the arduino controller in the dropdown menu.
Select the correct signal pin the servo is connected to and click "attach". Clicking "Enable" will energize the servo. Invert button allows you to invert the direction of the servo. Clicking "AutoDisable" automatically stops energizing the servo after a given amount of seconds.
Now, you should be able to control the servo with the slider bar in Basic Tab. In this demo, "AutoDisable" is set by default to prevent burning the servo. But it automatically Enables the servo if you move the slider or send a Python "moveTo()" in a script.

In the Control Tab, select the arduino controller in the dropdown menu.
Select the correct signal pin the servo is connected to and click "attach". Clicking "Enable" will energize the servo. Invert button allows you to invert the direction of the servo. Clicking "AutoDisable" automatically stops energizing the servo after a given amount of seconds.
Now, you should be able to control the servo with the slider bar in Basic Tab. In this demo, "AutoDisable" is set by default to prevent burning the servo. But it automatically Enables the servo if you move the slider or send a Python "moveTo()" in a script.

    

By clicking the Limits button, you can set the limits of your servo.
There is two types of limits, the input and the output.
Input limits are the max and min values you expect to measure, after any scaling. Output limits are the min and max angle that the microcontroller will tell the servo to move to.
Moving the slider to a position and clicking on MIN or MAX will set the limits.
Generally we modify only the Output mapping.
The REST position is where the servo will be set when initialized.
You can save your configuration by selecting Servo drop down menu
and click "save service config".

    

These are the main functions a servo can do:

servo.attach (controller, pin, pos, velocity): Initial servo device attachement to the microcontroller
servo.detach (controller): detach the servo from the microcontroller
servo.enable (): will turn the servo motor on
servo.disable (): will turn the servo motor off
servo.moveTo (pos): ask the servo to move to a position
servo.moveToBlocking (pos): ask the servo to move to a position and wait the position to be reached
servo.sync (servo02): will sync servo02 with servo01, if you create a second servo
servo.map (inputMin, inputMax, outputMin, outputMax): default to (0,180, 0, 180). Allow to map a range to a valid output range that can be understand by the servo. The outputMin and outputMax must have value between 0 and 180.
servo.setInverted (true/false): Reverse the direction of rotation of the servo.

MORE INFO   SEE PYTHON SCRIPT
    

Maybe this can redirect to this link http://myrobotlab.org/quick_start

The Python Service allows development and execution of Python scripts which interact and control other Services.
The GUI provides a rudementary IDE for this Service. You can find a large number of scripts in the community library pyrobotlab

MORE INFO   SEE PYTHON SCRIPT

If you have something to hide this service is for you !
Useful to store passwords or secrets keys ( like api keys ) inside an AES safe and expose some code lines.
It is important to never expose API keys inside any script !

SEE PYTHON SCRIPT
  

The Runtime is the first Service to start when MyRobotLab begins.
Every running instance of MyRobotLab includes a single Runtime Service.
The Runtime is a singleton, which means there should be only one per running process of MyRobotLab.
Its responsibilities include the creation, removal, and merging of Services into the Service registry.
The registry is critical for routing communication between Services.
In addition to managing the endpoints of Service communication the Runtime can retrieve information
regarding details of the Java VM, operating system, and other details.

MORE INFO   SEE PYTHON SCRIPT
       

The OpenCV Service is a library of vision functions.
Some of the functions are:

-Face detection
-Fast Lucas Kanade optical tracking
-Background forground separation
-Motion detection
-Color segmentation
-Yolo object recognition
-More...

Many of the functions in OpenCV are implemented as pipeline filters in MRL.
That is a filter can run, and the output of one can be connected to the input of another.
Not all filters are capable of "pipelining"

How to Add an OpenCV Filter:

Step 1 - select from the available filter list
Step 2 - press the arrow button to add it into the left pipeline
Step 3 - give it a unique name
Step 4 - the filter is running in OpenCV


MORE INFO SEE PYTHON SCRIPT