Wireless Sensor Networks Author: Matthias Wagner / Albert Martinez - - PowerPoint PPT Presentation

wireless sensor networks
SMART_READER_LITE
LIVE PREVIEW

Wireless Sensor Networks Author: Matthias Wagner / Albert Martinez - - PowerPoint PPT Presentation

Wireless Sensor Networks Author: Matthias Wagner / Albert Martinez M. Schubert, OTH Regensburg, Germany Course structure 1.#lecture# 2.#lecture# 3.#lecture# Clock,# SimpliciTI# RF#basics# GPIO,Timer# protocol# Data# storage,#


slide-1
SLIDE 1

Wireless Sensor Networks

Author: Matthias Wagner / Albert Martinez

  • M. Schubert, OTH Regensburg, Germany
slide-2
SLIDE 2

Course structure

1.#lecture#

Clock,# GPIO,Timer# SPI,#UART#

2.#lecture#

RF#basics# MRFI#chat#

3.#lecture#

SimpliciTI# protocol#

Data# storage,#

Project#

WSN || Matthias Wagner 2

slide-3
SLIDE 3

WSN || Matthias Wagner 3

WSN: Timetable 2015

Nr: 1 2 3 4 5 6 7 8 9 10 11 date: 18.03.15 26.03.15 01.04.15 08.04.15 15.04.15 22.04.15 29.04.15 06.05.15 13.05.15 20.05.15 27.05.15

Room: S159 S081 group

1: 2: 1: 2: 1: 2: 1: 2: 1: 2: 1: 2: 1: 2: 1: 2: 1: 2: 1: 2: 11:45 - 13:15 13:30 - 15:00

9 10 5 6 7 8 1 2 3 4

Exam

Q&A project Intro practical training 3 address transmiss ion Non volatile

  • bjects

peer to peer Non volatile

  • bjects

Range extender Intro WSN Intro practical Intro practical training 2 Intro practical

Exam

part 1 part 2 part 3 Intro WSN team up Intro practical training 1 Clocks GPIO Flash First steps / project setup ADC Timer UART SPI Intro practical training 2 MRFI LQI MRFI CRC RSSI Simple Chat

name poject

slide-4
SLIDE 4

Project

  • Group of 2 – 4 students
  • Minimun of two MSP430 boards
  • Documentation + Code
  • Presentation

WSN || Matthias Wagner 4

slide-5
SLIDE 5

Wireless sensor networks (WSN)

A Wireless sensor network (WSN) can be defined as a network of devices, denoted as nodes, which can sense the environment and communicate the information gathered from the monitored field (e.g., an area or volume) through wireless links

Chiara Buratti, Andrea Conti, Davide Dardari and Roberto Verdone 2009 ISSN 1424-8220

slide-6
SLIDE 6

http://www.libelium.com/wp-content/themes/libelium/images/content/applications/libelium_smart_world_infographic_big.png

slide-7
SLIDE 7

! Environment#

! Air#and#water#quality# ! Sea#temperature# ! ErupLon#monitoring#

! Health#Care#

! Blood#glucose# ! Heart#rate#

Applications

! Commercial#use#

! Customer#tracking# ! AdverLsement#

! Home#Intelligence#

! Smart#Home# ! Light#sensor#/#switch#(WSAN)#

! Military#

WSN || Matthias Wagner 8

slide-8
SLIDE 8

Sensor Module / Node

Battery Sensor ADC / Digital Bus Microcontroller Memory RAM / SD Radio Sensing Unit Processing Unit Communication Unit Power Unit

WSN || Matthias Wagner 9

slide-9
SLIDE 9

Network

WSN || Matthias Wagner 10

slide-10
SLIDE 10
  • CC430F6137
  • microSD card
  • UART
  • SPI
  • push button

CC430 target board

WSN || Matthias Wagner 11

slide-11
SLIDE 11
  • 16 bit Microcontroller
  • 20 MHz maximal frequency
  • 32 kB of Flash memory
  • 4 kB RAM
  • 44 GPIO
  • 2x 16 bit Timers
  • 10 and 12 bit ADC
  • 128 Bit AES Security Encryption Coprocessor
  • Communication via UART, SPI and I2C

