Home
PICPLC16B User Manual
Contents
1. P 4 x r b UE LOA p a VS Y P 4 4 y Fx PICPLC16B KEY FEATURES Power ON OFF switch Power supply 16 30V DC or 12 22V AC Isolated power supply for optocouplers Optocouplers inputs Optocouplers DIP switches SW4 and SW5 used to enable disable connection between optocouplers and MCU Development mode jumpers 8 Reset push button 9 USB connector 10 On board 2 0 USB programmer 11 RS 232 communication port 12 Reference voltage 13 A D converter input D HU I m D e 3 2 z S al LI i D am POR m s PR ce B B m BER a SERIAL ETHERNET MikroElektronika SONOS Up up 14 RS 485 communication port 15 MCU socket with PIC18F4520 microcontroller 16 DIP switch SW1 used to enable disable pull up pull down resistors on PORTA and PORTE pins 17 DIP switch SW2 used to enable disable RS232 RS 485 communication and MOSI MISO and 5 lines 18 DIP switch SW3 used to enable disable Ethernet con nection 19 Direct port access connectors 20 Ethernet communication port 21 DIP switches SW6 and SW7 enable disable relays 22 Relays 23 Relays outputs and 24 Change over contact wu rh d Si 48805 1 R 1 a
2. OMAN gt 0 uo 1983002 0M 9 of 2 SOFTWARE AND HARDWARE SOLUTIONS FOR EMBEDDED WORLD 5 OSQHOOUADOOUPHOO USER MANUAL DO DIRECT PORT ACCESS CONNECTORS All microcontroller input output pins can be accessed via IDC 10 2x5 connectors placed along the right side of the board For each microcontroller port there 15 one 10 pin connector providing up to eight port pins and two additional pins connected to VCC and GND These connectors can be used to connect the system to external devices such as Serial Ethernet Compact Flash keyboard etc If external and on board peripherals use the same pins then on board peripherals must be disconnected from the microcontroller by setting the appropriate jumpers switches The connectors can also be used for attaching logic probes or other test equipment PORT ACCESS CONNECTORS Figure 26 Flat cable connector MikroElektroniKa software AND HARDWARE SOLUTIONS FOR EMBEDDED WORLD USER MANUAL Pull down line is J6 connected s 1 U RN2 6 RB4 RB6 8 RB7 9 DIRECT PORT ACCESS S SOFTWARE AND HARDWARE SOLUTIONS FOR EMBEDDED WORLD MikroElektronika oDexyoed Ordid ul NOW
3. Ajddns S SOFTWARE AND HARDWARE SOLUTIONS FOR EMBEDDED WORLD MikroElektronika No part of this manual including the product and software described in it may be reproduced transmitted transcribed stored in a retrieval system or translated into any language in any form or by any means excepting the documentation kept by the purchaser for backup purposes without expressed written permission of MikroElektronika company Product warranty or service will not be extended if the product is repaired modified or altered unless such repair modification or alteration is authorized in writing by MikroElektronika MikroElektronika provides this manual as is without warranty of any kind either expressed or implied including but limiting implied warranties conditions of merchantability fitness for a particular purpose In no event shall MikroElektronika its directors officers employees or distributors be liable for any indirect specific incidental or consequential damages whatsoever including damages for loss of business profits and business information business interruption or any other pecuniary loss arising from any defect or error in this manual or product even if MikroElektronika has been advised of the possibility of such damages Specification and information contained in this manual are furnished for internal use only and are subject to change at any time
4. The microcontroller PORTB pins cannot provide enough current necessary to directly run relays and they are connected to the ULN2804 Darlington drivers therefore Ports RB and RD must be driven low 1 e pulled down so that relays can be switched on when the microcontroller sets a logic one on any of its outputs Each relay has one LED connected in parallel with its coil It is used to indicate whether pe the appropriate relay is active or not Reley outputs consist of three con tacts normally open normally closed and change over thus enabling any device to be connected to it 1 For example if you connect light bulb as per Figure 23 it will be turned on by relay activation 1 e whenever appropriate MCU output is driven high RLY1 VCC REL E R31 MCU Port Driver IE 4 mE ULN2804 gt 220 Light bulb connection MikroElektroniKa software AND HARDWARE SOLUTIONS FOR EMBEDDED WORLD SANDER s e os MikroElektronika PICxxxx J zai oo ii YL 19 6 840 Vd H 2 VINOO s uo paso yD LAAN UMOP INd uo 1983002 LM 0 Aajay uo
5. PERIPHERALS Figure 9 USB 2 0 programmer circuit diagram MikroElektroniKa software AND HARDWARE SOLUTIONS FOR EMBEDDED WORLD USER MANUAL POWER SUPPLY SUPERVISOR AND RESET CIRCUIT 5 In industrial environment it is very important to have a reliable device capable of performing under different conditions The most important issue for all electronic circuits is a stable power supply However in harsh environments there can be some deviations from the power supply nominal values A power supply supervisor monitors power supply level and restarts the microcontroller if it is too low or too high It can also be connected to reset button thus generating reset signal when the button is pressed Figure 10 Power supply supervisor VCC VCC VCC VCC R66 R63 R65 10K 100 10K VCC eee RESET L e RESET OUT to MCU C26 100nF R64 C28 E27 10K 100nF 10uF E RESET BUTTON Figure 11 Power supply supervisor circuit diagram POWER SUPPLY SUPERVISOR AND RESET GCUIRGWIT SOFTWARE AND HARDWARE SOLUTIONS FOR EMBEDDED WORLD MikroElektronika USER MANUAL 4 VOLTAGE REFERENCE 5 Voltage reference is electronic circuit that produces fixed constant voltage which in our case am
6. sKejay qe ecc a CCC OC B nas f M m E EI EJ wi sew S DDdJid d m O129UUOO 58 EJ m I F4 JO 22 204 m 2 ss900e 4 Eu s m 7 E an ES uod ws tsou gt o sox m E 987 54 E t KRI o p E pu EJ ttj wm ow Cwom QNOOBA s Mw T 510 E ELI cay SIS9J uMOp nd D OQV Jo dn jnd pe E owes oeuuoo Ul 99UE 2117720 N KAKKA Y SHI 135 SUNG 39 ONITIVIEN O4 woad indui 92U9J9J9 d E E 7 b E3 ES A960 v 4 xe pue XL 5 cec SH 00 951 Es FLUE 857 in eee OR CVS CAO Ue qO JosiMedns OV Acc cV O 9l Q z gsn usnd 19594 sJej dooojdo jddns
7. T 1 T 1 1 1 14 i Y 2404 1 5 y SOFTWARE AND HARDWARE SOLUTIONS FOR EMBEDDED WORLD MANUAL CONNECTING THE SYSTEM USER SCODQUS OH AUOOTP DO AJ e Q Gi Apart from this manual the PLC Programmable Logic Controller system box contains PICPLCI6B system product CD USB cable RS232 cable and user s manual for the PICPLC16B In order to use the PICPLC16B properly it is necessary to go through the fol lowing steps Step no 1 Take your development system and product CD out of the box Insert the prod uct CD into CD drive Please do not connect development system to PC yet le SYSTEMI Step no 2 Install PICFlash2 programmer software to enable a program to be trans ferred from PC to the microcontroller chip Installation instructions are con tained in the PICFlash 2 programmer manual Step no 3 Install USB drivers on your PC to enable programmer s hardware to ope rate properly on the PICPLC16B board For detailed installation instruc tions refer to the nstalling USB drivers manual Step no 4 Connect the PICPLC16B to external power supply and for programming to PC using USB cable Please use one of USB ports on the back of the PC because they are directly connected to the computer motherboard The first time you switch the PICPLC16B on your PC will automatically detect a new hardware You will be immediately prompted whether Win
8. dows should search for new drivers update or not Select the option No not this time and click Another window appears click Next and the operating system will automatically find the drivers Click Finish to com plete this process and run P CFlash 2 as explained in PICFlash 2 program mer manual Next time you switch the PICPLC16B on Windows will not ask for new drivers update during driver installation CONNECTING Tl After these four steps your PICPLCIOB 15 successfully installed and ready for use You can read a program from the chip or write a new one into it The product CD provides numerous simple program examples that will make your first steps Easy SOFTWARE AND HARDWARE SOLUTIONS FOR EMBEDDED WORLD MikroElektronika INTRODUCTION PICPLCI16B is a programmable logic controller design to control devices in industry and automatics using relays It has a built in programmer so that there is no need for additional hardware for the microcontroller programming Besides this controller has inputs isolated by optocouplers 12 bit A D converter RS 232 and RS 485 communication modules and Ether net communication module as well Four IDC 10 male connectors enable the PICPLC16B to be directly connected to the microcontroller pins if needed Figure 1 illustrates the PICPLC16B development system As seen there are identification marks next to ea
9. 220uF 35 4 E2 E3 E1 o L2 POWER SUPPLY SWITCH U12 7 8 220uF 35 2200 35 VCC VCC Power supply circuit diagram SOFTWARE AND HARDWARE SOLUTIONS FOR EMBEDDED WORLD MikroElektronika 5 ON BOARD USS 2 0 PROGRAMMER USER MANUAL ON BOARD USB 2 0 PROGRAMMER 8 There is no need to use external equipment during pro Teo JU gramming as the PICPLC16B development system has RESET Ec its own on board USB 2 0 programmer All you need to do is to connect the system to PC using USB cable enable Development MODE by setting E 184 jumpers J1 J2 J3 and in the left hand position and RC SEEEN turn the power switch on 4 ON BOARD PROGRAMMER Am __ 12 m t MEI EU AM Use the PI Cflash2 programming software supplied with the Li board to load a program into microcontroller USB 2 0 programmer L _ 100 5 vC D Development MODE 30 USB ENABLED DISABLED GND J USB LINK USB CONNECTOR R6 1K VCC ex ve RB7 i RB6 PICflash 4 POWER On Board R5 1K MCLR USB 27 26 100 Supply Voltage Supervisor cim VCC m 2 m w O Z i
10. E3MikroElektronika SOFTWARE AND HARDWARE SOLUTIONS FOR EMBEDDED WORLD waking it sigle PIGPLOT6B t TT TIT Big gt Lad 0 as F p Hi IBPICPLCIGB 3 With useful implemented peripherals plentiful practical code examples and a broad set of add on boards Serial Ethernet Compact Flash MMC SD etc MikroElektronika development boards make fast and reliable tools that can satisfy the needs of experienced engineers and beginners alike USB 2 0 IN CIRCUIT TOUCH PROGRAMMER SCREEN TO OUR VALUED CUSTOMERS want to express my thanks to you for being interested in our products and having confidence in MikroElektronika It is our intention to provide you with the best quality products Furthermore we will continue to improve our performance to better suit your needs Nebojsa Matic General Manager DISCLAIMER All products owned by MikroElektronika protected by copyright international copyright treaty Therefore you should treat this manual as any other copyright material The manual and products may not be copied partially or as a whole without written consent of MikroElektronika Manual PDF edition be printed for private local use but for distribution Modifying manuals products is prohibited HIGH RISK ACTIVITIES The products of MikroElektro
11. RT485 RX485 and TX485 and communication lines MISO MOSI and SCK DIP switch SW3 enables Ethernet connection DIP switches SW4 and SWS enable disable optocouplers inputs and DIP switches SW6 and SW7 enable disable connection between MCU and relays SWITCHES AND JUMPERS x JUMPERS Similarly jumpers are used to break or establish connection between two points Under the plastic cover of a jumper there is a metal contact which establishes connection when the jumper is placed over two pins Jumper is commonly used as a selector between two possible connections via 3 pin connec tor As illustrated in Figure 3 the middle connector pin can be connected to the left or right pin depending on the jumper s position Jumper is not Jumper is placed Jumper is placed placed and on the right side on the left side middle pin is connecting middle connecting mid unconnected and right pin dle and left pin Jumper as a selector SOFTWARE AND HARDWARE SOLUTIONS FOR EMBEDDED WORLD MikroElektronika MANUAL MCU PORT 2 The PICPLCI6B comes with 40 pin microcontrollers PIC18F4520 in DIP40 package The microcontroller pins are routed to various peripherals ports are directly connected to Direct Port Access Connectors which are normally used for connecting external peripherals to the board or as points for connecting digital logi
12. c probes i Some pins are connected to other peripherals such as optocouplers RS 232 communication RS 485 communication etc MCU PORT g Pull up pull down 965 5 Pod resistors P J5 E RNI VCC XIX x i 1 P AX JUS 1 OC3 RA FA SE E JORE ES p oc on Pod Pod P TE i VCC i n 1 2630 I m m m m m gt Figure 5 System connection MikroElektroniKa software AND HARDWARE SOLUTIONS FOR EMBEDDED WORLD USER Lor MANUAL e POWER SUPPLY The PICPLC16B can use two independet power supply sources One of them is PICPLC16B board power supply and the other is 1solated power supply for optocouplers Power supply for PICPLCI6B board can be AC or DC AC power supply voltage ranges between 12 and 22V whereas DC power supply voltage ranges between 16 and 30V Isolated power supply for optocouplers is denoted by OCVCC on the board Figure 6 illustrates power supply connector POWER SUPPLY Figure 6 Power supply connector CN1 PWR 1 DB1 B250C1500 E5 E6 220uF 35 2200 35 012 220 35 220uF 35 220uF 35
13. ch component on a silkscreen both on the top and bottom These marks describe connections to the microcontroller operation modes and provide other useful infor mation so that there is almost no need for additional schematics 2144 4 dj RRERERERR Li cnm E St BLY LS LS m v9 RRRBREBR og R ne ae LI w LIS 503 G P CPLCIGB ZRRRER 14 4 Dna ls TL SERIAL ETHERNET 8 35523234 88855 D E 2B E MikroElektroniKa software AND HARDWARE SOLUTIONS FOR EMBEDDED WORLD USER MANUAL SWITCHES The PICPLC16B development system features a number of peripheral devices In order to enable them before programming the appropriate jumpers or switches have to be properly set Switches are mechanical devices used to establish or break connection between two contacts The PICPLC16B development system has seven groups of switches HS gt Switchison amp x T 69 J 9 a s Switch is amp Switches 1 2 3 and 4 are ON DIP switch SW1 is used to enable external pull up pull down resistors on PORTA and PORTE DIP switch SW2 is used to enable disable lines between RS 232 module RX232 and TX232 RS 485 module
14. le system the microcon troller is connected to LTCA85 via three switches 3 4 and 5 of DIP switch SW2 55 mE 4 Figure 16 RS 485 communication COMMUNICATION RS 485 circuit diagram MikroElektroniKa software AND HARDWARE SOLUTIONS FOR EMBEDDED WORLD USER CODQUOODRDOOHPDO MANUAL ON BOARD SERIAL ETHERNET Ethernet is a most commonly used Local Area Network LAN technology today On the top of physical layer Ethernet stations mutually communicate by sending data packets to each other Each station is assigned a single 48 bit MAC address which is used to specify both destination and source of each data packet VCC3 3C LEDB C10 22pF 25 MHz C9 22pF VCC3 3C FP1 FERRITE BEAD Figure 19 Ethernet circuit diagram SOFTWARE AND HARDWARE SOLUTIONS FOR EMBEDDED WORLD MikroElektronika MANUAL 4G OPTOCOUPLERS 5 The PICPLC16B has 16 optocouplers inputs Optocouplers are widely used in industrial applications where inputs must be galvanized 1 electrically isolated from the rest of devel opment board The main idea 15 to protect the microcontroller from voltage spikes that might occur on input lines ABI Pen aw 4 4t NE 7 A OPTOGOUIPLERS Figure 20 Optocoupler group In order that input circuit is elec
15. nika not fault tolerant nor designed manufactured or intended for use or resale as on line control equipment in hazardous environments requiring fail safe performance such as in the operation of nuclear facilities aircraft navigation or communication systems air traffic control direct life support machines or weapons systems in which the failure of Software could lead directly to death personal injury or severe physical or environmental damage High Risk Activities MikroElektronika and its suppliers specifically disclaim any expressed or implied warranty of fitness for High Risk Activities LICENSE AGREEMENT By using our products you agree to be bound by all terms of this agreement Copyright by MikroElektronika 2003 2008 PIC and MPLAB are registered trademarks of Microchip Company Windows is a registered trademark of Microsoft Corporation All other trade and or service marks are the property of the respective owners zd cc LLI QO QO CONTENTS ecccccon PICPLC16B KEY FEATURES 4 S CONNECTING THE SYSTEM 5 Z INTRODUCTION 6 2 Switches and Jumpers 7 e MCU Ports 8 TE Power Supply 9 On Board USB 2 0 Programmer 10 Power Supply Supervisor and Reset Circuit 11 Cc Reference Voltage 12 RS 232 Communication 13 RS 485 Communication 14 On Board Serial Ethernet 15 LH Optocouplers 16 lt Relays 18 Direct Port Access 20 V
16. ounts to 4 096V It is used in both Analog to Digital ADC and Digital to Analog Converter DAC to specify input and output voltage ranges Voltage Reference Voltage reference circuit diagram VOLTAGE REFERENCE MikroElektroniKa software AND HARDWARE SOLUTIONS FOR EMBEDDED WORLD USER CODQUOODRQDOOHPDO MANUAL RS 232 COMMUNICATION 15 ___ SUPPLY Oo RS 232 communication enables point to point data trans 56282 Eom S fer It is commonly used in data acquisition applications to 122 transfer data between the microcontroller and PC Since the voltage levels of the microcontroller and PC are not direct ly compatible with each other a level converter such as MAX232 must be used RS 232 COMMUNICATION T2out R2in beds ot i i Serial Cable c RS232 circuit diagram SOFTWARE AND HARDWARE SOLUTIONS FOR EMBEDDED WORLD MikroElektronika MANUAL 4 Al RS 485 COMMUNICATION q 5 RS 485 communication enables point to point and point to multi point data transfer It is commonly used to enable data transfer between several microcontrollers LTC485 interface transceiver is few used for transforming signal on microcontrollers Rt Rx and Tx lines into a differential signal on A and B lines The PICPLC16B development board has one RS 485 communica tion device In order to provide more flexib
17. trically isolated from the rest of board it must have its own power supply 12V DC The optocoupler chip has one LED on each input and one open col lector transistor on each output pin The first 8 optocoupler outputs are connected to the microcontroller PORTA and PORTE the other 8 optocouplers outputs are connected to the microcontroller PORTC PORTA E and PORTC must be driven high by putting jumpers J5 and J7 in the upper position MikroElektroniKa software AND HARDWARE SOLUTIONS FOR EMBEDDED WORLD MANUAL 12V _ OCVCC OCGND CN4 POSSIBLE INPUT FOR OPTOCOUPLERS OCGND and OCVCC belong to external power supply Optocoupler power OCVCC OPTOCOUPLERS 55 iE gt 1N4148 OCVCC R17 HCPL2630 330 Pull up line is connected Before the button When the button is is pressed levelis pressed level is high inactive state low active state RPACK8 9 Figure 21 Optocoupler circuit diagram SOFTWARE AND HARDWARE SOLUTIONS FOR EMBEDDED WORLD MikroElektronika MANUAL RELAYS 5 In order to control devices which use high power for their operation the PICPLC16B has 16 relays connected to the microcontroller PORTB and PORTD The relay coil voltage amounts to 12V DC 012 RELAYS s AE Ce 5 PEN SES os
18. without notice and should be construed as a commitment by MikroElektronika MikroElektronika assumes no responsibility or liability for any errors or inaccuracies that may appear in this manual including the product and software described in it Product and corporate names appearing in this manual may or may not be registered trademarks or copyrights of their respective companies and are used only for identification or explanation and to the owners benefit with no intent to infringe a Eu IC O 2 e OD c E Y MY ww Nn m MMA AN E 1 8 e 3 9 E 4 E N Y eoeoo eoeooo 99 P IV Y Y LYOddNS TVIINHDAL MOU SN jeuonippe 15 10 5 uno Aue nof JI 2 Velo IV Y sN 12e1u02 jesodoud e JUBWIWWOD uonsenb 1 1 Aue nof yi m s yc ev SNOILNTIOS 3HVMQS VH 38VM1JOS
Download Pdf Manuals
Related Search
Related Contents
RCA RMW1131 User's Manual eClient 620L Manuel d`utilisation Hampton Bay 55296 Use and Care Manual pericolo - Schneider Electric Nebulizadores térmicos de alto rendimiento Trasmettitori di posizione elettronici 4200 Fisher Select the recording mode for best image recordings. High montage 86369 - Care Fitness Operating Instructions Copyright © All rights reserved.
Failed to retrieve file