The Datasheet Archive - 100 Million Datasheets from 7500 Manufacturers.    


Datasheet Search Engine   
 
Part # or Description: • 5V RS232 Driver • 2SC5066* • "Real Time Clock" • "USB connector" • "blue led" 5mm • 10 watt zener diode • 2N3055* motorola
 
Search Tip: Try entering the part number only. Include a wildcard (eg. lm317* or 1n4148*)

 

 

INCLUDES: Passive RFID Basics Application Note MCRF355/360 Data Sheet


Datasheet Thumbnail

  

Download PDF



Top Searches for this datasheet



microID13.56 RFID System Design Guide
INCLUDES: Passive RFID Basics Application Note MCRF355/360 Data Sheet Microchip Development Sample Format MCRF355/360 Factory Programming Support (SQTPSM) MCRF355/360 Applications Application Note Antenna Circuit Design Application Note 13.56 Reader Reference Design Contact Programmer Reference Design
CUSTOMER NOTIFICATION SYSTEM
Register site (www.microchip.com/cn) receive most current information products.
1999 Microchip Technology Inc.
July 1999 /DS21299C
DATA SHEET MARKINGS
Microchip uses various data sheet markings designate each document phase relates product development stage. markings appear bottom data sheet, between copyright document page numbers. definitions each marking provided below your use. Marking Advance Information Description information products design phase. Your designs should finalized with this information revised information will published when product becomes available. This preliminary information products production fully characterized. specifications these data sheets subject change without notice. Before finalize your design, please ensure that have most current revision data sheet contacting your Microchip sales office. Information contained data sheet products full production.
Preliminary
Marking
"All rights reserved. Copyright 1999, Microchip Technology Incorporated, USA. Information contained this publication regarding device applications like intended through suggestion only superseded updates. representation warranty given liability assumed Microchip Technology Incorporated with respect accuracy such information, infringement patents other intellectual property rights arising from such otherwise. Microchip's products critical components life support systems authorized except with express written approval Microchip. licenses conveyed, implicitly otherwise, under intellectual property rights. Microchip logo name registered trademarks Microchip Technology Inc. U.S.A. other countries. rights reserved. other trademarks mentioned herein property their respective companies. licenses conveyed, implicitly otherwise, under intellectual property rights."
Trademarks Microchip name logo, PICmicro registered rademarks Microchip Technology Incorporated U.S.A. microID RFLAB trademarks Microchip Technology Inc. Serialized Quick Turn Programming (SQTP) service mark Microchip Technology Inc. other trademarks mentioned herein property their respective companies.
July 1999 /DS21299C
1999 Microchip Technology Inc.
Table Contents
PAGE
PASSIVE RFID BASICS
Introduction Definitions System Handshake Backscatter Modulation Data Encoding Data Modulation Anticollision
13.56 PASSIVE RFID DEVICE WITH ANTICOLLISION
Features Application Package Type Description Layout Coordinates (Microns) Electrical characteristics Functional Description Device Programming MCRF355/360 Guide Product Identification System
MICROCHIP DEVELOPMENT SAMPLE FORMAT MCRF355/360 FACTORY PROGRAMMING SUPPORT (SQTPSM)
Introduction File Specification
MCRF 355/360 APPLICATIONS
Introduction Mode Operation Anticollision Features External Circuit Configuration Programming Device
ANTENNA CIRCUIT DESIGN
Introduction Review Basic Theory RFID antenna Design Induced Voltage Antenna Coil Wire Types Ohmic Losses Inductance Various Antenna Coils Configuration Antenna Circuits Consideration Quality Factor Bandwidth Tuning Circuit Resonant Circuits Tuning Method Read Range RFID Devices References
1999 Microchip Technology Inc.
DS21299C-page
Table Contents
PAGE
13.56 READER REFERENCE DESIGN
Introduction Reader Circuits Optimization Long-Range Applications Reader Schematic Reader Bill Materials Reader Source Code PICmicro®
CONTACT PROGRAMMER
Introduction Hardware Firmware Interface Contact Programmer Schematic Contact Programmer Bill Materials Contact Programmer Source Code PICmicro®
RECOMMENDED ASSEMBLY FLOWS
Wafer Frame Assembly Flow Wafer Assembly Flow
WORLDWIDE SALES SERVICE
DS21299C-page
1999 Microchip Technology Inc.
AN680
Passive RFID Basics
Author: Pete Sorrells Microchip Technology Inc.
Modulation
Periodic fluctuations amplitude carrier used transmit data back from reader. Systems incorporating passive RFID tags operate ways that seem unusual anyone already understands microwave systems. There only transmitter passive transmitter transponder purest definition term, bidirectional communication taking place. field generated reader (the energy transmitter) three purposes: Induce enough power into coil energize tag. Passive tags have battery other power source; they must derive power operation from reader field. 13.56 designs must operate over vast dynamic range carrier input, from very near field range VPP) maximum read distance range VPP). Provide synchronized clock source tag. Many RFID tags divide carrier frequency down generate on-board clock state machines, counters, etc., derive data transmission rate data returned reader. Some tags, however, employ onboard oscillators clock generation. carrier return data from tag. Backscatter modulation requires reader peak-detect tag's modulation reader's carrier. page additional information backscatter modulation.
INTRODUCTION
Radio Frequency Identification (RFID) systems radio frequency identify, locate track people, assets, animals. Passive RFID systems composed three components interrogator (reader), passive tag, host computer. composed antenna coil silicon chip that includes basic modulation circuitry non-volatile memory. energized time-varying electromagnetic radio frequency (RF) wave that transmitted reader. This signal called carrier signal. When field passes through antenna coil, there voltage generated across coil. This voltage rectified supply power tag. information stored transmitted back reader. This often called backscattering. detecting backscattering signal, information stored fully identified.
DEFINITIONS
Reader
Usually microcontroller-based unit with wound output coil, peak detector hardware, comparators, firmware designed transmit energy read information back from detecting backscatter modulation.
RFID device incorporating silicon memory chip (usually with on-board rectification bridge other front-end devices), wound printed input/output coil, lower frequencies) tuning capacitor.
Carrier
Radio Frequency (RF) sine wave generated reader transmit energy retrieve data from tag. these examples frequencies 13.56 assumed; higher frequencies used RFID tagging, communication methods somewhat different. 2.45 GHz, example, uses true link. 13.56 MHz, utilize transformer-type electromagnetic coupling.
1998 Microchip Technology Inc.
DS00680B-page
AN680
SYSTEM HANDSHAKE
Typical handshake reader follows: reader continuously generates carrier sine wave, watching always modulation occur. Detected modulation field would indicate presence tag. enters field generated reader. Once received sufficient energy operate correctly, divides down carrier begins clocking data output transistor, which normally connected across coil inputs. tag's output transistor shunts coil, sequentially corresponding data which being clocked memory array. Shunting coil causes momentary fluctuation (dampening) carrier wave, which seen slight change amplitude carrier. reader peak-detects amplitude-modulated data processes resulting bitstream according encoding data modulation methods used.
BACKSCATTER MODULATION
This terminology refers communication method used passive RFID send data back reader. repeatedly shunting coil through transistor, cause slight fluctuations reader's carrier amplitude. link behaves essentially transformer; secondary winding (tag coil) momentarily shunted, primary winding (reader coil) experiences momentary voltage drop. reader must peak-detect this data about down (about riding 100V sine wave) shown Figure This amplitude-modulation loading reader's transmitted field provides communication path back reader. data bits then encoded further modulated number ways.
FIGURE
AMPLITUDE MODULATED BACKSCATTERING SIGNAL
100V
DS00680B-page
1998 Microchip Technology Inc.
AN680
DATA ENCODING
Data encoding refers processing altering data bitstream in-between time retrieved from RFID chip's data array transmission back reader. various encoding algorithms affect error recovery, cost implementation, bandwidth, synchronization capability, other aspects system design. Entire textbooks written subject, there several popular methods used RFID tagging today: (Non-Return Zero) Direct. this method data encoding done all; clocked from data array directly output transistor. peak-detected modulation high `1'. Differential Biphase. Several different forms differential biphase used, general bitstream being clocked data array modified that transition always occurs every clock edge, distinguished transitions within middle clock period. This method used embed clocking information help synchronize reader bitstream; because always transition clock edge, inherently provides some error correction capability. clock edge that does contain transition data stream error used reconstruct data. Biphase_L (Manchester). This variation biphase encoding which there always transition clock edge.
FIGURE
SIGNAL
VARIOUS DATA CODING WAVEFORMS
WAVEFORM DESCRIPTION
Data
Digital Data
Rate
Clock Signal
NRZ_L (Direct)
Non-Return Zero Level represented logic high level. represented logic level.
Biphase_L (Manchester)
Biphase Level (Split Phase) level change occurs middle every clock period. represented high level change midclock. represented high level change midclock.
Differential Biphase_S
Differential Biphase Space level change occurs middle every clock period. represented change level start clock. represented change level start clock.
1998 Microchip Technology Inc.
DS00680B-page
AN680
DATA MODULATION
Although data transferred host amplitude-modulating carrier (backscatter modulation), actual modulation accomplished with three additional modulation methods: Direct. direct modulation, Amplitude Modulation backscatter approach only modulation used. high envelope `0'. Direct modulation provide high data rate noise immunity. (Frequency Shift Keying). This form modulation uses different frequencies data transfer; most common mode Fc/8/10. other words, transmitted amplitude-modulated clock cycle with period corresponding carrier frequency divided transmitted amplitude-modulated clock cycle period corresponding carrier frequency divided amplitude modulation carrier thus switches from Fc/8 Fc/10 corresponding bitstream, reader only count cycles between peak-detected clock edges decode data. allows simple reader design, provides very strong noise immunity, suffers from lower data rate than some other forms data modulation. Figure data modulation used with encoding. (Phase Shift Keying). This method data modulation similar FSK, except only frequency used, shift between accomplished shifting phase backscatter clock degrees. common types are: Change phase `0', Change phase data change provides fairly good noise immunity, moderately simple reader design, faster data rate than FSK. Typical applications utilize backscatter clock Fc/2, shown Figure
FIGURE
MODULATED SIGNAL, FC/8 FC/10
cycles
cycles
cycles
cycles
cycles
FIGURE
MODULATED SIGNAL
Phase Shift
Phase Shift
Phase Shift
Phase Shift
DS00680B-page
1998 Microchip Technology Inc.
AN680
ANTICOLLISION
many existing applications, single-read RFID sufficient even necessary: animal tagging access control examples. However, growing number applications, simultaneous reading several tags same field absolutely critical: library books, airline baggage, garment, retail applications few. order read multiple tags simultaneously, reader must designed detect condition that more than active. Otherwise, tags will backscatter carrier same time, amplitude-modulated waveforms shown Figures would garbled. This referred collision. data would transferred reader. tag/reader interface similar serial bus, even though "bus" travels through air. wired serial application, arbitration necessary prevent contention. RFID interface also requires arbitration that only transmits data over "bus" time. number different methods development today preventing collisions; most patented patent pending, related making sure that only "talks" (backscatters) time. MCRF355/360 Data Sheet (page 13.56 Reader Reference Design (page chapters more information regarding MCRF355/360 anticollision protocol.
1998 Microchip Technology Inc.
DS00680B-page
AN680
NOTES:
DS00680B-page
1998 Microchip Technology Inc.
MCRF355/360
13.56 Passive RFID Device with Anticollision
FEATURES
Frequency operation: 13.56 Built-in anticollision algorithm reading tags same field "Cloaking" feature minimizes detuning effects adjacent tags Manchester coding protocol Data modulation frequency: bits user-programmable memory Contact programming factory-programmed options Very power CMOS design Die, wafer, PDIP SOIC package options On-chip resonance capacitor (MCRF360) Read-only device after programming device needs external antenna coils pick magnetic fields also send back encoded (modulated) data reader. antenna coils connected series. first coil (L1) connected between Antenna Antenna second coil (L2) connected between Antenna VSS. MCRF355 requires external capacitor form resonant circuit along with antenna coils. Figure details. MCRF360 internal resonance capacitor between Antenna (across coils). This capacitance utilized form tuned circuit along with external antenna coils. Section external resonant circuits. device includes modulation transistor that located between Antenna VSS. This modulation gate used send data reader. modulation transistor designed result approximately resistance between Drain, which connected Antenna Source, which connected VSS, when turned-on. circuit tuned operating frequency (13.56 MHz) reader when modulation transistor turned-off condition. This condition called uncloaking. modulation transistor turns there will shorting effect across resistance across This results change inductance antenna coil, and, therefore, circuit longer resonates 13.56 MHz. This condition called cloaking. occurrence cloaking uncloaking device controlled modulation signal that turns modulation transistor off, resulting communication from device reader. data stream consists bits Manchesterencoded data. code waveforms shown Figure 6-3. data sent reader modulating (AM) carrier signal (13.56 MHz). After completion data transmission, device goes into sleep mode 40%. device repeats transmitting sleep cycles long energized. Sleep time determined built-in, low-current timer. variation sleep time approximately 20%. variation sleep time between each device results randomness time slot. Each device wakes transmits data different
APPLICATION
Signal Interrogator Data MCRF355
PACKAGE TYPE
PDIP/SOIC VPRG Ant.
Ant.
DESCRIPTION
MCRF355 MCRF360 Microchip's newest additions microIDfamily RFID tagging devices. They uniquely designed read-only passive Radio Frequency Identification (RFID) devices with advanced anticollision feature, operating 13.56 MHz. device powered remotely rectifying magnetic fields that transmitted from interrogator (reader). device total pads (see Layout). Three used connect external resonant circuit elements. additional three pads used programming testing device.
microID trademark Microchip Technology Inc.
1999 Microchip Technology Inc.
Preliminary
DS21287C-page
MCRF355/360
time slot with respect each other. Based this scenario, reader able read many tags that same field. device total bits contact reprogrammable memory. bits reprogrammable contact programmer. contact programmer (part number PG103003) available from Microchip Technology Inc. Factory programming prior shipment, known Serialized Quick Turn ProgrammingSM (SQTPSM), also available. device available form packaged SOIC PDIP. Note: Information provided herein preliminary subject change without notice.
LAYOUT
Ant.
VPRG
Ant.
Antenna Coil Antenna Coil
COORDINATES (MICRONS)
Name Ant. Ant. VPRG Lower Lower Left Left -610.0 -605.0 -605.0 463.4 463.4 463.4 489.2 -579.8 -58.2 -181.4 496.8 157.6 Upper Right -521.0 -516.0 -516.0 552.4 552.4 552.4 Upper Right 578.2 -490.8 30.8 -92.4 585.8 246.6 Passivation Openings Width Height Center Center -565.5 -560.5 -560.5 507.9 507.9 507.9 533.7 -535.3 -13.7 -136.9 541.3 202.1
Note coordinates referenced from center die. minimum distance between pads (edge edge) mil. Size 1.417 1.513
Serialized Quick Turn Programming (SQTP) service mark Microchip Technology Inc.
DS21287C-page
Preliminary
1999 Microchip Technology Inc.
MCRF355/360
ELECTRICAL CHARACTERISTICS
TABLE 5-1:
Name Ant. Ant. VPRG
FUNCTION TABLE
Function
Storage temperature 65°C +150°C Ambient temp. with power applied .-40°C +125°C Maximum current into coil pads
*Notice: Stresses above those listed under "Maximum ratings" cause permanent damage device. This stress rating only functional operation device those other conditions above those indicated operational listings this specification implied. Exposure maximum rating conditions extended periods affect device reliability.
Connected antenna coil Connected antenna coils Connected antenna coil Device ground during test mode. voltage supply programming Main clock pulse device Input/Output programming read test.
TABLE 5-2:
CHARACTERISTICS
parameters apply across Commercial (C): Tamb -20oC 70oC specified operating ranges, unless otherwise noted. Parameters Reading voltage Hysteresis voltage Operating current Testing voltage Programming voltage: High level input voltage level input voltage High voltage Current leakage during sleep time Modulation resistance Symbol VDDR VHYST IDDR VDDT IDD_OFF VDDT VDDT Units External voltage programming testing 2.4V during reading 25°C Conditions voltage reading
Note resistance between Drain Source gates modulation transistor (when turned VPRG internal pull-down resistor
Pull-Down resistor
RPDW
Note: This parameter tested production.
1999 Microchip Technology Inc.
Preliminary
DS21287C-page
MCRF355/360
TABLE 5-3: CHARACTERISTICS
Commercial (C): Tamb -20oC 50oC parameters apply across specified operating ranges, unless otherwise noted. Parameters Operating frequency Modulation frequency Coil voltage during reading Coil clamp voltage Test mode clock frequency Sleep time Internal resonant capacitor (MCRF360) Resonant frequency (MCRF360) Write/Erase pulse width Clock high time Clock time Stop condition pulse width Stop condition setup time Setup time high voltage High voltage delay time Data input setup time Data input hold time Output valid from clock Data retention
Symbol VPP_AC VCLMP_AC Fclk TOFF CRES
Units Manchester
Conditions
13.5598 13.56 13.5602 Carrier frequency Peak-to-Peak voltage across coil during reading Peak -to-Peak coil clamp voltage 25°C time anticollision feature, 25°C Internal resonant capacitor between Antenna 13.56 MHz)
THIGH TLOW TPW:STO TSU:STO TSU:HH TDL:HH TSU:DAT THD:DAT
12.93
13.56 1000
14.30
with 1.377 Time program bit, 25°C 25°C 25°C 25°C 25°C 25°C Delay time before next clock, 25°C 25°C 25°C 25°C
Years 120°C
TABLE 5-4:
Coil current
ABSOLUTE MAXIMUM/MINIMUM RATINGS
Symbol Units Conditions Peak-to-Peak coil current
Parameters Maximum Power Dissipation Assembly temperature Storage temperature
IPP_AC
PMPD TASM TSTORE
DS21287C-page
Preliminary
1999 Microchip Technology Inc.
MCRF355/360
FUNCTIONAL DESCRIPTION
6.1.3 DATA MODULATION device contains three major sections. first Front-End section, second Controller Logic, third Memory section. Figure shows block diagram device. data modulation circuit consists modulation transistor (MOSFET) 1-turn antenna coil (L2). connected parallel. transistor designed result less than ohms (RM) between Antenna VSS. transistor turns transistor shorts and, therefore, external circuit detuned (cloaking). Cloaking uncloaking occur driving transistor off, respectively. Therefore, since data encoded Manchester format, data will sent uncloaking cloaking transistor each. Similarly, data will sent cloaking uncloaking transistor each.
Front-End Section
Front-End section includes power supply, power-on-reset, data modulation circuits. 6.1.1 POWER SUPPLY
power supply circuit generates voltage (VDD) rectifying induced coil voltage. power supply circuit includes high-voltage clamping diodes prevent excessive voltage development across antenna coil. 6.1.2 POWER-ON-RESET (POR)
This circuit generates power-on-reset when first enters reader field. reset releases when sufficient power developed regulator allow correct operation.
FIGURE 6-1:
BLOCK DIAGRAM
CONTROLLER LOGIC MEMORY Address Pulse Data Wake-up Signal 154-Bit Memory Array Column Drivers (High Voltage Circuit)
FRONT-END
Power Supply Power Reset Modulation
Column Decoders Clock Generator Modulation Logic
Modulation Pulse
Sleep Timer (anticollision) Read/Write Logic Test Logic
Set/Clear
VPRG
1999 Microchip Technology Inc.
Preliminary
DS21287C-page
MCRF355/360
Antenna
MCRF360 requires external inductor capacitance order resonate 13.56 MHz. About one-fourth turns inductor should connected between Antenna VSS; remaining turns should connected between Antenna Antenna MCRF355 1.377 inductor plus external capacitance order resonate 13.56 MHz. Figure 6-2(a) shows configuration external circuit MCRF355. external antenna coils series capacitor that connected across inductors form parallel resonant circuit pick incoming signals also send back modulated signals reader. first coil (L1) connected between Antenna Antenna second coil (L2) connected between Antenna VSS. capacitor connected between Antenna VSS. Figure 6-2(b) shows another configuration external circuit MCRF355. this case, resonant circuit formed capacitors inductor. Figure 6-2(c) shows configuration external circuit MCRF360.
FIGURE 6-2:
CONFIGURATION EXTERNAL RESONANT CIRCUITS
Carrier Interrogator Data Signal
Antenna MCRF355 Antenna
Where: Mutual Inductance between
Carrier Interrogator Data Signal
Antenna
MCRF355 Antenna
-C1C2
Antenna Carrier Interrogator Data Signal MCRF360 Antenna
10045
Where: Mutual Inductance between
DS21287C-page
Preliminary
1999 Microchip Technology Inc.
MCRF355/360
6.3.1
Controller Logic
CLOCK PULSE GENERATOR
6.3.3
SLEEP TIMER
This circuit generates clock pulse (CLK). clock pulse generated on-board, time-base oscillator. clock pulse used baud rate timing, data modulation rate, etc. 6.3.2 MODULATION LOGIC
This circuit generates sleep time (100 40%) anticollision feature. During this sleep time (TOFF), modulation transistor remains turned-on condition (cloaked) which detunes resonant circuit away from operating frequency (13.56 MHz). 6.3.4 READ/WRITE LOGIC
This logic acts upon serial data (154 bits) being read from memory array. data then converted Manchester code. code waveforms shown Figure 6-3. encoded data then modulation gate Front-End section.
This logic controls reading programming memory array.
FIGURE 6-3:
SIGNAL Data
CODE WAVEFORMS
WAVEFORM DESCRIPTION
Digital Data Internal Clock Signal
NRZ-L (Reference only)
Non-Return Zero Level represented logic high level. represented logic level.
BIPHASE-L (Manchester)
Biphase Level (Split Phase) level change occurs middle every clock period. represented high level change midclock. represented high level change midclock.
Note:
NRZ-L signals shown reference only. NRZ-L output device
1999 Microchip Technology Inc.
Preliminary
DS21287C-page
MCRF355/360
DEVICE PROGRAMMING
Timing
Apply VDDT voltage VDD. Leave VSS, CLK, VPRG ground. Load mode code into VPRG pad. VPRG sampled high edge. above mode function (3.2.2) will executed when last code entered. Power device (VDD VSS) exit programming mode. alternative method exit programming mode bring logic "High" before VPRG (high voltage). programming mode entered after exiting current function.
MCRF355/360 contact programmable device. device bits programmable memory. programmed following procedure. programmer, part number PG103003, also available from Microchip.) 7.0.1 PROGRAMMING LOGIC
Programming logic enabled applying power device clocking device while loading mode code VPRG (See Examples through test definitions). Both VPRG pads have internal pull-down resistors.
Configuration
Programming Mode
Erase Code: Program Code: Read Code: 0111010100 0111010010 0111010110
Connect antenna pads ground.
Note:
means logic "Low" (VIL) means logic "High" (VIH).
Signal Timing
Examples through show timing sequence programming reading device.
EXAMPLE 7-1:
Number: VPRG:
PROGRAMMING MODE ERASE
Note:
Erases entire array state between Number
DS21287C-page
Preliminary
1999 Microchip Technology Inc.
MCRF355/360
EXAMPLE 7-2:
Number:
PROGRAMMING MODE PROGRAM
CLK: Pulse high program Leave leave VPRG:
VHH.
Program Program #153
Note:
Pulsing VPRG programming time while holding programs `0'.
EXAMPLE 7-3:
Number: CLK:
PROGRAMMING MODE READ
VPRG:
VIH. data data
Turn programmer drive during high MCRF355 drive VPRG.
#153 data
EXAMPLE 7-4:
TIMING DATA
THIGH TLOW
CLK: THD:DAT Vprg: TSU:STO TSU:DAT VIH. TSU:HH TDL:HH TPW:STO
1999 Microchip Technology Inc.
Preliminary
DS21287C-page
MCRF355/360
MCRF355/360 GUIDE PRODUCT IDENTIFICATION SYSTEM
order obtain information, e.g., pricing delivery, please refer factory listed sales office. MCRF355 Sawed wafer frame backgrind) Bumped, sawed wafer frame backgrind) Wafer backgrind) Bumped wafer backgrind) Dice waffle pack Bumped waffle pack SOIC PDIP
Package:
Temperature Range: Part Number:
-20°C +50°C MCRF355 13.56 Anticollision device MCRF360 13.56 Anticollision device with on-chip resonance capacitance
Sales Support
Data Sheets Products supported preliminary Data Sheet have errata sheet describing minor operational differences recommended workarounds. determine errata sheet exists particular device, please contact following: Your local Microchip sales office Microchip Corporate Literature Center U.S. FAX: (480) 786-7277 Microchip Worldwide Site (www.microchip.com) Please specify which device, revision silicon Data Sheet (include Literature using. Customer Notification System Register site (www.microchip.com/cn) receive most current information products.
DS21287C-page
Preliminary
1999 Microchip Technology Inc.
TB031
Microchip Development Sample Format
Header
111111111
Bytes User Data
16-Bit Checksum
Customer Byte Byte Byte Byte Checksum Checksum Number
header customer number bits user data bits zeros between each byte, header, checksum bits checksum Total: Notes: Users program bits MCRF355/360. array programmed custom format with combination bits. format presented here used Microchip microIDDevelopment System (DV103003) ordered production material with unique customer number. TB032 information ordering custom programmed production material. Microchip Development System (DV103003) uses nine (111111111) header. preprogrammed samples development have 11(= 0001 0001) customer number. development system, users program customer number byte) plus bytes user data, they deselect "Microchip Format" option MicroIDRFLAB program bits format. When users program samples using MicroIDRFLAB, RFLAB calculates checksum bytes) automatically adding bytes (customer number bytes user data), into checksum field device memory. Example details. When programmed energized reader field, outputs bits data. When demo reader detects data from tag, reports bytes data (customer number plus bytes user data) host computer header checksum correct. reader does send header checksum host computer. "MicroIDRFLab" simple terminal program such "terminal.exe" used read reader's output digits) host computer. When demo reader used terminal mode ("terminal.exe), tag's data appear after first dummy ASCII characters (GG). Example details. bits
EXAMPLE 7-1:
CHECKSUM
Checksum (xxxxxxxx xxxxxxxx) Byte Byte Byte Customer Number byte)
EXAMPLE 7-2:
READER'S OUTPUT TERMINAL MODE ("TERMINAL.EXE")
demo reader outputs GG+28 digits, i.e., 12345678901234567890ABCDEFGF. first ASCII characters (GG) dummy characters. tag's data next digits (112 bits) after first ASCII characters (GG).
1999 Microchip Technology Inc.
DS91031B-page
TB031
NOTES:
DS91031B-page
1999 Microchip Technology Inc.
TB032
MCRF355/360 Factory Programming Support (SQTPSM)
INTRODUCTION
MCRF355 MCRF360 13.56 tags which contact programmed. contact programming device performed user factory-programmed Microchip Technology, Inc. upon customer request. bits data programmed format pattern defined customer. factory programming, codes series numbers must supplied customer algorithm specified customer. This technical brief describes only case which identification codes (ID) series numbers supplied. customer supply codes series numbers floppy disk email. codes must conform Serialized Quick Turn ProgrammingSM (SQTPSM) format below: code files compressed, they should self-extracting files. code files used alphabetical order their file names (including letters numbers). Used (i.e., programmed) code files discarded Microchip after use. Each line code file must contain code code hexadecimal format. code line exactly bits characters, where last bits last character don't cares). Each line must with carriage return. Each hexadecimal code must preceded decimal series number. Series number code must separated space. series number must unique ascending avoid double programming. series numbers consecutive files must also count proper linking.
FILE SPECIFICATION
SQTP codes supplied Microchip must comply with following format: code file plain ASCII text file from floppy disk email headers).
FIGURE
EXAMPLE SEQUENTIAL CODE FILES
Filename FILE0000.TXT 00001 00002 00003 12345 Code Series Number Carriage Return
Last Code
Filename Next Code FILE0001.TXT 12346 12347 Code File
Space Necessary
Serialized Quick Turn Programming (SQTP) service mark Microchip Technology inc.
1998 Microchip Technology Inc.
DS91032A-page
TB032
NOTES:
DS91032A-page
1998 Microchip Technology Inc.
AN707
MCRF 355/360 Applications
Author: Youbok Lee, Ph.D. Microchip Technology Inc.
ohms) between Drain Source. This gate turns during logic "High" period modulation signal otherwise. When gate turns turnon resistance shorts external circuit between Antenna ground pad. Therefore, resonant frequency circuit changes. This called detuned cloaking. Since detuned frequency band reader, reader can't modulation gate turns modulation signal goes logic "Low." This turn-off condition again tunes resonant circuit frequency reader antenna. Therefore reader sees again. This called tuned uncloaking. coil induces maximum voltage during "uncloaking (tuned)" minimum voltage during cloaking (detuned). Therefore, cloaking uncloaking events develop amplitude modulation signal coil. This amplitude modulated signal coil perturbs voltage envelope reader coil. reader coil maximum voltage during cloaking (detuned) minimum voltage during uncloaking (tuned). detecting voltage envelope, data signal from readily reconstructed. Once device transmits bits data, goes into "sleep mode" about wakes from sleep time (100 transmits data package goes into sleep mode again. device repeats transmitting sleep cycles long energized.
INTRODUCTION
MCRF355 passive RFID device designed cost, multiple reading, various high volume tagging applications using frequency band 13.56 MHz. device total memory bits that reprogrammed contact programmer. device operates with data rate, asynchronously with respect reader's carrier. device turns when coil voltage reaches outputs data with Manchester format (see Figure data sheet). With given data rate kHz), takes about transmit bits data. After transmitting data, device goes into sleep mode 50%. MCRF355 needs only external parallel resonant circuit that consists antenna coil capacitor operation. external components must connected between antenna ground pads. circuit formed between Antenna ground must tuned operating frequency reader antenna.
MODE OPERATION
device transmits data tuning detuning resonant frequency external circuit. This process accomplished using internal modulation gate (CMOS), that very turn-on resistance
FIGURE
VOLTAGE ENVELOPE READER COIL
When cloaking
When uncloaking
microID trademark Microchip Technology Inc. rights reserved.
1999 Microchip Technology Inc.
DS00707A-page
AN707
FIGURE UNCLOAKING (TUNED) CLOAKING (DETUNED) MODES THEIR RESONANT FREQUENCIES
13.56
MCRF355
Coil voltage
MCRF355
13.56
13.56
MCRF355
Coil voltage
MCRF355
13.56
DS00707A-page
1999 Microchip Technology Inc.
AN707
ANTICOLLISION FEATURES
During sleep mode, device remains cloaked state where circuit detuned. Therefore, reader can't during sleep time. While sleep mode, reader receive data from other tags. This enables reader receive clean data from many tags without data collision. This ability read multiple tags same field called anticollision. Theoretically, more than tags read same field. However, affected distance from reader, angular orientation, movement tags, spacial distribution tags.
FIGURE
Data Packet
EXAMPLE READING MULTIPLE TAGS
Data Packet
Sleep
Reading data from
Reading data from Reading data from Reading data from
1999 Microchip Technology Inc.
DS00707A-page
AN707
EXTERNAL CIRCUIT CONFIGURATION
Since device transmits data tuning detuning antenna circuit, caution must given external circuit configuration. better modulation index, differences between tuned detuned frequencies must wide enough (about MHz). Figure shows various configurations external circuit. choice configuration must chosen depending form-factor tag. example, better choice printed circuit tags while, better candidate coil-wound tags. Both relate MCRF355. configuration (a), tuned resonance frequency determined total capacitance inductance from Antenna VSS. During cloaking, internal switch (modulation gate) shorts Antenna VSS. Therefore, inductance shorted out. result, detuned frequency determined total capacitance inductance When shorting inductance between Antenna VSS, detuned (cloak) frequency higher than tuned (uncloak) frequency configuration (b), tuned frequency (uncloak) determined inductance total capacitance between Antenna VSS. circuit detunes (cloak) when shorted. This detuned frequency (cloak) lower than tuned (uncloak) frequency MCRF360 includes internal capacitor. This device needs only external inductor operation. explanation tuning detuning same configuration (a).
FIGURE
VARIOUS EXTERNAL CIRCUIT CONFIGURATIONS
MCRF355
Ant.
tuned detuned
where:
Ant.
mutual inductance coupling coefficient inductors
inductors capacitor MCRF355 Ant.
tuned detuned
Ant. capacitors inductor
MCRF360
Ant.
tuned detuned
Ant.
inductors with internal capacitor
DS00707A-page
1999 Microchip Technology Inc.
AN707
PROGRAMMING DEVICE
memory bits MCRF355/360 reprogrammable contact programmer factory programming prior shipment, known Serialized Quick Turn ProgrammingSM (SQTPSM). more information about contact programming, page microID13.56 System Design Guide (DS21299). information about SQTP programming, please TB032 (DS91032), page design guide.
Serial Quick Turn Programming (SQTP) Service Mark Microchip Technology Inc.
1999 Microchip Technology Inc.
DS00707A-page
AN707
NOTES:
DS00707A-page
1999 Microchip Technology Inc.
AN710
Antenna Circuit Design
Author: Youbok Lee, Ph.D. Microchip Technology Inc.
REVIEW BASIC THEORY RFID ANTENNA DESIGN
Current Magnetic Fields
Ampere's states that current flowing conductor produces magnetic field around conductor. magnetic field produced current element, shown Figure round conductor (wire) with finite length given
INTRODUCTION
Passive RFID tags utilize induced antenna coil voltage operation. This induced voltage rectified provide voltage source device. voltage reaches certain level, device starts operating. providing energizing signal, reader communicate with remotely located device that external power source such battery. Since energizing communication between reader accomplished through antenna coils, important that device must equipped with proper antenna circuit successful RFID applications. signal radiated effectively linear dimension antenna comparable with wavelength operating frequency. However, wavelength 13.56 22.12 meters. Therefore, difficult form true antenna most RFID applications. Alternatively, small loop antenna circuit that resonating frequency used. current flowing into coil radiates near-field magnetic field that falls with r-3. This type antenna called magnetic dipole antenna. 13.56 passive applications, microhenries inductance hundred resonant capacitor typically used. voltage transfer between reader coils accomplished through inductive coupling between coils. typical transformer, where voltage primary coil transfers secondary coil, voltage reader antenna coil transferred antenna coil vice versa. efficiency voltage transfer increased significantly with high circuits. This section written coil designers RFID system engineers. reviews basic electromagnetic theories antenna coils, procedure coil design, calculation measurement inductance, antenna tuning method, read range RFID applications.
EQUATION
where: current distance from center wire permeability free space given 10-7 (Henry/meter) Weber
special case with infinitely long wire where:
-180°
Equation rewritten
EQUATION
Weber
FIGURE
CALCULATION MAGNETIC FIELD LOCATION CURRENT STRAIGHT CONDUCTING WIRE
Wire (into page)
1999 Microchip Technology Inc.
DS00710A-page
AN710
magnetic field produced circular loop antenna given
FIGURE
EQUATION
coil
CALCULATION MAGNETIC FIELD LOCATION CURRENT LOOP
where current radius loop distance from center wire permeability free space given 10-7 (Henry/meter)
FIGURE
above equation indicates that magnetic field strength decays with 1/r3. graphical demonstration shown Figure maximum amplitude plane loop directly proportional both current number turns, Equation often used calculate ampere-turn requirement read range. examples that calculate ampere-turns field intensity necessary power will given following sections.
DECAYING MAGNETIC FIELD DISTANCE
DS00710A-page
1999 Microchip Technology Inc.
AN710
INDUCED VOLTAGE ANTENNA COIL
Faraday's states that time-varying magnetic field through surface bounded closed path induces voltage around loop. Figure shows simple geometry RFID application. When reader antennas close proximity, time-varying magnetic field that produced reader antenna coil induces voltage (called electromotive force simply EMF) closed antenna coil. induced voltage coil causes flow current coil. This called Faraday's law. induced voltage antenna coil equal time rate change magnetic flux
EQUATION
where: magnetic field given Equation surface area coil inner product (cosine angle between vectors) vectors surface area Both magnetic field surface vector quantities.
Note:
EQUATION
where: number turns antenna coil magnetic flux through each turn
negative sign shows that induced voltage acts such oppose magnetic flux producing This known Lenz's emphasizes fact that direction current flow circuit such that induced magnetic field produced induced current will oppose original magnetic field. magnetic flux Equation total magnetic field that passing through entire surface antenna coil, found
presentation inner product vectors Equation suggests that total magnetic flux that passing through antenna coil affected orientation antenna coils. inner product vectors becomes maximized when cosine angle between degree, field surface coil) perpendicular each other. maximum magnetic flux that passing through coil obtained when coils (reader coil coil) placed parallel with respect each other. This condition results maximum induced voltage coil also maximum read range. inner product expression Equation also expressed terms mutual coupling between reader coils. mutual coupling between coils maximized above condition.
FIGURE
BASIC CONFIGURATION READER ANTENNAS RFID APPLICATIONS
Coil
V0sin(t) B0sin(t)
I0sin(t) Reader Electronics Tuning Circuit Reader Coil
1999 Microchip Technology Inc.
DS00710A-page
AN710
Using Equations Equation rewritten above equation, quality factor measure selectivity frequency interest. will defined Equations through
EQUATION
FIGURE
ORIENTATION DEPENDENCY ANTENNA
B-field
where: voltage coil current reader coil radius reader coil radius coil distance between coils mutual inductance between reader coils, given induced voltage developed across loop antenna coil function angle arrival signal. induced voltage maximized when antenna coil placed parallel with incoming signal where
EXAMPLE
CALCULATION B-FIELD COIL
EQUATION
MCRF355 device turns when antenna coil develops across This voltage rectified device starts operate when reaches VDC. B-field induce coil voltage with standard 7810 card size (85.6 0.76 calculated from coil voltage equation using Equation
above equation equivalent voltage transformation typical transformer applications. current flow primary coil produces magnetic flux that causes voltage induction secondary coil. shown Equation coil voltage largely dependent mutual inductance between coils. mutual inductance function coil geometry spacing between them. induced voltage coil decreases with r-3. Therefore, read range also decreases same way. From Equations generalized expression induced voltage tuned loop coil given
EQUATION
2fNSQBo 0.0449 2fNSQ µwbm
where following parameters used above calculation: coil size Frequency (85.6 (ISO card size) 0.0046224 13.56 (normal direction,
EQUATION
2fNSQB where: frequency arrival signal number turns coil loop area loop square meters (m2) quality factor circuit strength arrival signal angle arrival signal
Number turns
antenna coil coil voltage turn
DS00710A-page
1999 Microchip Technology Inc.
AN710
EXAMPLE NUMBER TURNS CURRENT (AMPERETURNS) EXAMPLE OPTIMUM COIL DIAMETER READER COIL
optimum coil diameter that requires minimum number ampere-turns particular read range found from Equation such
Assuming that reader should provide read range inches (38.1 given previous example, current number turns reader antenna coil calculated from Equation
EQUATION
EQUATION
where:
0.0449 0.38 0.43 ampere turns
taking derivative with respect radius
above result indicates that needs turn coil, 2-turn coil.
above equation becomes minimized when: above result shows relationship between read range optimum coil diameter. optimum coil diameter found
EQUATION
where: radius coil read range.
result indicates that optimum loop radius, 1.414 times demanded read range
1999 Microchip Technology Inc.
DS00710A-page
AN710
WIRE TYPES OHMIC LOSSES
Wire Size Resistance
diameter electrical wire expressed American Wire Gauge (AWG) number. gauge number inversely proportional diameter, diameter roughly doubled every wire gauges. wire with smaller diameter higher resistance. resistance conductor with uniform cross-sectional area found
EXAMPLE
skin depth copper wire 13.56 calculated
EQUATION
EQUATION
where: total length wire conductivity cross-sectional area
0.0179
0.187
wire resistance increases with frequency, resistance skin depth called resistance. approximated formula resistance given
Table shows diameter bare enamel-coated wires, resistance.
EQUATION
where: coil radius
Resistance Wire
charge carriers evenly distributed through entire cross section wire. frequency increases, reactance near center wire increases. This results higher impedance current density region. Therefore, charge moves away from center wire towards edge wire. result, current density decreases center wire increases near edge wire. This called skin effect. depth into conductor which current density falls 1/e, value along surface, known skin depth function frequency permeability conductivity medium. skin depth given
EQUATION
where: frequency permeability material conductivity material
DS00710A-page
1999 Microchip Technology Inc.
AN710
TABLE
Wire Size (AWG)
WIRE CHART
Dia. Mils (bare) 289.3 287.6 229.4 204.3 181.9 162.0 166.3 128.5 114.4 101.9 90.7 80.8 72.0 64.1 57.1 50.8 45.3 40.3 35.9 32.0 28.5 25.3 22.6 20.1 17.9 Dia. Mils (coated) 131.6 116.3 106.2 93.5 83.3 74.1 66.7 59.5 52.9 47.2 42.4 37.9 34.0 30.2 28.0 24.2 21.6 19.3 Ohms/ 1000 0.126 0.156 0.197 0.249 0.313 0.395 0.498 0.628 0.793 0.999 1.26 1.59 2.00 2.52 3.18 4.02 5.05 6.39 8.05 10.1 12.8 16.2 20.3 25.7 32.4 Cross Section (mils) 83690 66360 52620 41740 33090 26240 20820 16510 13090 10380 8230 6530 5180 4110 3260 2580 2060 1620 1290 1020 Wire Size (AWG) Dia. Mils (bare) 15.9 14.2 12.6 11.3 10.0 1.76 1.57 1.40 1.24 1.11 0.99 Dia. Mils (coated) 17.2 15.4 13.8 12.3 11.0
Ohms/ 1000 41.0 51.4 65.3 81.2 106.0 1080 1320 1660 2140 2590 3350 4210 5290 6750 8420 10600
Cross Section (mils) 79.2 64.0 50.4 39.7 31.4 25.0 20.2 16.0 12.2 9.61 7.84 6.25 4.84 4.00 3.10 2.46 1.96 1.54 1.23 0.98
Note: 2.54 10-3
Note: 2.54
1999 Microchip Technology Inc.
DS00710A-page
AN710
INDUCTANCE VARIOUS ANTENNA COILS
electric current element that flows through conductor produces magnetic field. This time-varying magnetic field capable producing flow current through another conductor this called inductance. inductance depends physical characteristics conductor. coil more inductance than straight wire same material, coil with more turns more inductance than coil with fewer turns. inductance inductor defined ratio total magnetic flux linkage current through inductor:
Inductance Straight Wound Wire
inductance straight wound wire shown Figure given
EQUATION
0.002l where: length radius wire respectively.
EXAMPLE EQUATION
where: number turns current magnetic flux (Henry)
INDUCTANCE CALCULATION STRAIGHT WIRE:
inductance wire with feet (304.8cm) long diameter calculated follows:
EQUATION
0.002 304.8 304.8 0.60967 7.965 4.855
coil with multiple turns, inductance greater spacing between turns becomes smaller. Therefore, antenna coil that formed limited space often needs multilayer winding reduce number turns.
Calculation Inductance
Inductance coil calculated many different ways. Some readily available from references[1-4]. must remembered that coils actual resulting inductance differ from calculated true result because distributed capacitance. that reason, inductance calculations generally used only starting point final design.
Inductance Thin Film Inductor with Rectangular Cross Section
Inductance conductor with rectangular cross section shown Figure calculated
FIGURE
STRAIGHT THIN FILM INDUCTOR
EQUATION
0.002l 0.50049 where: width thickness length conductor
DS00710A-page
1999 Microchip Technology Inc.
AN710
Inductance Circular Coil with Single Turn
inductance circular coil shown Figure calculated
Inductance N-turn Circular Coil with Multilayer FIGURE N-TURN CIRCULAR COIL WITH SINGLE LAYER
N-turns coil Center coil
FIGURE
CIRCULAR COIL WITH SINGLE TURN
EQUATION
0.01257 2.303log
Figure shows N-turn inductor circular coil with multilayer. inductance calculated
EQUATION
0.31
where: mean radius loop (cm) diameter wire (cm) where:
average radius coil number turns winding thickness winding height
Inductance N-turn Circular Coil with Single Layer
inductance circular coil with single layer calculated
EQUATION
-22.9l 25.4a where: number turns length radius coil
1999 Microchip Technology Inc.
DS00710A-page
AN710
Inductance Spiral Wound Coil with Single Layer
inductance spiral inductor calculated EQUATION
Inductance N-turn Square Loop Coil with Multilayer
Inductance multilayer square loop coil calculated
EQUATION
0.008aN 2.303log 0.2235 0.726 where: number turns side square measured center rectangular cross section winding winding length winding depth shown Figure
FIGURE
SPIRAL COIL
Note: dimensions
FIGURE
N-TURN SQUARE LOOP COIL WITH MULTILAYER
View
Cross Sectional View
DS00710A-page
1999 Microchip Technology Inc.
AN710
Inductance Flat Square Coil
Inductance flat square coil rectangular cross section with turns calculated by[4]:
EQUATION
0.2235 0.0467aN 2.414a 0.02032aN 0.914
where: side length inches thickness inches width inches
FIGURE
SQUARE LOOP INDUCTOR WITH RECTANGULAR CROSS SECTION
formulas inductance widely published provide reasonable approximation relationship between inductance number turns given physical size[1-4]. When building prototype coils, wise exceed number calculated turns about then remove turns achieve right value. production coils, best specify inductance tolerance rather than specific number turns.
1999 Microchip Technology Inc.
DS00710A-page
AN710
CONFIGURATION ANTENNA CIRCUITS
Reader Antenna Circuits
inductance reader antenna coil 13.56 typically range microhenries (µH). antenna formed aircore ferrite core inductors. antenna also formed metallic conductive trace board flexible substrate. reader antenna made either single coil, that typically forming series parallel resonant circuit, double loop (transformer) antenna coil. Figure shows various configurations reader antenna circuit. coil circuit must tuned operating frequency maximize power efficiency. tuned resonant circuit same bandpass filter that passes only selected frequency. tuned circuit related both read range bandwidth circuit. More this subject will discussed following section. Choosing size type antenna circuit depends system design topology. series resonant circuit results minimum impedance resonance frequency. Therefore, draws maximum current resonance frequency. Because simple circuit topology relatively cost, this type antenna circuit suitable proximity reader antenna. other hand, parallel resonant circuit results maximum impedance resonance frequency. Therefore, maximum voltage available resonance frequency. Although minimum resonant current, still strong circulating current that proportional circuit. double loop antenna coil that formed parallel antenna circuits also used. frequency tolerance carrier frequency output power level from read antenna regulated government regulations (e.g., USA). limits 13.56 frequency band follows: Tolerance carrier frequency: 13.56 0.01% 1.356 kHz. Frequency bandwidth: kHz. Power level fundamental frequency: mv/m meters from transmitter. Power level harmonics: -50.45 down from fundamental signal.
transmission circuit including antenna coil must designed meet limits.
FIGURE
VARIOUS READER ANTENNA CIRCUITS
Series Resonant Circuit
Parallel Resonant Circuit
(secondary coil)
(primary coil)
reader electronics Transformer Loop Antenna
DS00710A-page
1999 Microchip Technology Inc.
AN710
Antenna Circuits
MCRF355 device communicates data tuning detuning antenna circuit (see AN707). Figure shows examples external circuit arrangement. external circuit must tuned resonant frequency reader antenna. detuned condition, circuit element between antenna pads shorted. frequency difference (delta frequency) between tuned detuned frequencies must adjusted properly optimum operation. been found that maximum modulation index maximum read range occur when tuned detuned frequencies separated MHz. tuned frequency formed from circuit elements between antenna pads without shorting antenna pad. detuned frequency found when antenna shorted. This detuned frequency calculated from circuit between antenna pads excluding circuit element between antenna pads. Figure (a), tuned resonant frequency detuned frequency
EQUATION
detuned this case, fdetuned higher than tuned Figure 13(b) shows another example external circuit arrangement. This configuration controls tuned detuned frequencies. tuned untuned frequencies
EQUATION
tuned
EQUATION
detuned typical inductance coil about microhenry with turns. Once inductance determined, resonant capacitance calculated from above equations. example, coil inductance then needs capacitance resonate 13.56 MHz.
EQUATION
where: Total inductance between antenna pads inductance between antenna antenna pads inductance between ant. pads mutual inductance between coil coil
coupling coefficient between coils tuning capacitance
1999 Microchip Technology Inc.
DS00710A-page
AN710
CONSIDERATION QUALITY FACTOR BANDWIDTH TUNING CIRCUIT
voltage across coil product quality factor circuit input voltage. Therefore, given input voltage signal, coil voltage directly proportional circuit. general, higher results longer read range. However, also related bandwidth circuit shown following equation.
EQUATION
FIGURE
VARIOUS EXTERNAL CIRCUIT CONFIGURATIONS
MCRF355
Ant.
detuned tuned
where:
Ant.
mutual inductance coupling coefficient inductors
inductors capacitor MCRF355 Ant.
Ant. capacitors inductor
tuned detuned
MCRF360
Ant.
tuned detuned
Ant.
inductors with internal capacitor
DS00710A-page
1999 Microchip Technology Inc.
AN710
Bandwidth requirement limit circuit MCRF355
Since MCRF355 operates with data rate kHz, reader antenna circuit needs bandwidth least twice data rate. Therefore, needs:
RESONANT CIRCUITS
Once frequency inductance coil determined, resonant capacitance calculated from:
EQUATION
minimum Assuming circuit turned 13.56 MHz, maximum attainable obtained from Equations
EQUATION
practical applications, parasitic (distributed) capacitance present between turns. parasitic capacitance typical antenna coil (pF). This parasitic capacitance increases with operating frequency device. There different resonant circuits: parallel series. parallel resonant circuit maximum impedance resonance frequency. minimum current maximum voltage resonance frequency. Although current circuit minimum resonant frequency, there circulation current that proportional circuit. parallel resonant circuit used both high-power reader antenna circuit. other hand, series resonant circuit minimum impedance resonance frequency. result, maximum current available circuit. Because simplicity availability high current into antenna element, series resonant circuit often used simple proximity reader.
EQUATION
96.8 practical resonant circuit, range 13.56 band about However, significantly increased with ferrite core inductor. system designer must consider above limits optimum operation.
Parallel Resonant Circuit
Figure shows simple parallel resonant circuit. total impedance circuit given
EQUATION
where angular frequency given maximum impedance occurs when denominator above equation minimized. This condition occurs when:
EQUATION
This called resonance condition, resonance frequency given
EQUATION
1999 Microchip Technology Inc.
DS00710A-page
AN710
applying Equation into Equation impedance resonance frequency becomes: applying Equation Equation into Equation parallel resonant circuit
EQUATION
where load resistance.
EQUATION
parallel resonant circuit proportional load resistance also ratio capacitance inductance circuit. When this parallel resonant circuit used antenna circuit, voltage drop across circuit obtained combining Equations
FIGURE
PARALLEL RESONANT CIRCUIT
EQUATION
NQSB
parallel resonant circuit determine bandwidth, circuit. above equation indicates that induced voltage coil inversely proportional square root coil inductance, proportional number turns surface area coil.
EQUATION
-2RC
quality factor, defined various ways such
Series Resonant Circuit
simple series resonant circuit shown Figure expression impedance circuit
EQUATION
Energy Stored System Cycle -Energy Dissipated System Cycle reac -resis
EQUATION
where:
ohmic resistance coil capacitor reactance coil capacitor, respectively, such that:
inductance
capacitance
EQUATION
EQUATION
where:
angular frequency resonant frequency bandwidth ohmic losses
impedance Equation becomes minimized when reactance component cancelled each other such that This called resonance condition. resonance frequency same parallel resonant frequency given Equation
DS00710A-page
1999 Microchip Technology Inc.
AN710
FIGURE SERIES RESONANCE CIRCUIT
When circuit tuned resonant frequency such voltage across coil becomes: EQUATION jQVin above equation indicates that coil voltage product input voltage circuit. example, circuit with have coil voltage that times higher than input signal. This because energy input signal spectrum becomes squeezed into single frequency band.
13.56
half power frequency bandwidth determined given
EQUATION
EXAMPLE
CIRCUIT PARAMETERS
ohmic resistance then values 13.56 resonant circuit with are:
quality factor, series resonant circuit given series circuit forms voltage divider, voltage drops coil given
EQUATION
2.347 13.56MHz
58.7 (pF) 2fXL 13.56
EQUATION
1999 Microchip Technology Inc.
DS00710A-page
AN710
TUNING METHOD
circuit must tuned resonance frequency maximum performance (read range) device. examples tuning circuit follows: Voltage Measurement Method: voltage signal source resonance frequency. Connect voltage signal source across resonant circuit. Connect Oscilloscope across resonant circuit. Tune capacitor coil while observing signal amplitude Oscilloscope. Stop tuning maximum voltage. S-parameter Impedance Measurement Method using Network Analyzer: S-Parameter Test (Network Analyzer) measurement, calibration. Measure resonant circuit. Reflection impedance reflection admittance measured instead S11. Tune capacitor coil until maximum null (S11) occurs resonance frequency, impedance measurement, maximum peak will occur parallel resonant circuit, minimum peak series resonant circuit.
FIGURE
VOLTAGE FREQUENCY RESONANT CIRCUIT
FIGURE
FREQUENCY RESPONSES RESONANT CIRCUIT
Note Response, Impedance Response Parallel Resonant Circuit, Impedance Response Series Resonant Circuit. (a), null resonance frequency represents minimum input reflection resonance frequency. This means circuit absorbs signal frequency while other frequencies reflected back. (b), impedance curve peak resonance frequency. This because parallel resonant circuit maximum impedance resonance frequency. shows response series resonant circuit. Since series resonant circuit minimum impedance resonance frequency, minimum peak occurs resonance frequency.
DS00710A-page
1999 Microchip Technology Inc.
AN710
READ RANGE RFID DEVICES
Read range defined maximum communication distance between reader tag. general, read range passive RFID products varies, depending system configuration affected following parameters: Operating frequency performance antenna coils antenna tuning circuit Antenna orientation Excitation current Sensitivity receiver Coding modulation) decoding demodulation) algorithm Number data bits detection (interpretation) algorithm Condition operating environment (electrical noise), etc. read range 13.56 relatively longer than that device. This because antenna efficiency increases frequency increases. With given operating frequency, conditions related antenna configuration tuning circuit. conditions determined circuit topology reader. condition communication protocol device, related firmware software program data detection. Assuming device operating under given condition, read range device largely affected performance antenna coil. always true that longer read range expected with larger size antenna with proper antenna design. Figures show typical examples read range various passive RFID devices.
FIGURE
READ RANGE SIZE TYPICAL PROXIMITY APPLICATIONS*
0.5-inch diameter
1-inch diameter
inche
inch Reader Antenna
inches
2-inch diameter
2-inch 3.5-inch" (Credit Card Type)
FIGURE
READ RANGE SIZE TYPICAL LONG RANGE APPLICATIONS*
0.5-inch diameter
1-inch diameter
inches
inch Long Range Reader
2-inch diameter inches
inch
2-inch" 3.5-inch (Credit Card Type)
Note:
Actual results shorter longer than range shown, depending upon factors discussed above.
1999 Microchip Technology Inc.
DS00710A-page
AN710
REFERENCES
Welsby, Theory Design Inductance Coils, John Wiley Sons, Inc., 1960. Frederick Grover, Inductance Calculations Working Formulas Tables, Dover Publications, Inc., York, NY., 1946. Keith Henry, Editor, Radio Engineering Handbook, McGraw-Hill Book Company, York, NY., 1963. James Hardy, High Frequency Circuit Design, Reston Publishing Company, Inc.Reston, Virginia, 1975.
DS00710A-page
1999 Microchip Technology Inc.
microID13.56 DESIGN GUIDE
13.56 Reader Reference Design
INTRODUCTION
This chapter provides reference guide 13.56 reader designer. schematic included this chapter 13.56 Reference Reader included DV103003 microIDDeveloper's Kit. circuit designed short read-range applications. basic design modified long-range other applications with MCRF355/360 devices. electronic copy PICmicro® microcontroller source code available upon request. transmitting section contains 13.56 signal oscillator (74HC04), power amplifier (Q2), tuning circuits. tuning circuit matches impedance between antenna coil circuit power driver 13.56 MHz. radiating signal strength from antenna must comply with government regulations. best performance, antenna coil circuit must tuned same frequency tag. design antenna circuits given Application Note AN710 (DS00710). receiving section contains envelope detector (D6), hi-pass filters, amplifiers U3). When energized, transmits bits data that encoded Biphase-L (Manchester). Manchester encoding, data represented logic high-to-low level change midclock, data represented low-to-high level change midclock. There always level change middle every clock.
READER CIRCUITS
RFID reader consists transmitting receiving sections. transmits carrier signal (13.56 MHz), receives backscattered signal from tag, performs data processing. reader also communicates with external host computer. basic block diagram typical RFID reader shown Figure 2-1.
FIGURE 2-1:
FUNCTIONAL BLOCK DIAGRAM TYPICAL RFID READER
13.56 Signal Oscillator
Power Amplifier
Tuning Circuit
Microcontroller
Filter Amplifier
Envelope Detector
Ant. Coil
Serial Interface (RS232) Host Computer
microID trademark Microchip Technology Inc. PICmicro registered trademark Microchip Technology
1999 Microchip Technology Inc.
DS21311A-page
microID13.56 Design Guide
FIGURE 2-2: SIGNAL WAVEFORMS
14.285 Data Signal
Signal Waveform Reader Coil
After Envelope Detector
After Pulse Shaping
DS21311A-page
1999 Microchip Technology Inc.
microID13.56 Design Guide
FIGURE 2-3: BIPHASE-L (MANCHESTER) SIGNAL
Data
Data
When energized reader's carrier signal, transmits back with amplitude modulated signal. This results perturbation voltage amplitude across reader antenna coil. envelope detector detects changes voltage amplitude passes into filter (R7, C11). charged signal capacitor passes through active filters amplifiers. signal that passing through this receiving section data signal. This filteredshaped data signal into microcontroller data processing.
Specifications Transmitting Signal
Each country limits signal strength radio frequency signal that intentionally radiated from device. USA, maximum signal strength that radiated from device regulated Federal Communication Commission (FCC). device operating 13.56 frequency band must comply with Part 15.225 federal regulation. limits 13.56 frequency band follows: Tolerance carrier frequency: 13.56 0.01% kHz. Frequency bandwidth: kHz. Power level fundamental frequency: mv/m meters from transmitter. Power level harmonics: -50.45 down from fundamental signal.
transmission circuit including antenna coil must designed meet limits.
1999 Microchip Technology Inc.
DS21311A-page
microID13.56 Design Guide
OPTIMIZATION LONGRANGE APPLICATIONS
Optimize input sensitivity reader. sensitivity measure weak signal still satisfactorily received. sensitivity proportional carrier power square modulation index 100% modulation such MCRF355). inversely proportional noise signal. limit sensitivity receiving section reader noise, both external internal. external noises come from various sources such computers, televisions, appliances, motors, power lines, transformers, etc. internal noise mostly thermal noise components. reduce noise, reader should operated distance away from noise sources. receiving section have bandpass filter reduce noises. bandpass filter will pass only data signal processing. receiving section should have sensitivity about -120 long-range applications. Optimize amplitude gain circuit. receiving circuit amplifies modulated signals before data processing. input signal contains both real data noise. Typically, amplifiers used both gain amplifier filter. gain must optimized within circuit obtain gains only real data signal.
reader circuit provided designed about 5-inch read-range, using 2-inch 2-inch coil that printed with MCRF355. read-range increased increasing reader power, sensitivity, antenna size. read-range more than 30-inches achieved with MCRF355 optimized reader. order optimize reader circuit long-range applications, following aspects considered: Optimize output power level within limits. reader should provide sufficient signal level tag. needs about across coil circuit operation. power level radiating from reader antenna must comply government regulations such specifications USA. limits 13.56 band described Section 2.1. long-range applications, designer start with about antenna voltage optimize signal strength read-range within government regulations. Increase size antenna. readrange, general, proportional size reader coil (see Equation Application Note 710). optimum radius antenna 1.414 times read-range. Increase antenna circuit. read-range increases with antenna circuit. This because induced voltage directly proportional circuit. recommended long-range applications follows: reader
DS21311A-page
1999 Microchip Technology Inc.
microID13.56 Design Guide
READER SCHEMATIC
1999 Microchip Technology Inc.
DS21311A-page
microID13.56 Design Guide
READER BILL MATERIALS
Line Part 02-01523-D 03-01523 04-01523 MM74HC04M LF347M LM339M PIC16C558-20/ LM78L05ACM LM78L12ACM L7809CD2T MMBT2907ALT1 IRL510 RLS4148TE11C ERJ-3GSYJ332V ERJ-3GSYJ182V ERJ-3GSYJ103V ERJ-3GSYJ223V ERJ-3GSYJ104V ERJ-3GSYJ681V ERJ-3GSYJ102V ERJ-3GSYJ303V ERJ-3EKF7151V MFR-25FRF 14K0 RM73B1JT106J ERJ-3GSYJ100V EVM-7JSX30B13 ECUV1H104KBW Part Description ASSY DWG, MCRF355 microID READER SCHEMATIC, MCRF355 microID READER FABRICATION, MCRF355 microID READER SMT, CMOS INVERTER, SOIC SMT, QUAD BI-FET AMP, SOIC SMT, POWER OFFSET VOLT QUAD COMPARATORS,14P SOIC PIC16C558-20/SO EPROM-BASED 8-BIT CMOS MICROCONTROLLER REG, REGULATOR REG, +12V REGULATOR +9V, 1.5A TO-263 TRANSISTOR, PNP, 2N2907A, SOT-23 TRANSISTOR, N-CHANNEL FET, TO220AB SMT, 3.3K OHM, 1/16W, 0603 SMT, 1.8K OHM, 1/16W, 0603 SMT, OHM, 1/16 0603 SMT, OHM, 0603 SMT, 100K 1/16W TYPE 0603 SMT, 1/16W 0603 SMT, 1/16W 0603 SMT, 1/16W 0603 SMT, 7.15K 1/16W 0603 RES, 1/4W SMT, 1/16W 0603 SMT, 1/16W 0603 SMT, POT, SEALED, SMT, 0.1uF 10%, 1206 Flip upside bend legs toward Reference Designator Assembly 02-01523 02-01523 02-01523 02-01523 02-01523 02-01523 02-01523 02-01523 02-01523 02-01523 02-01523 02-01523 02-01523 02-01523 02-01523 02-01523 02-01523 02-01523 02-01523 02-01523 02-01523 02-01523 02-01523 02-01523 02-01523 02-01523 02-01523 02-01523 02-01523 02-01523 02-01523 02-01523 02-01523 02-01523 02-01523
DIODE SMT, ROHM DIODE LL-34 DIODE D1-D6 R15, R16, R8-R10 R13, connected from R17, R18, C12, C13, C16-18, C23-C26, C14, C19-C22
ECU-V1H220JCV SMT, CERAMIC 0603 ECUV1H102KBV SMT, 1000 CERAMIC 0603
ECU-V1H271JCV SMT, CERAMIC 0603 ECUV1H152KBV SMT, 1500 CERAMIC 0603
GRM42CAP SMT, 500V 1206 C0G" 6C0G471G500AL GRM426C0G121J500AL ECUV1H272KBV ECE-A1EU220 SMT, 500V 1206 C0G" SMT, 2700PF CERAMIC 0603 CAP, 22UF RADIAL ELECTROLYTIC
DS21311A-page
1999 Microchip Technology Inc.
microID13.56 Design Guide
Assembly 02-01523 02-01523 02-01523 02-01523 Line Part GRM426C0G100J500AL GRM426C0G220J500AL 43LS477 MCX0001 Part Description SMT, 500V 1206 SMT, 500V 1206 INDUCTOR, 0.47 Reference Designator NEEDED)
OSCILLATOR, CUSTOM 13.560 MHz, PARALLEL MODE, LOAD, HC49 CASE, CONN, MINI-DIN, 6-PIN CONN, D-SUB RECPT ANGLE WITH JACK SCREWS LABEL, MCRF355 READER FIRMWARE, 355READ.HEX, 1/25/99, SMT, 1/16W 0603
02-01523 02-01523 02-01523 02-01523
MDC-096 KF22-E9S-NJ 08-00170 ERJ-3GSYJ511V
1999 Microchip Technology Inc.
DS21311A-page
microID13.56 Design Guide
READER SOURCE CODE PICmicro®
;receiver.asm
;Processor: PIC16C558 operating 13.56 nsec processor 16c558 #include "P16c558.inc" _config h'3ff2' ;protection off,PWRT enabled,watchdog disabled,HS oscillator
#define _CARRY #define _ZERO
STATUS,0 STATUS,2
#define _125KHZ PORTA,1 #define _RS232TX PORTA,2 #define _RS232RX PORTA,3 #define _RS232 PORTA #define SIGNAL PORTB,4 invmask h'2' ;Define variables constants here-delay =h'20' wait =h'21' acctime =h'22' ;accumulated sync interval sum-also used halfbit interval threshold #define halfthr acctime ;halfbit interval threshold halfthr =acctime ;halfbit interval threshold recv_csumhi =h'23' bytes storing received checksum recv_csumlo =h'24' bitcnt =h'25' ;RS232 counter cycle_cnt =h'26' halfthr =h'27' ;threshold value between halfbit fullbit intervals ptr1 =h'28' ;temporary storage ptr2 =h'29' ;temporary storage TXchar =h'2a' ;character transmit over RS232 temp =h'2b' ;temporary storage shiftcnt =h'2c' ;used strip framing bits from rec'd data array letters =h'2d' ;storage area next character send charcnt =h'2e' lastbit =h'2f' ;the stores last rec'd bit-flip complementing ;;;!!!!!!!!!!!!!!!!!!!!!bit storage area-16 bytes storage, indirectly addressed ;;;Note that tests detect area-be careful move different ;;;processor relocate this storage area recvbits =h'40' bytes aside storing received bits-actual number bytes transmission ;;Note that main loop uses tests determine receive runaway condition limit ;;processing time). Keep this mind recvbits storage area changed future. ;;40h-60h reserved received bits-actual receiving area 40h-51h, rest overrun area ;;52h-73h ;;52h-60h sendascii xfercnt aside ASCII conversion received bytes before RS232 transmission. Note that contains useful information from during receive demodulated bits. Also, bits being received while ASCII conversion serial transmission taking place. character: "go" Character 2-37: ASCII representation received bytes (until checksum used) Character `\n' newline =h'52' =d'14' ;begin storage area ASCII conversion received bytes ;defines number received bytes convert ASCII transmit
DS21311A-page
1999 Microchip Technology Inc.
microID13.56 Design Guide
;Overall function- recover Manchester encoded RFID message after demodulation comparator decision. comparator input trips interrupt PORTB change. ;The steps are: Initialize registers seek synch field. Determine width from synch field averaging periods between transitions over synch field. TMR0 cleared each edge. timer overflows before next edge, synch seek starts over. synch field composed bits. measured width establish threshold period between repeat bits complement previous bit. This Manchester encoding method. Since there always transition middle each interval transmitted, repeated will appear pair edges that occur with halfbit interval period. that complement last received will appear interval between edges full interval period. Shift bits they received into storage array. When timer overflows, consider data field over. received data format LSb, where first received. There bytes message, followed checksum message contents. remaining unused. Compute checksum received byte message compare received checksum. checksums match, convert message checksum into ASCII form transmit over RS232 serial link. message format "GG" :the characters (start message) bytes which ASCII representation bytes received "\n" closing newline character serial data rate 9600 bps, data bits, stop, parity
h'000' goto init h'004'
;RESET vector location ;interrupt vector location
;;isr(): interrupt service routine interrupts enabled transition PORTB BEWARE! minimize interrupt response time, status register archived. execution path determined register uses calculated goto's. next current execution dependent signal context (i.e. sync start, w/in sync, w/in data, etc.) very cautious here-must stay w/in instructions this work! Sync field processed follows: -Ignore first transitions, they response power reset -Accumulate next intervals -Establish half width from full width threshold value based average interval measured above. Manchester encoding, repeat previous will series halfbit width intervals, complement previous will fullbit width interval. halfbit defined 1.5x(average sync). -wait interval over fullbit threshold. This sync. accordance Manchester encoding, sync field will addwf PCL,f calculated goto ;first sync edge calculated goto here clrf TMR0 movf PORTB,f must read PORTB before clearing RBIF INTCON,RBIF just case timer interrupt happened just edge INTCON,T0IF movlw (first_cycle isr-d'1') next calculated goto offset clrf lastbit lastbit sync retfie ;end first cycle here. Note that first transitions ignored, because sync start
1999 Microchip Technology Inc.
DS21311A-page
microID13.56 Design Guide
;corrupted power reset. first_cycle clrf TMR0 movf PORTB,f must read PORTB before clearing RBIF INTCON,RBIF movlw (second_cycle isr-d'1') next calculated goto offset retfie ;end cycle here. Note that first transitions ignored, because sync start ;corrupted power reset. second_cycle clrf TMR0 movf PORTB,f must read PORTB before clearing RBIF INTCON,RBIF movlw recvbits movwf store data bits movlw (third_cycle isr-d'1') next calculated goto offset retfie ;end cycle here. Note that first transitions ignored, because sync start ;corrupted power reset. cycle transition, from here measure ;the longest interval sync field. third_cycle clrf TMR0 movf PORTB,f must read PORTB before clearing RBIF INTCON,RBIF clrf acctime reset accumulated sync interval average movlw (fourth_cycle isr-d'1') next calculated goto offset retfie ;end cycle here. Start looking longest sync interval here. fourth_cycle movf TMR0,w clrf TMR0 movf PORTB,f INTCON,RBIF addwf acctime,f first measured sync cycle, must largest movlw (fifth_cycle isr-d'1') retfie ;end cycle here. fifth_cycle movf TMR0,w clrf TMR0 movf PORTB,f INTCON,RBIF addwf acctime,f acctime acctime TMR0 movlw (sixth_cycle isr-d'1') retfie ;end cycle here. sixth_cycle movf TMR0,w clrf TMR0 movf PORTB,f INTCON,RBIF addwf acctime,f acctime acctime TMR0 movlw (seventh_cycle isr-d'1') retfie ;end cycle here. seventh_cycle movf TMR0,w clrf TMR0 movf PORTB,f INTCON,RBIF addwf acctime,f acctime acctime TMR0 movlw (eighth_cycle isr-d'1') retfie ;end cycle here. eighth_cycle movf TMR0,w
DS21311A-page
1999 Microchip Technology Inc.
microID13.56 Design Guide
clrf TMR0 movf PORTB,f INTCON,RBIF addwf acctime,f acctime acctime TMR0 movlw (nineth_cycle isr-d'1') retfie ;end cycle here. nineth_cycle movf TMR0,w clrf TMR0 movf PORTB,f INTCON,RBIF addwf acctime,f acctime acctime TMR0 movlw (tenth_cycle isr-d'1') retfie ;end 10th cycle here. tenth_cycle movf TMR0,w clrf TMR0 movf PORTB,f INTCON,RBIF addwf acctime,f acctime acctime TMR0 movlw (eleventh_cycle isr-d'1') retfie ;end 11th cycle here. -this last sync cycles accumulated. Average result ;and determine halfbit threshold remaining sync cycles. eleventh_cycle movf TMR0,w clrf TMR0 movf PORTB,f INTCON,RBIF addwf acctime,f acctime acctime TMR0 movlw (twelfth_cycle isr-d'1') retfie ;end 12th cycle here. Start averaging sync interval accumulated time twelfth_cycle movf PORTB,f INTCON,RBIF acctime,f acctime/2 acctime,f acctime/4 acctime,f interval acctime/8 movlw h'1f' clear MSbs that have been carry andwf acctime,f movlw (cycle13 isr-d'1') retfie ;end 13th cycle here. Calculate halfbit threshold 1.5(sync interval avg) Note that ;that threshold value will kept acctime (=halfthr) cycle13 clrf TMR0 movf PORTB,f INTCON,RBIF acctime,w half sync interval addwf acctime,f halfthr 1+1.5x(sync interval avg) incf acctime,f movlw (sync_end h'100'-h'1'-isr) PCLATH,0 adjust origin 100h retfie h'100' ;sync wait. sync distinguished fullbit interval. halfthr sync_end movf TMR0,w clrf TMR0 movf PORTB,f INTCON,RBIF subwf halfthr,w Test interval detect sync field (halfthr
1999 Microchip Technology Inc.
DS21311A-page
microID13.56 Design Guide
movlw (sync_end h'100'-isr-d'1') btfss STATUS,C Carry halfthr movlw (bit1 h'100'-isr-h'1');12 halfbit, sync detected. Proceed data processing retfie ;rec'd processing here -bit1 block bit1 movf TMR0,w clrf TMR0 movf PORTB,f INTCON,RBIF subwf halfthr,w Test interval determine bit. repeated btfsc STATUS,C goto halfabit1 ;fullbit processing here comf lastbit,f Complement lastbit fullbit measurement lastbit,w INDF,f shift movlw (bit2 h'100'-isr-h'1') retfie halfabit1 ;repeated lastbit,w INDF,f movlw (half21-h'100'-isr-h'1') retfie ;2nd half interval processing half21 ;2nd half, bit1 clrf TMR0 movf PORTB,f INTCON,RBIF movlw (bit2-h'100'-isr-h'1');8 retfie ;rec'd processing here -bit2 block bit2 movf TMR0,w clrf TMR0 movf PORTB,f INTCON,RBIF subwf halfthr,w Test interval determine bit. repeated btfsc STATUS,C goto halfabit2 ;fullbit processing here comf lastbit,f Complement lastbit fullbit measurement lastbit,w INDF,f shift movlw (bit3 h'100'-isr-h'1') retfie halfabit2 ;repeated lastbit,w INDF,f movlw (half22-h'100'-isr-h'1') retfie ;2nd half interval processing half22 ;2nd half, bit2 clrf TMR0 movf PORTB,f INTCON,RBIF movlw (bit3-h'100'-isr-h'1');8 retfie ;rec'd processing here -bit3 block bit3 movf TMR0,w clrf TMR0
DS21311A-page
1999 Microchip Technology Inc.
microID13.56 Design Guide
movf PORTB,f INTCON,RBIF subwf halfthr,w Test interval determine bit. repeated btfsc STATUS,C goto halfabit3 ;fullbit processing here comf lastbit,f Complement lastbit fullbit measurement lastbit,w INDF,f shift movlw (bit4 h'100'-isr-h'1') retfie halfabit3 ;repeated lastbit,w INDF,f movlw (half23-h'100'-isr-h'1') retfie ;2nd half interval processing half23 ;2nd half, bit3 clrf TMR0 movf PORTB,f INTCON,RBIF movlw (bit4-h'100'-isr-h'1');8 retfie ;rec'd processing here -bit4 block bit4 movf TMR0,w clrf TMR0 movf PORTB,f INTCON,RBIF subwf halfthr,w Test interval determine bit. repeated btfsc STATUS,C goto halfabit4 ;fullbit processing here comf lastbit,f Complement lastbit fullbit measurement lastbit,w INDF,f shift movlw (bit5 h'100'-isr-h'1') retfie halfabit4 ;repeated lastbit,w INDF,f movlw (half24-h'100'-isr-h'1') retfie ;2nd half interval processing half24 ;2nd half, bit4 clrf TMR0 movf PORTB,f INTCON,RBIF movlw (bit5-h'100'-isr-h'1');8 retfie ;rec'd processing here -bit5 block bit5 movf TMR0,w clrf TMR0 movf PORTB,f INTCON,RBIF subwf halfthr,w Test interval determine bit. repeated btfsc STATUS,C goto halfabit5 ;fullbit processing here comf lastbit,f Complement lastbit fullbit measurement lastbit,w INDF,f shift movlw (bit6 h'100'-isr-h'1')
1999 Microchip Technology Inc.
DS21311A-page
microID13.56 Design Guide
retfie halfabit5 ;repeated lastbit,w INDF,f movlw (half25-h'100'-isr-h'1') retfie ;2nd half interval processing half25 ;2nd half, bit5 clrf TMR0 movf PORTB,f INTCON,RBIF movlw (bit6-h'100'-isr-h'1') retfie ;rec'd processing here -bit6 block bit6 movf TMR0,w clrf TMR0 movf PORTB,f INTCON,RBIF subwf halfthr,w Test interval determine bit. repeated btfsc STATUS,C goto halfabit6 ;fullbit processing here comf lastbit,f Complement lastbit fullbit measurement lastbit,w INDF,f shift movlw (bit7 h'100'-isr-h'1') retfie halfabit6 ;repeated lastbit,w INDF,f movlw (half26-h'100'-isr-h'1') retfie ;2nd half interval processing half26 ;2nd half, bit6 clrf TMR0 movf PORTB,f INTCON,RBIF movlw (bit7-h'100'-isr-h'1') retfie ;rec'd processing here -bit7 block bit7 movf TMR0,w clrf TMR0 movf PORTB,f INTCON,RBIF subwf halfthr,w Test interval determine bit. repeated btfsc STATUS,C goto halfabit7 ;fullbit processing here comf lastbit,f Complement lastbit fullbit measurement lastbit,w INDF,f shift movlw (bit8 h'100'-isr-h'1') retfie halfabit7 ;repeated lastbit,w INDF,f movlw (half27-h'100'-isr-h'1') retfie ;2nd half interval processing half27 ;2nd half, bit7
DS21311A-page
1999 Microchip Technology Inc.
microID13.56 Design Guide
clrf TMR0 movf PORTB,f INTCON,RBIF movlw (bit8-h'100'-isr-h'1') retfie ;rec'd processing here -bit8 block bit8 movf TMR0,w clrf TMR0 movf PORTB,f INTCON,RBIF subwf halfthr,w Test interval determine bit. repeated btfsc STATUS,C goto halfabit8 ;fullbit processing here comf lastbit,f Complement lastbit fullbit measurement lastbit,w INDF,f shift movlw (bit1 h'100'-isr-h'1') incf FSR,f retfie halfabit8 ;repeated lastbit,w INDF,f movlw (half28-h'100'-isr-h'1') retfie ;2nd half interval processing half28 ;2nd half, bit8 clrf TMR0 movf PORTB,f INTCON,RBIF movlw (bit1-h'100'-isr-h'1') incf FSR,f advance next byte recvbits storage array retfie
;The negative RS232 supply generated inverter clocked ~125 port RA1. ;first pump -5V, i.e. generate clock (T=8 usec, ;run total cycles before sending data ;put line stop level alphabet clrwdt INTCON,GIE movlw sendascii movwf ;make sure interrupts
movlw xfercnt ASCII represented received bytes xfer addlw xfercnt addlw h'3' ;plus start character newline character movwf charcnt ;;set registers bank STATUS,RP0 ;point bank movlw h'8' movwf TRISA ;RA3 input, RA2-0 output movlw h'10' movwf TRISB ;RB7-5,3-0 output, input movlw b'00001100' ;set timer option internal clock, prescale->watchdog/16 movwf OPTION_REG ;port pullups enabled STATUS,RP0 ;point back bank ;;done setting registers bank back bank _RS232TX ;default mark mode call gen125khz
1999 Microchip Technology Inc.
DS21311A-page
microID13.56 Design Guide
;start test transmission sendA movf INDF,w movwf TXchar movlw d'8' movwf bitcnt ;stop last _RS232TX call TX_RS232 ;stop
call ;start call call sendchar btfsc goto goto setbit nextbit
ti17 first _RS232TX TX_RS232 ti17 TXchar,0 setbit _RS232TX nextbit _RS232TX
;burn 17Ti (includes call)
;burn 17Ti (includes call, adjusts timing) ;1Ti ;3Ti
;4Ti ;6Ti ;7Ti ;17Ti ;18Ti ;20Ti
call TX_RS232 TXchar,f call ti10 decfsz bitcnt,f goto sendchar ;stop last _RS232TX call TX_RS232
;stop
incf decfsz goto movlw movwf movlw movwf waiting call decfsz goto decfsz goto goto inalpha call goto
FSR,f charcnt,f inalpha d'255' charcnt d'10' bitcnt ti17 charcnt,f waiting bitcnt,f waiting seekinit ti10 sendA
;;subroutine-RS232 timing voltage inverter maintenance baud rate 9600 bps-this time usec Timing this subroutine: to104 loop 5.605 usec, additional setup overhead 1.77 usec. to104 loops, that leaves 5.844 usec make calling routine meet usec target. 5.844= 19.8 Note that 5.844 evenly divisible instruction cycle time. Need save instruction every sent-w/ stop start overhead, easier save extra instructions
DS21311A-page
1999 Microchip Technology Inc.
microID13.56 Design Guide
every character sent bits) TX_RS232 movlw d'17' ;time usec, Ti=295 nsec movwf wait to104 movlw invmask ;flip voltage inverter xorwf _RS232,f movlw d'4' movwf delay wait4usec decfsz delay,f usec half inverter clock period goto wait4usec decfsz wait,f goto to104 movlw invmask xorwf _RS232,f return
;;subroutine-generates cycles ~125 RS232 voltage inverter gen125khz movlw d'128' movwf cycle_cnt next125 _125KHZ movlw d'4' movwf delay highside decfsz delay,f goto highside _125KHZ movlw d'4' movwf delay lowside decfsz delay,f goto lowside decfsz cycle_cnt,f goto next125 return ;;end gen125khz ;;subroutine-ti17: burn Ti-includes call this subroutine ti15: burn including call ti10: burn including call ti17 movlw d'3' movwf delay burn9 decfsz delay,f goto burn9 clrwdt
1999 Microchip Technology Inc.
DS21311A-page
microID13.56 Design Guide
return ti15 movlw movwf burn9Ti decfsz delay,f goto burn9Ti return ti12 clrwdt ti10 goto dly1 goto dly2 goto leaveti10 ;6Ti leaveti10 return ;8Ti+2Ti=10Ti dly2 ;4Ti dly1 ;2Ti ;13+2 call ti15=15Ti d'3' delay ;15+2 call ti17=17Ti
;================= ;;initialization ;================= init ;1st configuration-note that setting PORTB 7,6,5,4,0 outputs disables ;them external interrupt sources. this application PORTB-4 utilized ;external interrupt source upon change state. other external interrupt sources ;set outputs disable them interrupts. ;;set registers bank STATUS,RP0 ;point bank movlw h'8' movwf TRISA ;RA3 input, RA2-0 output movlw h'10' movwf TRISB ;RB7-5,3-0 output, input movlw b'00001000' ;set timer option internal clock, prescaler movwf OPTION_REG ;port pullups enabled STATUS,RP0 ;point back bank ;;done setting registers bank back bank movlw HIGH movwf PCLATH ;setup calculated goto's dependent context when entering ;isr ;;initialization sync field search- done turn after data recovery complete failed) seekinit clrwdt movlw d'19' movwf bitcnt ;clear storage field movlw recvbits movwf clrbits clrf INDF incf FSR,f decfsz bitcnt,f goto clrbits
movlw recvbits movwf ;start received bits field movf PORTB,w ;read PORTB before clearing INTCON sure RBIF=0
DS21311A-page
1999 Microchip Technology Inc.
microID13.56 Design Guide
clrf INTCON clrf TMR0 From here register represents offset when answering isr. used other purpose until interrupts disabled. movlw d'0' clrf PCLATH INTCON,RBIE ;enable portB change interrupt enable INTCON,GIE ;global interrupts enabled.
;==================== ;;tag word search ;==================== ;The main loop monitors T0IF flag detect successfully received word (subject ;checksum test). word processing driven. calculated goto method used ;position context word speed. THIS REASON, REGISTER CANNOT USED MAIN LOOP! main loop detects timer overflow, register cleared ;return processing first sync edge search. ;Also, expect recvbits area 40h-52h while receiving data. will tested ;determine this bitwise (because can't used main loop). seeksync INTCON,RBIE movlw d'0' ;calculated goto offset sync edge processing clrf PCLATH clrf ;FSR indicate gathering bits INTCON,RBIE INTCON,T0IF main clrwdt btfsc FSR,6 goto datamain ;receiving data, monitor progress btfsc INTCON,T0IF goto seeksync TMR0 overflows receiving bits, seeksync goto main ;check done receiving bits using TMR0 overflow indicator. Also test overflow from ;proper storage area runaway condition (non noise tripping comparator) datamain clrwdt btfsc INTCON,T0IF goto calc_checksum timer overflows, calculate checksum received data btfsc FSR,5 set, overrun proper area. goto seeksync ;search sync. goto datamain ;Data received this point. processing tasks remain: framing bits must removed from received data bytes checksum checksum data bytes must calculated compared received checksum checksums match, transmit data over RS232 link. calc_checksum clrf INTCON clrgie INTCON,GIE btfsc INTCON,GIE ;make sure it's clear before proceeding goto clrgie movf PORTB,f clrf INTCON ;disable interrupts while processing received data ;remove framing bits shifting data array left until framing ;shifted movlw movwf movwf d'17' bitcnt shiftcnt
1999 Microchip Technology Inc.
DS21311A-page
microID13.56 Design Guide
shiftout movlw recvbits+d'17' movwf roll_left INDF,f decf FSR,f decfsz shiftcnt,f goto roll_left ;rotate left shiftcnt bytes decfsz bitcnt,f goto next_RL goto framestripped ;bit shift left through array (successively byte less each time) next_RL movf bitcnt,w movwf shiftcnt goto shiftout framestripped ;1st check data-This illegal combination movlw recvbits movwf movlw d'14' movwf bitcnt zerotest movf INDF,w btfss STATUS,Z goto nonzero decfsz bitcnt,f goto zerotest goto seekinit ;all zeros received. Ignore message nonzero checksum first bytes received. should match last bytes received. movlw recvbits movwf movlw d'14' movwf bitcnt clrf recv_csumlo clrf recv_csumhi sumbytes movf INDF,w addwf recv_csumlo,f btfsc STATUS,C incf recv_csumhi,f ;carry into high byte necessary incf FSR,f ;point next data byte decfsz bitcnt,f goto sumbytes ;now compare received checksum calculated checksum. Transmit data they match. movf recv_csumhi,w subwf INDF,f btfss STATUS,Z goto seekinit incf FSR,f ;point received checksum movf recv_csumlo,w subwf INDF,f btfss STATUS,Z goto seekinit ;message passes checksum. Convert ASCII transmit. ;now convert ASCII form movlw recvbits movwf ptr1 ;keep track where conversion movlw sendascii movwf ptr2 movwf movlw movwf INDF incf ptr2,f
DS21311A-page
1999 Microchip Technology Inc.
microID13.56 Design Guide
incf FSR,f movwf INDF ;double indicate start incf ptr2,f ;next ascii character movlw xfercnt ;how many bytes convert ASCII movwf bitcnt movlw h'4' movwf PCLATH ;set PCLATH lookup table asciiconv movf ptr1,w movwf swapf INDF,w andlw h'f' ;isolate call hex2ascii movwf temp ;hold ASCII character movf ptr2,w movwf movf temp,w ;store ASCII representation received byte movwf INDF incf ptr2,f ;advance ASCII movf ptr1,w ;back received bytes movwf movf INDF,w andlw h'f' ;isolate call hex2ascii movwf temp movf ptr2,w movwf movf temp,w ;store ASCII representation received byte movwf INDF incf ptr2,f ;advance ASCII incf ptr1,f ;advance received byte decfsz bitcnt,f goto asciiconv ;done data conversion, indicate newline before sending movlw "\n" ;newline character incf FSR,f movwf INDF
;cleared RS232 transmission goto alphabet ;hexadecimal ASCII conversion table h'3ff' hex2ascii addwf PCL,f retlw ;ascii retlw ;ascii retlw ;ascii retlw ;ascii retlw ;ascii retlw ;ascii retlw ;ascii retlw ;ascii retlw ;ascii retlw ;ascii retlw ;ascii retlw ;ascii retlw ;ascii retlw ;ascii retlw ;ascii retlw ;ascii
1999 Microchip Technology Inc.
DS21311A-page
microID13.56 Design Guide
NOTES:
DS21311A-page
1999 Microchip Technology Inc.
microID13.56 DESIGN GUIDE
Contact Programmer
INTRODUCTION
Chapter Overview
Device Programming
This chapter will address details programming MCRF355 device using MCRF355 Contact Programmer. timing diagrams device test modes other specifications found MCRF355/360 data sheet (DS21287) under Section 3.4, "Signal Timing." detailed description test modes will included this section. Please refer data sheet more information. Included DV103003 Development MCRF355 Contact Programmer. This circuit offers possible solution programming MCRF355 using PIC16C63. hardware details, firmware listing, interface provided here.
MCRF355 data array made EEPROM bits. These bits directly accessed through device test modes. When erased, each cell goes logic `1'. programming pulse width (TWC, described data sheet) required bring each individual down logic `0'. command side, three logic levels required program device: VDD, VHH, VIH, VIL. 2.5V typical VDDT VDDT
Section data sheet also titled "Device Programming." information contained this section also found there. test mode commands that required program MCRF355 follows:
Test Modes
Erase Program Read
MCRF355 Contact Programmer designed carry these test modes based commands coming through RS-232 communications port. three voltage levels (VDD, VHH, VIH, VIL) present programmer board, originating from power supply. test mode timings have been programmed into PIC16C63, leaving simple RS-232 command initiate complete required test modes.
1998 Microchip Technology Inc.
DS21310B-page
microID13.56 Design Guide
HARDWARE
Description Operation
FIRMWARE
Overview
Programming initiated side. MCRF355 Contact Programmer receives command from through RS-232 port, into USART P16C63. Based this command, microcontroller then sends proper test mode signal MCRF355 device, using three voltage levels present programming board. high voltage level VHH, additional circuitry required buffer these signals from port pins PIC16C63. switching three voltage levels handled analog switch. complete schematic MCRF355 Contact Programmer found Section 5.0.
Control MCRF355 Contact Programmer accomplished through simple ASCII commands. This enables user come with interface specific his/her needs. development includes RFLAB, visual basic interface MCRF355 Contact Programmer. However, user interface designed that uses MCRF355 Contact Programmer board existing firmware, operation firmware must understood. should noted here that MCRF355 Contact Programmer easily used number different ways, depending operation firmware. included schematic allows this approach. This section outlines operation firmware that included with development kit. 3.1.1 COMMANDS
simple ASCII commands mentioned above described here:
TABLE 3-1:
ASCII
RS-232 COMMANDS, 9600 BAUD,
Description
Program device Erase device Read device Receive data from Upload data
simple terminal program used interface MCRF355 Programmer board. should understood that PICmicro® programs MCRF355 from data stored RAM. Updating this data from accomplished through serial commands. This data described PICmicro data array. commands initiated with above ASCII letter. complete description each command included here: Program Device uppercase initiates this command. This command programs MCRF355 with data that been previously loaded into PICmicro's data array. busy light MCRF355 Contact Programmer board will showing that programming been initiated. Upon program completion, light will off, uppercase uppercase will echoed back letter corresponds successful program, letter indicates failed program.
PICmicro registered trademark Microchip Technology Inc.
DS21310B-page
1998 Microchip Technology Inc.
microID13.56 Design Guide
Erase Device uppercase initiates this command. busy light MCRF355 Contact Programmer board will showing that erase command been initiated. Upon completion erase, light will off, uppercase uppercase will echoed back letter corresponds successful erase, letter indicates failed erase. Read Device uppercase initiates this command. busy light MCRF355 Contact Programmer board will showing that read command been initiated. This command updates data array PIC16C65A with data from MCRF355. Upon completion, light will off, uppercase will echoed back Receive Data uppercase initiates this command. This command loads PIC16C65A data array with data bits programmed. Following uppercase "D," PICmicro will expect more bytes data. PICmicro will echo back after each byte. After 20th byte, busy light will off, command complete. Upload Data uppercase initiates this command. This command returns data bits from data array PICmicro Following uppercase "U," single space (ASCII 0x20) will initiate data transfer. bytes will follow. After 20th byte, busy light will off, command complete. should noted here that 154-bit data array evenly divisible 8-bit byte. 20th data byte contains bits 153.
FIGURE 3-1:
DATA BYTE Byte Sample Data From 01111010 Byte 01111010 #153 Byte don't care
1998 Microchip Technology Inc.
DS21310B-page
microID13.56 Design Guide
3.1.2 COMMAND SEQUENCE
INTERFACE
Overview
Using these five ASCII commands, user then able program verify MCRF355 device. Using these five commands, recommended command sequences follow:
Program
Erase Device. Doing erase command prior programming necessary return bits logic state. Command "E." Load Data Array. user must send bytes containing bits from MCRF355 Programmer. Command "D." Program Device. user must initiate programming. Command "P."
Included with DV103003 developers RFLAB 13.56, Microsoft® Windows®-based program that handles above described serial communication. This Visual Basic® interface that allows easy control MCRF355 Programming board. Figure screen shot this software, RFLAB 13.56.
System Requirements
RFLAB 32-bit application developed using Visual Basic 5.0. will only under Windows higher.
Installation
uppercase returned, device been programmed.
RFLAB 13.56 comes 3.5-inch disks. entire installation will require approximately megabytes space. Running a:/setup.exe disk number will install software onto your Windows higher After installation complete, shortcut executable found your start menu. default path this shortcut under Program Files>RFLAB> RFLAB 13.56 MHz.
FIGURE 4-1:
RFLAB 13.56 DIALOG
DS21310B-page
1998 Microchip Technology Inc.
microID13.56 Design Guide
Operation Detecting Programmer
order software run, MCRF355 Contact Programmer must connected through available port. Please have programmer connected powered before initiate RFLAB. important that power supply used. When RFLAB comes will scan available serial ports, looking MCRF Contact Programmer. Once programmer found, status bottom window will indicate this. programmer found, selecting port manually instead relying auto detection process. Manual selection port done choosing which port menu: Options>COM Port. this also fails, please verify that power connections serial port connections secure. Once software detected that programmer connected computer, free program device. 4.4.1 COMMAND BUTTONS bottom third programming window shows list box. This list will echo commands they being sent MCRF355 Contact Programming board. command buttons described will activity this box. This provided better describe ASCII commands behind command buttons. 4.4.2 DATA FORMAT
left corner window will show four command buttons. Clear Data, Program, Erase, Read. CLEAR DATA button will clear text boxes window. This command will erase device, just clears text boxes your screen. ERASE button will send erase command programming board. PROGRAM button will initiate programming sequence described above Section 3.1.2. single click will Erase device, download data, program device, then verify program. READ button will send Read command, followed Upload command programming board. text boxes screen will then updated with correct data.
right corner programming window will show selector labeled TAG. selections marked "Microchip" "Other." This selector toggles data encoded into 154-bit stream. When selector "Other," user complete control over each bit. test boxes labeled DATA free edited. When selector "Microchip," only data bytes free edit. additional text boxes will showing this. This mode encodes these data bytes into stream. Nine header bits, checksum bytes, framing zeros encoded along with these data bits. This encoding scheme detailed Figure 4-2. "Microchip" format used firmware 13.56 reference reader, included DV103003 kit.
FIGURE 4-2:
MICROCHIP FORMAT
data bytes encoded with nine leading 1's, 8-bit checksum bytes, framing zeros around each byte. Leading Byte Byte
Byte Chksum1 Chksum2
1998 Microchip Technology Inc.
DS21310B-page
microID13.56 Design Guide
CONTACT PROGRAMMER SCHEMATIC
DS21310B-page
1998 Microchip Technology Inc.
microID13.56 Design Guide
CONTACT PROGRAMMER BILL MATERIALS
Part 02-01524-D 03-01524 04-01524 PIC16C63A-04/P MICROCHIP Manufacturer Part Description ASSY DWG, MCRF355 microID Programmer SCHEMATIC, MCRF355 microID Programmer FABRICATION, MCRF355 microID Programmer PIC16C63A-04/SP, CMOS MICROCONTROLLER SOCKET, COLLET OPEN FRAME .300W 0.5A JACK, POWER, PIN, MOUNT LED, GREEN T1-3/4 DIFFUSED LED, YELLOW T1-3/4 DIFFUSED XTAL OSC, 10.000 MHZ, FULL SIZE DUAL RS232 DRIVER SUPERVISOR CIRCUIT W/OPEN DRAIN OUTPUT CONN, D-SUB RECPT ANGLE WITH JACK SCREWS Reference Designator Assembly 02-01524 02-01524 02-01524 02-01524
02-01524 02-01524 02-01524 02-01524 02-01524 02-01524 02-01524 02-01524
110-91-328-41-001 MC7805ACT AC-001 521-9173 521-9174 OECS-100-1-A101A MAX232ACPE MCP130-450DI/TO
MILL-MAX MOTOROLA POWER DYNAMICS DIALIGHT DIALIGHT MAXIM MICROCHIP
02-01524 02-01524 02-01524 02-01524 02-01524 02-01524 02-01524 02-01524 02-01524
KF22-E9S-NJ 2-0016-03340-000006-00X 592CZ5U104M050B 470QBK 10QBK B3F-1000 SJ-5018 08-00126 08-00171
KYCON
C1,C2,C4C8,C10-C17 R2-R7 SW1, Placed corners
TEXTOOL SOCKET, TEST, (0.300) GREEN SPRAGUE YAGEO YAGEO OMRON CAP, AXIAL 0.1uF RES, 1/4W CARBON FILM RES, 1/4W CARBON FILM KEYSWITCH, MOMENTARY MOUNT MISC, RUBBER FEET, HIGH BLACK LABEL, NEED HELP WITH ASSY/SERIAL LABEL, MCRF355 PROGRAMMER FIRMWARE, 355_9.HEX, x/xx/99, xxxxh SAMTEC AAVID HEADER, 1x15, BREAKAWAY, 0.025 POST, CONTACT HEATSINK, TO-220, SCREW, #4-40 PANHEAD PHILLIPS
02-01524 02-01524 02-01524
TSW-1-15-07-G-S 577202B00000
1998 Microchip Technology Inc.
DS21310B-page
microID13.56 Design Guide
Assembly 02-01524 02-01524 02-01524 02-01524 02-01524 02-01524 02-01524 02-01524 02-01524 02-01524 02-01524 Part 701-7357 ADG417BN MAX518 OP295 521-9165 TSW-102-07-S-S MNT-102-BK-T Manufacturer CONCORD ANALOG DEVICES MAXIM ANALOG DEVICES DIALIGHT SAMTEC SAMTEC Part Description NUT, #4-40 STEEL CAD-PLATED ADG417BN ANALOG SWITCH, MAX518 8-BIT DAC, OP295 DUAL LED, T1-3/4 DIFFUSED POSITION JUMPER BLOCK (SHUNT) CAP, 47pF AXIAL CERAMIC 100V RES, 5.1K 1/4W RES, 22.1K 1/4W METAL FILM RES, 2.21K 1/4W METAL FILM Reference Designator @JP1 R10,R14
HEADER, 0.025 POST
A470J15C0GHVVWA PHILLIPS 5043CX5K100J MFR-25FBF 22K1 MFR-25FBF 2K21 PHILLIPS YAGEO YAGEO
DS21310B-page
1998 Microchip Technology Inc.
microID13.56 Design Guide
CONTACT PROGRAMMER SOURCE CODE PICmicro®
include file processor #include <P16c63.inc>
TITLE "MCRF355 Programmer Board" _config b'00000001000001' ;protection off,PWRT disabled,watchdog disabled,XT oscillator Note: Assume Crystal instruction 400ns, .4us list p=16c63 ;The purpose this firmware program accept commands RS-232 execute commands MCRF355 (DUT). device serially programmed using ;the MCRF clock dutsck data dutsda. generated 8-bit ;through unity gain buffering Op-Amp. programming voltage also generated 8-bit through buffering Op-Amp with gain analog switch used isolate Op-Amp from dutsda line, they multiplexed. ;The program structured conduct read after erasing. program also ;goes directly read mode after programming. MCRF355 device serial test modes ;are used erase, read, program follows: ;TEST MODE CODES MCRF355 #define erase_code b'11010100' #define read_code b'11010110' #define prog_code b'11010010'
;Serial Commands from Send ERASE command Upload data array Download data array from Send PROGRAM command Send READ command unknown command will result error condition, which PICmicro will return lowercase flash busy light seconds.
;General program description: Five above commands/routines (Erase, Read, Program, Upload, Download) used program/erase/read TAG. Program Read commands update data_arry picMicro. following examples would erase/read/write TAG:
;Erase Sequence: Send erase command PART update picMicro data_array
;Read Sequence: update picMICRO data_aray upload this data array
;Program
Sequence: (includes erase, erase verify, program verify) Send erase command PART update picMicro data_array download data programmed Program Read back from upload verify bits programmed.
1998 Microchip Technology Inc.
DS21310B-page
microID13.56 Design Guide
multiple programs known blank part, command/routine that would required. ;Definitions follows: #define #define #define #define #define #define #define dutpgm dutsck serial_switchportb,3 led_yellowportb,4 led_red led_green dutsda portb,0 portb,2 push-button programming serial clock junper serial programming BUSY indicator Fail indicator Pass indicator serial data clock
portb,5 portb,6 portb,7 porta,0 porta,1
#define #define #define dutvpp #define which_dacflag,7 #define current_bitflag,0
serial data serial clock porta,2; Analog Switch enable ;This flag used select either ;DAC
;These 8-bit DAC, vref 5.0V voltages going through op-amp stages ;vhh gain 11X, gain #define vil.0 ;will volts
;Memory Allocation ;-cblock 0x20
rcv_data ;UART data read_byte ;Storage location during read_device temp ;TEMP variable temp1 ;Temp variable temp2 ;TEMP variable tempa ;TEMP variable tempb ;TEMP variable tempd1 ;TEMP variable tempd2 ;TEMP variable mcrf_bottom :20;bottom entire data spot pc_bottom:20;bottom entire data spot, used verify. temp3 ;TEMP variable ucount ;TEMP variable flag ;TEMP variable daber1 daber2 Vdut ;Vpp Programming voltage ;Vcc voltage ;TEMP variable ;TEMP variable ;dut variable endc
flag ;-;7 which being used toggling
DS21310B-page
1998 Microchip Technology Inc.
microID13.56 Design Guide
;MAIN ROUTINE goto 0x00 reset 0x05 ;RESET VECTOR
;Program Memory Begin
;Set Data reset clrf movlw movwf clrf ;Set Data movlw movwf clrf ;Set UART
Direction Registers Port STATUS,RP0 ;bank1 PORTB ;Clear pins B'00000001' TRISB ;set DDR- portB status,rp0 PORTB ;Clear pins Direction Registers Port STATUS,RP0 ;bank1 B'00000000' TRISA ;set DDR- portB status,rp0 PORTA ;Clear pins
movlw movwf movlw movwf movlw movwfTXSTA movlw movwf movlw movwf
STATUS,RP0 b'00100000' PIE1 SPBRG b'10100100' STATUS,RP0 b'10010000' RCSTA b'01000000' INTCON
;Select register page ;Enable RCIF interrupt ;9600 baud @10MHz ;Async, High baud rate ;Select register page ;Enable continous reception 8-bit,spen=1,cren=1 enable ;disable global interrupts
;Reset DACs open analog switch movlw movwf call movlw movwf call ;Set variables movlw movwf movlw movwf main .128 dutvpp flag,7 vdut SetDACXV flag,7 vdut SetDACXV ;open analog switch ;DAC
;DAC
;Set 8-bit with gain ;Set 2.5V, 8-bit with unity gain
1998 Microchip Technology Inc.
DS21310B-page
microID13.56 Design Guide
This main loop. PICmicro will here wait byte come from
wait waitloop btfss goto movf movwf pir1,rcif;Check byte come into UART waitloop ;has pattern arrived yet? rcreg,0 ;move rcreg into rcv_data ;move into rcv_data led_green led_red led_yellow led_yellow ;Turn busy light
;Execute when data received UART cchk1 movlw xorwf btfss goto call movlw btfss movlw movwf goto 0x50 rcv_data,0 exclusive against command status,2 ZERO set, they were same. cchk2 False program_device; True 0x59 true flag,1 test programming success 0X4E false txreg command complete wait
cchk2
movlw 0x45 xorwf rcv_data,0 exclusive against command btfss status,2 ZERO set, they were same. goto chk3 False call erase_device; True movlw 0x59 True btfss flag,1 Test Erase Success movlw 0x4E False movwf txreg command complete goto wait
chk3
movlw 0x52 xorwf rcv_data,0 exclusive against command btfss status,2 ZERO set,

Other recent searches


ZX95-2390A+ - ZX95-2390A+   ZX95-2390A+ Datasheet
SX6126A - SX6126A   SX6126A Datasheet
SS5554US - SS5554US   SS5554US Datasheet
SBH52444x - SBH52444x   SBH52444x Datasheet
RF5622 - RF5622   RF5622 Datasheet
FS6322-02 - FS6322-02   FS6322-02 Datasheet
AN646 - AN646   AN646 Datasheet

 

Privacy Policy | Disclaimer
© 2012 Datasheet Archive