SlideShare une entreprise Scribd logo
1  sur  46
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 1
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
Hackathon: “IPTPI and LeJaRo Meet The Real World”
How many tasks must a PiBot spell
Before you call him intellect
How many threads must JVM propel
Before you make it understand
Trayan Iliev
tiliev@iproduct.org http://iproduct.org
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 2
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
Trademarks
Oracle®, Java™ and JavaScript™ are trademarks or registered
trademarks of Oracle and/or its affiliates.
LEGO® is a registered trademark of LEGO® Group. Programs are not
affiliated, sponsored or endorsed by LEGO® Education or LEGO® Group.
Raspberry Pi™ is a trademark of Raspberry Pi Foundation.
Other names may be trademarks of their respective owners.
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 3
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
Disclaimer
All information presented in this document and all supplementary materials
and programming code represent only my personal opinion and current
understanding and has not received any endorsement or approval by IPT -
Intellectual Products and Technologies or any third party. It should not be
taken as any kind of advice, and should not be used for making any kind of
decisions with potential commercial impact.
The information and code presented may be incorrect or incomplete. It is
provided "as is", without warranty of any kind, express or implied, including but
not limited to the warranties of merchantability, fitness for a particular purpose
and non-infringement. In no event shall the author or copyright holders be
liable for any claim, damages or other liability, whether in an action of contract,
tort or otherwise, arising from, out of or in connection with the information,
materials or code presented or the use or other dealings with this information
or programming code.
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 4
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
About me ...
Trayan Iliev
Assistent Professor at Sofia
University
&
CEO of IPT – Intellectual Products
& Technologies
an IT Education Company
specialized in Java™ and
Java EE and Web trainings
Oracle®, Java™ and JavaScript™ are trademarks or registered trademarks of Oracle and/or its affiliates.
Other names may be trademarks of their respective owners.
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 5
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
... and Java™ Robotics
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 6
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
How to Build a Robot with Java™?
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 7
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
How to Build a Robot with Java™?
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 8
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
How to Build a Robot with Java™?
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 9
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
… and Why?
A great way to learn Java™ - why not?
Multithreading
Event driven and asynchronous programming
Actually reactive programming
Java 8 Lambdas and Streaming
Serial and network communication (Web Sockets are
great :)
and much, much more ...
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 10
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
Low Level GPIO Programming is Fun :)
public class MotorDemo01 {
public static void main(String[] args) throws InterruptedException {
// initialize wiringPi library
Gpio.wiringPiSetupGpio();
// Motor direction pins
Gpio.pinMode(5, Gpio.OUTPUT);
Gpio.pinMode(6, Gpio.OUTPUT);
// SoftPwm.softPwmCreate(12, 0, 100);
Gpio.pinMode(12, Gpio.PWM_OUTPUT);
Gpio.pinMode(13, Gpio.PWM_OUTPUT);
Gpio.pwmSetMode(Gpio.PWM_MODE_MS);
Gpio.pwmSetRange(480);
Gpio.pwmSetClock(2);
Gpio.pwmWrite(12, 460);
Gpio.pwmWrite(13, 460);
Gpio.digitalWrite(5, 0);
Gpio.digitalWrite(6, 1);
Thread.sleep(5000);
System.out.println("Running motors forward accelerating");
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 11
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
How to Build a Robot with Java™?
IPT – Intellectual Products & Technologies
Trayan Iliev, http://www.iproduct.org/
BG OUG Meeting – Hisarya
June 13, 2014
Slide 12
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License
Low Level GPIO Programming is Fun :)
public class MotorDemo01 {
public static void main(String[] args) throws InterruptedException {
// initialize wiringPi library
Gpio.wiringPiSetupGpio();
// Motor direction pins
Gpio.pinMode(5, Gpio.OUTPUT);
Gpio.pinMode(6, Gpio.OUTPUT);
// SoftPwm.softPwmCreate(12, 0, 100);
Gpio.pinMode(12, Gpio.PWM_OUTPUT);
Gpio.pinMode(13, Gpio.PWM_OUTPUT);
Gpio.pwmSetMode(Gpio.PWM_MODE_MS);
Gpio.pwmSetRange(480);
Gpio.pwmSetClock(2);
Gpio.pwmWrite(12, 460);
Gpio.pwmWrite(13, 460);
Gpio.digitalWrite(5, 0);
Gpio.digitalWrite(6, 1);
// SoftPwm.softPwmWrite(12, i);
Thread.sleep(5000);
System.out.println("Running motors forward accelerating");
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 13
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
The Platforms
Lego®
Mindstorms®
- http://www.lego.com/en-us/mindstorms
Raspberry Pi™ - https://www.raspberrypi.org/raspberry-pi-2-
on-sale/
Banana Pi®
- http://www.bananapi.org/p/product.html
SparkFun®
pcDuino v2 & v3 -
https://www.sparkfun.com/products/12856
BeagleBone - http://beagleboard.org/bone
ODROID – http://www.hardkernel.com/main/main.php
Arduino (Sorry no Java™ here – YET) & all the clones
PINGUINO = similar to Arduino but on PIC microcontrollers
LEGO® is a registered trademark of LEGO® Group. Programs of IPT are not affiliated,
sponsored or endorsed by LEGO® Education or LEGO® Group. Raspberry Pi™ is a
trademark of Raspberry Pi Foundation. Other names may be trademarks of their
respective owners.
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 14
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
Lego® Mindstorms®
Pros:
Easy to use – even for children, using graphical editor
Ready made hardware components – no need to solder
and drill :)
There is a Java on Lego project – LeJOS (www.lejos.org/)
Cons:
Too easy to use – the graphical editor is not my personal
favourite when programming more complex algorithms, or if
integration is needed with other libraries (easy with LeJOS)
Custom sensors or Arduino integration may be harder to do
Limited computational capabilities
,
LEGO® is a registered trademark of LEGO® Group. Programs of IPT are not affiliated,
sponsored or endorsed by LEGO® Education or LEGO® Group. Raspberry Pi™ is a
trademark of Raspberry Pi Foundation. Other names may be trademarks of their
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 15
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
Raspberry Pi™
Pros:
Much better computational power for only 35$ - 900MHz quad-
core ARM Cortex-A7 CPU, 1GB DR2 SDRAM, compatibility with
Raspberry Pi 1
Cons:
You have to build everything
in your robot yourself ...
... but it can be fun :)
There is a 40 pin GPIO
available, there are motor
drivers, servos, sensors for Pi
IPT – Intellectual Products & Technologies
Trayan Iliev, http://www.iproduct.org/
BG OUG Meeting – Hisarya
June 13, 2014
Slide 16
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License
The Platforms
LeJOS, Java for Lego® Mindstorms®, The Pi4J Project –
Connecting Java to Raspberry Pi™, Arduino.
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 17
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
SparkFun® pcDuino v3
CPU: AllWinner A20 SoC 1GHz
ARM Cortex A7 Dual Core
GPU: OpenGL ES2.0, OpenVG
1.1 Mali 400 Dual Core
1GB DRAM
Onboard Storage: 4GB Flash,
microSD card (TF) slot for up to
32GB
Arduino-Style Peripheral Headers
SATA Host Socket
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 18
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
The Platforms
LeJOS, Java for Lego® Mindstorms®, The Pi4J Project –
Connecting Java to Raspberry Pi™, Arduino.
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 19
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
Arduino and the Clones
Open hardware and software project
Low level and real time microcontroller programming
Easy to program using Arduino IDE
New: Plugin for Eclipse under development!
There is a big variety of boards
Even very cheap ones < 15$
Pulolu
A-Star
Micro/Mini
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 20
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
But Lets See Some Code: Lego
a
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 21
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
But Lets See Some Java Code: LeJOS
public class MotorDemo07 {
public static void main(String[] args) {
final EV3 ev3 = (EV3) BrickFinder.getLocal();
TextLCD lcd = ev3.getTextLCD();
Audio audio = ev3.getAudio();
//Color sensor
EV3ColorSensor colorSensor = new EV3ColorSensor(SensorPort.S3);
SensorMode color = colorSensor.getRGBMode();
float[] colorSample = new float[color.sampleSize()];
playMessage(audio);
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 22
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
LeJOS (2)
EV3TouchSensor touchSensor = new EV3TouchSensor(SensorPort.S1);
SensorMode touch = touchSensor.getTouchMode();
float[] sample = new float[touch.sampleSize()];
RegulatedMotor mA, mB, mC;
mA = new EV3LargeRegulatedMotor(MotorPort.A);
mB = new EV3LargeRegulatedMotor(MotorPort.B);
mC = new EV3LargeRegulatedMotor(MotorPort.C);
mB.setSpeed(120);// 2 RPM
mC.setSpeed(120);
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 23
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
LeJOS (3)
mB.synchronizeWith(new RegulatedMotor[] { mC });
long startTime = System.currentTimeMillis();
long duration;
int lastColorId = Color.NONE;
for (int i = 0; i < 4; i++) {
// go forward
mB.startSynchronization();
mB.forward();
mC.forward();
mB.endSynchronization();
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 24
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
LeJOS (4)
// go until not obstacle
do {
duration = System.currentTimeMillis() - startTime;
touch.fetchSample(sample, 0);
color.fetchSample(colorSample, 0);
lcd.drawString("" + colorSample[0], 0, 3);
lcd.drawString("" + colorSample[1], 0, 4);
lcd.drawString("" + colorSample[2], 0, 5);
} while (duration < 60000 && mB.isMoving() && mC.isMoving()
&& sample[0] == 0 && isReflecting(colorSample));
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 25
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
LeJOS (5)
mB.startSynchronization(); // go back
mB.backward();
mC.backward();
mB.endSynchronization();
mB.startSynchronization(); // turn back
mB.rotate(1000, true);
mC.rotate(-1000, true);
mB.endSynchronization();
while (mB.isMoving() && mC.isMoving())
Thread.yield();
}
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 26
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
LeJOS (6)
mB.flt();
mC.flt();
mA.close();
mB.close();
mC.close();
}
private static void playMessage(final Audio audio) {
audio.playSample(new File("pozdrav_01.wav"), 100);
}
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 27
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
LeJOS (7)
You have to adjust the thresholds by trial and error :)
private static boolean isReflecting(float[] colorSample){
return colorSample[0] > 0.015
|| colorSample[1] > 0.015
|| colorSample[2] > 0.015;
}
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 28
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
Pi4J – Java Low Level GPIO (I2C, SPI, Serial) for
Raspberry Pi
General-purpose input/output (GPIO) – allow digital (and
Analog on Arduino) input and output
Allows listeners to be registered for events connected with the
signal
Supports I²C (Inter-Integrated Circuit) – slower but uses only
two pins for bidirectional data transmission with many devices
(different addresses).
Serial Peripheral Interface (SPI) – much faster but requires
additional wires
See for more details IPT repository @ GitHub:
https://github.com/iproduct/course-social-robotics/wiki/Lectures
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 29
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
Pi4J (1) – GPIO Initialization
public class MotorDemo01 {
public static void main(String[] args) throws
InterruptedException {
// initialize wiringPi library using Broadcom pin
numbering scheme
Gpio.wiringPiSetupGpio();
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 30
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
Pi4J (2) - Setup
// Motor direction pins
Gpio.pinMode(5, Gpio.OUTPUT);
Gpio.pinMode(6, Gpio.OUTPUT);
// Motor speed pulse width modulated (PWM) pins
Gpio.pinMode(12, Gpio.PWM_OUTPUT);
Gpio.pinMode(13, Gpio.PWM_OUTPUT);
Gpio.pwmSetMode(Gpio.PWM_MODE_MS);
Gpio.pwmSetRange(480);
Gpio.pwmSetClock(2);
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 31
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
Pi4J (3) – Turning Left / Right
System.out.println("Turning left");
//setting motor directions
Gpio.digitalWrite(5, 1);
Gpio.digitalWrite(6, 0);
//setting speed
Gpio.pwmWrite(12, 460); // speed 460 of 480 max
Gpio.pwmWrite(13, 460);
// turn duration
Thread.sleep(3000);
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 32
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
Pi4J (4) – Accelerating / Decelerating
System.out.println("Motors forward accelerating");
for (int i = 0; i <= 480; i++) {
//setting motor directions
Gpio.digitalWrite(5, 1);
Gpio.digitalWrite(6, 1);
//setting speed
Gpio.pwmWrite(12, i);
Gpio.pwmWrite(13, i);
Thread.sleep(40);
}
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 33
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
Pi4J (5) – Finishing Politely
// turning the motors off
Gpio.digitalWrite(5, 0);
Gpio.digitalWrite(6, 0);
Gpio.pwmWrite(12, 0);
Gpio.pwmWrite(13, 0);
System.out.println("End of the demo.");
}
}
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 34
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
Pi4J – Java Low Level GPIO (I2C, SPI, Serial) for
Raspberry Pi (2)
More programming examples – on the Pi :)
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 35
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
Source: http://commons.wikimedia.org/wiki/File:Internet_of_things_signed_by_the_author.jpg,
Author: Wilgengebroed on Flickr (https://www.flickr.com/photos/wilgengebroed/8249565455/),
License: GenericAttribution-NonCommercial 2.0 Generic (CC BY-NC 2.0) -
https://creativecommons.org/licenses/by-nc/2.0/
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 36
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
Internet of Things (IoT)
Today computers—and, therefore, the Internet—are almost wholly
dependent on human beings for information. Nearly all of the roughly
50 petabytes (a petabyte is 1,024 terabytes) of data available on the
Internet were first captured and created by human beings—by typing,
pressing a record button, taking a digital picture, or scanning a bar
code. ... The problem is, people have limited time, attention and
accuracy—all of which means they are not very good at capturing data
about things in the real world. ... We're physical, and so is our
environment ... If we had computers that knew everything there was to
know about things ... we would be able to track and count everything,
and greatly reduce waste, loss and cost. We would know when things
needed replacing, repairing or recalling, and whether they were fresh
or past their best. The Internet of Things has the potential to change
the world, just as the Internet did. Maybe even more so.
— Kevin Ashton, 'That 'Internet of Things' Thing', RFID Journal,
July 22, 2009
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 37
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
Web Socket Based Communication
Architecture
Proxies: HTTP CONNECT –
Tunnelling
HTTP/S can be used
WebSockets over SSL
(wss:// scheme)
IPT – Intellectual Products & Technologies
Trayan Iliev, http://www.iproduct.org/
BG OUG Meeting – Hisarya
June 13, 2014
Slide 38
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License
Теория на игрите
RoboCup 2013 – Eindhoven by Albert van Breemen
[https://www.flickr.com/photos/robocup2013/10151792836]
License: Attribution-NonCommercial-ShareAlike 2.0 Generic (CC BY-NC-SA 2.0)
https://creativecommons.org/licenses/by-nc-sa/2.0/
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 39
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
More Information about Java™ Robotics:
https://github.com/iproduct/course-social-
robotics/wiki/Study-Materials
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 40
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
References
Social Robotics Lectures (Github wiki) –
https://github.com/iproduct/course-social-robotics/wiki/Lectures
Iliev, T., Ontology Based Multi-Agent Architecture for Adaptive
Courseware Delivery, Int. Workshop on Interactive Computer-aided
Learning ICL'2003, Villach, Austria, September 24-26, 2003
Internet of Things (IoT) in Wikipedia –
http://en.wikipedia.org/wiki/Internet_of_Things
Brooks, R.: A robust layered control system for a mobile robot. IEEE
Journal of Robotics and Automation, 2(1), 1986, pp. 14-23
Brooks, R., Intelligence without representation, Artificial Intelligence,
47, 1991, pp.139-159
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 41
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
Thanks for Your Attention!
Questions?
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 42
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
PROGRAMMING PROJECTS
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 43
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
LeJaRo: Follow The Line & Grasp That CUP
Using LeJOS APIs program the robot
to follow a white/color line.
When reaching the end of the line
LeJaRo should play a pre-
programmed sound, go 8 cm further,
and grasp the coffee cup placed
there.
Then the robot should turn back and
go 40 cm strait, drop the coffee cup,
and play another sound signaling the
successful finishing of the task.
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 44
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
IPTPI : Universal Soldier
Program the robot to say welcome
(GPIO, mplayer + ProcessBuilder)
Read motor encoders data from
Arduino A-Star Micro using USB
serial and program a feedback
loop to straighten the course.
Read data from optical array to
program robot to follow a line
Read compass, accelerometer and
gyroscope data (Pulolu MinIMU-9)
and make the robot orient better
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 45
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
Cocktail Maker: Make You Wish
No Alcohol in FMI :)
Assemble RPi2 / Arduino, low
voltage pumps (3x), liquid flow-
meters and hoses to a machine able
to dose precisely 3 types of liquids
Assemble breadboard with 3
MOSFET transistors (IRL 540N)
IPT – Intellectual Products & Technologies
Trayan Iliev, http://product.org/
http://robolearn.org/
RoboLearn Hackathon: IPTPI
and LeJaRо meet the Real
World - Sofia, Dec 04, 2015
Slide 46
Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0
Unported License. In presentation are used materials from https://openclipart.org/
Make Two Wheels Rpi2 Robot from Scratch

Contenu connexe

Similaire à Hackathon: “IPTPI and LeJaRo Meet The Real World”

Technologies, Places, Business Models for Open Design @ Pixelversity, Helsink...
Technologies, Places, Business Models for Open Design @ Pixelversity, Helsink...Technologies, Places, Business Models for Open Design @ Pixelversity, Helsink...
Technologies, Places, Business Models for Open Design @ Pixelversity, Helsink...Massimo Menichinelli
 
computer_vision_dummies_with_Opencv.pdf
computer_vision_dummies_with_Opencv.pdfcomputer_vision_dummies_with_Opencv.pdf
computer_vision_dummies_with_Opencv.pdfDeepuChaudhary12
 
Python and Jupyter: Your Gateway for Learning
Python and Jupyter: Your Gateway for LearningPython and Jupyter: Your Gateway for Learning
Python and Jupyter: Your Gateway for LearningCarol Willing
 
Applying IoT
Applying IoTApplying IoT
Applying IoTNorseDisc
 
Overview of the OpenCV library and some use cases - 2024-04-19
Overview of the OpenCV library and some use cases - 2024-04-19Overview of the OpenCV library and some use cases - 2024-04-19
Overview of the OpenCV library and some use cases - 2024-04-19Alessandra Bilardi
 
Understanding Technologies - Presentation for College Students
Understanding Technologies - Presentation for College StudentsUnderstanding Technologies - Presentation for College Students
Understanding Technologies - Presentation for College StudentsKetan Raval
 
Android lollipop for developers
Android lollipop for developersAndroid lollipop for developers
Android lollipop for developersRoyi benyossef
 
Open source software for startups
Open source software for startupsOpen source software for startups
Open source software for startupsvictorneo
 
Python 101 For The Net Developer
Python 101 For The Net DeveloperPython 101 For The Net Developer
Python 101 For The Net DeveloperSarah Dutkiewicz
 
Developing Apps with GPT-4 and ChatGPT_ Build Intelligent Chatbots, Content G...
Developing Apps with GPT-4 and ChatGPT_ Build Intelligent Chatbots, Content G...Developing Apps with GPT-4 and ChatGPT_ Build Intelligent Chatbots, Content G...
Developing Apps with GPT-4 and ChatGPT_ Build Intelligent Chatbots, Content G...BIHI Oussama
 
What are the career options for a python programmer
What are the career options for a python programmerWhat are the career options for a python programmer
What are the career options for a python programmerIntellipaat
 
Programming the Real World: Javascript for Makers
Programming the Real World: Javascript for MakersProgramming the Real World: Javascript for Makers
Programming the Real World: Javascript for Makerspchristensen
 
Java Device I/O at Raspberry PI to Build a Candy Vending Machine
Java Device I/O at Raspberry PI to Build a Candy Vending MachineJava Device I/O at Raspberry PI to Build a Candy Vending Machine
Java Device I/O at Raspberry PI to Build a Candy Vending MachineJeff Prestes
 
Python Projects For Beginners | Python Projects Examples | Python Tutorial | ...
Python Projects For Beginners | Python Projects Examples | Python Tutorial | ...Python Projects For Beginners | Python Projects Examples | Python Tutorial | ...
Python Projects For Beginners | Python Projects Examples | Python Tutorial | ...Edureka!
 
OpenAPI at Scale
OpenAPI at ScaleOpenAPI at Scale
OpenAPI at ScaleNordic APIs
 
Opening the IoT - Joe Fortey - IoT Midlands Meet Up - 29/07/14
Opening the IoT  - Joe Fortey - IoT Midlands Meet Up - 29/07/14Opening the IoT  - Joe Fortey - IoT Midlands Meet Up - 29/07/14
Opening the IoT - Joe Fortey - IoT Midlands Meet Up - 29/07/14WMG, University of Warwick
 
Year 5-6: Ideas for teaching coding
Year 5-6: Ideas for teaching codingYear 5-6: Ideas for teaching coding
Year 5-6: Ideas for teaching codingJoanne Villis
 
Blackboard DevCon: Introducing IMS Learning Tools Interoperability
Blackboard DevCon: Introducing IMS Learning Tools InteroperabilityBlackboard DevCon: Introducing IMS Learning Tools Interoperability
Blackboard DevCon: Introducing IMS Learning Tools InteroperabilityCharles Severance
 
Dl4j in the wild
Dl4j in the wildDl4j in the wild
Dl4j in the wildAdam Gibson
 
Leonid Yuriev - TopGun
Leonid Yuriev - TopGunLeonid Yuriev - TopGun
Leonid Yuriev - TopGunDefconRussia
 

Similaire à Hackathon: “IPTPI and LeJaRo Meet The Real World” (20)

Technologies, Places, Business Models for Open Design @ Pixelversity, Helsink...
Technologies, Places, Business Models for Open Design @ Pixelversity, Helsink...Technologies, Places, Business Models for Open Design @ Pixelversity, Helsink...
Technologies, Places, Business Models for Open Design @ Pixelversity, Helsink...
 
computer_vision_dummies_with_Opencv.pdf
computer_vision_dummies_with_Opencv.pdfcomputer_vision_dummies_with_Opencv.pdf
computer_vision_dummies_with_Opencv.pdf
 
Python and Jupyter: Your Gateway for Learning
Python and Jupyter: Your Gateway for LearningPython and Jupyter: Your Gateway for Learning
Python and Jupyter: Your Gateway for Learning
 
Applying IoT
Applying IoTApplying IoT
Applying IoT
 
Overview of the OpenCV library and some use cases - 2024-04-19
Overview of the OpenCV library and some use cases - 2024-04-19Overview of the OpenCV library and some use cases - 2024-04-19
Overview of the OpenCV library and some use cases - 2024-04-19
 
Understanding Technologies - Presentation for College Students
Understanding Technologies - Presentation for College StudentsUnderstanding Technologies - Presentation for College Students
Understanding Technologies - Presentation for College Students
 
Android lollipop for developers
Android lollipop for developersAndroid lollipop for developers
Android lollipop for developers
 
Open source software for startups
Open source software for startupsOpen source software for startups
Open source software for startups
 
Python 101 For The Net Developer
Python 101 For The Net DeveloperPython 101 For The Net Developer
Python 101 For The Net Developer
 
Developing Apps with GPT-4 and ChatGPT_ Build Intelligent Chatbots, Content G...
Developing Apps with GPT-4 and ChatGPT_ Build Intelligent Chatbots, Content G...Developing Apps with GPT-4 and ChatGPT_ Build Intelligent Chatbots, Content G...
Developing Apps with GPT-4 and ChatGPT_ Build Intelligent Chatbots, Content G...
 
What are the career options for a python programmer
What are the career options for a python programmerWhat are the career options for a python programmer
What are the career options for a python programmer
 
Programming the Real World: Javascript for Makers
Programming the Real World: Javascript for MakersProgramming the Real World: Javascript for Makers
Programming the Real World: Javascript for Makers
 
Java Device I/O at Raspberry PI to Build a Candy Vending Machine
Java Device I/O at Raspberry PI to Build a Candy Vending MachineJava Device I/O at Raspberry PI to Build a Candy Vending Machine
Java Device I/O at Raspberry PI to Build a Candy Vending Machine
 
Python Projects For Beginners | Python Projects Examples | Python Tutorial | ...
Python Projects For Beginners | Python Projects Examples | Python Tutorial | ...Python Projects For Beginners | Python Projects Examples | Python Tutorial | ...
Python Projects For Beginners | Python Projects Examples | Python Tutorial | ...
 
OpenAPI at Scale
OpenAPI at ScaleOpenAPI at Scale
OpenAPI at Scale
 
Opening the IoT - Joe Fortey - IoT Midlands Meet Up - 29/07/14
Opening the IoT  - Joe Fortey - IoT Midlands Meet Up - 29/07/14Opening the IoT  - Joe Fortey - IoT Midlands Meet Up - 29/07/14
Opening the IoT - Joe Fortey - IoT Midlands Meet Up - 29/07/14
 
Year 5-6: Ideas for teaching coding
Year 5-6: Ideas for teaching codingYear 5-6: Ideas for teaching coding
Year 5-6: Ideas for teaching coding
 
Blackboard DevCon: Introducing IMS Learning Tools Interoperability
Blackboard DevCon: Introducing IMS Learning Tools InteroperabilityBlackboard DevCon: Introducing IMS Learning Tools Interoperability
Blackboard DevCon: Introducing IMS Learning Tools Interoperability
 
Dl4j in the wild
Dl4j in the wildDl4j in the wild
Dl4j in the wild
 
Leonid Yuriev - TopGun
Leonid Yuriev - TopGunLeonid Yuriev - TopGun
Leonid Yuriev - TopGun
 

Plus de Trayan Iliev

Making Machine Learning Easy with H2O and WebFlux
Making Machine Learning Easy with H2O and WebFluxMaking Machine Learning Easy with H2O and WebFlux
Making Machine Learning Easy with H2O and WebFluxTrayan Iliev
 
Rapid Web API development with Kotlin and Ktor
Rapid Web API development with Kotlin and KtorRapid Web API development with Kotlin and Ktor
Rapid Web API development with Kotlin and KtorTrayan Iliev
 
IPT Reactive Java IoT Demo - BGOUG 2018
IPT Reactive Java IoT Demo - BGOUG 2018IPT Reactive Java IoT Demo - BGOUG 2018
IPT Reactive Java IoT Demo - BGOUG 2018Trayan Iliev
 
Learning Programming Using Robots - Sofia University Conference 2018
Learning Programming Using Robots - Sofia University Conference 2018 Learning Programming Using Robots - Sofia University Conference 2018
Learning Programming Using Robots - Sofia University Conference 2018 Trayan Iliev
 
Active Learning Using Connected Things - 2018 (in Bulgarian)
Active Learning Using Connected Things - 2018 (in Bulgarian)Active Learning Using Connected Things - 2018 (in Bulgarian)
Active Learning Using Connected Things - 2018 (in Bulgarian)Trayan Iliev
 
Spring 5 Webflux - Advances in Java 2018
Spring 5 Webflux - Advances in Java 2018Spring 5 Webflux - Advances in Java 2018
Spring 5 Webflux - Advances in Java 2018Trayan Iliev
 
Fog Computing - DEV.BG 2018
Fog Computing - DEV.BG 2018Fog Computing - DEV.BG 2018
Fog Computing - DEV.BG 2018Trayan Iliev
 
Microservices with Spring 5 Webflux - jProfessionals
Microservices  with Spring 5 Webflux - jProfessionalsMicroservices  with Spring 5 Webflux - jProfessionals
Microservices with Spring 5 Webflux - jProfessionalsTrayan Iliev
 
Reactive Microservices with Spring 5: WebFlux
Reactive Microservices with Spring 5: WebFlux Reactive Microservices with Spring 5: WebFlux
Reactive Microservices with Spring 5: WebFlux Trayan Iliev
 
What's new in java 9?
What's new in java 9?What's new in java 9?
What's new in java 9?Trayan Iliev
 
NGRX Apps in Depth
NGRX Apps in DepthNGRX Apps in Depth
NGRX Apps in DepthTrayan Iliev
 
Stream Processing with CompletableFuture and Flow in Java 9
Stream Processing with CompletableFuture and Flow in Java 9Stream Processing with CompletableFuture and Flow in Java 9
Stream Processing with CompletableFuture and Flow in Java 9Trayan Iliev
 
React HOCs, Context and Observables
React HOCs, Context and ObservablesReact HOCs, Context and Observables
React HOCs, Context and ObservablesTrayan Iliev
 
Reactive Java Robotics & IoT with Spring Reactor
Reactive Java Robotics & IoT with Spring ReactorReactive Java Robotics & IoT with Spring Reactor
Reactive Java Robotics & IoT with Spring ReactorTrayan Iliev
 
Reactive robotics io_t_2017
Reactive robotics io_t_2017Reactive robotics io_t_2017
Reactive robotics io_t_2017Trayan Iliev
 
Java & JavaScipt Reactive Robotics and IoT 2016 @ jProfessionals
Java & JavaScipt Reactive Robotics and IoT 2016 @ jProfessionalsJava & JavaScipt Reactive Robotics and IoT 2016 @ jProfessionals
Java & JavaScipt Reactive Robotics and IoT 2016 @ jProfessionalsTrayan Iliev
 
IPT High Performance Reactive Java BGOUG 2016
IPT High Performance Reactive Java BGOUG 2016IPT High Performance Reactive Java BGOUG 2016
IPT High Performance Reactive Java BGOUG 2016Trayan Iliev
 
Reactive Java Robotics IoT - jPrime 2016
Reactive Java Robotics IoT - jPrime 2016Reactive Java Robotics IoT - jPrime 2016
Reactive Java Robotics IoT - jPrime 2016Trayan Iliev
 
IPT angular2 typescript SPA 2016
IPT angular2 typescript SPA 2016IPT angular2 typescript SPA 2016
IPT angular2 typescript SPA 2016Trayan Iliev
 
Reactive Java Robotics and IoT - IPT Presentation @ Voxxed Days 2016
Reactive Java Robotics and IoT - IPT Presentation @ Voxxed Days 2016Reactive Java Robotics and IoT - IPT Presentation @ Voxxed Days 2016
Reactive Java Robotics and IoT - IPT Presentation @ Voxxed Days 2016Trayan Iliev
 

Plus de Trayan Iliev (20)

Making Machine Learning Easy with H2O and WebFlux
Making Machine Learning Easy with H2O and WebFluxMaking Machine Learning Easy with H2O and WebFlux
Making Machine Learning Easy with H2O and WebFlux
 
Rapid Web API development with Kotlin and Ktor
Rapid Web API development with Kotlin and KtorRapid Web API development with Kotlin and Ktor
Rapid Web API development with Kotlin and Ktor
 
IPT Reactive Java IoT Demo - BGOUG 2018
IPT Reactive Java IoT Demo - BGOUG 2018IPT Reactive Java IoT Demo - BGOUG 2018
IPT Reactive Java IoT Demo - BGOUG 2018
 
Learning Programming Using Robots - Sofia University Conference 2018
Learning Programming Using Robots - Sofia University Conference 2018 Learning Programming Using Robots - Sofia University Conference 2018
Learning Programming Using Robots - Sofia University Conference 2018
 
Active Learning Using Connected Things - 2018 (in Bulgarian)
Active Learning Using Connected Things - 2018 (in Bulgarian)Active Learning Using Connected Things - 2018 (in Bulgarian)
Active Learning Using Connected Things - 2018 (in Bulgarian)
 
Spring 5 Webflux - Advances in Java 2018
Spring 5 Webflux - Advances in Java 2018Spring 5 Webflux - Advances in Java 2018
Spring 5 Webflux - Advances in Java 2018
 
Fog Computing - DEV.BG 2018
Fog Computing - DEV.BG 2018Fog Computing - DEV.BG 2018
Fog Computing - DEV.BG 2018
 
Microservices with Spring 5 Webflux - jProfessionals
Microservices  with Spring 5 Webflux - jProfessionalsMicroservices  with Spring 5 Webflux - jProfessionals
Microservices with Spring 5 Webflux - jProfessionals
 
Reactive Microservices with Spring 5: WebFlux
Reactive Microservices with Spring 5: WebFlux Reactive Microservices with Spring 5: WebFlux
Reactive Microservices with Spring 5: WebFlux
 
What's new in java 9?
What's new in java 9?What's new in java 9?
What's new in java 9?
 
NGRX Apps in Depth
NGRX Apps in DepthNGRX Apps in Depth
NGRX Apps in Depth
 
Stream Processing with CompletableFuture and Flow in Java 9
Stream Processing with CompletableFuture and Flow in Java 9Stream Processing with CompletableFuture and Flow in Java 9
Stream Processing with CompletableFuture and Flow in Java 9
 
React HOCs, Context and Observables
React HOCs, Context and ObservablesReact HOCs, Context and Observables
React HOCs, Context and Observables
 
Reactive Java Robotics & IoT with Spring Reactor
Reactive Java Robotics & IoT with Spring ReactorReactive Java Robotics & IoT with Spring Reactor
Reactive Java Robotics & IoT with Spring Reactor
 
Reactive robotics io_t_2017
Reactive robotics io_t_2017Reactive robotics io_t_2017
Reactive robotics io_t_2017
 
Java & JavaScipt Reactive Robotics and IoT 2016 @ jProfessionals
Java & JavaScipt Reactive Robotics and IoT 2016 @ jProfessionalsJava & JavaScipt Reactive Robotics and IoT 2016 @ jProfessionals
Java & JavaScipt Reactive Robotics and IoT 2016 @ jProfessionals
 
IPT High Performance Reactive Java BGOUG 2016
IPT High Performance Reactive Java BGOUG 2016IPT High Performance Reactive Java BGOUG 2016
IPT High Performance Reactive Java BGOUG 2016
 
Reactive Java Robotics IoT - jPrime 2016
Reactive Java Robotics IoT - jPrime 2016Reactive Java Robotics IoT - jPrime 2016
Reactive Java Robotics IoT - jPrime 2016
 
IPT angular2 typescript SPA 2016
IPT angular2 typescript SPA 2016IPT angular2 typescript SPA 2016
IPT angular2 typescript SPA 2016
 
Reactive Java Robotics and IoT - IPT Presentation @ Voxxed Days 2016
Reactive Java Robotics and IoT - IPT Presentation @ Voxxed Days 2016Reactive Java Robotics and IoT - IPT Presentation @ Voxxed Days 2016
Reactive Java Robotics and IoT - IPT Presentation @ Voxxed Days 2016
 

Dernier

Dementia (Alzheimer & vasular dementia).
Dementia (Alzheimer & vasular dementia).Dementia (Alzheimer & vasular dementia).
Dementia (Alzheimer & vasular dementia).Mohamed Rizk Khodair
 
會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文
會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文
會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文中 央社
 
ANTI PARKISON DRUGS.pptx
ANTI         PARKISON          DRUGS.pptxANTI         PARKISON          DRUGS.pptx
ANTI PARKISON DRUGS.pptxPoojaSen20
 
Spring gala 2024 photo slideshow - Celebrating School-Community Partnerships
Spring gala 2024 photo slideshow - Celebrating School-Community PartnershipsSpring gala 2024 photo slideshow - Celebrating School-Community Partnerships
Spring gala 2024 photo slideshow - Celebrating School-Community Partnershipsexpandedwebsite
 
Championnat de France de Tennis de table/
Championnat de France de Tennis de table/Championnat de France de Tennis de table/
Championnat de France de Tennis de table/siemaillard
 
How to Analyse Profit of a Sales Order in Odoo 17
How to Analyse Profit of a Sales Order in Odoo 17How to Analyse Profit of a Sales Order in Odoo 17
How to Analyse Profit of a Sales Order in Odoo 17Celine George
 
Analyzing and resolving a communication crisis in Dhaka textiles LTD.pptx
Analyzing and resolving a communication crisis in Dhaka textiles LTD.pptxAnalyzing and resolving a communication crisis in Dhaka textiles LTD.pptx
Analyzing and resolving a communication crisis in Dhaka textiles LTD.pptxLimon Prince
 
e-Sealing at EADTU by Kamakshi Rajagopal
e-Sealing at EADTU by Kamakshi Rajagopale-Sealing at EADTU by Kamakshi Rajagopal
e-Sealing at EADTU by Kamakshi RajagopalEADTU
 
philosophy and it's principles based on the life
philosophy and it's principles based on the lifephilosophy and it's principles based on the life
philosophy and it's principles based on the lifeNitinDeodare
 
The basics of sentences session 4pptx.pptx
The basics of sentences session 4pptx.pptxThe basics of sentences session 4pptx.pptx
The basics of sentences session 4pptx.pptxheathfieldcps1
 
Basic Civil Engineering notes on Transportation Engineering, Modes of Transpo...
Basic Civil Engineering notes on Transportation Engineering, Modes of Transpo...Basic Civil Engineering notes on Transportation Engineering, Modes of Transpo...
Basic Civil Engineering notes on Transportation Engineering, Modes of Transpo...Denish Jangid
 
Graduate Outcomes Presentation Slides - English (v3).pptx
Graduate Outcomes Presentation Slides - English (v3).pptxGraduate Outcomes Presentation Slides - English (v3).pptx
Graduate Outcomes Presentation Slides - English (v3).pptxneillewis46
 
The Liver & Gallbladder (Anatomy & Physiology).pptx
The Liver &  Gallbladder (Anatomy & Physiology).pptxThe Liver &  Gallbladder (Anatomy & Physiology).pptx
The Liver & Gallbladder (Anatomy & Physiology).pptxVishal Singh
 
BỘ LUYỆN NGHE TIẾNG ANH 8 GLOBAL SUCCESS CẢ NĂM (GỒM 12 UNITS, MỖI UNIT GỒM 3...
BỘ LUYỆN NGHE TIẾNG ANH 8 GLOBAL SUCCESS CẢ NĂM (GỒM 12 UNITS, MỖI UNIT GỒM 3...BỘ LUYỆN NGHE TIẾNG ANH 8 GLOBAL SUCCESS CẢ NĂM (GỒM 12 UNITS, MỖI UNIT GỒM 3...
BỘ LUYỆN NGHE TIẾNG ANH 8 GLOBAL SUCCESS CẢ NĂM (GỒM 12 UNITS, MỖI UNIT GỒM 3...Nguyen Thanh Tu Collection
 
Major project report on Tata Motors and its marketing strategies
Major project report on Tata Motors and its marketing strategiesMajor project report on Tata Motors and its marketing strategies
Major project report on Tata Motors and its marketing strategiesAmanpreetKaur157993
 
The Story of Village Palampur Class 9 Free Study Material PDF
The Story of Village Palampur Class 9 Free Study Material PDFThe Story of Village Palampur Class 9 Free Study Material PDF
The Story of Village Palampur Class 9 Free Study Material PDFVivekanand Anglo Vedic Academy
 

Dernier (20)

Mattingly "AI & Prompt Design: Named Entity Recognition"
Mattingly "AI & Prompt Design: Named Entity Recognition"Mattingly "AI & Prompt Design: Named Entity Recognition"
Mattingly "AI & Prompt Design: Named Entity Recognition"
 
Dementia (Alzheimer & vasular dementia).
Dementia (Alzheimer & vasular dementia).Dementia (Alzheimer & vasular dementia).
Dementia (Alzheimer & vasular dementia).
 
會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文
會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文
會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文
 
ANTI PARKISON DRUGS.pptx
ANTI         PARKISON          DRUGS.pptxANTI         PARKISON          DRUGS.pptx
ANTI PARKISON DRUGS.pptx
 
“O BEIJO” EM ARTE .
“O BEIJO” EM ARTE                       .“O BEIJO” EM ARTE                       .
“O BEIJO” EM ARTE .
 
Spring gala 2024 photo slideshow - Celebrating School-Community Partnerships
Spring gala 2024 photo slideshow - Celebrating School-Community PartnershipsSpring gala 2024 photo slideshow - Celebrating School-Community Partnerships
Spring gala 2024 photo slideshow - Celebrating School-Community Partnerships
 
Championnat de France de Tennis de table/
Championnat de France de Tennis de table/Championnat de France de Tennis de table/
Championnat de France de Tennis de table/
 
How to Analyse Profit of a Sales Order in Odoo 17
How to Analyse Profit of a Sales Order in Odoo 17How to Analyse Profit of a Sales Order in Odoo 17
How to Analyse Profit of a Sales Order in Odoo 17
 
Analyzing and resolving a communication crisis in Dhaka textiles LTD.pptx
Analyzing and resolving a communication crisis in Dhaka textiles LTD.pptxAnalyzing and resolving a communication crisis in Dhaka textiles LTD.pptx
Analyzing and resolving a communication crisis in Dhaka textiles LTD.pptx
 
e-Sealing at EADTU by Kamakshi Rajagopal
e-Sealing at EADTU by Kamakshi Rajagopale-Sealing at EADTU by Kamakshi Rajagopal
e-Sealing at EADTU by Kamakshi Rajagopal
 
philosophy and it's principles based on the life
philosophy and it's principles based on the lifephilosophy and it's principles based on the life
philosophy and it's principles based on the life
 
The basics of sentences session 4pptx.pptx
The basics of sentences session 4pptx.pptxThe basics of sentences session 4pptx.pptx
The basics of sentences session 4pptx.pptx
 
Basic Civil Engineering notes on Transportation Engineering, Modes of Transpo...
Basic Civil Engineering notes on Transportation Engineering, Modes of Transpo...Basic Civil Engineering notes on Transportation Engineering, Modes of Transpo...
Basic Civil Engineering notes on Transportation Engineering, Modes of Transpo...
 
Mattingly "AI and Prompt Design: LLMs with NER"
Mattingly "AI and Prompt Design: LLMs with NER"Mattingly "AI and Prompt Design: LLMs with NER"
Mattingly "AI and Prompt Design: LLMs with NER"
 
Graduate Outcomes Presentation Slides - English (v3).pptx
Graduate Outcomes Presentation Slides - English (v3).pptxGraduate Outcomes Presentation Slides - English (v3).pptx
Graduate Outcomes Presentation Slides - English (v3).pptx
 
IPL Online Quiz by Pragya; Question Set.
IPL Online Quiz by Pragya; Question Set.IPL Online Quiz by Pragya; Question Set.
IPL Online Quiz by Pragya; Question Set.
 
The Liver & Gallbladder (Anatomy & Physiology).pptx
The Liver &  Gallbladder (Anatomy & Physiology).pptxThe Liver &  Gallbladder (Anatomy & Physiology).pptx
The Liver & Gallbladder (Anatomy & Physiology).pptx
 
BỘ LUYỆN NGHE TIẾNG ANH 8 GLOBAL SUCCESS CẢ NĂM (GỒM 12 UNITS, MỖI UNIT GỒM 3...
BỘ LUYỆN NGHE TIẾNG ANH 8 GLOBAL SUCCESS CẢ NĂM (GỒM 12 UNITS, MỖI UNIT GỒM 3...BỘ LUYỆN NGHE TIẾNG ANH 8 GLOBAL SUCCESS CẢ NĂM (GỒM 12 UNITS, MỖI UNIT GỒM 3...
BỘ LUYỆN NGHE TIẾNG ANH 8 GLOBAL SUCCESS CẢ NĂM (GỒM 12 UNITS, MỖI UNIT GỒM 3...
 
Major project report on Tata Motors and its marketing strategies
Major project report on Tata Motors and its marketing strategiesMajor project report on Tata Motors and its marketing strategies
Major project report on Tata Motors and its marketing strategies
 
The Story of Village Palampur Class 9 Free Study Material PDF
The Story of Village Palampur Class 9 Free Study Material PDFThe Story of Village Palampur Class 9 Free Study Material PDF
The Story of Village Palampur Class 9 Free Study Material PDF
 

Hackathon: “IPTPI and LeJaRo Meet The Real World”

  • 1. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 1 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ Hackathon: “IPTPI and LeJaRo Meet The Real World” How many tasks must a PiBot spell Before you call him intellect How many threads must JVM propel Before you make it understand Trayan Iliev tiliev@iproduct.org http://iproduct.org
  • 2. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 2 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ Trademarks Oracle®, Java™ and JavaScript™ are trademarks or registered trademarks of Oracle and/or its affiliates. LEGO® is a registered trademark of LEGO® Group. Programs are not affiliated, sponsored or endorsed by LEGO® Education or LEGO® Group. Raspberry Pi™ is a trademark of Raspberry Pi Foundation. Other names may be trademarks of their respective owners.
  • 3. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 3 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ Disclaimer All information presented in this document and all supplementary materials and programming code represent only my personal opinion and current understanding and has not received any endorsement or approval by IPT - Intellectual Products and Technologies or any third party. It should not be taken as any kind of advice, and should not be used for making any kind of decisions with potential commercial impact. The information and code presented may be incorrect or incomplete. It is provided "as is", without warranty of any kind, express or implied, including but not limited to the warranties of merchantability, fitness for a particular purpose and non-infringement. In no event shall the author or copyright holders be liable for any claim, damages or other liability, whether in an action of contract, tort or otherwise, arising from, out of or in connection with the information, materials or code presented or the use or other dealings with this information or programming code.
  • 4. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 4 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ About me ... Trayan Iliev Assistent Professor at Sofia University & CEO of IPT – Intellectual Products & Technologies an IT Education Company specialized in Java™ and Java EE and Web trainings Oracle®, Java™ and JavaScript™ are trademarks or registered trademarks of Oracle and/or its affiliates. Other names may be trademarks of their respective owners.
  • 5. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 5 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ ... and Java™ Robotics
  • 6. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 6 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ How to Build a Robot with Java™?
  • 7. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 7 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ How to Build a Robot with Java™?
  • 8. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 8 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ How to Build a Robot with Java™?
  • 9. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 9 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ … and Why? A great way to learn Java™ - why not? Multithreading Event driven and asynchronous programming Actually reactive programming Java 8 Lambdas and Streaming Serial and network communication (Web Sockets are great :) and much, much more ...
  • 10. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 10 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ Low Level GPIO Programming is Fun :) public class MotorDemo01 { public static void main(String[] args) throws InterruptedException { // initialize wiringPi library Gpio.wiringPiSetupGpio(); // Motor direction pins Gpio.pinMode(5, Gpio.OUTPUT); Gpio.pinMode(6, Gpio.OUTPUT); // SoftPwm.softPwmCreate(12, 0, 100); Gpio.pinMode(12, Gpio.PWM_OUTPUT); Gpio.pinMode(13, Gpio.PWM_OUTPUT); Gpio.pwmSetMode(Gpio.PWM_MODE_MS); Gpio.pwmSetRange(480); Gpio.pwmSetClock(2); Gpio.pwmWrite(12, 460); Gpio.pwmWrite(13, 460); Gpio.digitalWrite(5, 0); Gpio.digitalWrite(6, 1); Thread.sleep(5000); System.out.println("Running motors forward accelerating");
  • 11. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 11 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ How to Build a Robot with Java™?
  • 12. IPT – Intellectual Products & Technologies Trayan Iliev, http://www.iproduct.org/ BG OUG Meeting – Hisarya June 13, 2014 Slide 12 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License Low Level GPIO Programming is Fun :) public class MotorDemo01 { public static void main(String[] args) throws InterruptedException { // initialize wiringPi library Gpio.wiringPiSetupGpio(); // Motor direction pins Gpio.pinMode(5, Gpio.OUTPUT); Gpio.pinMode(6, Gpio.OUTPUT); // SoftPwm.softPwmCreate(12, 0, 100); Gpio.pinMode(12, Gpio.PWM_OUTPUT); Gpio.pinMode(13, Gpio.PWM_OUTPUT); Gpio.pwmSetMode(Gpio.PWM_MODE_MS); Gpio.pwmSetRange(480); Gpio.pwmSetClock(2); Gpio.pwmWrite(12, 460); Gpio.pwmWrite(13, 460); Gpio.digitalWrite(5, 0); Gpio.digitalWrite(6, 1); // SoftPwm.softPwmWrite(12, i); Thread.sleep(5000); System.out.println("Running motors forward accelerating");
  • 13. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 13 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ The Platforms Lego® Mindstorms® - http://www.lego.com/en-us/mindstorms Raspberry Pi™ - https://www.raspberrypi.org/raspberry-pi-2- on-sale/ Banana Pi® - http://www.bananapi.org/p/product.html SparkFun® pcDuino v2 & v3 - https://www.sparkfun.com/products/12856 BeagleBone - http://beagleboard.org/bone ODROID – http://www.hardkernel.com/main/main.php Arduino (Sorry no Java™ here – YET) & all the clones PINGUINO = similar to Arduino but on PIC microcontrollers LEGO® is a registered trademark of LEGO® Group. Programs of IPT are not affiliated, sponsored or endorsed by LEGO® Education or LEGO® Group. Raspberry Pi™ is a trademark of Raspberry Pi Foundation. Other names may be trademarks of their respective owners.
  • 14. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 14 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ Lego® Mindstorms® Pros: Easy to use – even for children, using graphical editor Ready made hardware components – no need to solder and drill :) There is a Java on Lego project – LeJOS (www.lejos.org/) Cons: Too easy to use – the graphical editor is not my personal favourite when programming more complex algorithms, or if integration is needed with other libraries (easy with LeJOS) Custom sensors or Arduino integration may be harder to do Limited computational capabilities , LEGO® is a registered trademark of LEGO® Group. Programs of IPT are not affiliated, sponsored or endorsed by LEGO® Education or LEGO® Group. Raspberry Pi™ is a trademark of Raspberry Pi Foundation. Other names may be trademarks of their
  • 15. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 15 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ Raspberry Pi™ Pros: Much better computational power for only 35$ - 900MHz quad- core ARM Cortex-A7 CPU, 1GB DR2 SDRAM, compatibility with Raspberry Pi 1 Cons: You have to build everything in your robot yourself ... ... but it can be fun :) There is a 40 pin GPIO available, there are motor drivers, servos, sensors for Pi
  • 16. IPT – Intellectual Products & Technologies Trayan Iliev, http://www.iproduct.org/ BG OUG Meeting – Hisarya June 13, 2014 Slide 16 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License The Platforms LeJOS, Java for Lego® Mindstorms®, The Pi4J Project – Connecting Java to Raspberry Pi™, Arduino.
  • 17. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 17 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ SparkFun® pcDuino v3 CPU: AllWinner A20 SoC 1GHz ARM Cortex A7 Dual Core GPU: OpenGL ES2.0, OpenVG 1.1 Mali 400 Dual Core 1GB DRAM Onboard Storage: 4GB Flash, microSD card (TF) slot for up to 32GB Arduino-Style Peripheral Headers SATA Host Socket
  • 18. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 18 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ The Platforms LeJOS, Java for Lego® Mindstorms®, The Pi4J Project – Connecting Java to Raspberry Pi™, Arduino.
  • 19. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 19 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ Arduino and the Clones Open hardware and software project Low level and real time microcontroller programming Easy to program using Arduino IDE New: Plugin for Eclipse under development! There is a big variety of boards Even very cheap ones < 15$ Pulolu A-Star Micro/Mini
  • 20. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 20 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ But Lets See Some Code: Lego a
  • 21. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 21 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ But Lets See Some Java Code: LeJOS public class MotorDemo07 { public static void main(String[] args) { final EV3 ev3 = (EV3) BrickFinder.getLocal(); TextLCD lcd = ev3.getTextLCD(); Audio audio = ev3.getAudio(); //Color sensor EV3ColorSensor colorSensor = new EV3ColorSensor(SensorPort.S3); SensorMode color = colorSensor.getRGBMode(); float[] colorSample = new float[color.sampleSize()]; playMessage(audio);
  • 22. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 22 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ LeJOS (2) EV3TouchSensor touchSensor = new EV3TouchSensor(SensorPort.S1); SensorMode touch = touchSensor.getTouchMode(); float[] sample = new float[touch.sampleSize()]; RegulatedMotor mA, mB, mC; mA = new EV3LargeRegulatedMotor(MotorPort.A); mB = new EV3LargeRegulatedMotor(MotorPort.B); mC = new EV3LargeRegulatedMotor(MotorPort.C); mB.setSpeed(120);// 2 RPM mC.setSpeed(120);
  • 23. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 23 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ LeJOS (3) mB.synchronizeWith(new RegulatedMotor[] { mC }); long startTime = System.currentTimeMillis(); long duration; int lastColorId = Color.NONE; for (int i = 0; i < 4; i++) { // go forward mB.startSynchronization(); mB.forward(); mC.forward(); mB.endSynchronization();
  • 24. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 24 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ LeJOS (4) // go until not obstacle do { duration = System.currentTimeMillis() - startTime; touch.fetchSample(sample, 0); color.fetchSample(colorSample, 0); lcd.drawString("" + colorSample[0], 0, 3); lcd.drawString("" + colorSample[1], 0, 4); lcd.drawString("" + colorSample[2], 0, 5); } while (duration < 60000 && mB.isMoving() && mC.isMoving() && sample[0] == 0 && isReflecting(colorSample));
  • 25. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 25 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ LeJOS (5) mB.startSynchronization(); // go back mB.backward(); mC.backward(); mB.endSynchronization(); mB.startSynchronization(); // turn back mB.rotate(1000, true); mC.rotate(-1000, true); mB.endSynchronization(); while (mB.isMoving() && mC.isMoving()) Thread.yield(); }
  • 26. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 26 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ LeJOS (6) mB.flt(); mC.flt(); mA.close(); mB.close(); mC.close(); } private static void playMessage(final Audio audio) { audio.playSample(new File("pozdrav_01.wav"), 100); }
  • 27. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 27 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ LeJOS (7) You have to adjust the thresholds by trial and error :) private static boolean isReflecting(float[] colorSample){ return colorSample[0] > 0.015 || colorSample[1] > 0.015 || colorSample[2] > 0.015; }
  • 28. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 28 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ Pi4J – Java Low Level GPIO (I2C, SPI, Serial) for Raspberry Pi General-purpose input/output (GPIO) – allow digital (and Analog on Arduino) input and output Allows listeners to be registered for events connected with the signal Supports I²C (Inter-Integrated Circuit) – slower but uses only two pins for bidirectional data transmission with many devices (different addresses). Serial Peripheral Interface (SPI) – much faster but requires additional wires See for more details IPT repository @ GitHub: https://github.com/iproduct/course-social-robotics/wiki/Lectures
  • 29. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 29 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ Pi4J (1) – GPIO Initialization public class MotorDemo01 { public static void main(String[] args) throws InterruptedException { // initialize wiringPi library using Broadcom pin numbering scheme Gpio.wiringPiSetupGpio();
  • 30. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 30 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ Pi4J (2) - Setup // Motor direction pins Gpio.pinMode(5, Gpio.OUTPUT); Gpio.pinMode(6, Gpio.OUTPUT); // Motor speed pulse width modulated (PWM) pins Gpio.pinMode(12, Gpio.PWM_OUTPUT); Gpio.pinMode(13, Gpio.PWM_OUTPUT); Gpio.pwmSetMode(Gpio.PWM_MODE_MS); Gpio.pwmSetRange(480); Gpio.pwmSetClock(2);
  • 31. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 31 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ Pi4J (3) – Turning Left / Right System.out.println("Turning left"); //setting motor directions Gpio.digitalWrite(5, 1); Gpio.digitalWrite(6, 0); //setting speed Gpio.pwmWrite(12, 460); // speed 460 of 480 max Gpio.pwmWrite(13, 460); // turn duration Thread.sleep(3000);
  • 32. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 32 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ Pi4J (4) – Accelerating / Decelerating System.out.println("Motors forward accelerating"); for (int i = 0; i <= 480; i++) { //setting motor directions Gpio.digitalWrite(5, 1); Gpio.digitalWrite(6, 1); //setting speed Gpio.pwmWrite(12, i); Gpio.pwmWrite(13, i); Thread.sleep(40); }
  • 33. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 33 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ Pi4J (5) – Finishing Politely // turning the motors off Gpio.digitalWrite(5, 0); Gpio.digitalWrite(6, 0); Gpio.pwmWrite(12, 0); Gpio.pwmWrite(13, 0); System.out.println("End of the demo."); } }
  • 34. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 34 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ Pi4J – Java Low Level GPIO (I2C, SPI, Serial) for Raspberry Pi (2) More programming examples – on the Pi :)
  • 35. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 35 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ Source: http://commons.wikimedia.org/wiki/File:Internet_of_things_signed_by_the_author.jpg, Author: Wilgengebroed on Flickr (https://www.flickr.com/photos/wilgengebroed/8249565455/), License: GenericAttribution-NonCommercial 2.0 Generic (CC BY-NC 2.0) - https://creativecommons.org/licenses/by-nc/2.0/
  • 36. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 36 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ Internet of Things (IoT) Today computers—and, therefore, the Internet—are almost wholly dependent on human beings for information. Nearly all of the roughly 50 petabytes (a petabyte is 1,024 terabytes) of data available on the Internet were first captured and created by human beings—by typing, pressing a record button, taking a digital picture, or scanning a bar code. ... The problem is, people have limited time, attention and accuracy—all of which means they are not very good at capturing data about things in the real world. ... We're physical, and so is our environment ... If we had computers that knew everything there was to know about things ... we would be able to track and count everything, and greatly reduce waste, loss and cost. We would know when things needed replacing, repairing or recalling, and whether they were fresh or past their best. The Internet of Things has the potential to change the world, just as the Internet did. Maybe even more so. — Kevin Ashton, 'That 'Internet of Things' Thing', RFID Journal, July 22, 2009
  • 37. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 37 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ Web Socket Based Communication Architecture Proxies: HTTP CONNECT – Tunnelling HTTP/S can be used WebSockets over SSL (wss:// scheme)
  • 38. IPT – Intellectual Products & Technologies Trayan Iliev, http://www.iproduct.org/ BG OUG Meeting – Hisarya June 13, 2014 Slide 38 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License Теория на игрите RoboCup 2013 – Eindhoven by Albert van Breemen [https://www.flickr.com/photos/robocup2013/10151792836] License: Attribution-NonCommercial-ShareAlike 2.0 Generic (CC BY-NC-SA 2.0) https://creativecommons.org/licenses/by-nc-sa/2.0/
  • 39. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 39 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ More Information about Java™ Robotics: https://github.com/iproduct/course-social- robotics/wiki/Study-Materials
  • 40. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 40 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ References Social Robotics Lectures (Github wiki) – https://github.com/iproduct/course-social-robotics/wiki/Lectures Iliev, T., Ontology Based Multi-Agent Architecture for Adaptive Courseware Delivery, Int. Workshop on Interactive Computer-aided Learning ICL'2003, Villach, Austria, September 24-26, 2003 Internet of Things (IoT) in Wikipedia – http://en.wikipedia.org/wiki/Internet_of_Things Brooks, R.: A robust layered control system for a mobile robot. IEEE Journal of Robotics and Automation, 2(1), 1986, pp. 14-23 Brooks, R., Intelligence without representation, Artificial Intelligence, 47, 1991, pp.139-159
  • 41. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 41 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ Thanks for Your Attention! Questions?
  • 42. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 42 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ PROGRAMMING PROJECTS
  • 43. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 43 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ LeJaRo: Follow The Line & Grasp That CUP Using LeJOS APIs program the robot to follow a white/color line. When reaching the end of the line LeJaRo should play a pre- programmed sound, go 8 cm further, and grasp the coffee cup placed there. Then the robot should turn back and go 40 cm strait, drop the coffee cup, and play another sound signaling the successful finishing of the task.
  • 44. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 44 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ IPTPI : Universal Soldier Program the robot to say welcome (GPIO, mplayer + ProcessBuilder) Read motor encoders data from Arduino A-Star Micro using USB serial and program a feedback loop to straighten the course. Read data from optical array to program robot to follow a line Read compass, accelerometer and gyroscope data (Pulolu MinIMU-9) and make the robot orient better
  • 45. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 45 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ Cocktail Maker: Make You Wish No Alcohol in FMI :) Assemble RPi2 / Arduino, low voltage pumps (3x), liquid flow- meters and hoses to a machine able to dose precisely 3 types of liquids Assemble breadboard with 3 MOSFET transistors (IRL 540N)
  • 46. IPT – Intellectual Products & Technologies Trayan Iliev, http://product.org/ http://robolearn.org/ RoboLearn Hackathon: IPTPI and LeJaRо meet the Real World - Sofia, Dec 04, 2015 Slide 46 Licensed under the Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License. In presentation are used materials from https://openclipart.org/ Make Two Wheels Rpi2 Robot from Scratch