Professional Documents
Culture Documents
CHAPTER 1
A Reconfigurable Multi-Touch Remote Control System for Teleoperated Robots is designed and implemented using PIC Micro controller to make the display work easy. The entire project was developed under embedded systems. 2.2 EMBEDDED SYSTEMS: A system is something that maintains its existence and functions as a whole through the interaction of its parts. E.g. Body, Mankind, Access Control, etc A system is a part of the world that a person or group of persons during some time interval and for some purpose choose to regard as a whole, consisting of interrelated components, each component characterized by properties that are selected as being relevant to the purpose. Embedded System is a combination of hardware and software used to achieve a single specific task. Embedded systems are computer systems that monitor, respond to, or control an external environment. Environment connected to systems through sensors, actuators and other I/O interfaces. Embedded system must meet timing & other constraints imposed on it by environment. An embedded system is a microcontroller-based, software driven, reliable, realtime control system, autonomous, or human or network interactive, operating on diverse physical variables and in diverse environments and sold into a competitive and cost conscious market. An embedded system is not a computer system that is used primarily for processing, not a software system on PC or UNIX, not a traditional business or scientific application. High-end embedded & lower end embedded systems. High-end embedded system - Generally 32, 64 Bit Controllers used with OS. Examples Personal Digital Assistant and Mobile phones etc .Lower end embedded systems - Generally 8,16 Bit Controllers used with an minimal operating systems and hardware layout designed for the
CHAPTER 3
Robot Section:
3.3 DESCRIPTION OF THE BLOCK DIAGRAM The AC main Block is the power supply which is of single phase 230V ac. This should be given to step down transformer to reduce the 230V ac voltage to low voltage. i.e., to 6V or 12V ac this value depends on the transformer inner winding. The output of the transformer is given to the rectifier circuit. This rectifier converts ac voltage to dc voltage. But the voltage may consist of ripples or harmonics. To avoid these ripples the output of the rectifier is connected to filter. The filter thus removes the harmonics. This is the exact dc voltage of the given specification. But the controller operates at 5V dc. So we need a regulator to reduce the voltage. 7805 regulator produces 5V dc. The 7805 regulator produces 5V dc and this voltage is given to PIC micro controller, Zigbee module. The output of the microcontroller is given to the Zigbee module. The receiver receives the signal through antenna and sends that signal to microcontroller. The output of the micro controller is given to the Robot displacement motors with the help of motor control unit.
10
3.6POWERSUPPLY
3.7 CIRCUIT DESCRIPTION POWER SUPPLY: Power supply unit consists of Step down transformer, Rectifier, Input filter, Regulator unit, Output filter. The Step down Transformer is used to step down the main supply voltage from 230V AC to lower value. This 230 AC voltage cannot be used directly, thus it is stepped down. The Transformer consists of primary and secondary coils. To reduce or step down the voltage, the transformer is designed to contain less number of turns in its secondary core. The output from the secondary coil is also AC waveform. Thus the conversion from AC to DC is essential. This conversion is achieved by using the Rectifier Circuit Unit. The Rectifier circuit is used to convert the AC voltage into its corresponding DC voltage. There are Half-Wave, Full-Wave and bridge Rectifiers available for this specific function. The most important and simple device used in Rectifier circuit is the diode. The simple function of the diode is to conduct when forward biased and not to conduct in reverse bias.
11
12
13
CHAPTER 4
14
Power supply unit consists of following units i) Step down transformer ii) Rectifier unit iii) Input filter iv) Regulator unit v) Output filter
15
4.2.1 STEPDOWN TRANSFORMER: The Step down Transformer is used to step down the main supply voltage from 230V AC to lower value. This 230 AC voltage cannot be used directly, thus it is stepped down. The Transformer consists of primary and secondary coils. To reduce or step down the voltage, the transformer is designed to contain less number of turns in its secondary core. The output from the secondary coil is also AC waveform. Thus the conversion from AC to DC is essential. This conversion is achieved by using the Rectifier Circuit/Unit. 4.2.2 RECTIFIER UNIT: The Rectifier circuit is used to convert the AC voltage into its corresponding DC voltage. There are Half-Wave, Full-Wave and bridge Rectifiers available for this specific function. The most important and simple device used in Rectifier circuit is the diode. The simple function of the diode is to conduct when forward biased and not to conduct in reverse bias. The Forward Bias is achieved by connecting the diodes positive with positive of the battery and negative with batterys negative. The efficient circuit used is the Full wave Bridge rectifier circuit. The output voltage of the rectifier is in rippled form, the ripples from the obtained DC voltage are removed using other circuits available. The circuit used for removing the ripples is called Filter circuit. 4.2.3 INPUT FILTER: Capacitors are used as filter. The ripples from the DC voltage are removed and pure DC voltage is obtained. And also these capacitors are used to reduce the harmonics of the input voltage. The primary action performed by capacitor is charging and discharging. It charges in positive half cycle of the AC voltage and it will discharge in negative half cycle. So it allows only
16
7805 Regulator Regulator regulates the output voltage to be always constant. The output voltage is maintained irrespective of the fluctuations in the input AC voltage. As and then the AC voltage changes, the DC voltage also changes. Thus to avoid this Regulators are used. Also when the internal resistance of the power supply is greater than 30 ohms, the output gets affected. Thus this can be successfully reduced here. The regulators are mainly classified for low voltage and for high voltage. Further they can also be classified as: i) Positive regulator 1---> input pin 2---> ground pin 3---> output pin It regulates the positive voltage. ii) Negative regulator 1---> ground pin 2---> input pin 3---> output pin It regulates the negative voltage.
17
4.2.5 OUTPUT FILTER: The Filter circuit is often fixed after the Regulator circuit. Capacitor is most often used as filter. The principle of the capacitor is to charge and discharge. It charges during the positive half cycle of the AC voltage and discharges during the negative half cycle. So it allows only AC voltage and does not allow the DC voltage. This filter is fixed after the Regulator circuit to filter any of the possibly found ripples in the output received finally. Here we used 0.1F capacitor. The output at this stage is 5V and is given to the Microcontroller. 4.3 MICRO CONTROLLER: A computer-on-a-chip is a variation of a microprocessor which combines the processor core (CPU), some memory, and I/O (input/output) lines, all on one chip. The computer-on-a-chip is called the microcomputer whose proper meaning is a computer using a (number of) microprocessor(s) as its CPUs, while the concept of the microcomputer is known to be a microcontroller. A microcontroller can be viewed as a set of digital logic circuits integrated on a single silicon chip. This chip is used for only specific applications. 4.3.1 ADVANTAGES OF USING A MICROCONTROLLER OVER MICROPROCESSOR: A designer will use a Microcontroller to 1. Gather input from various sensors 2. Process this input into a set of actions 3. Use the output mechanisms on the Microcontroller to do something useful
18
19
20
21
22
23
The peer-to-peer topology also has a PAN coordinator; however, it differs from the star topology in that any device may communicate with any other device as long as they are in range of one another. Peer-to-peer topology allows more complex network formations to be implemented, such as mesh networking topology. Applications such as industrial control and monitoring, wireless sensor networks, asset and inventory tracking, intelligent agriculture, and security would benefit from such a network topology. A peer-
24
25
26
The radio operates at one or more of the following unlicensed bands: 868868.6 MHz (e.g., Europe) 902928 MHz (e.g., North America) 24002483.5 MHz (worldwide) MAC sub layer The MAC sub layer provides two services: the MAC data service and the MAC management service interfacing to the MAC sub layer management entity (MLME) service access point (SAP) (known as MLME-SAP). The MAC data service enables the transmission and reception of MAC protocol data units (MPDUs) across the PHY data service. The features of the MAC sub layer are beacon management, channel access, GTS management, frame validation, acknowledged frame delivery, association, and 27
The data frame provides a payload of up to 104 bytes. The frame is numbered to ensure that all packets are tracked. A frame-check sequence ensures that packets are received without error. This frame structure improves reliability in difficult conditions. Another important structure for 802.15.4 is the acknowledgment (ACK) frame. It provides feedback from the receiver to the sender confirming that the packet was received without error. The device takes advantage of specified "quiet time" between frames to send a short packet immediately after the data-packet transmission.
28
29
The network coordinator maintains overall network knowledge. It's the most sophisticated of the three types and requires the most memory and computing power.
The full function device (FFD) supports all 802.15.4 functions and features specified by the standard. It can function as a network coordinator. Additional memory and computing power make it ideal for network router functions or it could be used in network-edge devices (where the network touches the real world).
The reduced function device (RFD) carries limited (as specified by the standard) functionality to lower cost and complexity. It's generally found in network-edge devices.
POWER AND BEACONS Ultra-low power consumption is how ZigBee technology promotes a long lifetime for devices with non rechargeable batteries. ZigBee networks are designed to conserve the power of the slave nodes. For most of the time, a slave device is in deep-sleep mode and wakes up only for a fraction of a second to confirm its presence in the network. For
30
32
access controlthe device maintains a list of trusted devices within the network data encryption, which uses symmetric key 128-bit advanced encryption standard frame integrity to protect data from being modified by parties without cryptographic keys
sequential freshness to reject data frames that have been replayedthe network controller compares the freshness value with the last known value from the device and rejects it if the freshness value has not been updated to a new value
The actual security implementation is specified by the implementer using a standardized toolbox of ZigBee security
ACCELEROMETER SENSORS:
Introduction One of the most common inertial sensors is the accelerometer, a
dynamic sensor capable of a vast range of sensing. Accelerometers are available that can measure acceleration in one, two, or three orthogonal axes. They are typically used in one of three modes: As an intertial measurement of velocity and position;
33
There are considerable advantages to using an analog accelerometer as opposed to aninclinometer such as a liquid tilt sensor inclinometers tend to output
binary information(indicating a state of on or off), thus it is only possible to detect when the tilt has exceeded some thresholding angle.
Principles of Operation: Most accelerometers are Micro-Electro-Mechanical Sensors (MEMS). The basic principle of operation behind the MEMS accelerometer is the displacement of a small proof mass etched into the silicon surface of the integrated circuit and suspended by small beams. Consistent with Newton's second law of motion (F = ma), as an acceleration is applied to the device, a force develops which displaces the mass. The support beams act as a spring, and the fluid (usually air) trapped inside the IC acts as a damper, resulting in a second order lumped physical system. This is the source of the limited operational bandwidth and non-uniform frequency response of accelerometers. For more information, see reference to Elwenspoek, 1993.
34
Capacitive: Accelerometers that implement capacitive sensing output a voltage dependent on the distance between two planar surfaces. One or both of these plates are charged with an electrical current. Changing the gap between the plates changes the electrical capacity of the system, which can be measured as a voltage output. This method of sensing is known for its high accuracy and stability. Capacitive accelerometers are also less prone to noise and variation with temperature, typically dissipate less power, and can have larger bandwidths due to internal feedback circuitry. (Elwenspoek 1993) Piezoelectric: Piezoelectric sensing of acceleration is natural, as acceleration is directly proportional to force. When certain types of crystal are compressed, charges of opposite polarity accumulate on opposite sides of the crystal. This is known as the piezoelectric effect. In a piezoelectric accelerometer, charge accumulates on the crystal and is translated and amplified into either an output current or voltage. Piezoelectric accelerometers only respond to AC phenomenon such as vibration or shock. They have a wide dynamic range, but can be expensive depending on their quality (Doscher 2005) 35
Specifications A typical accelerometer has the following basic specifications: Analog/digital Number of axes
36
Analog vs. digital: The most important specification of an accelerometer for a given application is its type of output. Analog accelerometers output a constant variable voltage depending on the amount of acceleration applied. Digital accelerometers output a variable frequency square wave, a method known as pulse-width modulation. A pulse width modulated accelerometer takes readings at a fixed rate, typically 1000 Hz (though this may be user-configurable based on the IC selected). The value of the acceleration is proportional to the pulse width (or duty cycle) of the PWM signal. For use with ADCs commonly used for music interaction systems, analog accelerometers are usually preferred.
Number of axes: Accelerometers are available that measure in one, two, or three dimensions. The most familiar type of accelerometer measures across two axes. However, three-axis accelerometers are increasingly common and inexpensive. Output range: To measure the acceleration of gravity for use as a tilt sensor, an output range of 1.5 g is sufficient. For use as an impact sensor, one of the most common musical applications, 5 g or more is desired.
37
Bandwidth: The bandwidth of a sensor is usually measured in Hertz and indicates the limit of the near-unity frequency response of the sensor, or how often a reliable reading can be taken. Humans cannot create body motion much beyond the range of 10-12 Hz. For this reason, a bandwidth of 40-60 Hz is adequate for tilt or human motion sensing. For vibration measurement or accurate reading of impact forces, bandwidth should be in the range of hundreds of Hertz. It should also be noted that for some older microcontrollers, the bandwidth of an accelerometer may extend beyond the Nyquist frequency of the A/D converters on the MCU, so for higher bandwidth sensing, the digital signal may be aliased. This can be remedied with simple passive low-pass filtering prior to sampling, or by simply choosing a better microcontroller.
Amplitude stability: This is not a specification in itself, but a description of several. Amplitude stability describes a sensor's change in sensitivity depending on its application, for instance over varying temperature or time (see below). Other specifications include: Zero g offset (voltage output at 0 g) Noise (sensor minimum resolution) Temperature range 38
Uses: The acceleration measurement has a variety of uses. The sensor can be implemented in a system that detects velocity, position, shock, vibration, or the acceleration of gravity to determine orientation (Doscher 2005) A system consisting of two orthogonal sensors is capable of sensing pitch and roll. This is useful in capturing head movements. A third orthogonal sensor can be added to the network to obtain orientation in three dimensional space. This is appropriate for the detection of pen angles, etc. The sensing capabilities of this network can be furthered to six degrees of spatial measurement freedom by the addition of three orthogonal gyroscopes. As a shock detector, an accelerometer is looking for changes in acceleration. This jerk is sensed as an overdamped vibration. Verplaetse has outlined the bandwidths associated with various implementations of accelerometers as an input device. These are: Location Head Hand , Wrist, Finger Usage Frequency Acceleration Tilt 0-8 Hz xx 0.04-1.0 g Cont. 8-12 Hz 41
Foot, Leg Cont. 0-12 Hz 0.2-6.6 g Depending on the sensitivity and dynamic range required, the cost of an accelerometer can grow to thousands of dollars. Nonetheless, highly accurate inexpensive sensors are available.
42
CHAPTER 5
43
44
5.3 INTRODUCTION TO EMBEDDED C: Ex: Hitec c, Keil c HI-TECH Software makes industrial-strength software development tools and C compilers that help software developers write compact, efficient embedded processor code. For over two decades HI-TECH Software has delivered the industry's most reliable embedded software development tools and compilers for writing efficient and compact code to run on the most popular embedded processors. Used by tens of thousands of customers including General Motors, Whirlpool, Qualcomm, John Deere and many others, HI-TECH's reliable development tools and C compilers, combined with world-class support have helped serious embedded software programmers to create hundreds of breakthrough new solutions. Whichever embedded processor family you are targeting with your software, whether it is the ARM, PICC or 8051 series, HI-TECH tools and C compilers can help you write better code and bring it to market faster. HI-TECH PICC is a high-performance C compiler for the Microchip PIC micro 10/12/14/16/17 series of microcontrollers. HI-TECH PICC is an industrial-strength ANSI C compiler - not a subset implementation like some other PIC compilers. The PICC compiler implements full ISO/ANSI C, with the exception of recursion. All data types are supported including 24 and 32 bit IEEE standard floating point. HI-TECH PICC makes full use of specific PIC features and using an intelligent optimizer, can generate high-
45
ANSI C - full featured and portable Reliable - mature, field-proven technology Multiple C optimization levels An optimizing assembler Full linker, with overlaying of local variables to minimize RAM usage Comprehensive C library with all source code provided Includes support for 24-bit and 32-bit IEEE floating point and 32-bit long data types
Mixed C and assembler programming Unlimited number of source files Listings showing generated assembler Compatible - integrates into the MPLAB IDE, MPLAB ICD and most 3rd-party development tools
46
49
50
Speed: Assembly language programs are generally the fastest programs around. Space: Assembly language programs are often the smallest. Capability: You can do things in assembly which are difficult or impossible in High level languages.
52
Knowledge: Your knowledge of assembly language will help you write better programs, even when using High level languages. An example of an assembler we use in our project is RAD 51.
5.6.2 Simulator: Simulator is a machine that simulates an environment for the purpose of training or research. We use a UMPS simulator for this purpose in our project. 5.6.3 UMPS: Universal microprocessor program simulator simulates a microcontroller with its external environment. UMPS is able to simulate external components connected to the microcontroller. Then, debug step is dramatically reduced. UMPS is not dedicated to only one microcontroller family, it can simulate all kind of microcontrollers. The main limitation is to have less than 64K-Bytes of RAM and ROM space and the good microcontroller library. UMPS provide all the facilities other low-cost simulator does not have. It offers the user to see the "real effect" of a program and a way to change the microcontroller family without changing IDE. UMPS provide a low-cost solution to the problems. UMPS is really the best solution to your evaluation. 5.6.4 UMPS key features: -The speed, UMPS can run as fast as 1/5 the real microcontroller speed. No need to wait 2 days to see the result of a LCD routine access. All the microcontroller parts are simulated, interrupts, communication protocol, parallel handshake, timer and so on. - UMPS have an integrated assembler/disassembler and debugger. It is able to accept an external assembler or compiler. It has a text editor which is not limited to 64K-bytes and 53
54
4. Regulators 7812 1 No, 7805 1 No 5. LCDs 2 Nos 6. IR Sensors Transmitters- 2 Nos, Receivers - 2 Nos
56
57
CHAPTER 6 RESULT
58
59
CHAPTER 7 CONCLUSION
60
61
CHAPTER 8 BIBILOGRAPHY
62
Bibliography: BOOKS: Customizing and programming ur pic microcontroller- Myke Predcko Complete guide to pic microcontroller -e-book C programming for embedded systems- Kirk Zurell Teach yourself electronics and electricity- Stan Giblisco Embedded Microcomputer system- onathan w.Valvano(2000) Embedded PIC microcontroller- John Peatman
63
64