amperka / ino

Command line toolkit for working with Arduino hardware

Home Page:http://inotool.org

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Unable to build for Mega 2560 with boards.txt from 1.6.0 IDE

jgarbers opened this issue · comments

Running ino 0.3.7 after installing the Arduino IDE 1.6, I'm able to build and install for my Uno board. But when I want to use my Mega 2560 board using

uno build -m mega

I get this error:

  File "/Library/Python/2.7/site-packages/ino-0.3.7-py2.7.egg/ino/commands/build.py", line 151, in setup_flags
    mcu = '-mmcu=' + board['build']['mcu']

This appears to be due to some difference in the structure of the 1.6 boards.txt file, which has separate sections with keys like mega.menu.cpu.atmega2560 and mega.menu.cpu.atmega1280. A comment in the file says

# default board may be overridden by the cpu menu

On a wild guess, I added the line

mega.build.mcu = atmega2560

to *boards.txt", and after an ino clean the build seems to have succeeded. Similarly, to get ino upload to work, I added

mega.upload.protocol=wiring
mega.upload.speed=115200
mega.upload.maximum_size=253952

It appears that to get ino compatible with this new boards.txt, there'll need to be some additional logic for picking up the right configuration keys.

Up this, it solved my problem on Fedora23. I had to something similar for the nano board.

Also the upload don't seem to be working