CVS: python/mspgcc jtag.py,1.13,1.14
"Chris Liechti" <[email protected]> Sun, 8 Feb 2009 19:39:05 +0000
| Newsgroups | gmane.comp.hardware.texas-instruments.msp430.gcc.cvs |
|---|---|
| Message-ID | <[email protected]> |
Update of /cvsroot/mspgcc/python/mspgcc In directory 23jxhf1.ch3.sourceforge.com:/tmp/cvs-serv32014/mspgcc Modified Files: jtag.py Log Message: - added --spy-bi-wire-jtag option (4 wire on spy-bi-wire devices) - fix for edd length segments - comment updtes Index: jtag.py =================================================================== RCS file: /cvsroot/mspgcc/python/mspgcc/jtag.py,v retrieving revision 1.13 retrieving revision 1.14 diff -u -w -d -r1.13 -r1.14 --- jtag.py 13 Mar 2007 11:34:00 -0000 1.13 +++ jtag.py 8 Feb 2009 19:39:03 -0000 1.14 @@ -1,6 +1,6 @@ # Parallel JTAG programmer for the MSP430 embedded proccessor. # -# (C) 2002-2006 Chris Liechti <[email protected]> +# (C) 2002-2009 Chris Liechti <[email protected]> # this is distributed under a free software license, see license.txt # # http://mspgcc.sf.net @@ -40,6 +40,7 @@ #INTERFACE_TYPE JTAG_IF = 0 SPYBIWIRE_IF = 1 +SPYBIWIREJTAG_IF = 2 #reset methods PUC_RESET = 1 << 0 #Power up clear (i.e., a "soft") reset. @@ -300,6 +301,10 @@ status = MSP430_Configure(INTERFACE_MODE, SPYBIWIRE_IF) if status != STATUS_OK: raise IOError("Could not configure the library: %s (device not spi-bi-wire capable?)" % MSP430_Error_String(MSP430_Error_Number())) + elif interface == 'spy-bi-wire-jtag': + status = MSP430_Configure(INTERFACE_MODE, SPYBIWIREJTAG_IF) + if status != STATUS_OK: + raise IOError("Could not configure the library: %s (device not spi-bi-wire capable?)" % MSP430_Error_String(MSP430_Error_Number())) else: status = MSP430_Configure(INTERFACE_MODE, JTAG_IF) if status != STATUS_OK: @@ -608,6 +613,8 @@ _parjtag.set_flash_callback(self.progess_update) bytes = 0 for seg in self.data: + # pad length if it is not even + if len(seg.data) & 1: seg.data += '\xff' _parjtag.memwrite(seg.startaddress, seg.data) bytes += len(seg.data) if self.verbose: ------------------------------------------------------------------------------ Create and Deploy Rich Internet Apps outside the browser with Adobe(R)AIR(TM) software. With Adobe AIR, Ajax developers can use existing skills and code to build responsive, highly engaging applications that combine the power of local resources and data with the reach of the web. Download the Adobe AIR SDK and Ajax docs to start building applications today-http://p.sf.net/sfu/adobe-com