Saturday, December 10, 2011

Control Video Lecture Industrial Automation and Control - PLC and Sequence Control, RLL, Structured Design

Lecture Video Introduction to Sequence Control, PLC , RLL



Lecture Video Sequence Control. Scan Cycle,Simple RLL Programs



Lecture Video Sequence Control More RLL Elements RLL Syntax




Lecture Video A Structured Design Approach to Sequence




Lecture Video PLC Hardware Environment


read more "Control Video Lecture Industrial Automation and Control - PLC and Sequence Control, RLL, Structured Design"

Friday, December 9, 2011

Control 2 Channel RF Remote Control Transmitter Using AT90S2323


This is the transmitter circuit that is controlled by microcontroller AT90S2323. This circuit is work based on TLP434 RF transmitter module at 418MHz. This circuit is design using low power supply that is for more battery economy and safe transmition of the data. Here’s figure of the transmitter circuit.



If you press the S2 key, the logic of this pin goes to '0' (0V) and AVR awake frome the sleep mode (because PB1 is INT0) and check if pressed the S1 key. If not, the AVR take as pressed key the S2. If yes the AVR take as pressed key the S1. If you press the S1 key the logic of this pin and PB1 (through 1N4148) goes to '0' (0V). In this case the AVR take as pressed key the S1. After, calculate the checksum and transmit 4 times the same 4 byte sequence to make sure that receiver takes the data and goes to sleep mode until next interrupt on PB1. When the INT0 pin (PB1) of AVR goes to 0V, the transmitter TLP434A is working. If you stop press the switch S1 or S2, the TLP is stop working. The safe transmition of the data based to transmition of 4 bytes with serial form at 2400 bps (bits per seconds). 1st and 2nd byte are for recognition of valid remote control from receiver (like ID bytes), 3rd byte is command byte. The relays status dependet by the value of this byte. Finally, the 4th byte is the checksum of the earlier 3 bytes.


read more "Control 2 Channel RF Remote Control Transmitter Using AT90S2323"

Control 2 Channel RF Remote Control Receiver Using AT902313


If the article before is about transmitter, so this is the receiver for the RF remote control. This circuit is using RF receiver module RLP434A at 418MHz. This circuit is control using microcontroller. The 2 relays with can handle any electric (or electronic) device up to 10 Amps (the contacts of my relays are 10Amp at 250Volts). Here’s the figure of the circuit.




The RLP434A is an RF receiver module with receipt frequency at 418MHz with ASK modulation. There are 2 outputs from this module, the digital, with levels from 0v to VCC (5 volts in our case) and the analog output. Analog output is not used. The transmitter send 4 bytes with 2400bps 4 times and the receiver RLP-434A, collect them and move them to AT90S2313 to RxD pin, PD0. AT90S2313 use a hardware UART adjusted at 2400bps and the hardware the UART is more stable, with smaller code, than software UART that I use in the transmitter. If some serial data arrive at the middle-time of some other routine other than receive routine, for sure we will loose this bits of data. The hardware UART does not have this problem because have buffer for this (UDR register).


read more "Control 2 Channel RF Remote Control Receiver Using AT902313"

Monday, December 5, 2011

Control Video Lecture Industrial Automation and Control - Feedforward Control Ratio Control and Time Delay Systems and Inverse Response Systems

Lecture Video Feedforward Control Ratio Control



Lecture Video Time Delay Systems and Inverse Response Systems



Lecture Video Special Control Structures



Lecture Video Concluding Lesson on Process Control

read more "Control Video Lecture Industrial Automation and Control - Feedforward Control Ratio Control and Time Delay Systems and Inverse Response Systems"

Schematic DB9 pin connector for RS232 serial Communication

Serial Communication

All communication we have dealt with up to now has been parallel. Data being transferred between one location and another (R0 to the accumulator, for example) travel along the 8-bit data bus. Because of this data bus, data bytes can be moved about the microcontroller at high speed.
However, parallel communication has the disadvantage of requiring at least eight separate lines (in an 8-bit system) and in most cases extra lines to synchronize the data transfer (in the case of the microcontroller, the control bus).
Serial communication has the advantage of requiring only one line for the data, a second line for ground and possibly a third line for the clock. Therefore, because serial communication requires less physical wires, it is more suitable for transmitting data over longer distances.
The obvious disadvantage of serial communication, compared with parallel, is the reduction in the data transfer rate. If we imagine a system where it takes 1us for data to settle on the data bus, we could say it takes 1us to transfer a data byte using parallel communication. If we imagine the same timeframe for data bits settling on the serial line, it would take 8us to transfer a data byte using serial communication (1us for each bit).

