Go Down

Topic: Mighty-1284p repo updated for IDE 1.6.x (Read 15824 times) previous topic - next topic

bperrybap

at first i just downloaded and unzipped files. when that didnt work i copied boards.txt from 1284 folder to the avr folder. at least the 1284 options showed up then but still that error. then as a last resort i put the original boards.txt back and added the 20mhz no-led entry to it. then got serious about editing and changing and of course things got worse. initially though no luck before any changes or editing.

i will delete all this and start over from scratch. as always your help and patience is appreciated.
What would you suggest to the instructions to make it clearer how to install the package?

john1993

almost impossible to improve upon the instructions in post #1, except of course it didnt work for me this time. im sure i did something silly.

anyway lets find out why it failed before i make any real suggestions. only improvement at this time is adding the name of the board so it is easier to find in the menu and maybe the baud naming thing you mentioned. But these are trivial cosmetic items not worth mentioning.

i started right at the beginning of arduino and things were not working too well which is understandable for anything new. around 0018-0023 everything was great. chances a sketch worked was almost certain and all this folder stuff was manageable. then things started downhill and issues with compatibility and file locations cropped up. it wouldnt be the first time in computers that "progress" and "improvements" caused downhill slide.

this is not just myself but observations from many other beginners. my only general comment would be to make things easier for noobs and simplify instead of complicate. ive had many general suggestions over the years here for things like clock, pin naming, baud, pc interface, loaders, etc but dont want to get too far off topic. mostly i just want to see where i went wrong with this particular install. i will wipe this pc and start from scratch. stay tuned.

john1993

so i reformatted the hd, reinstalled windows and followed instructions again. this time it worked. as confirmation the original crowded image was restored and the same procedure duplicated. this time it failed again. so something on the drive, maybe registry or other arduino droppings interfere.

anyway while things were working i tested a few benchmark programs. there is definite improvement since last time i played with arduino for this chip couple years back. thanks to all those who put effort into making it better. particularly the opti.

speaking of which it would be nice to get a lst file with comments so i can crunch it down and squeeze in some favorite enhancements.

pico

#33
Jun 19, 2015, 05:07 am Last Edit: Jun 19, 2015, 05:26 am by pico
so i reformatted the hd, reinstalled windows and followed instructions again. this time it worked. as confirmation the original crowded image was restored and the same procedure duplicated. this time it failed again. so something on the drive, maybe registry or other arduino droppings interfere.
When you mentioned that you first saw the boards.txt entries when you copied the file up one level from mighty-1284p/avr to mighty-1284p, that gave me pause.

It suggests that the IDE you are running is 1.0x rather than 1.6.x.

The Arduino IDE developers changed the position of the files starting with the 1.5.x IDEs.

IDEs 1.5.x and later (including 1.6.x) expects boards.txt to appear under mighty-1284p/avr, while IDEs 1.0.x and earlier expects to find them in mighty-1284p.

Are you installing the Windows IDE using the windows installer version, or the zip file install version? If the former, try installing with the zip file version instead -- much less chance of interference between new and previous installed versions of the IDE. In fact, pretty much the only way to do it if you want to run multiple installed versions of the IDE (which is often required for a variety of reasons.)
WiFi shields/Yun too expensive? Embeddedcoolness.com is now selling the RFXduino nRF24L01+ <-> TCP/IP Linux gateway: Simpler, more affordable, and even more powerful wireless Internet connectivity for *all* your Arduino projects! (nRF24L01+ shield and dev board kits available too.)

john1993

always zip file because i agree installers in general are evil. as mentioned i downloaded another copy of 1.6.4 and know exactly which version is being used because i always click on the exe flle. no task bar, desktop icons. or win start menu here. in the "crowded" partition i have every version of arduino from 0013 up and something there conflicts. maybe some rainy day i will take time to find exactly what.

for now if the need arises to use arduino with this chip i can always restore that virgin windows partition which works fine. atm the only reason to do that would be enhancing the bootloader and i wouldnt even start on that w/o a lst file.

pico

always zip file because i agree installers in general are evil. as mentioned i downloaded another copy of 1.6.4 and know exactly which version is being used because i always click on the exe flle. no task bar, desktop icons. or win start menu here. in the "crowded" partition i have every version of arduino from 0013 up and something there conflicts. maybe some rainy day i will take time to find exactly what.