CC430F6137

WSN || Matthias Wagner 12

slide-12
SLIDE 12
  • sub 1 GHz Transceiver
  • 300 – 928 MHz Freqency band
  • Programmable data rate from 0.6 to 600 kbps
  • Low power consumption (14.7 mA

in RX mode)

  • High Sensitivity

Integrated CC1101

WSN || Matthias Wagner 13

slide-13
SLIDE 13
  • Active mode:
  • LPM0:

SMCLK and ACLK active. CPU and MCLK disabled

  • LPM1:

ACLK is active. CPU, MCLK are disabled. SMCLK depend

  • LPM2:

DC generator and ACLK active. CPU, MCLK, SMCLK, DCO are disabled

  • LPM3:

ACLK active. CPU, MCLK and SMCLK disabled

  • LPM4:

CPU and all clocks disabled

Low Power Modes

WSN || Matthias Wagner 14

slide-14
SLIDE 14
  • Universal Serial Communication Interface (USCI)
  • Synchronous communication

SPI and I2C

WSN || Matthias Wagner 15

slide-15
SLIDE 15

UART

!

  • USB Serial Adapter
  • Terminal program

WSN || Matthias Wagner 16

  • Universal Asynchronous Receiver Transmitter
  • Asynchronous communication
slide-16
SLIDE 16

WSN || Matthias Wagner 17

Wireless data transmission

Data transmission via electromagnetic radioation

slide-17
SLIDE 17

WSN || Matthias Wagner 18

isotropic radiator

slide-18
SLIDE 18

WSN || Matthias Wagner 19

Free-space path loss

slide-19
SLIDE 19

WSN || Matthias Wagner 20

Received energy

1 10 100 1⋅10-8 1⋅10-7 1⋅10-6 1⋅10-5 1⋅10-4 0,001 0,01 0,1

433 MHz 915 MHz 2.4 GHz

slide-20
SLIDE 20

WSN || Matthias Wagner 21

Signal modulation

OOK : On Off keying AM: Amplitude modulation FM: Frequency modulation

slide-21
SLIDE 21

WSN || Matthias Wagner 22

2-FSK: Frequency Shift keying

4-FSK, GFSK

MSK: Minimum Shift keying

QAM, FSK, ASK

slide-22
SLIDE 22

WSN || Matthias Wagner 23

base frequency bands

ISM SRD

Industrial, Scientific and Medical Band 433 MHz Region 1 (Europa, Africa) 902 MHz Region 2 (America) 2,4 GHz Short Range Devices 433 MHz 868 MHz some ranges at 2,45 GHz (typically limited to 25-100 mW ERP)

slide-23
SLIDE 23

WSN || Matthias Wagner 24

slide-24
SLIDE 24

SimpliciTI

  • handling network traffic
  • routing/forwarding messages
  • data encryption
  • CRC
  • data whitening

RF protocol for MSP430 microcontrollers

WSN || Matthias Wagner 25

slide-25
SLIDE 25

Topologies:

  • Peer-to-Peer
  • Star Topology

Types of devices:

  • Access Point (AP)
  • End Device (ED)
  • Range Extender (RE)

Architecture

WSN || Matthias Wagner 26

slide-26
SLIDE 26

SimpliciTI Layers vs OSI

WSN || Matthias Wagner 27

!

slide-27
SLIDE 27

http://www.inetdaemon.com/tutorials/basic_concepts/network_models/osi_model/osi_and_internet_protocols.shtml 28

slide-28
SLIDE 28
  • Board Support Package (BSP): minimal

support to a specific microcontroller

  • Minimal RF Interface (MRFI):

communication with the radio chip

Data Link/Physical layer

WSN || Matthias Wagner 29

slide-29
SLIDE 29

Transmission Frequencies

WSN || Matthias Wagner 30