Synchronous Serial Communication
Synchronous serial communication requires an extra line for the clock signal. For serial communication, the 8-bit parallel data byte must be shifted down the serial line (in transmission). Therefore, one bit is followed by another. Some kind of system must be used to determine how long each bit is on the line. For example, the serial system designer may decide each bit will be on the line for 1us and, as explained above, transmission of the full eight bits would take 8us.
Asynchronous Serial Communication
A good example of asynchronous serial communication is the interface between a keyboard and a computer. In this case, the keyboard is the transmitter and the computer is the receiver. With asynchronous communication, a clock signal is not sent with the data. There are a number of reasons why this form of communication might be desirable over synchronous communication. One advantage is the fact that the physical line for the clock is not needed. Also, asynchronous communication is better over long distances. If we try to synchronize a remote receiver by sending the clock signal, due to propagation delays and interference, the validity of the clock is lost.
Another reason for not transmitting the clock arises when the data rate is erratic. For example, data rate from a keyboard to a computer is dependent upon the typist. The user may type at a rate of sixty words per minute, but at other times he/she may type a lot less. And for long periods there may be no data sent at all. Because of this erratic data rate an asynchronous communication system is suitable.
DB9 pin connector for RS232 serial Communication, How to wire the DB9 PIN connector to DB25 PIN connector

DB9 pin connector for RS232 serial Communication DB9 PIN to DB25 PIN conversion

The 8051 Serial Port
The 8051 includes an on-chip serial port that can be programmed to operate in one of four different modes and at a range of frequencies. In serial communication the data is rate is known as the baud rate, which simply means the number of bits transmitted per second. In the serial port modes that allow variable baud rates, this baud rate is set by timer 1.
The RS232 connector was originally developed to use 25 pins. In this DB25 connector pinout provisions were made for a secondary serial RS232 communication channel. In practice, only one serial communication channel with accompanying handshaking is present. Only very few computers have been manufactured where both serial RS232 channels are implemented. Examples of this are the Sun SparcStation 10 and 20 models and the Dec Alpha Multia. Also on a number of Telebit modem models the secondary channel is present. It can be used to query the modem status while the modem is on-line and busy communicating. On personal computers, the smaller DB9 version is more commonly used today. The diagrams show the signals common to both connector types in black. The defined pins only present on the larger connector are shown in red. Note, that the protective ground is assigned to a pin at the large connector where the connector outside is used for that purpose with the DB9 connector version.
The DB9 (originally DE-9) connector is an analog 9-pin plug of the D-Subminiature connector family (D-Sub or Sub-D).

The DB9 connector is mainly used for serial connections, allowing for the asynchronous transmission of data as provided for by standard RS-232 (RS-232C).




The only thing left is that we need some sort of connector to connect to the serial port. The sample code below is written for Comm1 and most computers use a 9 pin DB9 male connector for Comm1 so a 9 pin female connector is included for this project. We  also need  a DB9 extension cable to make the connection easier. There should be 3 wires soldered to the DB9 connector pins 2, 3 and 5. Connect the wire from pin 5 of the connector to ground on the breadboard. Connect the wire from pin 2 of the connector to pin 14 of the MAX232.
DB9 pin connector for RS232 serial Communication between humidity monitoring project and computer.

BACK to Content Page


 . Next Page


 .   Previous Page
DB9 pin connector for RS232 serial Communication,db9 pinout,db9 connector,db9 cable,db9 price,db9 serial port,aston martin,rs232,db9 serial
rs232 db9 connector,db9 connector datasheet,db25 connector,outlook connector,keyboard with 9 pin d connector,mini din connector,db9 connector configuration,15 pin,Converts a USB port into a 9-pin male RS-232 serial port, DB9 Serial Cables, DB9 mice mouse cable Cables Serial Cable Computer Cables Computer Cable Switch Box USB Switch boxes Monitor Cables Assembly cables.Shop for DB9 Cable Cables and Connectors Computer Accessories and read product reviews. Find cheap prices on DB9 Cable Cables and Connectors Computer,Serial (RS232) null modem cable (DB9-DB9). Pinout and signals for building a serial (RS232) nullmodem cable. Use this cable between two DTE devices,RS232 serial cables and adapters. Pinout and wiring layout for many situations. DB9 to DB25 conversion and null modem wiring diagrams.This creates an electrically continuous screen covering the whole cable and connector ... It is now common to see DE9 connectors sold as "DB9" connectors.Cables To Go offers a wide selection of DB9 RS-232 Cables ready to ship today! Need help? Chat with one of our cable experts.
read more "Schematic DB9 pin connector for RS232 serial Communication"

