欢迎光临MCUWAY! 本站网名:单片机之路  永久域名:www.mcuway.com

设为首页

加入收藏

电子基础 初学MCU 单片机类型 MCU程序 MCU应用 设计软件 测控电路 技术论坛
 您现在的位置: 单片机之路 >> 单片机程序 >> 单片机编程 >> 文章正文

自制STK500 串口ISP下载线

HVProg

  
  • Compatible with AvrStudio
  • Supports all AVR Controllers
  • Parallel and serial High-Voltage-Programming
  • Small and easy layout with only a few parts
  • STK500 protocol
  • Schematics and board layout available

Introduction

The project started as an enhancement of Martin Thomas  Evertool project. He has rebuilt the AVRISP and JTAG adapter with only a few parts. Unfortunately they both don't support high-voltage programming modes - the only possibility to 'rescue' AVR controllers when you i.e disabled the reset or SPI fuses. The only widely available possibility was the STK500 from ATMEL.
HVProg is a redesign of the original STK500 without all components of a development board. It is based on the original ATMEL schematics that are freely available on the net (i.e at avrfreaks.net). The main target was to keep all nessecary functionality to programm all available AVR controllers in every programming mode that the STK500 supports.

If you look for a development board for ATMEL AVR controllers you better buy the original STK500. If you only need an ISP programming adapter the AVRISP included in Evertool is better suited for you!


Please consider:
  • HVProg can't replace a real development board and will never do
  • No ESD protoction
  • HVProg in the Basic-Version needs a stabilized 12V and 5V input voltage
  • For one step a working programmer is needed (AvrProg compatible prefered, see software section)
  • HVProg has only been tested in 5V environments
There are two versions of the project available:
  • The Basic-Version has seperate connectors for the different programming modes and is only available as schematic. It needs a stabilized 5V and 12V input voltage and is supposed to be used for own board development. This version will not be updated except to the correction of errors.

  • The Advanced-Version is available as schematic and board layout. Adapter boards for HV-Programming will be ready soon and a good tutorial how to build a case for HVProg is linked. This version needs an unstabilized input voltage of at least 15V (AC or DC).

Programming interfaces

Basic-Version

  • 6 Pin ISP
  • 10 Pin ISP
  • Serial-High-Voltage Programming (no standard connector)
  • Parallel-High-Voltage Programming (STK500 compatible control und data connectors and one connector with other needed signals)

Advanced-Version

  • 6 pin ISP
  • 20 pin connector for ISP, parallel and serial high-voltage programming

Changelog

  • 03.10.2004 -> First version released (V0.2)
  • 05.10.2004 -> Schematics as eagle file released
  • 06.11.2004 -> Version 0.3 with less parts
  • 24.4.2005 ->Completely updated site with lots of new infos

Copyright

The schematics, boards and every other available information on this site are freely available for noncommercial use only. I am not responsible if anything get damaged by my circuits or by false information provided or any other reason. I am also not responsible for linked content. These sites are property of their owners.

Hardware

Basic-Version (v0.3)

  • Schematic (Eagle-Format, Freeware 4.11):   Download
  • Schematic as gif-file (~400kb):   Download
  • Part list as txt:   Download

Advanced version (v0.5)

  • Schematic (Eagle-Format):   Download
  • Schematic as gif-file:   Download
  • Board (Eagle-Format):   Download
  • Case: At avr-projekte.de is a very good guide how to build a case for HVProg. The site is in german but with lots of self explaining pictures so give it a try: To the guide
  • Pictures of the assembled PCB are lower on this site

Connector details

  • ISP: The connector is compatible with the ATMEL standard (see STK500 User Guide  page 51)

  • HV-Seriel: (For exact pinning check the appropriate controller datasheet. Section Memory Programming/High Voltage Serial Programming)

    Pin nameuC pin
    SWCLKXTAL1
    TRSTReset (High Voltage Enable Jumper must be set)
    PPD0'Serial Data Input' (usually PB0)
    PPD1'Serial Instr. Input' (usually PB1)
    PPD2'Serial Data Output' (usually PB2)


  • HV-Parallel: For special connections check STK500 User Guide (Table 3-3 page 21, look for BSEL2 and PJUMP)

    Pin nameuC pin
    VCCtarget supply voltage uC
    GNDground
    TRSTReset (High Voltage Enable Jumper must be set)
    SWCLKXTAL1
    PPC0If BSEL2 then connect to PortA.0 otherwise not needed
    PPC1PortD.1: Rdy/Bsy
    PPC2PortD.2: OE
    PPC3PortD.3: WR
    PPC4PortD.4: BS1
    PPC5PortD.5: XA0
    PPC6PortD.6: XA1
    PPC7PortD.7: PAGEL
    PPD0PortB.0
    PPD1PortB.1
    PPD2PortB.2
    PPD3PortB.3
    PPD4PortB.4
    PPD5/MOSIPortB.5
    PPD6/MISOPortB.6; if PJUMP connect it to PortC.0
    PPD7/SCKPortB.7; if PJUMP connect it to PortC.1


  • External clock to reanimate controllers with wrong clock settings (fuses) is available SWCLK. The external clock has to be connected to XTAL1 and can be adjusted up to 3,69MHz with the STK500 plugin in AvrStudio.


