[python-win32] Using the COM interface of Infinion Memtool

Markus Hubig mhubig at imko.de
Wed Apr 21 16:10:38 CEST 2010


Hi Greg,

thank You for your help, now I just got my basic flashing script up and
running, ... mostly ;-)

01 import memtool
02 mt = memtool.SMTMemtool()
03 mt.Init("C:\\Program Files\\Memtool\\Targets\\genXC164CM_8F.dat")
04 mt.ConnectTarget()
05 fm = mtool.GetFlashModByIndex(1)
06 sectors = fm.NumOfSectors
07 for i in range(1,sectors):
08     fm.EraseSector(i)
07 mt.OpenFile("C:\\trime-ibt\\Hexfiles\\file.hex")
08 mt.SelectAllSections()
09 mt.AddSelectedSections()
10 fm.ProgramSections()
11 fm.VerifySections()
12 mt.Cleanup()
13 del(mt)

The Problem I have now is when I run the mt.Init() method in line 3, I get a
window where I have to select a COM-Port and the COM-Port speed and press
OK. This is not acceptable for me, because I wanna serialize the flashing
process
for a lot of modules.

Can you/anyone guess from my early-binding-file (
http://gist.github.com/361226) if
there is a way to suppress the display of the COM-Port window and pass the
COM-Port
and Speed Parameter within my script?

- Markus
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-win32/attachments/20100421/a50cff90/attachment.html>


More information about the python-win32 mailing list