Introduction: A Novel Design for Raspberry Pi Wireless Shield Extension Board

Picture of A Novel Design for Raspberry Pi Wireless Shield Extension Board

Recently, we design a type of raspberry pi wireless shield (or extension board) for raspberry pi. By using this rpi shield, you can conveniently control your objective, like LED, TANK, CAR, etc. In this example, by using this wireless shield, we control the LED lamp to breathe.

the video can be seen at: http://youtu.be/kgt7f3D9FCM

the rpi shield is at http://www.smartarduino.com/raspberry-pie-pi-rpi-wireless-shield-support-zigbee_p93897.html

Step 1: Main Functions

Picture of Main Functions

Main functions:

1. Support XBee low power wireless module, and the Bluetooth module with XBee interface;

2. Support NRF24L01/NRF24L01+ low power 2.4G wireless transceiver module;

3. Support RFM12B-D (315MHz, 433MHz, 868MHz, and 915MHz) wireless transceiver module;

4. Integrate RGB LED light, by the soft PWM of raspberry pi GPIO, can control the colors and brightness, also can control the colorful breathe lamp, together with the wireless module.

Step 2: Login Mobile

Picture of Login Mobile

let xbee wireless module connect to mobile, to make mobile control raspberry pi board

Step 3: Pc Control Raspberry Pi Board

Picture of Pc Control Raspberry Pi Board

let PC connect xbee wireless module to control raspberry pi board.

Step 4: Let the Lamp Breathe

Picture of Let the Lamp Breathe

then we can make the lamp breathe.

video: http://youtu.be/kgt7f3D9FCM

Step 5: Code

Picture of Code

import time

import RPi.GPIO as GPIO

GPIO.setwarnings(False)

GPIO.setmode(GPIO.BOARD)

GPIO.setup(15, GPIO.OUT)

GPIO.setup(16, GPIO.OUT)

GPIO.setup(18, GPIO.OUT)

RGB_R = GPIO.PWM(15, 50) # channel=15 frequency=50Hz

RGB_G = GPIO.PWM(16, 50) # channel=16 frequency=50Hz

RGB_B = GPIO.PWM(18, 50) # channel=18 frequency=50Hz

RGB_R.start(0)

RGB_G.start(0)

RGB_B.start(0)

try:

while 1:

for dc in range(0, 101, 5):

RGB_R.ChangeDutyCycle(dc)

time.sleep(0.1)

for dc in range(100, -1, -5):

RGB_R.ChangeDutyCycle(dc)

time.sleep(0.1)

for dc in range(0, 101, 5):

RGB_G.ChangeDutyCycle(dc)

time.sleep(0.1)

for dc in range(100, -1, -5):

RGB_G.ChangeDutyCycle(dc)

time.sleep(0.1)

for dc in range(0, 101, 5):

RGB_B.ChangeDutyCycle(dc)

time.sleep(0.1)

for dc in range(100, -1, -5):

RGB_B.ChangeDutyCycle(dc)

time.sleep(0.1)

for dc in range(0, 101, 5):

RGB_R.ChangeDutyCycle(dc)

RGB_G.ChangeDutyCycle(dc)

time.sleep(0.1)

for dc in range(100, -1, -5):

RGB_R.ChangeDutyCycle(dc)

RGB_G.ChangeDutyCycle(dc)

time.sleep(0.1)

for dc in range(0, 101, 5):

RGB_R.ChangeDutyCycle(dc)

RGB_B.ChangeDutyCycle(dc)

time.sleep(0.1)

for dc in range(100, -1, -5):

RGB_R.ChangeDutyCycle(dc)

RGB_B.ChangeDutyCycle(dc)

time.sleep(0.1)

for dc in range(0, 101, 5):

RGB_G.ChangeDutyCycle(dc)

RGB_B.ChangeDutyCycle(dc)

time.sleep(0.1)

for dc in range(100, -1, -5):

RGB_G.ChangeDutyCycle(dc)

RGB_B.ChangeDutyCycle(dc)

time.sleep(0.1)

for dc in range(0, 101, 5):

RGB_R.ChangeDutyCycle(dc)

RGB_B.ChangeDutyCycle(dc)

RGB_B.ChangeDutyCycle(dc)

time.sleep(0.1)

for dc in range(100, -1, -5):

RGB_R.ChangeDutyCycle(dc)

RGB_B.ChangeDutyCycle(dc)

RGB_B.ChangeDutyCycle(dc)

time.sleep(0.1)

except KeyboardInterrupt:

pass

p.stop()

GPIO.cleanup()

Comments

Gibo65 (author)2015-09-19

...on youtube link subst ) on 9 char! sorry :-|

Gibo65 (author)2015-09-19

Hi Nice! Is also interesting obtain python code of ZigBee Wireless Blueetooth HC-05 and NRF24L01 supported devices! Also RFM12B-D I don't know where connect it! I have only blinked LED1 and paired device but I don't am able to connect any BT device @ raspian S.O. (as BT keyboard or other devices) ;-)

https://www.youtube.com/watch?v=kgt7f3D)FCM&feature=youtu.be

Gibo65 (author)2015-09-19

About This Instructable

2,460views

21favorites

License:

Bio: Specializing in the OpenSource Hardware. skype: yichone
More by yichone:Make a Wireless Bluetooth/WiFi Robot Tank Car Chassis Based on ESP8266 and HC-06Mobile Robot Arm DoArm S7 by wifi Arduino uno r3Installation for DoArm S6
Add instructable to: