boards.txt interdependent sub-menus

27 views
Skip to first unread message

William Westfield

unread,
May 28, 2015, 7:43:46 PM5/28/15
to Arduino Developers
I’ve been working on the “modern” boards.txt file for optiboot.
I’d like to have sub-menus for CPU and Clockrate. That works fine for setting “build.f_cpu" and “upload.speed”, but I need “bootloader.low_fuses” to be dependent on BOTH cpu and clock.

Is there a way to do this? Right now I set low_fuses in the clock menu, and am trying to override it in the mega8 CPU menu (where it needs to be different), but it needs different values for 8MHz and 16MHz.

Thanks
Bill W

boards-1.6.txt

Rob Tillaart

unread,
May 29, 2015, 2:17:19 PM5/29/15
to Arduino Developers
quick thought:
this is typically solved with XML and/or JSON of files. A txt file is mainly a sequential list, with XML/JSON you can code hierarchies without duplicates. 
And yes that means a more complex parser to read the data. 

In a txt file I guess duplication is the only straightforward option, but that tend to become large.

In the end you want some sort of 2D array with f_cpu  and  upload.speed on the axes

Rob





--
You received this message because you are subscribed to the Google Groups "Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to developers+...@arduino.cc.



--
You received this message because you are subscribed to the Google Groups "Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to developers+...@arduino.cc.


Charles Porth

unread,
Jun 9, 2015, 1:35:16 PM6/9/15
to devel...@arduino.cc

You would be over clocking Will, unless I am mistake for the max clockspeed, what your practly doing is trying to patch a kernel, my guess is its a Linux one because I've seen this in my android phone and on Ubuntu, if you haven't patched a kernel I would look it up on Google there are several different ways, it differs from OS to OS, BUT BEFORE you do an thing on the, text doc I would recommend if you have an old PC put Ubuntu on to it and do it from there first or if you have an android phone, root it and download two things kernel patch(er) and file expert

Net-Tech, the tech you need

Reply all
Reply to author
Forward
0 new messages