How to use the JTAG interface of AVR microcontroller

Publisher:EnchantedMagicLatest update time:2016-10-26 Source: elecfans Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere
AVR's JTAG emulator is very easy to use and is highly recommended. It can download and perform software and hardware simulation on all mega series with JTAG interfaces.
When I first started using the AVR JTAG emulator, I was not very clear about how to use it. After reading the English and Chinese instructions for the AVR JTAG emulator, I still did not understand its specific use. After my own exploration, I finally understood how to use this emulator. In fact, the method of using this emulator is very simple, but the instructions are too complicated, which makes people more and more confused. However, using this emulator is indeed much more convenient. It can realize hardware simulation and software simulation, step program, and find program loopholes. It is a good auxiliary debugging tool.
The following is a relatively simple method of use that I have explored:
(1) The use environment of AVR JTAG is: AVR Studio 4.07 or above, 9-15DC power supply, PC and RS232 port.
(2) Install AVR Studio: When installing AVRStudio, put the CD provided with the machine into the CD-ROM, select the setup.Exe file in the avrstuio4.07 directory, and follow the steps prompted by the installation wizard.
(3) Before starting AVR Studio, connect JTAGICE between the host PC and the target board to ensure that AVR Studio can automatically detect the connection.
(4) To connect the emulator to the host computer, connect one end of the "serial communication cable" that comes with the emulator to the "serial communication port" of the emulator, and the other end to any serial port of the computer. Note: AVR Studio cannot share serial port resources with other programs. Before opening AVR Studio, close other programs that use the serial port (such as ModeM.IrDA).
(5) Connection between JTAGICE and the target board: At least 6 lines are required to connect to the target board to complete the simulation task. They are: TCK, TMS, TDO, TDI, Vref, GND, and there are two optional pins nSRST and Vsupply. Pin nTRST is not connected. The function of Vsupply is to power the JTAGICE from the target board (only for the interface part). The function of nSRST is to monitor the reset line of the target board. However, it is not necessary during the simulation process. If the application programs the JTD bit in MCUSR, the JTAG interface will be closed. In order to reprogram the target board using JTAGICE, the reset pin must be controlled.
AVR JTAG emulator connection summary: Connect the AVR JTAG to the PC serial port and power it with a 9-15VDC DC power supply. Connect the AVR JTAG download line according to (5). This completes the overall connection of the emulator. At the same time, the target board should also be powered on.
(7) When the JTAGICE is connected, you can turn on the power: Perform the power-on operation in the following order to ensure normal communication between the JTAGICE, the PC and the target board.
Reference address:How to use the JTAG interface of AVR microcontroller

Previous article:AVR Driver for ADS7816
Next article:Several USART interface functions of AVR

Latest Microcontroller Articles
  • Learn ARM development(21)
    First, declare the task pointer, because it will be used later. Task pointer volatile TASK_TCB* volatile g_pCurrentTask = NULL;volatile TASK_TCB* vol ...
  • Learn ARM development(20)
    With the previous Tick interrupt, the basic task switching conditions are ready. However, this "easterly" is also difficult to understand. Only through continuous practice can we understand it. ...
  • Learn ARM development(19)
    After many days of hard work, I finally got the interrupt working. But in order to allow RTOS to use timer interrupts, what kind of interrupts can be implemented in S3C44B0? There are two methods in S3C44B0. ...
  • Learn ARM development(14)
    Since development under LINUX is still quite troublesome, is there a more convenient and simple development method under WINDOWS? The answer is yes. Of course, it is not a development tool like ADS, because it ...
  • Learn ARM development(15)
    When using GCC to develop ARM, you will definitely encounter compiler problems. For example, you will encounter various warnings and errors when compiling C code. For example, I encountered several warnings yesterday, so let's take a look at what these warnings are ...
  • Learn ARM development(16)
  • Learn ARM development(17)
  • Learn ARM development(18)
  • Embedded system debugging simulation tool
Change More Related Popular Components

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号