Atmel AT89Sx makeshift programmer
---------------------------------

The makeshift programmer for uploading programs to Atmel chips AT89S51 (tested), AT89S52 (tested), AT89LP2052 (untested), AT89LP4052 (untested) and others, if their configuration is properly made (untested).

serisp.asm	- program for AT89C2051 (or similar chip, depending on your situation). Compile it with MCU8051IDE and upload it to your chip using your old programmer (try to borrow one, if you have not any).
uploader.cpp	- control program for uploading programs using your new makeshift programmer. Compile it using command "g++ -o uploader uploader.cpp".
uploader.conf	- configuration file describing how to program particular chip. Contains 4 (2 tested and 2 untested) configuratins as mentioned above.

Using the control program:

Input is pure binary file. You can prepare it from Intel's HEX file using following command: "srec_cat yourprogram.hex -intel -o yourprogram.bin -binary"

Connect the programmer to serial port of your machine. You need to have permission to use it. Of course, you can use override using the sudo command.

The syntax of control program is:

uploader <ic_type> <serial_port_device> <command> (<command> ...)

<ic_type>		- type of IC you try to program - must correspond with its name in uploader.conf
<serial_port_device>	- path to special file of the serial port serial_port_device
<command>		- erase | read <destination_binary_filename> | write <source_binary_filename>

Example of use:

(connect the circuitry to serial port - in this case the USB to RS232 cable is used - and switch the Vcc on)

uploader at89s51 /dev/ttyUSB0 erase

(switch the Vcc off, wait a couple of seconds and switch it on again)

uploader at89s51 /dev/ttyUSB0 write mytestprg.bin

(switch the Vcc off, wait a couple of seconds and switch it on again)

uploader at89s51 /dev/ttyUSB0 read mytestprg.check.bin

(now you can switch the Vcc off and compare the mytestprg.check.bin to mytestprg.bin to verify success of programming process; note, that the whole memory of the MCU is read, even if has been programmed partially)


Copyright (C) 2016 Petr Borsky
This fileset is distributed "as-is", absolutely without any warranty. Their author only hopes it will be helpful.
Anybody is permitted to use, modify, distribute and/or redistribute it strictly for non-commercial purposes.
Nobody is permitted to remove neither this README.txt nor this copyright note from the fileset if it is (re)distributed.