Sun SPOT, Wireless Sensors Networks

download Sun SPOT, Wireless Sensors Networks

If you can't read please download the document

description

Introducción a las redes de sensores inlámbricos (WSN) y estudio particular de la solución Sun Spot de ORACLE.

Transcript of Sun SPOT, Wireless Sensors Networks

  • 1. Sun SPOT Wireless Sensors Networks Jos Jaime Ariza ISIS group (University of Mlaga) Slideshare version, original version at http://jariza.net/ponencias.

2. 1. SENSORS NETWORKS 3. 1. SENSORS NETWORKS 4. 1. SENSORS NETWORKS 5. 1. SENSORS NETWORKS Applications Air pollution. Forest fire detection. Water monitoring. Agriculture. Structural monitoring. Enviromental sensing. Machine monitoring. Etc... 6. 1. SENSORS NETWORKS Gateway Sensor node Sensor node Sensor node Sensor node Sensor node Sensor node Sensor node 7. 1. SENSORS NETWORKS Requirements Wireless communications. Low power consumption. Easy deployment. Sensors. Heterogeneous network. 8. 2. COMMUNICATIONS A sensor may use a communication device to connect to a network, but it is of key importance that devices speak a common language. 9. 2. COMMUNICATIONS ISO standarizes the different communication levels of devices, so that they can understand each other. WIRELESS PERSONAL AREA NETWORKS (WPAN) WIRELESS LOCAL AREA NETWORKS (WPAN) 10. 2. COMMUNICATIONS ISO standarizes the different communication levels of devices, so that they can understand each other. 11. 2. COMMUNICATIONS ISO standarizes the different communication levels of devices, so that they can understand each other. 12. 2. COMMUNICATIONS ISO standarizes the different communication levels of devices, so that they can understand each other. Security (authentication and privacy) Hardware interfacing 13. 2. COMMUNICATIONS ISO standarizes the different communication levels of devices, so that they can understand each other. Fixed network 14. 2. COMMUNICATIONS ISO standarizes the different communication levels of devices, so that they can understand each other. Mobile network 15. 2. COMMUNICATIONS ISO standarizes the different communication levels of devices, so that they can understand each other. Mobile network 16. 2. COMMUNICATIONS For wireless sensor implementation there are several technologies... 17. 2. COMMUNICATIONS For wireless sensor implementation there are several technologies... ZigBee (WPAN) Bluetooth (WLAN/WPAN) Wi-Fi (WLAN) 802.15.4 250 kbps TX: 35mA Standby: 3A 32-60 kB memory Sensors, remote control... Mesh, P-P, P-M. 802.15.1 1 Mbps TX: 40mA Standby: 200A 100+ kB memory Telecom, audio... P-M. 802.11 300Mbps TX: > 400mA Standby: 20mA 100+ kB memory Internet... P-M 18. 2. COMMUNICATIONS For wireless sensor implementation there are several technologies... 19. 3. WIRELESS SENSORS Sensor, processing and communication units can be packed into a tight, cheap and low power circuit. 20. 3. WIRELESS SENSORS Any sensor can connect to a WPAN and, through it, to any other wireless network, like mobile phones, laptops, PDAs, etc. 21. 4. Sun SPOT Sun Small Programmable Object Technology Java platform for developing applications for wireless sensors 22. 4. Sun SPOT 314,93 23. 4. Sun SPOT Gateway Mota 24. 4. Sun SPOT Processor Board Core CPU: ARM9, 32bit, 400Mhz. RAM: 1Mb Flash: 8Mb Radio: 2.4 Ghz 802.15.4. USB interface. 3 serial lines. 770 mAh L-ion battery. Deep sleep: 40A/65A Temperature sensor. 25. 4. Sun SPOT Sensor Board ATmega microcontroller. 4 digital GPIO. 4 analog GPIO and ADC. Tri-color light sensor. 2/4/8G 3-axis accelerometer. I2C. Speaker. IR receiver & IR transmitter. 8 RGB LEDs. 2 switches. 26. 4. Sun SPOT Software Virtual Marchine Squawk VM (J2ME CLDC 1.1). Memory protection (bad code). Security protection (malicious code). Programming with... Java. Netbeans. SunSPOT SDK. 27. 4. Sun SPOT Communications Wireless 802.15.4 +250Kbps ZigBee support Topologies: adhoc, mesh, cluster tree, star. Wired USB 28. 4. Sun SPOT Sqwak VM Mainly written in Java. Runs on ARM9 without underlying OS. Drivers written in Java. Open Source. Isolate application model. 29. 4. Sun SPOT Build and deploy flow Javac Java source Squawk suit converter SunSPOT Build 30. 4. Sun SPOT Sqwak split VM 31. 4. Sun SPOT SunSPOT SDK Squawk Java VM: Desktop and Sun SPOT Libraries Java ME CLDC 1.1 libraries Hardware libraries SPI, PIO... (drivers written in Java) Demo sensor board library Wireless layer libraries Network layer libraries 802.15.4 MAC (layer written in Java) 32. 4. Sun SPOT Code spnippet: send broadcast try { dgConnection = (DatagramConnection) Connector.open("radiogram://broadcast:37"); dg = dgConnection.newDatagram(dgConnection.getMaximumLength()); dg.reset(); dg.writeUTF("I rock"); dgConnection.send(dg); } catch (IOException ex) { //Catch code } 33. 4. Sun SPOT Code spnippet: receive broadcast try { dgConnection = (RadiogramConnection) Connector.open("radiogram://:37"); dg = dgConnection.newDatagram(dgConnection.getMaximumLength()); } catch (IOException e) {/*Catch code*/} while(true){ try { dg.reset(); dgConnection.receive(dg); tmp = dg.readUTF(); } catch (IOException e) {/*Catch code*/} } 34. 4. Sun SPOT Code spnippet: sensors reading ILightSensor lightSensor = (ILightSensor) Resources.lookup(ILightSensor.class); min = ((IMeasurementInfo)lightSensor).getMinValue(); max = ((IMeasurementInfo)lightSensor).getMaxValue(); lightLevel = lightSensor.getAverageValue(); 35. 4. Sun SPOT Code spnippet: outputs ITriColorLEDArray leds = (ITriColorLEDArray) Resources.lookup(ITriColorLEDArray.class); leds.getLED(0).setOff(); leds.getLED(0).setColor(LEDColor.BLUE); leds.getLED(0).setOn(); leds.getLED(3).setRGB(0, 0, 0); speaker = (IToneGenerator) Resources.lookup(IToneGenerator.class, "speaker"); speaker.startTone(freq); speaker.stopTone(); 36. Thank you Any question?