Your SlideShare is downloading. ×
Versuch 3 mel-p_so_c-cy3271-good
Versuch 3 mel-p_so_c-cy3271-good
Versuch 3 mel-p_so_c-cy3271-good
Versuch 3 mel-p_so_c-cy3271-good
Versuch 3 mel-p_so_c-cy3271-good
Versuch 3 mel-p_so_c-cy3271-good
Versuch 3 mel-p_so_c-cy3271-good
Versuch 3 mel-p_so_c-cy3271-good
Versuch 3 mel-p_so_c-cy3271-good
Versuch 3 mel-p_so_c-cy3271-good
Versuch 3 mel-p_so_c-cy3271-good
Versuch 3 mel-p_so_c-cy3271-good
Versuch 3 mel-p_so_c-cy3271-good
Versuch 3 mel-p_so_c-cy3271-good
Versuch 3 mel-p_so_c-cy3271-good
Versuch 3 mel-p_so_c-cy3271-good
Versuch 3 mel-p_so_c-cy3271-good
Versuch 3 mel-p_so_c-cy3271-good
Versuch 3 mel-p_so_c-cy3271-good
Versuch 3 mel-p_so_c-cy3271-good
Versuch 3 mel-p_so_c-cy3271-good
Versuch 3 mel-p_so_c-cy3271-good
Versuch 3 mel-p_so_c-cy3271-good
Versuch 3 mel-p_so_c-cy3271-good
Versuch 3 mel-p_so_c-cy3271-good
Versuch 3 mel-p_so_c-cy3271-good
Versuch 3 mel-p_so_c-cy3271-good
Versuch 3 mel-p_so_c-cy3271-good
Versuch 3 mel-p_so_c-cy3271-good
Versuch 3 mel-p_so_c-cy3271-good
Versuch 3 mel-p_so_c-cy3271-good
Upcoming SlideShare
Loading in...5
×

Thanks for flagging this SlideShare!

Oops! An error has occurred.

×
Saving this for later? Get the SlideShare app to save on your phone or tablet. Read anywhere, anytime – even offline.
Text the download link to your phone
Standard text messaging rates apply

Versuch 3 mel-p_so_c-cy3271-good

171

Published on

Published in: Business, Technology
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total Views
171
On Slideshare
0
From Embeds
0
Number of Embeds
0
Actions
Shares
0
Downloads
5
Comments
0
Likes
0
Embeds 0
No embeds

Report content
Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
No notes for slide

