| The Datasheet Archive - 100 Million Datasheets from 7500 Manufacturers. |
2004 In-System Programming With 8051-Based Microcontrollers
Top Searches for this datasheetGENERAL ENGINEERING TOPICS MICROCONTROLLERS MISCELLANEOUS CIRCUITS 2004 In-System Programming With 8051-Based Microcontrollers Many Dallas Semiconductor 8051-based microcontrollers support in-system programming internal ROM-based bootstrap loader. In-system programmability allows preassembled hardware custom-programmed demand, also allows software upgrades physically inaccessible locations. This application note discusses theory behind bootloader operation, construct physical interface host, well debugging tips event possible problems. Introduction Many members Dallas Semiconductor 8051-based microcontroller family support insystem programming commonly available RS-232 serial interface. In-system programming means that program and/or data memory modified without disassembling embedded system physically replace memory. With emphasis ease-of-use versatility, this feature adds number very valuable features embedded design: Allows hardware assembled stocked factory software-customized right before shipment, Eliminates high cost disassembling units field when software updates required, Allows software upgrades physically inaccessible locations, Accesses dedicated configuration status registers, Enables loading software into secure microcontrollers with memory encryption. Devices with this feature include: DS2250, DS2250T, DS2251T, DS2252T, DS5000, DS5000T Secure Microcontroller Modules DS5000FP, DS5001FP, DS5002FP, DS5002FPM Secure Microprocessors DS5240, DS5250 High-Speed Secure Microprocessors DS80C400 Networking Microprocessor DS89C420, DS89C430, DS89C440, DS89C450 Ultra-High-Speed Flash Microcontrollers bootstrap loader invoked taking more external device pins specified state. When activated, device begins execution loader software from dedicated inside device. Upon receipt carriage return character, serial port performs autobaud function synchronizes itself host's baud rate. Communication between host (usually target common RS-232 interface found most PCs, eliminating need expensive custom hardware. protocol used bootloader simple consists more ASCII character commands with associated status messages file transfer routines. Communications performed using free Microcontroller Tool communications software from Dallas Semiconductor with serial communications tool. Most these devices also support in-application programming, allowing device modify program memory under control application software. this design perform the-fly software updates while still performing primary function. Details presented datasheet user's guide that particular device. This document intended supplement information provided datasheet and/or user's guides particular device. Please reference these documents needed while reading this application note. Physical Connection bootstrap loader invoked taking more pins specified state shown Table this time application software execution terminated program control transferred internal bootstrap ROM. sure check appropriate errata sheet there errata associated with bootstrap loader activation. Table Bootstrap Loader Stimuli Device DS2250(T) DS5000(T) DS5000FP PSEN PROG P1.7 P2.7 P2.6 Unconnected logic DS2251T DS2252T DS5001FP DS5002FP/FPM DS5240 DS5250 DS80C400 DS89C420 DS89C430 DS89C440 DS89C450 Unconnected logic physical connection method invoking bootloader varies slightly between device families, contains same basic elements. connecting RS-232 CMOS level translator required shown interface communication control signals between host target microcontroller. comparable RS-232 translator substituted shown. figures shown below signal microcontroller load mode select. Several designs buffer with tri-state outputs. When active (low state), enables buffers turn driving multiple signals that activate bootloader. This buffer generically referred schematics "HC/AC125", because similar device logic families will such 74HC125, 54HC125, 74AC125, 74LS125, etc. These devices common should available from supplier general purpose logic such Motorola, Fairchild Semiconductor, Toshiba, Microelectronics, many others. other devices single signal activates bootloader, this buffer needed. this case signal connected directly activation target microcontroller. Figure Physical Connection, DS89C420/430/440/450-based designs Figure Physical Connection, DS5240/50 DS5001/2FP-based designs Figure Physical Connection, DS5000-based designs bootloader uses clock source attached XTAL1/XTAL2 pins time base. crystal used, must meet recommendations (resonance fundamental mode, parallel ATcut, amount load capacitance, etc.) listed datasheet that device. Because bootloader relies internal timers autobaud measurements, restrictions range frequencies compatible with bootloader. Please consult User's Guide your particular device range clock frequencies that compatible with bootloader. Software After bootstrap loader been activated, microcontroller will poll serial port, looking carriage return (0Dh) character eight data bit, parity, stop (8-N-1) format. bootstrap loader software measures length high spaces within that character determine baud rate host system. This autobaud feature allows bootstrap loader communicate with number host systems without being limited fixed baud rate. Once bootstrap loader been invoked baud rate calculated, device will transmit sign-on banner identifying device. Then device will display prompt character wait commands. Again, command varies between device families, they usually single ASCII characters will always include versions load, verify, erase memory commands. Consult specific device user guide command listing. simple bootstrap loader interface permits several ways communicate between target microcontroller. simplest Microcontroller Tool (MTK) from Dallas Semiconductor. utility communicating with ROM/bootstrap loader most Dallas Semiconductor Microcontrollers. high-featured front-end, simplifying task configuring target uploading downloading code configuring special functions. main window allows user type commands directly target microcontroller. Many commands supported target loader entered directly from main window MTK. Special support provided file-related commands which require special communication protocols. Figure Microcontroller Tool also possible simple terminal emulator such Procomm Plus Hyperterminal communication target microcontroller based DS5000FP, DS5001FP, DS5002FP, DS80C400. Other 8051-based microcontrollers from Dallas Semiconductor utilize interactive loading protocol that requires protocol-aware application. Debugging Communication Problems following list most common problems encountered while communicating with microcontroller bootstrap loader. Wrong Clock Frequency bootstrap loader unable autobaud device clocked wrong frequency. Check user's guide supported frequencies. frequency-dependent problems suspected, highly recommended that bootloader problems debugged using 11.0592MHz crystal. This very standard microcontroller operating frequency will generate most standard baud rates. Other Applications Interfering with Port Background applications intentionally unintentionally interfering with selected port Check Task Manager possible conflict sources. Baud Rate Fast Selected Operating Frequency slow operating frequencies (below approximately MHz) device able autobaud high baud rates unable process large files without overrunning buffer. Reduce baud rate again. Microcontroller Operating possible that observed failure with bootloader rather microcontroller itself. following short diagnostic checklist troubleshoot system-level problems. power being supplied power pins device correct voltage? sure probe actual microcontroller, traces board, most accurate reading. held address pins toggle? most devices holding places device into external access mode, which forces device fetch instructions from external bus. Although immediately evident device generating right addresses, presence address activity indicates microcontroller operational state. certain devices toggles default. active? Does match expected frequency? most devices, signal will oscillate division oscillator frequency. Does device have sufficient decoupling capacitance? Most Dallas Semiconductor microcontrollers operate higher internal clock rates than their traditional counterparts. Drop-in designs upgrades require additional capacitance accommodate performance increase. Obsolete Version Microcontroller Tool using latest version Microcontroller Tool software? Errata Conditions Have checked appropriate errata sheet relevant errata? Although rare, possible bootstrap loader deviate from published specifications certain device revisions. Cable Long Excessive cable length between host computer target computer degrade signal quality. There definite rule long cable length should standard operating principles such using shielded cable, keeping away from noise sources such motors Tesla coils should help. effect long cables reduced decreasing baud rate use. More Information DS2250: DS2250T: DS2251T: DS2252T: QuickView Full (PDF) Data Sheet QuickView Full (PDF) Data Sheet QuickView Full (PDF) Data Sheet QuickView Full (PDF) Data Sheet DS5000FP: QuickView Full (PDF) Data Sheet Free Samples DS5000T: QuickView Full (PDF) Data Sheet DS5001FP: QuickView Full (PDF) Data Sheet DS5002FP: QuickView Full (PDF) Data Sheet Free Samples DS5240: DS5250: QuickView Full (PDF) Data Sheet QuickView Full (PDF) Data Sheet DS89C420: QuickView Full (PDF) Data Sheet Free Samples DS89C430: QuickView Full (PDF) Data Sheet Free Samples DS89C440: QuickView Full (PDF) Data Sheet Free Samples DS89C450: QuickView Full (PDF) Data Sheet Free Samples Other recent searchesZL50130 - ZL50130 ZL50130 Datasheet STM32F103x4 - STM32F103x4 STM32F103x4 Datasheet STM32F103x6 - STM32F103x6 STM32F103x6 Datasheet SOP28 - SOP28 SOP28 Datasheet SOP32 - SOP32 SOP32 Datasheet SCHOTT1000 - SCHOTT1000 SCHOTT1000 Datasheet RX78K0R - RX78K0R RX78K0R Datasheet Real-Time - Real-Time Real-Time Datasheet Operating - Operating Operating Datasheet System - System System Datasheet Analysis - Analysis Analysis Datasheet CubeSuite - CubeSuite CubeSuite Datasheet QB-52GB-YS-01T - QB-52GB-YS-01T QB-52GB-YS-01T Datasheet MAX5974 - MAX5974 MAX5974 Datasheet MAX5974A - MAX5974A MAX5974A Datasheet MAX5974C - MAX5974C MAX5974C Datasheet MAX5974B - MAX5974B MAX5974B Datasheet MAX5974D - MAX5974D MAX5974D Datasheet MAX5974A - MAX5974A MAX5974A Datasheet MAX5974B - MAX5974B MAX5974B Datasheet MAX5974C - MAX5974C MAX5974C Datasheet MAX5974D - MAX5974D MAX5974D Datasheet
Privacy Policy | Disclaimer |