821 819,9 820 820,1 820,2 820,3 820,4 820,5 820,6 820,7 820,8 820,9 MHz Power channel spacing 1 2 3 4 base freq. : 820MHz

RF Transmission Frequencies

slide-30
SLIDE 30

!

WSN || Matthias Wagner 31

Power settings

slide-31
SLIDE 31
  • Detect accidental change of data during transmission
  • A short check value gets attached to the message
  • The attached value is the remainder of a polynomial

division

Cyclic Redundancy Check (CRC)

WSN || Matthias Wagner 32

slide-32
SLIDE 32
  • Indicates the power received in a transmission
  • The MRFI_Rssi() function provides the RSSI value
  • Often used to detect the noise in a specific channel

Received Signal Strength Indicator (RSSI)

WSN || Matthias Wagner 33

slide-33
SLIDE 33

Algorithm to minimize collisions between radios:

  • Check a channel for a very shot time
  • Compare the noise in the channel with the noise of a

transmission

  • If there is no transmission in this channel send the data
  • If the channel is occupied then wait for a while and

repeat the process

Clear Channel Assessment (CCA)

WSN || Matthias Wagner 34

slide-34
SLIDE 34
  • mrfiPacket_t

mrfiPacket_t : is a structure which contains two type definitions a) a) Packet.frame Packet.frame: frame of data b) b) Packet.rxMetrics Packet.rxMetrics: statistics on the last received packet

MRFI frame

WSN || Matthias Wagner 35

  • void MRFI_RxCompleteISR()

void MRFI_RxCompleteISR(): received packet interrupt

Length (1B) Source (4B) Destination (4B) Payload (Length-8 bytes long) RSSI (1B) CRC (1b) LQI (7b)

slide-35
SLIDE 35
  • BSP_INIT(void)
  • BSP_Delay(uint16_t usec)
  • BSP_EARLY_INIT(void)
  • MRFI_Init(void)
  • MRFI_Transmit(mrfiPacket_t * pPacket, uint8_t txType)
  • MRFI_Receive(mrfiPacket_t * pPacket)
  • Mrfi_RxModeOn(void)
  • MRFI_RxOn(void)

API of Data Link/Physic Layer

WSN || Matthias Wagner 36

slide-36
SLIDE 36
  • Mrfi_RxModeOff(void)
  • MRFI_RxIdle(void)
  • MRFI_Sleep(void)
  • MRFI_WakeUp(void)
  • int8_t MRFI_Rssi(void)
  • uint8_t MRFI_RandomByte(void)
  • Mrfi_DelayUsec(uint16_t howLong)
  • MRFI_GetRadioState(void)

API of Data Link/Physic Layer

WSN || Matthias Wagner 37

slide-37
SLIDE 37
  • NWK: connecting two different peers and

selecting the proper route

  • APP NWK: manage network as an internal

peer to peer object

NWK Layer

WSN || Matthias Wagner 38

slide-38
SLIDE 38

39

SimpliciTI frame

PREAMBLE Radio synchronization PORT Forwarded frame (7), Encryption context (6) Application port number (5-0 SYNC Radio synchronization DEVICE INFO Sender/receiver and platform capabilities LENGTH Length of remaining packet in bytes TRACTID Transaction id MISC Miscellaneous frame fields APP PAYLOAD Application data DST ADDR Destination address FCS Frame Check Sequence SRCADDR Source address

WSN || Matthias Wagner

slide-39
SLIDE 39

WSN || Matthias Wagner 40

secure SimpliciTI frame

slide-40
SLIDE 40
  • SMPL_Init
  • SMPL_Link
  • SMPL_Unlink
  • SMPL_LinkListen
  • SMPL_Send
  • SMPL_SendOpt
  • SMPL_Receive
  • SMPL_Ping

API of NWK

WSN || Matthias Wagner 41

slide-41
SLIDE 41

SMPL_Ioctl: change configuration parameters while run time

  • Frequency
  • Radio
  • Encryption
  • Access to current connection
  • Firmware and protocol characteristics
  • AP nwk mgmt control

API of NWK

WSN || Matthias Wagner 42