Technical Note TN8000.23 Converting binary to ROM TN8000.23 Technical Note Converting an .axe binary file to a .bin, a .hex or a .rom file for industrial programmers Rev 2 September 2006 www.semtech.com 1 Technical Note TN8000.23 Converting binary to ROM Table of Contents 1 2 3 4 5 6 Introduction ......................................................................................................................................................3 axe2rom ............................................................................................................................................................3 Double speed products...................................................................................................................................3 axe2rom usage.................................................................................................................................................4 Using Phyton ChipProg+ ................................................................................................................................4 Converting an .axe file to a Standard/Extended Intel .hex file ....................................................................4 © Semtech 2006 www.semtech.com 2 Technical Note TN8000.23 Converting binary to ROM 1 INTRODUCTION The development tools for XE8000 generate a binary file as output file for programming; the file extension is either *.axe for Raisonance RIDE or *.bin for Phyton Project-XE. Note *.axe is equivalent to *.bin As some industrial programmers such as BPMicro BP-XXX need a ROM file, this technical note explains how to do the conversion from binary format to ROM format. Note: When you use Phyton ChipProg+ or RIDE and the XELoader to program with an XE8000MP this utility is not needed. 2 AXE2ROM The utility axe2rom.exe performs the following gnu commands on the binary files: c816-objcopy.exe <file>.axe –target = <file>.srec c816-srec2rom.exe <file>.srec -prog -o <file>.rom 3 DOUBLE SPEED PRODUCTS For the products like the XE8807A and the XE8802A, in 4kInstruction mode, the useful memory is 4k instructions but physically the whole flash array is used, the instructions are read in parallel. The axe2rom.exe utility performs one more action that consists of doubling the code. See the example below with a 3 instruction code: 0000 0001 0002 0003 … … 0ffe 0fff 1000 1001 1002 0033FFFB <- First line of your code 0033F82C 0033F82C 00000000 00000000 00000000 0033FFFB <- First line of your code (copied) 0033F82C 0033F82C The code of the line 0000h is copied to line 1000h (4096d). Both lines are read at the same time when the microcontroller is used in double speed mode. © Semtech 2006 www.semtech.com 3 Technical Note TN8000.23 Converting binary to ROM 4 AXE2ROM USAGE The utility axe2rom.exe is a command line executable see the usage instruction below: C:\SEMTECH>axe2rom Usage: axe2rom [-t target_name] | [input_file] | Converts a binary file (*.axe or *.bin) to *.rom -h : Display this information. -t target_name : Specifies the target chip to be programmed List of possible targets (please respect the syntax): xe88LC01a, xe88LC02-4kI, xe88LC02-8kI, xe88LC03, xe88LC05a xe88LC06a, xe88LC07a, xe1283-4kI, xe1283-8kI, input_file : Input_file to convert in *.rom Input file formats : *.axe, *.bin *** axe2rom Version V 1.0 Release date Dec 20 2004 *** Copyright (c) 1997-2004, XEMICS SA, Monruz 2, CH-2000 Neuchatel, Switzerland C:\SEMTECH > Converting an *.axe file to an *.rom file is as follow: C:\SEMTECH >axe2rom -t xe88lc02-4ki file.axe Generated file : file.rom (2305 instructions) C:\SEMTECH > 5 USING PHYTON CHIPPROG+ The Phyton ChipProg+ uses binary images, in order to use a *.axe file the user can either change the file extension from *.axe to *.bin or select the axe file using the filter *.* Note: To avoid errors during the checksum, set 2Mb buffer size in "Configure | Buffers | Edit" dialog of ChipProg+ 6 CONVERTING AN .AXE FILE TO A STANDARD/EXTENDED INTEL .HEX FILE As explained in section 1, development tools for XE8000 generate a Raisonance .axe binary file. To convert this .axe file into Standard/Extended Intel .hex, just call this Raisonance RIDE utility. C:\RIDE\BIN>c816-objcopy file.axe --target=ihex file.hex C:\RIDE\BIN> © Semtech 2006 www.semtech.com 4 Technical Note TN8000.23 Converting binary to ROM © Semtech 2006 All rights reserved. Reproduction in whole or in part is prohibited without the prior written consent of the copyright owner. The information presented in this document does not form part of any quotation or contract, is believed to be accurate and reliable and may be changed without notice. No liability will be accepted by the publisher for any consequence of its use. Publication thereof does not convey nor imply any license under patent or other industrial or intellectual property rights. Semtech. assumes no responsibility or liability whatsoever for any failure or unexpected operation resulting from misuse, neglect improper installation, repair or improper handling or unusual physical or electrical stress including, but not limited to, exposure to parameters beyond the specified maximum ratings or operation outside the specified range. SEMTECH PRODUCTS ARE NOT DESIGNED, INTENDED, AUTHORIZED OR WARRANTED TO BE SUITABLE FOR USE IN LIFE-SUPPORT APPLICATIONS, DEVICES OR SYSTEMS OR OTHER CRITICAL APPLICATIONS. INCLUSION OF SEMTECH PRODUCTS IN SUCH APPLICATIONS IS UNDERSTOOD TO BE UNDERTAKEN SOLELY AT THE CUSTOMER’S OWN RISK. Should a customer purchase or use Semtech products for any such unauthorized application, the customer shall indemnify and hold Semtech and its officers, employees, subsidiaries, affiliates, and distributors harmless against all claims, costs damages and attorney fees which could arise. Contact Information Semtech Corporation Wireless and Sensing Products Division 200 Flynn Road, Camarillo, CA 93012 Phone (805) 498-2111 Fax : (805) 498-3804 © Semtech 2006 www.semtech.com 5