for now if the need arises to use arduino with this chip i can always restore that virgin windows partition which works fine. atm the only reason to do that would be enhancing the bootloader and i wouldnt even start on that w/o a lst file.
Well, then it deepens the mystery because the zip file installs are supposed to be mostly limited to working within their own trees (but that's never been 100% true, and is even less so now with all the burgeoning BM stuff.)

BTW, the bootloaders all have .lst files -- I have uploaded a .lst file for the 20MHz optiboot bootloader for reference.
WiFi shields/Yun too expensive? Embeddedcoolness.com is now selling the RFXduino nRF24L01+ <-> TCP/IP Linux gateway: Simpler, more affordable, and even more powerful wireless Internet connectivity for *all* your Arduino projects! (nRF24L01+ shield and dev board kits available too.)

pico

#36
Jun 20, 2015, 05:43 am Last Edit: Jun 21, 2015, 04:26 am by pico
Thanks to Per (pert) for testing and confirming the operation of the new 20MHz optiboot bootloader!

Per also found and corrected a typo in the new 'sleeping beauty" entry in boards.txt.alt. Pull request has been merged, and v1.6.3 of repo updated.

If you want to manually correct the typo, rather than downloading again, just change

slwwpingbeauty.upload.maximum_data_size=16384  

to  

sleepingbeauty.upload.maximum_data_size=16384
WiFi shields/Yun too expensive? Embeddedcoolness.com is now selling the RFXduino nRF24L01+ <-> TCP/IP Linux gateway: Simpler, more affordable, and even more powerful wireless Internet connectivity for *all* your Arduino projects! (nRF24L01+ shield and dev board kits available too.)

john1993

it was a surprise to see the noled version so much bigger than the led one. not 2x but almost half again. so much for my theory that pretty flashing lights take up valuable memory space.

i must say the first post here is an example of how things should really be done. excellent attention to instructions and links, if only more developers followed suit. thanks for doing such a great job. maybe arduino is becoming a practical tool for me to use on one of my favorite avrs.

bperrybap

it was a surprise to see the noled version so much bigger than the led one. not 2x but almost half again. so much for my theory that pretty flashing lights take up valuable memory space.

Go look at the .lst file and you can see why.
The 20Mhz image has code that is not in the optiboot.c code that is in the tree.
The 20Mhz image is not only built with a different version of the optiboot code (which is not what is checked into this 1284 core tree) but appears to have been built with the BIGBOOT option which adds extra features like EEPROM support.
All the other images were built with an older version of optiboot.

While I think it is great to have a pre-built image with the newer optiboot code and with BIGBOOT support, I think it is bad to have this 20 Mhz image using code that came from some other place than what is checked into the tree.

In looking at the location in the image where the optiboot version is stored, it looks like the 20Mhz image was built with optiboot version 6.2 while all the other images were built with optiboot version 5.0

The optiboot.c image that is in the tree is version 4.5 so it appears that none of the pre-built images were built with the optiboot.c source code that is in the tree.

I think it is bad to ship pre-built bootloaders that were not built with the accompanying source code.

--- bill


john1993

i would have to agree that its better to have correct source with the binary. in my case the list file is the source so no biggy. since im trying to cram a lot of non-standard function into minimum boot block the smaller older images are more useful. it only took me a couple minutes to change baud in the old/small opti to 20mhz. im just glad to have some working m1284 code as a starting point. and very happy libraries are improved so more programs work compared to last time i tried.

pico

#40
Jun 22, 2015, 03:57 am Last Edit: Jun 22, 2015, 04:11 am by pico
i would have to agree that its better to have correct source with the binary. in my case the list file is the source so no biggy. since im trying to cram a lot of non-standard function into minimum boot block the smaller older images are more useful. it only took me a couple minutes to change baud in the old/small opti to 20mhz.
Yes, not ideal to supply source when it doesn't actually match the built object code in the repo. I'm thinking in this case it might be better just to remove the obsolete source files, since anyone who is really interested in building their own custom bootloader for the 1284p, like yourself, is going to be likely to have their own opinion about which version of optiboot they are going to use, etc., and will certainly be capable of the google search to find the latest version of optiboot, etc.

I'll leave the .lst files as they do match the .hex files, and are useful as a reference (or even source) for anyone interested in the bootloader details.

Otherwise, for most users, the existing bootloader files will continue to do the job, regardless of which version of the source code they were originally built from. If someone wants to do a house clean at some time to tidy things up, they are welcome to, but it's not a high priority as far as I'm concerned. It's a relatively quick job to rebuild and rename all the bootloaders, but more work to then go in and change the boards.tx(.alt), and then actually test everything thoroughly to make sure everything is actually still working. As Bill (bperrybap) discovered, just because you build a new bootloader doesn't necessarily mean it's going to work first time.

im just glad to have some working m1284 code as a starting point. and very happy libraries are improved so more programs work compared to last time i tried.
Yeah, thanks, and glad you are finding it useful. I think with the new boards.txt.alt it's getting pretty slick. I'm even  toying with the idea of making it the standard boards.txt. Thoughts?

I think the patched standard libs are pretty essential. I remember having to argue with some people about that (well, one person in particular, as I recall), and whether they actually should be included in the repo, but after a certain point I ended up just doing it instead of spending all the time arguing about whether it could or should be done. Much more time efficient in the end!  :)

WiFi shields/Yun too expensive? Embeddedcoolness.com is now selling the RFXduino nRF24L01+ <-> TCP/IP Linux gateway: Simpler, more affordable, and even more powerful wireless Internet connectivity for *all* your Arduino projects! (nRF24L01+ shield and dev board kits available too.)

Insiduous

I have just spent the week reading everything I could find about the 1284p, from MB's site thru the forums (as crosslinked), and I'm excited. Downloaded the zip for the current IDE and got it all installed in moments.

