From 3d2c307c56c82cb16c79cbf7ff2be59d612be25d Mon Sep 17 00:00:00 2001 From: Markus Hitter Date: Thu, 14 May 2015 11:53:23 +0200 Subject: [PATCH] Configtool: use absolute path for .hex file when uploading. There were cases where the working directory got lost and teacup.hex weren't found. This should be the last bit to solve issue #132. --- configtool/build.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/configtool/build.py b/configtool/build.py index abe8c3a..d14d990 100644 --- a/configtool/build.py +++ b/configtool/build.py @@ -349,8 +349,11 @@ class Upload(wx.Dialog): else: cmdpath = "avrdude" - cmd = cmdpath + " -c %s -b %s -p %s -P %s -U flash:w:teacup.hex" % \ - (self.settings.programmer, self.baud, self.cpu, self.settings.port) + hexpath = "\"" + join(self.root, "teacup.hex") + "\"" + + cmd = cmdpath + " -c %s -b %s -p %s -P %s -U flash:w:%s:i" % \ + (self.settings.programmer, self.baud, self.cpu, self.settings.port, + hexpath) self.script.append(cmd) def uploadUpdate(self, evt):