Schematic MAX 232 serial communication between humidity data acquisition unit and computer

The MAX232 requires 5 external 1uF capacitors. These are used by the internal charge pump to create +10 volts and -10 volts.
• For the first capacitor, the negative leg goes to ground and the positive leg goes to pin 16.
• For the second capacitor, the negative leg goes to 5 volts and the positive leg goes to pin 2.
• For the third capacitor, the negative leg goes to pin 3 and the positive leg goes to pin 1.
• For the fourth capacitor, the negative leg goes to pin 5 and the positive leg goes to pin 4.
• For the fifth capacitor, the negative leg goes to pin 6 and the positive leg goes to ground.
Max232 serial communication humidity data acquisition unit and PC

The MAX232 includes 2 receivers and 2 transmitters so two serial ports can be used with a single chip. We will only use one transmitter for this project. To power the MAX232, Connect pin 16 to 5 volts. Connect pin 15 to ground.
UART (Universal Asynchronous Receiver Transmitter) or USART (Universal Synchronous Asynchronous Receiver Transmitter) are one of the basic interface which you will find in almost all the controllers available in the market till date. This interface provide a cost effective simple and reliable communication between one controller to another controller or between a controller and PC.
RS-232 Level Converters

Usually all the digial ICs works on TTL or CMOS voltage levels which cannot be used to communicate over RS-232 protocol. So a voltage or level converter is needed which can convert TTL to RS232 and RS232 to TTL voltage levels.
The most commonly used RS-232 level converter is MAX232. This IC includes charge pump which can generate RS232 voltage levels (-10V and +10V) from 5V power supply. It also includes two receiver and two transmitters and is capable of full-duplex UART/USART communication.
MAX232 Interfacing with Microcontrollers

To communicate over UART or USART, we just need three basic signals which are namely, RXD (receive), TXD (transmit), GND (common ground). So to interface MAX232 with any microcontroller (AVR, ARM, 8051, PIC etc..) we just need the basic signals. A simple schematic diagram of connections between a microcontroller and MAX232.
Bits SM0 and SM1 let us set the serial mode to a value between 0 and 3, inclusive. The four modes are defined in the chart immediately above. As you can see, selecting the Serial Mode selects the mode of operation (8-bit/9-bit, UART or Shift Register) and also determines how the baud rate will be calculated. In modes 0 and 2 the baud rate is fixed based on the oscillators frequency. In modes 1 and 3 the baud rate is variable based on how often Timer 1 overflows. Well talk more about the various Serial Modes in a moment.

The next bit, SM2, is a flag for "Multiprocessor communication." Generally, whenever a byte has been received the 8051 will set the "RI" (Receive Interrupt) flag. This lets the program know that a byte has been received and that it needs to be processed. However, when SM2 is set the "RI" flag will only be triggered if the 9th bit received was a "1". That is to say, if SM2 is set and a byte is received whose 9th bit is clear, the RI flag will never be set. This can be useful in certain advanced serial applications. For now it is safe to say that you will almost always want to clear this bit so that the flag is set upon reception of any character.

TH1 = 256 - ((Crystal / 192) / Baud)
TH1 = 256 - ((11059000 / 192) / 19200)
TH1 = 256 - ((57699) / 19200)
TH1 = 256 - 3 = 253

MAX 232 serial communication between humidity data acquisition unit and computer

 BACK to Content Page

. Next Page

.   Previous Page
MAX 232 serial communication between humidity data acquisition unit and,computer,max232 circuit,max232 schematic,max232 datasheet,max232cpe,rs232,max232n,max233,max485,look rs232 software,serial port software,serial port rs232,docklight rs232 terminal rs232 monitor
read more "Schematic MAX 232 serial communication between humidity data acquisition unit and computer"

Sunday, December 4, 2011

Schematic Assembly Language program for LCD code