(I just wish I had a board to test with ;-)

Curious, however: it's been over a year down this road and there are still issues with the bootloader sources?? Why?

I've also noticed that the new IDE doesn't list the 1284[p] as a Boards-Manager Option. No one has looked into that process?

In any event, I really want to thank the lot of you for hammering it into shape and getting it over the 1.6.x

pico

#42
Jul 05, 2015, 07:54 am Last Edit: Jul 05, 2015, 08:07 am by pico
I have just spent the week reading everything I could find about the 1284p, from MB's site thru the forums (as crosslinked), and I'm excited. Downloaded the zip for the current IDE and got it all installed in moments.

(I just wish I had a board to test with ;-)
The boards.txt file lists some links to various board and kit offerings that match up with the variant files in the repo:

bobuino.name=Bobuino and Skinny Bob, 16MHz using Optiboot
# Bobuino: http://crossroadsfencing.com/BobuinoRev17/index.html
# Skinny Bob: http:embeddedcoolness.com/shop/rfx-1284p-devdep-board-w-prototyping-area-nrf24l01-headers-kit/

mighty_opt.name="maniacbug" Mighty 1284p 16MHz using Optiboot
# https://maniacbug.wordpress.com/2011/11/27/arduino-on-atmega1284p-4/

mightymini.name=Mighty Mini 1284p @ 16MHz, Optiboot @ 1Mbps
#http://github.com/JChristensen/mini1284

sleepingbeauty.name=Sleeping Beauty 16MHz using OptiBoot
# http://www.firebirduino.com/sleeping_beauty/

These range form fully assembles boards (Bobuino, Sleeping Beauty) to self-assembly kits (RFX "Skinny Bob", "Mighty mini" 1284p) to breadboard projects ("maniacbug" Mighty 1284p).

The skill level for the kits varies according to your soldering fu: The "Skinny Bob" kit uses all through-hole components, whereas the "Mighty mini" uses smt components.

And of course you can always design or breadboard your own board using any of the pin layouts, so there are a lot of options covered here.

Curious, however: it's been over a year down this road and there are still issues with the bootloader sources?? Why?
In practice, it's never been a big deal, actually. If you just want to burn an existing bootloader file, you don't need the source to do that. If you are an advanced user who wants to build their own bootloader for some reason, you are likely going to want to use the latest optiboot version anyway. Or you can even use a listing file for source, if you know how, as has been discussed in this thread.

I should probably just delete the out-of-date optiboot source in the repo, since apparently it doesn't even correspond to the built bootloaders anyway.

I've also noticed that the new IDE doesn't list the 1284[p] as a Boards-Manager Option. No one has looked into that process?
It's been looked at, and rejected, as it offers no significant upside for the user over the current installation process, but does have a few material downsides.

In any event, I really want to thank the lot of you for hammering it into shape and getting it over the 1.6.x
No probs -- glad you are getting some value from it.  :)
WiFi shields/Yun too expensive? Embeddedcoolness.com is now selling the RFXduino nRF24L01+ <-> TCP/IP Linux gateway: Simpler, more affordable, and even more powerful wireless Internet connectivity for *all* your Arduino projects! (nRF24L01+ shield and dev board kits available too.)

Insiduous

Yes. Bills come first, but reading all this - and then the install - was informative and painless. (contrast to trying to figure out how to download and plop/drop teensy 3.1 or the stm32 support: those simply fail).

(( and the support for the avr 8-bit devices is much, much more consolidated and complete ))

I can see developing on a 1284p to see where you are, and then compacting and trimming to fit a 328p, too: wonderful idea all by itself.

(I think I even have a low-profile ZIF that fits these dips.. I'll find out tomorrow ;-)

scargill

I am hoping someone can help here. I stumbled across this - I've just loaded up these files.... and everything compiles just fine.

I am hoping someone can help me. The code you see below lets you have 2 port bits on the 328 as 16 bit PWM - which is marvelous - and works - pins 9 and 10 - I'm hoping I can extend this to 4 pins on the 1284.

void setupPWM16() {
    DDRB |= _BV(PB1) | _BV(PB2);        /* set pins as outputs */
    TCCR1A = _BV(COM1A1) | _BV(COM1B1)  /* non-inverting PWM */
        | _BV(WGM11);                   /* mode 14: fast PWM, TOP=ICR1 */
    TCCR1B = _BV(WGM13) | _BV(WGM12)
        | _BV(CS10);                    /* no prescaling */
    ICR1 = 0xffff;                      /* TOP counter value */
}

/* 16-bit version of analogWrite(). Works only on pins 9 and 10. */
void analogWrite16(uint8_t pin, uint16_t val)
{
    switch (pin) {
        case  9: OCR1A = val; break;
        case 10: OCR1B = val; break;
    }
}

Clearly references to OCR1A and B can be added in as OCR3A and B but I'm not sure which 2 pins to add - and also the setup, I'm not at all clear what needs changing in a duplicate of that code - to set up TIMER3 and the relevant pins.

Any clever 1284 guys out there able to help?
Regards

Peter Scargill
http://tech.scargill.net

Go Up