Created Tue, 28 Jan 2014 05:55:01 +0000 by fatboyatdesk
Tue, 28 Jan 2014 05:55:01 +0000
Thought I would share a bit of good news on something I have been working on.
I took the source for Chipkit Arduino and ported to XC32++ (really more of got it to build). Ran the thing not expecting too much to work. A few things didn't. Mostly a few compiler inline assembly pieces around the 32bit timer. Long and short of it is I seem to have the ability to run on a ChipKit UNO using MPLABX running Arduino compatible libraries. The delay stuff was the biggest issue (there also seems to be an off by one count in there if I recall for millis). Serial works which was what I was really not expecting. Digital pin stuff also seems to be working and I have an 1602 LCD working with the example Hello World.
But best of all.... I can now debug line by line.
I will now start playing with the peripherals such as i2c, interrupts, PWM, DAC, FM Transceivers, etc.
This will make Pic32 projects so much more productive!
Debugger plus community libraries for Arduino, I am in hog heaven.
Now this was really quite easy, what I don't understand why nobody else has done it before? The project does look very C++ but it still simply calls out to setup() and loop().
Regards Allan in Vancouver
Wed, 29 Jan 2014 14:24:41 +0000
Now this was really quite easy, what I don't understand why nobody else has done it before?
Many open source projects do not like the restrictive Microchip XC32 license policy..
Thu, 30 Jan 2014 05:39:19 +0000
There was really not much difference in the code if I recall. So definitely it could be #ifdef'd easily. atoi I recall was one as that is not standard and I simple implemented with sprintf if I recall.
But the debugger is soooo nice,complete with line by line stepping and breakpoints. And no bootloader overhead:-)
Allan in Vancouver
Sun, 02 Feb 2014 01:14:50 +0000
Probably more people would be doing this if they found this post:
http://chipkit.net/forum/viewtopic.php?f=19&t=473
Jacob