zwabbit

Using an updated Arduino IDE

Recommended Posts

Hey Jack, I was wondering if using an updated arduino IDE is as straightforward as copying the butterfly_platform folder into the hardware/tools folder of a newer IDE, or did you need to do modifications to the source code?

Share this post


Link to post
Share on other sites

Hey zwabbit,

It required some modifications to the Arduino source code. I have a plan to hopefully make it as easy as copying some folders into the newest version of the Arduino IDE. But I can't start working on that until the RetroCade is delivered later this month.

Jack.

Share this post


Link to post
Share on other sites

zwabbit,

Actually it looks close just because I only forked the Arduino repository in anticipation of trying to upgrade to the latest version. So what you see in github is just a straight fork with no modifications. The actual Papuino IDE source code is located on an old svn server here.

I spent a couple hours trying to do an update and created a new branch on github, called papuino, that I think has most of the changes needed. It compiles with Ant but there is a problem with getting the papilio core to copy into the temp directory. Things have changed quite a bit since 0018 and I'm not sure how things work now... The other issue is that I copied the papilio core that is based on the 0018 hardware core base, we will want to go through all the c code there and update that as well. Unless we can get a new soft processor based on the atmega128 up and running, then there should be no need.

Anyway, the next step is to figure out how to get the papilio tools directory and papilio core directory to copy into the temp directory.

Jack.

Share this post


Link to post
Share on other sites

Well, I was searching around for info on how to copy the papilio tools and core directories and I came across this:

http://arduino.cc/blog/2012/10/22/arduino-1-5-support-for-the-due-and-other-processors-easier-library-installation-simplified-board-menu-etc/

Looks like Arduino 1.5 is designed to do what we do with the Papilio without having to modify the base source code. So I think the best course of action here is to drop the effort to get 1.02 working and go straight to 1.5...

Jack.

Share this post


Link to post
Share on other sites

Excellent ! I second the request from zwabbit : an updated version of the arduino IDE for papilio would be very welcome !

I just had the need yesterday, to test the excellent Mozzi sound synthesis package :

http://sensorium.github.com/Mozzi/

Alas, the sketch only builds with arduino IDE >= 1.0... :-(

It would rock to play some Mozzi sounds right on the papilio (I have a Papilio One 500k in my case)

Share this post


Link to post
Share on other sites

Going to the 1.5 and implementing toolchains that can be added without fiddling with the ide source would be nice.

BUT.. What exactly does the new IDE give us that we already don't have?

Share this post


Link to post
Share on other sites

Updated libraries for use with various shields, which would be very nice from my perspective if I can get the voltage shield board put together for use with arduino shields (work in progress right now).

Share this post


Link to post
Share on other sites

Well, at least for the Mozzi library I mentioned about, the ide 1.0 or later is needed to build it

I tried compiling mozzi lib with arduino 0018, and the build fails with errors..

Share this post


Link to post
Share on other sites

Ok, I put a little time into this and managed to get everything setup as a zip file that you can just unzip into the Arduino 1.5 directory. It will create a new papilio core and everything seems to work. I haven't done a lot of testing but attached is the result.

Keep in mind this is using the core arduino files from 0018 modified to work with the atmega103. There hasn't been time to go through the 1.5 files and update for the atmega103. I came across this website and I like their approach to adding support for more AVR chips. I think we should adopt their strategy, heck we might be able to just use their files without modification, but even then the files are from 0020 which is a little behind, unless the core files have not changed since 0020?

Jack.

papilio-arduino1.5.zip

Share this post


Link to post
Share on other sites

:D :D :D

It works for the very simple LED blinking test I just did. (Our 500K's came in). That's enough to start demo'ing to my prof. Thanks Jack! Now back to fixing up the voltage shield, and the possibility that I may need to rewire a few things.

Edit:

Though, a thought, this worked when I forgot to copy over the custom.bit and custom_bd.mm files from the AVR8 software built using the Xilinx webpack. What are the vanilla custom* files in the zip you posted? Cause when I was testing out the papilio using the customized Arduino 018 with the custom* files I synthesized, the build process in the arduino ide failed.

Share this post


Link to post
Share on other sites

I too was able to succesfully test the blink sketch

Thanks jack !

However i didnt test building my own custom as zwabbit, nor

Could i build and test mozzi

I will be busy these days as i wait for my second baby born

So maybe someone can beat me to it

Thanks again jack

Share this post


Link to post
Share on other sites

Though, a thought, this worked when I forgot to copy over the custom.bit and custom_bd.mm files from the AVR8 software built using the Xilinx webpack. What are the vanilla custom* files in the zip you posted? Cause when I was testing out the papilio using the customized Arduino 018 with the custom* files I synthesized, the build process in the arduino ide failed.

It looks like I did not include the custom board type in the boards.txt file add the following entry to get custom boards:


##############################################################
papilio_Custom.name=Gadget Factory Papilio Custom Board
papilio_Custom.upload.tool=papilio
papilio_Custom.upload.protocol=sam-ba
papilio_Custom.upload.use_1200bps_touch=true
papilio_Custom.upload.wait_for_upload_port=false
papilio_Custom.upload.native_usb=false
papilio_Custom.upload.using=papilio_custom
papilio_Custom.upload.maximum_size=16384
papilio_Custom.build.mcu=atmega103
papilio_Custom.build.f_cpu=16000000L
papilio_Custom.build.core=arduino
##############################################################

The bit file that is included with the default board types is the "Shifty" variant instead of the "Vanilla" variant. Look at this page to learn more about the differences.

Jack.

Share this post


Link to post
Share on other sites

Hey Jack, the problem I mentioned with the custom cores is still around and I thought I should provide some more detail. I synthesized the AVR softcore version 1.6 linked here: https://github.com/GadgetFactory/Arduino-Soft-Core/zipball/v1.6 using Xilinx Webpack 14.2. I should note that I did not turn anything off, I left the core in its default state, since this was a first pass attempt to make sure the basic process worked. I then took the custom.bit and custom_bd.bmm files and dropped them into the bitstream folder in the arduino ide folder in the appropriate place, but when I attempt to upload my test program (the blink example) to the papilio, I get the following error:

ERROR:Data2MEM:6 - Illegal token 'RAMB16', 'opening range bracket '['' expected.

Line #23, File "bitstreams\custom_bd.bmm".

PM_Inst/RAM_Word0 RAMB16 [15:0] [0:1023] PLACED = X0Y4;

Any idea what could be causing that?

As an aside, using the "custom" files included by default worked insomuch as the IDE claimed to have written them to the board, but the blink example did not itself work.

Share this post


Link to post
Share on other sites

Zwabbit,

Ahh, yes, this is a known problem. The version of data2mem that is included with the core files is old. It doesn't understand the bmm file format that is created by newer versions of webpack. There is a discussion about it here. All that is needed is to update data2mem to a newer version. I should have done that when I put the core package together for Arduino 1.5 but I was more focused on seeing if it could work.

Jack

Share this post


Link to post
Share on other sites

I should technically just need to copy the data2mem.exe file from whichever version of WebPack I have for a short term solution I presume? And whatever modifications to the makefile that might crop up.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now