Software

The original ATMEL firmware is available in .ebn format that is only supported by AvrProg (included in AvrStudio). When you have the original Avr910 programmer or an improved version (like the one from Klaus Leidinger [German Site]) you can directly flash the firmware in the At90s8535 or Mega8535 (won't work with original Avr910). The file you need is in the AvrStudio directory: ".\Stk500\stk500.ebn".


Software installation:
  1. Connect the ISP programming adapter with your computer and the ISP port on the HVProg board
  2. Mount the 'Selfprogramming' jumper to pin 1,2
  3. Connect the power supply (Basic: only 5V supply needed. Advanced: Regular supply)
  4. Start AvrProg (AvrStudio: Tools/AvrProg)
  5. Select 'stk500.ebn' and set the appropriate fuses (ext. high frequency crystal, only for Mega8535)
  6. Flash the firmware
  7. Disconnect power supply and then the programming adapter
  8. Mount the 'Selfprogramming' jumper back to pin 2,3 (default)

Important:
With the original Avr910 you can't programm a Mega8535. For this one you need a newer version of the programmer like the one from Klaus Leidinger

How to set the Fuse-Bits:




Gallery

First prototype
PCB top
PCB bottom
Case
Both together
Ready to use
HV-Parallel board
40pin programming adapter
 



FAQ

When writing the firmware with Klaus Leidinger's programmer you get a write error (90s8535 only)
The problem is known and results in a bug in the programmers firmware. An Update is available here and should be used to prevent errors.


HV-Programming is not working with Basic-Version
The 12V power supply must be between 11.5V and 12.5V otherwise the programming mode cannot be entered.


HV- and/or ISP-Programming modes are not working
The 'Selfprogramming' Jumper must be placed at pin 2,3. For HV-Mode the 'High Voltage Enable' jumper hast to be mounted, too.


Can i use HVProg with the new 2.x firmware?
Yes, the original STK500 is completely simulated. All future firmware version should work without any problems.


→ 
 

普通文章28课:单片机音乐汇编程序设计
普通文章27课:单片机的一些基本概念
普通文章26课:单片机矩阵式键盘接口技术
普通文章51单片机教程(从原理开始基于汇编)
普通文章1课:单片机概述
普通文章2课:8051单片机引脚介绍
普通文章3课:单片机存储器结构结构分析
普通文章4课:第一个单片机小程序
普通文章5课:单片机延时程序分析
普通文章6课:单片机并行口结构
普通文章7课:单片机的特殊功能寄存器
普通文章8课:单片机寻址方式与指令系统
普通文章9课:单片机数据传递类指令
普通文章10课:单片机数据传送类指令
普通文章11课:单片机算术运算指令
普通文章12课:单片机逻辑运算类指令
普通文章13课:单片机逻辑与或异或指令祥解
普通文章14课:单片机条件转移指令
普通文章15课:单片机位操作指令
普通文章16课:单片机定时器与计数器
普通文章17课:单片机定时器/计数器的方式控制
普通文章18课:单片机的中断系统
普通文章19课:单片机定时器、中断试验
普通文章20课:单片机定时/计数器实验
普通文章21课:单片机串行口介绍

电子器件 基础电路 单片机语言 了解单片机
PIC系列 ARM系列 AVR系列 单片机源码
单片机编程 设计方法 应用实例 Protel
PowerPCD 知识点 练习题 单片机应用
  • 上一篇文章:
  • 下一篇文章:
  • 更多精彩内容>>>

    普通文章电流单位
    普通文章功率单位
    普通文章什么是达林顿管?
    普通文章晶闸管的作用与原理

    学习单片机的必经之路——单片机之路,永久域名:www.mcuway.com