PG302

From ShawnReevesWiki
Revision as of 01:23, 7 November 2013 by Shawn (talk | contribs)
Jump to navigationJump to search

The PG302 is a flash programmer produced by the now-defunct Iguana Labs, who provided kits and tutorials for learning how to program micro-controllers in the early 2000s. I use the programmer to write programs onto Atmel 89C2051 chips that cost less than two dollars each.

Iguana Labs provided a program for Windows that communicated with the programmer, allowing us not only to program chips, but to read programs from the chips, lock them, erase them, or verify their contents. There being good open-source tools for developing 8051 programs *nux, like [MCU 8051 IDE], I would prefer to use the programmer in Linux or Mac. The three options for this out-of-the-Windows use are

  1. Use [PG302-Linux], a program the author admits is buggy. I haven't had success with it yet.
  2. Use a program intended for direct serial communication, like GtkTerm. I have had success loading a program, using the protocol provided with PG302-Linux. For example, I open a serial port at 57600 baud, 8 bits, 1 stop bit, no parity, no flow control, to a serial cable connected to the programmer. Then I can issue commands like "3", which requests the chip checksum. For the complete protocol, see http://pg302.sourceforge.net/protocol.html
  3. Write a program to provide a GUI like the original PG302 control program for Windows. This could be done in Cocoa for Mac, with I/O Kit for serial communication, and a window with pull-down menus to select speed, buttons for various commands, and a file selector for reading, writing, and verifying files.

See also

Atmel, a manufacturer of 8051 devices: http://www.atmel.com/products/microcontrollers/8051architecture/default.aspx