查看: 2343|回复: 1
收起左侧

[参考] Review of PiFace Digital

2014-11-6 14:02:25 | 显示全部楼层 |阅读模式
Evaluation Type: Evaluation Boards
Application you used the part in: Home Automation
Was everything in the box required?: Yes
Comparable Products/Other parts you considered: No one

Detailed Review:
First of all, sorry for my poor english!
Using the piFace for my project was incredible simple.
The board that element14 provided me for this road test is well engineered and simple to use.

IMG_20130426_164119.jpg

IMG_20130426_164545.jpg

But let me describe the project in detail.




The Project

TheProject.jpg


IMG_20130530_184532.jpg

IMG_20130530_192347.jpg

The project is an home alarm based on a Raspberry Pi as server, a PiFace Digital as the connection with the sensors.


These one are 15 PIR sensors (each one for monitoring a room). To be considered that the PiFace has only 8 free inputs, so for my definitive project i'll need on other board to be stacked.

I've also used the relay output in order to activate:

  • an alarm
  • a light

So this are the project parts:


1 x Raspberry PI

1 x PiFace Digital

15 x PIR Sensors (LHI778 probe) as the free inputs are only 8

1 x Alarm siren

1 x High efficiency lamp


For the road test I've used only 4 PIR sensors and the leds on the PiFace digital because this is only a proof of concept for the complete project.




The PIR sensors

These sensors come from China and are based on the LHI778 chip:


Probe LHI778, high sensitivity.

Technical parameters:

  • Operating voltage: DC5V to 20V
  • Static power consumption: 65 microamps
  • Level output: 3.3V, low 0V
  • Delay time: adjustable (0.3 seconds to 18 seconds)
  • Blockade Time: 0.2 seconds
  • Trigger Mode: L can not be repeated, H can be repeated default value H
  • Sensing range: less than 120 degree cone angle of less than 7 meters
  • Operating temperature: -15 to +70 degrees
  • PCB Dimensions: 32 * 24mm, screw hole distance 28mm, screw aperture 2mm sensor lens size: (diameter): 23mm (default)

Features:

  • automatic induction: when someone enters its sensing range input high, people leave the sensor range automatic delay off high. Output low.
  • photosensitive control (optional): module is reserved for the location, you can set the photosensitive control, daytime or light sensing. The photosensitive Control optional features not installed at the factory photoresistor. If necessary, please purchase separately photoresistor install it yourself.
  • 3.two trigger modes: L can not be repeated, H can be repeated. Jumper selectable, default is H.
  • A.not repeat the trigger mode: the sensor output high, the delay time has elapsed, the output automatically from high to low.
  • B.repeatable trigger mode: the sensor output high, the delay period, if human activities within its sensing range, the output will always remain high until people leave only delay the high level goes low (sensor module detected after every activity of the body's automatic postponed a delay period of time, and the last time activities as the starting point of the delay time).
  • 4.induced blockade time (default setting: 0.2 seconds): sensing module in every sensor output (high to low) followed by set up a blockade of the time, in this period of time the sensor is not receiving any induction signal. This feature can be achieved both of the (inductive output time and the blocking time) interval can be applied to the interval detection products; This feature can effectively suppress the various interference generated in the process of load switching.
  • 5.wide operating voltage range: default Voltage DC5V to 20V
  • 6.micro-power: quiescent current of 65 microamps, particularly suitable for battery-powered electrical products.
  • 7.output high signal: easy to achieve docking with the various types of circuits.

IMG_20130530_184134.jpg

IMG_20130530_184218.jpg

Picture3.jpg



The Realization


The realization was incredible fast and funny.

The first step was to update Raspian Weezy software according to the instruction found here: http://www.farnell.com/datasheets/1684425.pdf

After this I'had to wire all the PIR sensors contact in order to enable the alarm.

The connection with the board was very easy because of the screw connectors.

In my case I had to wire the +5V on the output connectors and the GND on the inputs.

IMG_20130606_180026.jpg

IMG_20130606_173006.jpg


The Code


Coding the application is very simple.

Just a consideration about the sensor.

The PiFace input should be gorunded when the buttons are pressed, but the high level of the sensor output is 3.3V.

So I've to revert the logic inside the program.

The power of the PiFace is the coding: few rows of code and here is an alarm application!


Good


# Alarm program by Francesco Balsamo

#

# Using a PIR sensor with inverted logic

#

from time import sleep

import piface.pfio as pfio

pfio.init()

while(True):

        for pin_number in range(0,4):

                if pfio.digital_read(pin_number) == 0:

                        pfio.digital_write(pin_number+4,1) # Using only the leds

                else:

                        pfio.digital_write(pin_number+4,0) # Disabling only the leds



Conclusions

Using the PiFace Digital for my project was very simple and funny since I needed only a screwdriver, some cabling and few rows of code.

Finally, I really like the board and how it is realized.

I think that this board is fantastic and it will be the core of many projects that I've in mind for automatize my house.



回复

使用道具 举报

2015-7-27 15:50:03 | 显示全部楼层
呵呵,谢谢楼主了~~~~~~~~~~~












回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

关注我们,了解更多

官方微信

服务时间:10:00-16:00

13714503811

公司地址:深圳市龙岗区南湾街道东门头路8号

Copyright © 2012-2020 Powered by 树莓派论坛 2019.4  粤ICP备15075382号-1
快速回复 返回列表 返回顶部