0% found this document useful (0 votes)
3 views4 pages

Dso062 How To Program

This document provides instructions on how to program the 062 Oscilloscope using either a hardware programmer or a pre-loaded bootloader. It details the necessary tools, steps for programming with a hardware programmer like the Altera ByteBlasterMV, and the process for updating firmware via the bootloader using a serial level converter. Additionally, it includes notes on fuse configuration for the ATmega64 microcontroller.
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
3 views4 pages

Dso062 How To Program

This document provides instructions on how to program the 062 Oscilloscope using either a hardware programmer or a pre-loaded bootloader. It details the necessary tools, steps for programming with a hardware programmer like the Altera ByteBlasterMV, and the process for updating firmware via the bootloader using a serial level converter. Additionally, it includes notes on fuse configuration for the ATmega64 microcontroller.
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

DN062-08v02

How to Program 062 Oscilloscope


Model: 06201P,06201KP,06202KP

The firmware of the scope resides in its core controller, a ATmega64. This is an AVR series
micro-controller from Atmel. There are two ways to program the chip for the 06201 scope. One
method is using a hardware programmer. The other method is via the pre-loaded bootloader.
This design note explains both.

Program the Scope with a Hardware Programmer


To do this you need to prepare the following tools:
1) An AVR hardware programmer
2) Software to control programmer
The AVR is one of the most popular micro-controller series. It shouldn’t be too difficult to
find a ready-made programmer for it. There are also plenty of resources on the web for building
one yourself if you don’t want to purchase one. Normally, they also include information on the
controlling software. Also, you can use FPGA/CPLD programmers from some big names (such as
Altera or Xilinx) as an AVR programmer. You can also use the AVR STK200 parallel
programmer (or compatible). An advantage of the STK200 programmer is that it works with
PonyProg, a famous free programming software ([Link]). This article will use the
Altera programmer ByteBlasterMV as an example since the programming header on the 06201
board was designed to be compatible with it. For any other programmer you just need to make a
simple dongle to route signals to their correct pins. (JYE Tech provides programmers that are
compatible with the AVR STK200 and the Altera ByteBlasterMV. Please see
[Link] .)
The controlling software for Altera’s ByteBlasterMV was designed by Chan. It can be
downloaded from [Link] This program runs in DOS and
detailed instructions for usage can be found within the download.
Here are the programming steps for use with the ByteBlasterMV:
1) Identify the programming header (J4) and its orientation (Fig. 1 and Fig 2).

Fig. 1 Fig. 2

2) Correctly connect J4 to programmer with programming cable.


3) Connect the programmer to your PC parallel port.
4) Power up the scope.
5) Check if the programmer and connections work properly by typing in the command
“avrsp –pl1 –rf ”. This command reads the fuse information of the ATmega64. If it
returns valid results then go to the next step (see below for proper values).
6) Run command
avrsp -pl1 [Link] [[Link]]
to burn in the main firmware (and bootloader).

JYE Tech -1- [Link]


How to Program 062 Oscilloscope DN062-08v02

7) Run command
avrsp -pl1 [Link]
to burn in the EEPROM data (You don’t need to do this for firmware version -092
or higher).
8) Program fuse bytes in the following order (This is only necessary when the chip is
programmed for the first time or the fuses were changed).
avrsp -pl1 -fx11111111 (Fuse for extended byte, 0xFF)
avrsp -pl1 -fh11000000 (Fuse for high byte, 0xC0)
avrsp -pl1 -fl10101110 (Fuse low byte, 0xAE)
9) If no error was reported then programming is done. Power down scope and remove
programming cable.

Update the Scope Firmware via Bootloader


The scope was preloaded with a bootloader. Each time the scope is powered up it enters the
bootloader first and stays there for about 2 – 3 seconds. During this period the bootloader will
check the serial port for a communications request. If a request is found and communication
established it will accept the firmware download and flash the newly downloaded firmware into
the ATmega64. If nothing happens, it will boot into scope main firmware and start normal
operation.
To use the bootloader the following tools are needed:
1) Serial level converter.
2) Download program running on PC.
A level converter is needed because the scope serial port signal levels (0 - +5V) are not compatible
with standard serial port signal levels (+/- 3V - +/- 25V). A simple level converter can be easily
made with a few common components. The schematic is available at the JYE Tech web site
([Link] ). The finished
product can also be purchased from the same web site (PN: 100-04000-00B).
Alternatively many USB-Uart converters can be used for the same purpose. JYE Tech has
two USB-Uart converters available (PN 07301 and PN 08101). Please visit [Link] for
details.
The download program for the PC ([Link]) was designed by Shao Ziyang
([Link] ). This program communicates with the bootloader and transfers
code to be burned to the bootloader. It can be downloaded from the JYE Tech web site
([Link]
Steps to use the bootloader:
1) Connect serial level converter to the serial port pins (shown in Fig. 1) of the scope board.
Do not power up the scope yet.
2) Connect the other end of the level converter to PC (Fig. 3).

Oscilloscope PC
Level Converter
Board

Fig. 3

3) Run [Link]. Click “Language” and select “English”.


4) Click on “Options” at the main menu. Change settings on the tab “AVR” to those shown
in Fig. 4. Connect Key has to be “HEX 64”. Flash size should be 64K.
5) Change settings on tab “System” to those shown in Fig. 5. Communications protocol
should be set to “Lite Xmodem”.
6) Change settings on tab “Com Port” to those shown in Fig. 6. Com port number should

JYE Tech -2- [Link]


How to Program 062 Oscilloscope DN062-08v02

be chosen according to the actual port used. Communication format is 9600 bps, 8N1
with no parity and flow control.
7) Load HEX file to be downloaded to scope. Click “File – Load” and select your file.

8) C
l
i
c
k

o
n


D
n

i
c
o
n

( Fig. 4 Fig. 5
s
e
e

F
i
g
.
7
.
o
r

y
o
u

c
a
n

c
Fig. 6 Fig. 7
l
i
ck on “Operate – Download” from the main menu) Power up the scope immediately
after clicking. You will see AVRUBD is trying to communicate with the scope board.
If the handshake failed you will see a screen like that of Fig. 8.
9) Otherwise, download is successful if you see a screen like Fig. 9.

JYE Tech -3- [Link]


How to Program 062 Oscilloscope DN062-08v02

Fig. 8 Fig. 9

Notes
Fuse configuration of the ATmega64 is as follows. Usually these settings should not be
changed. In case these bytes are modified, a programmer is needed to restore them. They can not
be modified with the bootloader.
Fuse Extended Byte: 0bxxxxxx11 (0xFF)
Fuse Higher Byte: 0b11x00000 (0xC0)
Fuse Lower Byte: 0b10101110 (0xAE)

Revision History
Version Date Descriptions
01 2008.09.28 First created
02 2010.03.27 Corrected language errors by Mr. Brent Burns. Some minor changes made.

JYE Tech -4- [Link]

You might also like