Permalink
Browse files

Update SConstruct

correction in path of avrdude
  • Loading branch information...
b4zz4 committed Apr 12, 2013
1 parent ca36aee commit bb206967f9f0abf65b83716f2206153dc33b7437
Showing with 8 additions and 2 deletions.
  1. +8 −2 SConstruct
View
@@ -89,6 +89,7 @@ def getUsbTty(rx):
AVR_BIN_PREFIX = None
AVRDUDE_CONF = None
+AVR_HOME_DUDE = None
if platform == 'darwin':
# For MacOS X, pick up the AVR tools from within Arduino.app
@@ -112,8 +113,10 @@ else:
ARDUINO_PORT = resolve_var('ARDUINO_PORT', getUsbTty('/dev/ttyUSB*'))
SKETCHBOOK_HOME = resolve_var('SKETCHBOOK_HOME',
path.expanduser('~/share/arduino/sketchbook/'))
- AVR_HOME = resolve_var('AVR_HOME', '')
@xenris

xenris Jun 5, 2014

This worked originally. The changes cause "build\core.a: No such file or directory". Why was it changed? avr-gcc, avrdude, etc, are located in /usr/bin/, not in the arduino directories.

-
+ AVR_HOME = resolve_var('AVR_HOME',
+ path.join(ARDUINO_HOME, 'hardware/tools/avr/bin'))
+ AVR_HOME_DUDE = resolve_var('AVR_HOME',
+ path.join(ARDUINO_HOME, 'hardware/tools/'))
ARDUINO_BOARD = resolve_var('ARDUINO_BOARD', 'atmega328')
ARDUINO_VER = resolve_var('ARDUINO_VER', 0) # Default to 0 if nothing is specified
@@ -431,6 +434,9 @@ avrdudeOpts = ['-V', '-F', '-c %s' % UPLOAD_PROTOCOL, '-b %s' % UPLOAD_SPEED,
if AVRDUDE_CONF:
avrdudeOpts.append('-C %s' % AVRDUDE_CONF)
+if AVR_HOME_DUDE:
+ AVR_BIN_PREFIX=AVR_HOME_DUDE
+
fuse_cmd = '%s %s' % (path.join(path.dirname(AVR_BIN_PREFIX), 'avrdude'),
' '.join(avrdudeOpts))

0 comments on commit bb20696

Please sign in to comment.