Transcript

  • 1. 1 LEHRSTUHL FÜR INTEGRIERTE SENSORSYSTEME Prof. Dr.-Ing. Andreas König Dr.-Ing. Senthil Kumar Lakshmanan C. Bambang Dwi Kuncoro, M.Sc VERTIEFUNGSLABOR MIKROELEKTRONIK Versuch 3 RECONFIGURABLE WIRELESS SENSOR SYSTEMS AND NETWORks TECHNISCHE UNIVERSITÄT KAISERSLAUTERN
  • 2. 2 Contents 1. Aim 3 2. Introduction 3 2.1 Wireless Sensor Network ............................................................................................ 3 2.2 Sensor Node................................................................................................................. 5 2.3 System-on-Chip (SoC)................................................................................................. 6 2.4 Programmable System on Chip (PSoC) .................................................................... 6 3. CY3271- PSoC Kit with CyFiTM Low Power RF - Cypress Semiconductors 8 3.1 Hardware Components of the CY3271 ..................................................................... 8 3.1.1 PC Bridge........................................................................................................... 8 3.1.2 RF Expansion Card........................................................................................... 8 3.1.3 MultiFunction Expansion Card ......................................................................... 8 3.2 Software Components of the CY3271...................................................................... 10 3.2.1 PSoC Designer................................................................................................ 10 3.2.2 PSoC Programmer.......................................................................................... 11 3.2.3 Sense and Control Dashboard (SCD)........................................................... 11 3.3 Ultra Low Power Wireless Temperature Sensor ..................................................... 11 3.4 MultiFunction Expansion Card CapSense Slider .................................................... 14 3.5 Wireless Expansion Kit – (CY3271-EXP1) .............................................................. 15 3.5.1 Pigtail Thermistor Expansion Board .............................................................. 15 3.5.2 Weather Station Expansion Board ................................................................ 16 4. Energy Scavenging / Harvesting 18 5. Binder: Environmental Test Chamber 20 6. Basic Principles of Measurement using Wheatstone Bridge and Instrumentation Amplifier ……………………………………………………………………………………...21 6.1 PSoC Implementation................................................................................................ 24 6.1.1 Reading the Differential Value ....................................................................... 26 6.2 The Wheatstone bridge circuit .................................................................................. 27 7. Tasks 29 8. Acknowledgement 30 9. Reference 31
  • 3. 3 1. Aim Embedded systems, in cooperation with ever increasing variety of sensors, are ubiquitous in industry and daily life. From smart house hold appliances, e.g., washing or coffee machines, to automotive or medical applications such systems can be found. The large variety of products combined with small to moderate lot sizes requires in numerous applications more flexibility than can be obtained from systems compiled from off-the-shelf components, whereas dedicated implementations, e.g., ASICs will not pay of. Here, reconfigurable systems based on repeatedly programmable structures come and offer the required flexibility. Established Field-Programmable-Gate-Arrays (FPGA) today is complemented by programmable analog arrays in embedded systems. The capability to rapidly and flexibly change the analog processing part, too, supports efficient application development and revision. Compact embedded systems can be achieved by System-on- Chip (SoC) integration, which includes analog parts for sensing, digital computation parts, and power electronics for actuator control. Further, MEMS technology also allows to take sensors and potentially actuators on board. The lab was conceived to familiarize with the basic concept by a commercial Programmable SoC that offers analog and digital programmability or reconfigurability. The Cypress PSoC chips are used in several roles in the applied lab modules. (Most recently, PowerPSoC has been added to the family, which will see later lab integration.) The focus of the PSoC application here is in the context of Wireless Sensor Networks (WSN). Such networks of wirelessly connected cooperating nodes, e.g., the well known MICA motes, with one or several sensors each find more and more widespread application from environmental or aggricultural monitoring, reconnaissance and surveillance, automation and control, to home automation and ambient intelligence. A particular challenge in these systems is the energy supply due to limited battery capacities. Energy harvesting, e.g., exploiting heat differences based on Peltier elements, will be part of the lab considerations. This exercise will provide the opportunity to acquaint the participants with the above named technologies by establishing and applying a wireless sensor network based on cypress semi-conductors PSoC and CY3271 Kit. In the wake of the lab the participants will reconfigure the constituting PSoC units initially through pre-defined configuration patterns required for various sensing applications. A Micropelt thermoelectric generator will be regarded as potential WSN node energy resource by thermal energy harvesting. 2. Introduction 2.1Wireless Sensor Network A wireless sensor network (WSN) is a wireless network consisting of spatially distributed autonomous devices using sensors to cooperatively monitor physical or environmental conditions, such as temperature, sound, vibration, pressure, motion or pollutants, at different locations as shown in Figure 2-1. The development of wireless sensor networks was originally motivated by military applications. However, wireless sensor networks are now used in many industrial and civilian application areas, including industrial process monitoring and control, machine health monitoring, environment and habitat monitoring, healthcare applications, home automation, and traffic control. In a typical application, a WSN is scattered in a region where it is meant to collect data through its sensor nodes
  • 4. 4 Some challenges of a WSN are listed below: Limited power they can harvest Ability to withstand harsh environmental conditions Ability to cope with node failures Mobility of nodes Dynamic network topology Heterogeneity of nodes Large scale of deployment Several standards are currently either ratified or under development for wireless sensor networks. ZigBee is a mesh-networking standard intended for uses such as embedded sensing, medical data collection, consumer devices like television remote controls, and home automation. WirelessHART is an extension of the HART Protocol and is specifically designed for Industrial applications like Process Monitoring and Control. Also relevant to sensor networks is the emerging IEEE 1451 which attempts to create standards for the smart sensor market. The main point of smart sensors is to move the processing intelligence closer to the sensing device. Figure 2-1. Block diagram of a wireless sensor network with its constituiting sensor node architecture
  • 5. 5 2.2Sensor Node A sensor node, is a node in a wireless sensor network that is capable of performing some processing, gathering sensory information and communicating with other connected nodes in the network. In other words sensor nodes are the building blocks for a sensor network. Some commercially available sensor nodes are Mica, BTnode, EPIC mote etc. The main components of a sensor node are microcontroller, transceiver, external memory, power source and one or more sensors as shown in Figure 2-1. Microcontroller Microcontroller performs tasks, processes data and controls the functionality of other components in the sensor node. Other alternatives that can be used as a controller are: General purpose desktop microprocessor, Digital signal processors, Field Programmable Gate Array and Application-specific integrated circuit. Microcontrollers are most suitable choice for sensor node. Each of the four choices has their own advantages and disadvantages. Microcontrollers are the best choices for embedded systems. Because of their flexibility to connect to other devices, programmable, power consumption is less, as these devices can go to sleep state and part of controller can be active. There are wide range of microcontrollers available in the market, some of them are from Atmel, Texas Instruments, Motorola etc. In general purpose microprocessor the power consumption is more than the microcontroller, therefore it is not a suitable choice for sensor node. Digital Signal Processors are appropriate for broadband wireless communication. But in Wireless Sensor Networks, the wireless communication should be modest i.e., simpler, easier to process modulation and signal processing tasks of actual sensing of data is less complicated. Therefore the advantages of DSP's is not that much of importance to wireless sensor node. Field Programmable Gate Arrays can be reprogrammed and reconfigured according to requirements. Application Specific Integrated Circuits are specialized processors designed for a given application. ASIC's provide the functionality in the form of hardware, but microcontrollers provide it through software. Transceiver The various choices of wireless transmission media are Radio frequency, Optical communication (Laser) and Infrared. Laser requires less energy, but needs line-of-sight for communication and also sensitive to atmospheric conditions. Infrared like laser, needs no antenna but is limited in its broadcasting capacity. Radio Frequency (RF) based communication is the most relevant that fits to most of the WSN applications. The functionality of both transmitter and receiver are combined into a single device know as transceivers are used in sensor nodes. In this exercise, we will be performing our experiments with one such commercially available kit (with CyFiTM -low power RF). External Memory From an energy perspective, the most relevant kinds of memory are on-chip memory of a microcontroller and FLASH memory. Flash memories are used due to its cost and storage capacity. Memory requirements are very much application dependent.
  • 6. 6 Power Source Power consumption in the sensor node is for the Sensing, Communication and Data Processing. More energy is required for data communication in sensor node. Energy expenditure is less for sensing and data processing. The energy cost of transmitting is normally high compared to the other, namely sensing and data processing. Batteries are the main source of power supply for sensor nodes. Two major power saving policies used are Dynamic Power Management (DPM) and Dynamic Voltage Scaling (DVS). DPM takes care of shutting down parts of sensor node which are not currently used or active. DVS scheme varies the power levels depending on the non-deterministic workload. By varying the voltage along with the frequency, it is possible to obtain quadratic reduction in power consumption. Other power harvesting methods include vibration power harvesting, solar power harvesting, or piezoelectrinc power harvesting etc. Sensors Sensors are hardware devices that produce measurable response to a physical condition like temperature and pressure. Sensors sense or measure physical data of the area to be monitored. The continual analog signal sensed by the sensors is digitized by an anlog to digital converter and sent to controllers for further processing in recent applications. Characteristics and requirements of Sensor node should be small size, consume extremely low energy, operate in high volumetric densities, and be adaptive to the environment. Some sensors that will be deployed for measurement in this exercise are temperature sensor, ambient light sensor, pressure sensor, humidity sensor, and capacitive sensor. 2.3System-on-Chip (SoC) System-on-a-chip or system on chip (SoC or SOC) refers to integrating all components of a computer or other electronic system into a single integrated circuit (chip). It may contain digital, analog, mixed-signal, and often radio-frequency functions – all on one chip. A typical application is in the area of embedded systems. 2.4Programmable System on Chip (PSoC) PSoCTM (Programmable System-on-Chip) is a family of mixed-signal arrays made by Cypress Semiconductor, featuring a microcontroller and configurable integrated analog and digital peripherals. PSoC is a software configured, mixed-signal array with a built-in MCU core. PSoC resembles an ASIC in its flexibility and integration: blocks can be assigned a wide range of functions and interconnected on-chip. Unlike an ASIC, there is no special manufacturing process required to create the custom configuration - only startup code that is created by Cypress' PSoC Designer IDE. PSoC resembles an FPGA in that at power up it must be configured, but this configuration occurs by loading instructions from the built-in Flash memory. Unlike an FPGA, the current generation of PSoC cannot have its digital functions reprogrammed by VHDL or Verilog, it can only be configured with register settings. PSoC most closely resembles a microcontroller in usage, where code is executed to interact with the user-specified peripheral functions called "User Modules". The PSoC Designer IDE generates the startup configuration code and peripherals automatically based upon the users selections in a visual-studio-like GUI.
  • 7. 7 Cypress offers a visual, code-free embedded design tool for PSoC called PSoC Express. Using PSoC Express, most features of the PSoC can be accessed with drag and drop icons and logical expressions. The visual design is compiled to executable code without exposing the user to the underlying converted code, though a visual design can be converted and used as a basis of a traditional code-based design in PSoC Designer. Visual design elements cover features such as temperature sensors, capacitive sensors, and wireless 2.4 GHz radio communications. The Core, Configurable Analog and Digital Blocks, and the Programmable Routing and Interconnect. Configurable blocks are at the heart of PSoC’s flexibility. PSoC devices include up to 16 digital and 12 analog blocks, depending on the device. Using configurable analog and digital blocks, designers can create and quickly change advanced mixed-signal embedded applications. There are two types of digital blocks, Digital Building Blocks (DBBxx) and Digital Communication Blocks (DCBxx). Only the communication blocks can contain serial I/O user modules, such as SPI, UART etc.Each digital block is considered a 8-bit resource that designers can configure using pre-built digital functions or user modules (UM), or, by combining blocks, turn them into 16-, 24-, or even 32-bit resources. Concatenating UMs together is how 16bit PWMs and timers are created. There are two types of analog blocks. The continuous time (CT) blocks are composed of an op-amp circuit and designated as ACBxx where xx is 00-03. The other type is the switch cap (SC) blocks, which allow complex analog signal flows and are designated by ASCxy where x is the row and y is the column of the analog block. Designers can modify and personalize each module to any design. Figure 2-2 shows the architectural block diagram of PSoC. Video in reference [7] shows how the CyFi low power RF wireless solutions are used to monitor a winery from a single computer. Figure 2-2. PSoC Architectural block diagram [5]
  • 8. 8 3. CY3271- PSoC Kit with CyFiTM Low Power RF - Cypress Semiconductors (The figures used in this section are taken from the documents of Cypress semiconductors listed in the reference section) 3.1Hardware Components of the CY3271 [6] The CY3271 kit hardware consists of several boards: 3.1.1 PC Bridge The PC Bridge can be used to Program all PSoC devices in the CY3271 kit. It act as a bridge between all boards in the CY3271 system for different application and the PC, using a USB-to-I2C interface. It contains a 16-pin connector to connect to the RF Expansion Board or theMultiFunction board, for application data exchange in one side and a USB connection on the other side of the board as shown in Figure 3-1. It has a CyFi low-power RF transceiver (2.4 GHz). When this is combined with an onboard PSoC, it acts as the Hub in CyFi wireless networks. Figure 3-1. PC Bridge 3.1.2 RF Expansion Card The RF Expansion Card features a PSoC device and a CyFi transceiver similar to the PC bridge. It can be be combined with the power packs (battery board) to act as a standalone CyFi wireless node with an onboard thermistor for temperature measurements. With its female expansion connector, it can be used as a CyFi low-power RF module to add wireless connectivity to boards that are connected to it. For example, connecting the MultiFunction Expansion Card (more details explained in next section) into the RF Card enables you to wirelessly transmit the values of the sensors to the PC. Figure 3-2 shows the RF expansion kit. 3.1.3 MultiFunction Expansion Card The MultiFunction Expansion Card features a PSoC device, and several sensors and actuators that enable easy experimentation. A 7-element CapSense slider, CapSense
  • 9. 9 proximity sensor (requires use of the blue proximity antennae), Thermistor, Ambient light level sensor, and Red or green or blue triple LED cluster. Figure 3-3 shows the MultiFunction expansion card. Figure 3-2. RF Expansion board Figure 3-3. MultiFunction Expansion board The AAA Power Pack houses 2 AAA batteries, and can be used to power either the RF expansion board, MultiFunction expansion board, or both of them in series as shown in Figure 3-4 which will later be used for Task 1.
  • 10. 10 Figure 3-4. RF Expansion board into the 2x AAA alkaline cell battery and MultiFunction board 3.2Software Components of the CY3271 The software part of CY3271 has three parts. They are PSoC Designer, PSoC Programmer and Sense and control Dashboard. 3.2.1 PSoC Designer PSoC Designer™ is two tools in one. It combines a full featured integrated development environment (IDE) with a powerful visual programming interface for creating embedded systems for Cypress’ PSoC® Mixed-Signal Controllers, a Programmable System-on- Chip™. In simple terms, it is where all PSoC projects are created, edited, built, and debugged. Figure 3-5 shows the snap shot of the PSoC designer. Figure 3-5. PSoC Designer
  • 11. 11 3.2.2 PSoC Programmer PSoC Programmer is Cypress' flexible integrated programming application for programming PSoC® devices. It can be used with PSoC Designer as an integrated programmer or as a standalone programming application. Figure 3-6 shows the PSoC Programmer window. Figure 3-6. PSoC Programmer 3.2.3 Sense and Control Dashboard (SCD) Cypress Sense and Control Dashboard (SCD) is a software application used to connect one or more sensors to a Windows based personal computer. SCD enables data logging and monitoring of wired and wireless sensors created using PSoC. Some features of SCD include data logging, calibration, alarms, and data aggregation from several sensors. In the CY3271, SCD is used to wirelessly get data from sensors connected to the PC, using the RF expansion card. Figure 3-7 shows the SCD. So far the constituiting components of the CY3271 kit was briefly discribed. In the following section, some interesting example projects will be delt using the basic components of the CY3271 kit. 3.3 Ultra Low Power Wireless Temperature Sensor This demonstration shows a low power RF solution that runs on a AAA battery supply. This example demonstrates the temperature sensing capabilities using the thermistor in the RF expansion board. 1. Connect the PC Bridge into any free USB port on your computer. 2. Connect the RF expansion board to the PC bridge. 3. Program the RF Expansion board using PSoC programmer. Select the .Hex file of RF_ULP_TEMP located in the C:CypressCY3271FirmwareRF_ULP_TEMP. 4. while using PSoC Programmer, Set Device Family to 27x43, Device to CY8C27443 and click Program. 5. After successful programming, close the PSoC Programmer. 6. Open the SCD Dashboard software GUI that is already installed in your computer. To access the SCD Dashboard software, go to: Start > Programs > Cypress > Cypress Sense and Control Dashboard > Cypress Sense and Control Dashboard.
  • 12. 12 Click Continue to Load the last configuration. The red LED should start blinking on the PC Bridge indicating that there is I2C activity between the SCD software and the PC Bridge slave RF Hub application. 7. Now disconnect the RF expansion board from the PC bridge and connect it to the AAA battery pack. 8. Switch on power to the RF Expansion Board by placing the position of the switch to ON position. 9. Place the PC Bridge in Bind mode using the SCD Dashboard. This is described in the following method: Click the Manage Network button to add a new node as shown in Figure 3-8 In the Manage Network screen, click Add.. to add a new node as shown in Figure 3-9. Figure 3-7. Sense and control dashboard OFF ON Figure 3-8. Manage network button in the SCD Dashboard
  • 13. 13 Figure 3-9. Node configuration window On the Node Binding screen, click Begin Binding as shown in Figure 3-10. Figure 3-10. Node binding screen 10. Place the RF Expansion Board in Bind mode, by pressing the Bind button on the board when instructed by the GUI. The position of the bind button in the RF expansion board is shown in Figure 3-11 Figure 3-11. RF Expansion board (Bind Button) 11. Verify the success of the bind and click Next.
  • 14. 14 12. After it is bound, click Next. name the node and the sensor. Then configure the data format as discussed in the following steps. In the Configure Node screen, click Load Node Configuration button to load the stored configuration. Click Browse and load the ‘Template ULP Temp Sensor.xml’ file as shown in Figure 3-12. This file is located in Cypress/CY3271/Device Templates and click Finish. Figure 3-12. Configure node screen 13. Click Apply on all successive dialog boxes until the main SCD window reappears. Now the measurement readings from the thermistor in the RF expansion board is visible on the SCD. 3.4 MultiFunction Expansion Card CapSense Slider The MultiFunction demonstrations can be operated by programming the corresponding .hex file (CapSense, Light Sensor, Proximity Sensor, and Temperature Sensor) onto the MultiFunction board. The example described in this section is specific for the CapSense Slider. However, a similar approach can be used for the other MultiFunction demonstrations. This example demonstrates PSoC capacitive sensing capabilities. For this example, the MultiFunction expansion card is used. You can change the color of the LED array by moving your finger across the CapSense slider in the MultiFunction expansion card. This is achieved in two different ways. First method is to connect the MultiFunction expansion card directly to the arrangement discussed in section 3.3, as shown in Figure 3-4. Here the things to observe are as follows, When the finger position on the slider is at the origin, the LED is OFF. When the finger position is in between the origin and the 1/3 mark of the width of the Capsense slider, the LED emits the color blue. When the finger position on the slider is between the 1/3 and 2/3 marks of the width of the Capsense slider, the LED emits the color green.When the finger position is between the far end and the 2/3 mark of the width of the capsense slider, the LED emits the color red. For all other slider positions, the LED is OFF. This includes the absence of a finger on the slider.
  • 15. 15 Second method is to directly connect MultiFunction expansion card to the AAA battery board as shown in Figure 3-13. Move the switch to the ON position or away from the batteries. Now move your finger along the slider at the end of the MultiFunction board and observe how the LED changes color as explained above.Note here that the output for this example can be directly visualized in the Multi Function card itself (change in LED colours) and that the reason why the RF expansion card is not included. When you are finished with the demonstration, move the power switch to the OFF position. Figure 3-13. Multifunction expansion card with AAA power pack 3.5 Wireless Expansion Kit – (CY3271-EXP1) The CY3271-EXP1 kit hardware consists of a Weather Station Expansion Board and a Pigtail Thermistor Expansion Board. 3.5.1 Pigtail Thermistor Expansion Board The Pigtail Thermistor Expansion Board features a thermistor on a 3 foot cable. The thermistor at the end of the cable is identical to the thermistor used on the RF Expansion Board allowing dual temperature readings. The Pigtail Thermistor Expansion Board does not have a PSoC on board, rather it uses the PSoC from the RF Expansion Board to read the sensor. Figure 3-14. Pigtail thermistor expansion board The Pigtail Thermistor demonstration can be operated by downloading the corresponding .hex file onto the RF Expansion Board. General steps to be followed while using pigtail thermistor expansion board are as follows. 1. Connect the RF Expansion Board to the PC Bridge. 2. Insert the PC Bridge into any free USB port of your PC/laptop. 3. Open PSoC Programmer, and load Node_pigtailSensor.hex from the Hex Files folder located on your computer. 4. Set Device Family to 27x43, Device to CY8C27443 and click Program.
  • 16. 16 5. Disconnect the RF Expansion Board from the PC Bridge, leaving the Bridge connected to your computer. 6. Attach the Pigtail Thermistor Expansion Board and the battery pack to the RF Expansion board. 7. Switch on power to the RF Expansion Board by sliding the ON/OFF switch on the battery pack towards the RF Expansion Board. 8. Open the SCD software. 9. Place the PC Bridge in Bind mode using the SCD software. This is described below: Click Manage button to set up the sensor network. In the Manage Network screen, click Add to add a new node. On the Node Binding screen, click on Begin Binding. After this function is activated, the user has about 20 seconds to press the bind button on the RF Expansion Board. Verify the success of the bind. 10.Click Next to go to the Node Binding (2 of 2) window. In this window, assign a name to the newly bound node. On the Node Configuration pane, click Load Node configuration from a file and load Pigtail_Thermistor _Dashboard_Configuration.xml from the Configuration Files folder located on your computer. 11.Select graphical or textual mode of data display. The data is displayed in graphical or text format on the SCD screen. 12.Click Apply on all successive dialog boxes until the main SCD window reappears. 3.5.2 Weather Station Expansion Board The Weather Station Expansion Board features a PSoC device, and several sensors as shown in Figure 3-15: Temperature sensor-Thermistor: This is a Negative Temperature Coefficient Resistor whose resistance changes as ambient temperature changes between – 40°C to 125°C [2]. Ambient light sensor: LX1972 is a low cost silicon light sensor with spectral response that closely emulates the human eye [3]. Humidity sensor This capacitive atmospheric humidity sensor consists of a non- conductive foil, which is covered on both sides with a layer of gold. The dielectric constant of the foil changes as a function of the relative humidity of the ambient atmosphere and, accordingly, the capacitance value of the sensor is a measure for relative humidity [4]. Atmospheric pressure sensor: Bridge based piezoresistive chip from GE [1].
  • 17. 17 Figure 3-15. Weather station expansion board The Weather Station demonstration can be operated by downloading the corresponding .hex file onto the RF Expansion Board. General steps to be followed while using the weather station expansion board are as follows. 1. Connect the RF Expansion Board to the PC Bridge. 2. Insert the PC Bridge into any free USB port of your PC/laptop. 3. Open PSoC Programmer, and load RF_I2C_Bridge.hex from the Hex Files folder located on your computer. 4. Set Device Family to 27x43, Device to CY8C27443 and click Program. 5. Disconnect the RF Expansion Board from the PC Bridge, leaving the Bridge connected to your computer. 6. Attach the Weather Station Expansion Board and the battery pack to the RF Expansion board as shown in Figure 3-16. 7. Switch on power to the RF Expansion Board by sliding the ON/OFF switch on the battery pack towards the RF Expansion Board. 8. Open the SCD software. 9. Place the PC Bridge in Bind mode using the SCD software. Click Manage to set up the sensor network. In the Manage Network screen, click Add to add a new node. On the Node Binding screen, click Begin Binding. After activating this function, you have aproximately 20 seconds to press the bind button on the RF Expansion Board. Verify the success of the bind. 10.Click Next to go to the Node Binding (2 of 2) window. In this window, assign a name to the newly bound node. On the Node Configuration pane, click Load Node configuration from a file and load Weather_Station_Dashboard_Configuration.xml from the Configuration Files folder located on your computer. 11.Select graphical or textual mode of data display. The data is displayed in graphical or text format on the SCD screen. 12.Click Apply on all successive dialog boxes until the main SCD window reappears
  • 18. 18 Figure 3-16. RF Expansion board connected to the battery pack and weather station boards 4. Energy Scavenging / Harvesting Thermogenerators (TE) are transducers which convert heat energy (temperature differences) into electrical energy. In this exercise, we will be using the commercially available thermogenerators -TE Power Plus from Micropelt GmbH [8]. The thermogenerator consists of leg pairs of n- and p-type material. Each leg pair generates a certain voltage. The voltage (U) generated by a thermogenerator is directly proportional to the number of leg pairs (N) and the temperature difference (∆T) between top and bottom side times the Seebeck coefficient (α). This is represented as shown in equation (1) below. Figure 4-1 shows the block diagram of a micropelt thermogenerator. U = N x ∆T x α ……………………………………… (1) The voltage generated by the devices is shown in Figure 4-2 as a function of the temperature difference. Figure 4-1. Block diagram depicting the realization of a single leg pair to several leg pairs and its physical implementation using Micropelt technology [8]
  • 19. 19 Figure 4-2. Graph depicting the generated thermal voltage for various temperature difference [8] As a first step or part of this exercise, driving of thermister in the RF board using TE power plus is considered. The energy harvesting or scavenging set up for our WSN can be configured as shown in Figure 4-3. Figure 4-3. Energy Harvesting using Micropelt thermogenerator along with the Cypress RF expansion board General steps to be followed while using TE along with the RF expansion board are as follows. 1. Initially register the wiresless sensor node through normal procedure using SCD and load the node configuration as explained in section 3.3. 2. Switch off the power supply. Disconnect the RF expansion board from the AAA battery pack and connect it to the micropelt thermogenerator. 3. Check the connection of the provided TE to the modified AAA power pack board as shown in Figure 4-3. 4. In order to generate the voltage required for driving the RF expansion board and the thermistor mounted on it, heat the bottom surface of the TE using a solder machine to approximately 300°C for 1 minute. Switch on the Sensor board, if it doesn't
  • 20. 20 continue to report extend the heating time iteratively in about 30 seconds. Intervals. (Understand and explain why the bottom surface of the TE has to be heated). Warning: Care should be taken while handling the hot soldering equipment to avoid injury. Also, the device should be protected from too strong heating, i.e., heating should definitely be stopped if the blue metal fan on top starts to feel uncomfortably warm/hot. 5. Now attach the available pigtail sensor to the bottom of the TE using tapes. Register the pigtail sensor node using SCD as explained in the section 3.5.1. Appropriate calibration procedures has to be carried out if there are deviations in the measured data from the temperature sensors present in the pigtail arrangement and in RF expansion board. Binder environmental test chamber can be utilized for verifying the measured temperature data. Previously obtained calibration data from task 2(1) can be reused here. 6. Redo the heating procedure of the TE along with the pigtail attached to its bottom until ∆T ≥ 20 K condition is achieved. Because this would create approximately the required voltage (app. 3.3V) for driving the RF expansion board. 7. Note that energy harvesting supply voltage often has to be regenerated through reheating procedure when it fails to drive the load. Determine the minimum T (∆T), when the supply voltage breaks down and the sensor stops reporting. Use an additional volt meter for this task. Compare the result to the U-over-∆T characteristics of the device. 5. Binder: Environmental Test Chamber Figure 5-1. Binder Environmental test chamber – MK 53 series [9]
  • 21. 21 The cold/heat test chambers from Binder GmbH fulfil the highest demands for precision and performance. With the new screen controls, Binder serves as a model with regard to precision, and functionality. Equipped as standard with a multitude of operating functions, additional recorder and warning functions, they offer extremely easy handling and meet the highest standards of safety. The electronic compressor control allows the highest temporal temperature accuracies over the entire temperature range. Figure 5-1 shows MK53 series of the Binder environmental testing chamber. Due to the broad temperature range of – 40º C to + 180º C, it is optimally suited for wide range of tasks like for e.g. Electronics/semi-conductor industry, testing laboratory, quality assurance, automotive industry suppliers as well as transport/transport subcontractors, aircraft industry, mechanical engineering, building materials industry. 6. Basic Principles of Measurement using Wheatstone Bridge and Instrumentation Amplifier Many sensors available today exhibit a change in resistance when they are exposed to whatever they are sensing. They are inexpensive to manufacture and relatively easy to interface with signal conditioning circuits. One technique for measuring a change in resistance is to force a constant current through the resistive sensor and measure the voltage output. This requires both an accurate current source and an accurate means of measuring the voltage. Any change in the current will be interpreted as a resistance change. In addition, the power dissipation in the resistive sensor must be small, in accordance with the manufacturer's recommendations, so that self-heating does not produce errors, therefore the drive current must be small. An other measurement alternative use Wheatstone Bridge. Bridges offer an attractive alternative for measuring small resistance changes accurately. The basic Wheatstone bridge (actually developed by S. H. Christie in 1833) is shown in Figure 6-1. Figure 6-1. Wheatstone bridge It consists of four resistors connected to form a quadrilateral, a source of excitation (voltage or current) connected across one of the diagonals, and a voltage detector connected across the other diagonal. The detector measures the difference between the outputs of two voltage dividers connected across the excitation. A bridge measures
  • 22. 22 resistance indirectly by comparison with a similar resistance. The two principle ways of operating a bridge are as a null detector or as a device that reads a difference directly as voltage. In the figure 6-1, Rx is the unknown resistance to be measured; R1, R2 and R3 are resistors of known resistance and the resistance of R2 is adjustable. If the ratio of the two resistances in the known leg (R2 / R1) is equal to the ratio of the two in the unknown leg (Rx / R3), then the voltage between the two midpoints (B and D) will be zero and no current will flow through the galvanometer Vg. If the bridge is unbalanced, the direction of the current indicates whether R2 is too high or too low. R2 is varied until there is no current through the galvanometer, which then reads zero. Detecting zero current with a galvanometer can be done to extremely high accuracy. Therefore, if R1, R2 and R3 are known to high precision, then Rx can be measured to high precision. Very small changes in Rx disrupt the balance and are readily detected. At the point of balance, the ratio of R2 / R1 = Rx / R3 Therefore, Alternatively, if R1, R2, and R3 are known, but R2 is not adjustable, the voltage difference across or current flow through the meter can be used to calculate the value of Rx, using Kirchhoff's circuit laws (also known as Kirchhoff's rules). This setup is frequently used in strain gauge and resistance thermometer measurements, as it is usually faster to read a voltage level off a meter than to adjust a resistance to zero the voltage. If all four resistor values and the supply voltage (VS) are known, and the resistance of the galvanometer is high enough that Ig is negligible, the voltage across the bridge (VG) can be found by working out the voltage from each potential divider and subtracting one from the other. The equation for this is: This can be simplified to: where VG is the voltage of node B relative to node D. A desirable feature is to amplify the difference of two inputs will be found in many sensing applications. Traditionally this has been done with instrumentation amplifiers. Be it measuring the voltage across a current shunt or measuring the voltage across a resistive stress gauge bridge, it is often necessary to be able to amplify only the difference of two voltages.
  • 23. 23 Figure 6-2. Wheatstone bridge and differential amplifier Instrumentation amplifiers are useful in applications where a small differential signal riding on a big common mode signal needs to be amplified and a single ended output is desired. Characteristics of an Instrumentation Amplifier Common Mode Rejection Ratio The Common Mode Rejection Ratio (CMRR) determines the ability of an instrumentation amplifier to ignore the common mode signals (average of the two input signals) and amplify the differential signals (difference of the two input signals). Mathematically, Where, Ad is the differential gain Ac is the common mode gain Ideally, the common mode gain is expected to be zero and CMRR is expected to be infinity Input Impedance The instrumentation amplifier gets its input from sources with a finite output resistance. High input impedance is desired to ensure that the source is not loaded and the accuracy of the measurement is not affected. Input Common Mode Range Input Common Mode Range (ICMR) is the range of common mode input through which the instrumentation amplifier operates unsaturated.
  • 24. 24 Input Offset Voltage Input offset voltage is differential voltage that must be applied to the differential amplifier input to make the output voltage zero. Ideally, offset is expected to be zero volts. 6.1 PSoC Implementation Single-ended inputs are defined as being referenced to some ground reference. Amplification is easily done with a PSoC PGA User Module. The topology is shown in the figure below. Figure 6-3. Programmable Gain Amplifier The gain equation is defined below: For the PGA, this feedback is a string of resistors having a total resistance of 16 units. The feedback tap selects a specific attenuation that sets the gain. The resistance values are defined below: Combining both equations above results in the following:
  • 25. 25 The traditional differential amplifier has balanced gain. Its topology is shown in Figure 6- 4. Figure 6-4. Traditional Differential Amplifier This type of amplifier is used as the first stage for most instrumentation amplifiers. The outputs are functions of the input voltages and resistance values as shown in the equation below: Rearranging this equation results in the equation shown below: It is apparent that the common signal is the average of the two input voltages. It passes through at unity gain. The differential gain is 16/16 with half the gained differential signal added to the common signal on Vout1 and half the gained differential signal subtracted from the common signal on Vout2. This topology can be implemented with two PGAs. The block placement and parameter settings are shown in Fig. 6-5.
  • 26. 26 Figure 6-5. Block Placement for Differential Amplifier Figure 6-6. Differential Amplifier Parameter Settings For this example, Amp1 and Amp2 are exactly the same with a gain of four and the lower half of the resistor string set to analog ground. Software is required to detach the resistor strings from analog ground and connect to each other. This connection is made using the example below: AMP_1_SetGain(AMP_1_G1_00); // Enable PGA block - the input to ADC AMP_1_Start(AMP_1_MEDPOWER); // block is routed through PGA (Gain =1) AMP_2_SetGain(AMP_2_G1_00); AMP_2_Start(AMP_2_MEDPOWER); 6.1.1 Reading the Differential Value It is necessary to have an ADC with differential inputs. The user modules are the ADCINC. The placement and parameters to connect an ADCINC to the differential amplifier are shown in the Fig. 6-7.
  • 27. 27 Figure 6-7. Block Placement for DiffAmp and ADCINC Figure 6-8. ADCINC Parameter Settings The input connections are obvious. A subtle point is that the NegInputGain parameter must be set to 1 for the ADC to have differential inputs. 6.2 The Wheatstone bridge circuit The Wheatstone bridge demonstration can be operated by downloading the corresponding .hex file onto the RF Expansion Board. General steps to be followed while using the Wheatstone bridge circuit are as follows. 1. Connect the RF Expansion Board to the PC Bridge. 2. Insert the PC Bridge into any free USB port of your PC/laptop. 3. Open PSoC Programmer, and load Wheatstone_Bridge_2PGA_V1.hex from the Hex Files folder located on your computer. 4. Set Device Family to 27x43, Device to CY8C27443 and click Program. 5. Disconnect the RF Expansion Board from the PC Bridge, leaving the Bridge connected to your computer. 6. Construct the Wheatstone circuit as shown in Figure 6-1. Use three fix Resistors 10K and a variable Resistor 20K Build the Wheatstone Bridge on the proto board 7. Attach the Wheatstone bridge circuit and the battery pack to the RF Expansion board as shown in Figure 6-9.
  • 28. 28 The connection detail of Wheatstone bridge circuit to the RF Expansion board is shown in Figure 6-10. 8. Switch on power to the RF Expansion Board by sliding the ON/OFF switch on the battery pack towards the RF Expansion Board. 9. Open the SCD software. 10.Place the PC Bridge in Bind mode using the SCD software. Click Manage to set up the sensor network. In the Manage Network screen, click Add to add a new node. On the Node Binding screen, click Begin Binding. After activating this function, you have aproximately 20 seconds to press the bind button on the RF Expansion Board. Verify the success of the bind. 11.Click Next to go to the Node Binding (2 of 2) window. In this window, assign a name to the newly bound node. On the Node Configuration pane, click Load Node configuration from a file and load Wheatstone Bridge.xml from the Configuration Files folder located on your computer. 12.Select graphical or textual mode of data display. The data is displayed in graphical or text format on the SCD screen. 13.Click Apply on all successive dialog boxes until the main SCD window reappears. 14.Adjust the potentiometer on the Wheatstone Bridge circuit to see the changing of the voltage on the SCD window appear. Figure 6-9. RF Expansion board connected to the battery pack and Wheatstone bridge circuit Figure 6-10. Connection detail of Wheatstone bridge circuit RF Expansion board P0.2 P0.3 P0.4 P0.5 P0.6 GND 3.3V 15 13 11 9 7 5 3 1 16 14 12 10 8 6 4 2 Connect B on Wheatstone bridge circuit to P0.2 Connect D on Wheatstone bridge circuit to P0.4 Wireless Expansion Card Female Header Connect A on Wheatstone bridge circuit to GND Connect C on Wheatstone bridge circuit to 3.3 V
  • 29. 29 7. Tasks Task 1 1. Temperature measurement using the thermistor in the RF expansion board following the instructions in section 3.3. 2. Now invoke the PSoC designer, open the project for RF_ultra low power temperature sensing module. Open the header file and try to change the reporting time of the measurement from the sensors from 5 seconds to 30/60 seconds. Build target and reprogramm the RF expansion board again using PSoC programmer.After successful programming, connect it to the battery arrangement and invoke the sense and control dashboard (SCD) for invoking the node connection for sensor measurement. Cross verify the measurement interval after changing the reporting time. Hint Main.c houses all the firmware for the Temperature Sensor application. The firmware can be broken into the following parts: Power up initialization and setup Temperature Readings Main loop of the application with general tasks Calibration routine for the timer 3. Connect the sensor expansion boards (CapSense Slider) to this arrangement. Cross validate its functionality. Task 2 1. Now take the second RF board, connect the weather station expansion board. Configure the node connection and measure the 4 different quantities. 2. Introduce and familiarize with the lower and higher level alarm setting in the SCD. Task 3 1. Now take the third RF board, connect the pig tail thermistor sensor board. Configure the node connection and measure the temperature reading shown from the thermistor on the RF board and from the pig tail arrangement. Familiarize with the procedure for calibrating the sensors if there are variations in different sensor measurement. Binder environmental testing chamber can be used as a reference for calibrating. 2. Now using the pig tail sensor arrangement, measure the temperature for the given samples. (Test samples will be provided during the lab). 3. Use the energy harvesting device to the RF expansion board as explained in section 4 to measure the data from the sensor mounted on it. Cross verify the generated voltage using a voltmeter to that of the graph shown in Figure 4-2. Activate the sensor node in the RF expansion.
  • 30. 30 Task 4 1. Small voltage measurement using the Wheatstone Bridge following the instructions in section 6.2. 2. Adjust the potentiometer on the Wheatstone Bridge to get the voltage 0.5 Volt appear on the SCD window. 3. Open the project for Wheatstone_Bridge_2PGA_V1 module using PSoC Designer. Change the gain of both PGA module from 1 to 2 or 4. Build target and re-programme the RF expansion board again using PSoC programmer. After successful programming, connect it to the battery arrangement and invoke the sense and control dashboard (SCD) for invoking the node connection for small voltage measurement. Observe the output voltage result on the SCD windows appear. Hint Change the gain both of PGA on the PGA module properties using PSoC Designer editor Change the PGA_setgain in the main.c Read the PGA data sheet Task 5 1. Modify the project Wheatstone Bridge in Task 4 using Instrument Amplifier. 2. Open the project for Wheatstone_Bridge_2PGA_V1 module using PSoC Designer. Replace the PGA module to Instrument Amplifier module. Save project as Wheatstone_Bridge_INSAMP. Build target and re-programme the RF expansion board again using PSoC programmer. After successful programming, connect it to the battery arrangement and invoke the sense and control dashboard (SCD) for invoking the node connection for small voltage measurement. Observe the output voltage result on the SCD windows appear. Hint Replace the the PGA module to Instrumentation Amplifier module using PSoC Designer editor Modify code for INSAMP module in the main.c Read the INSAMP data sheet Make experiments using gain of INSAMP module that is fixed at: 2 and 4. 8. Acknowledgement It is gratefully acknowledged, that the employed PSoC kits are partly donations from Cypress Semiconductors Corporation.
  • 31. 31 9. Reference [1] “NPP- 301 series- surface mount pressure sensor” product data sheet, GE Novasensors. [2] “NTC Thermistor-ERT-J1VT332J” data sheet, Panasonic. [3] “LX1972 Ambient light sensor” data sheet, Microsemi. [4] “Vishay Humidity sensor-238169190001” data sheet, Vishay. [5] “PSoC Technical Reference Manual” Document No. 001-14463 Rev C, 2008. Cypress Semiconductors corporation. [6] “CY3271 first touch starter kit”- Cypress Semiconductors corporation [7] http://www.cypress.com/?controller=medialauncher2&sessionid=CYPR007 [8] http://www.micropelt.com/ [9] http://www.binder-world.com/eu/de/

×