In this post some routine in Assembly language are written to interface lcd with microcontroller 8051.Most projects you create with the 8051 CPU or any other microcontroller  require some form of display. The display may be LED or LCD. But now use of LCD is increasing/ The most common way to accomplish this is with the LCD (Liquid Crystal Display). LCDs have become a cheap and easy way to get text display for an embedded system Common displays are set up as 16 to 20 characters by 1 to 4 lines. variate of LCD are available and most of them can work on thees ways describes in the sub routines.

Data to be Displayed on LCD using micro controller requires following set of instructions in the form of code as follows.
 lcd_datadisplay: // this is a part of main program call sub routine, the function of this sub routine is to display //data on lcd.
SETB RS //Telling the LCD that the data which is being send is to be displayed
MOV P1,A //Character to be displayed is in Acc
SETB EN // the enable pin of lcd is set to logic one
CLR EN //High to Low pulse on EN to latch the data
CALL DELAY //Delay so that LCD finishes its internal operations
 ret // return from this routine is called
Command or Special Instruction.
 lcd_command: // in this sub-routine of lcd program, how different commands are sent to lcd is shown
CLR RS //Telling the LCD that the data which is being send is a command
MOV P1,A //Character to be displayed is in Acc
SETB EN
CLR EN //High to Low pulse on EN to latch the data
CALL DELAY //Delay so that LCD finishes its internal operations
ret // returning to the main code from where this sub-routine was called
Busy flag checking
ready:  // In this sub-routine the busy flag is checked
setb P1.7 ;D7 as input
clr P3.6 ;RS=0 cmd
setb P3.5 ;RW=1 for read
again:
setb P3.7 ;H->L pulse on E
clr P3.7
jb P1.7, again
ret // returning back to main program where this function is called
Data write Routine
data: // in this sub-routine how data will be written on lcd is shown
mov P1, A ;//move acc. data to port
setb P3.6 ;RS=1 data
clr P3.5 ;RW=0 for write
setb P3.7 ;H->L pulse on E
clr P3.7
lcall ready
ret // end of this sub-routine
Command write Routine
command: // this is another sub-routine showing how to write commands on lcd, you can use any of these //cammand subroutine
mov P1, A ;move acc. data to port
clr P3.6 ;RS=0 for cmd
clr P3.5 ;RW=0 for write
setb P3.7 ;H->L pulse on E
clr P3.7
lcall ready
ret
Initialization of LCD
initialization: // in this sub-routine initialization of LCD is described

mov A, #38H ; Initialize, 2-lines, 5X7 matrix.
lcall Command
mov A, #0EH ; LCD on, cursor on
lcall Command
mov A, #01H ; Clear LCD Screen
lcall Command
mov A, #06H ; Shift cursor right
lcall Command
Display clear
clear: // this is sub-routine to clear the display of LCD
setb p3.7 ;enable EN
clr 3.6 ;RS=0 for cmd.
mov DATA,#01h
clr p3.7 ;disable EN
lcall ready
RET

Note- As we need to clear the LCD frequently and not the whole initialisation , it is better to use this routine separately.

Displaying "HI Friends"

lcall initialization
lcall clear
mov A,#'H'
acall data
mov A,#'I'
lcall data
mov A,#'F'
lcall data
mov A,#'r'
lcall data
lcall data
mov A,#'i'
lcall data
mov A,#'e'
lcall data
mov A,#'n'
lcall data
mov A,#'d'
lcall data
mov A,#'s'
ret
Now following is complete ASSEMBLY LANGUAGE code to show something on LCD
lcall Initialization
lcall clear
mov a,#'H'
lcall data
mov a,#'I'
lcall data
mov a,#8ah
lcall command
mov a,#'8'
lcall data
mov a,#'0'
lcall data
mov a,#'5'
lcall data
mov a,#'1'
lcall data
mov a,#'M'
lcall data
mov a,#'C'
lcall data
end

BACK to Content Page

. Next Page

.   Previous Page
flash programmer for at89c51,up counter based project,up counter chip manufacture with assembly language using 89c51 microcontroller,correlation flow METER 8051,program of 7 segment in 8515,4 CHANNEL RTC,RFID door access software flow diagram,Microcontroller into a Walt Meter assembly download,Microcontroller into a Watt Meter assembly download,AT89S52 PC PROJECTS,MICROCONTROLLER AT89C2051 BASED COUNT DOWN TIMER
read more "Schematic Assembly Language program for LCD code"