chipKIT® Development Platform

Inspired by Arduino™

ChipKit Max32 - open source toolchain, compiling, debugging

Created Sat, 22 Sep 2012 12:24:14 +0000 by strim


strim

Sat, 22 Sep 2012 12:24:14 +0000

Hi, this is my first post on this forum. I'm a complete noob in the world of microcontrollers. I've recently acquired ChipKit Max32 board and ChipKit Network Shield. I did my homework by reading what's available on the ChipKit wiki. I have a few questions related to toolchain.

I've played a bit with MPIDE and MPLAB X, however these tools are hiding a lot of complexity from programmer. Since I don't know much about PIC32 or microcontrollers in general, I'd like to understand what's going on. And these tools might be great for rapid development, but they don't actually help with understanding how things work.

I'd like to be able to compile, debug and upload code to ChipKit board using just command line tools. As far as I see, ChipKit compiler is distributed with both MPIDE and as a separate download. Are these equal in functionality?

Could someone upload an example of application created with just command line tools? I'd really appreciate a tutorial that shows how to compile a minimal application (for example that sends something over serial line) without MPIDE or MPLAB X.

As I understand compiled program should be uploaded using avrdude. Can I use ICSP instead to do that? I assume that I'll lose bootloader if I do it, but is this supposed to "just" work? Would my program need additional initialization code in this case?

Is it possible to debug code compiled with open source toolchain using PICKit 2 (which I own too) ? For example with ejtag-proxy? Would it work with STK500v2 bootloader? Or only with code loaded directly over ICSP?

Thanks in advance.


Jacob Christ

Thu, 27 Sep 2012 20:35:07 +0000

From the wiki:

http://chipkit.org/wiki/index.php?title=Alternative_(to_MPIDE)_Build_Tools

Also, it is possible to debug, but I've never personally done it so I couldn't tell you how. Others that lurk here have and maybe willing to jump in.

Jacob


strim

Thu, 27 Sep 2012 20:45:01 +0000

From the wiki: http://chipkit.org/wiki/index.php?title=Alternative_(to_MPIDE)_Build_Tools Also, it is possible to debug, but I've never personally done it so I couldn't tell you how. Others that lurk here have and maybe willing to jump in. Jacob

Thanks for your answer, I've seen this article but it still does use Arduino libraries. I was thinking about pure-C example. In fact, I've just created such example myself and uploaded it to github. It still can be improved...

I also had some success with debugging through ejtag-proxy and plain gdb compiled with MIPS support. I want to document that in the wiki, but I'm still waiting for an account.


cobbj

Fri, 28 Sep 2012 00:40:38 +0000

Wiki account created - you'll get a random password at the email you signed up for this forum with, username is the same. Let me know by PM of you have any issues.


strim

Fri, 28 Sep 2012 09:37:41 +0000

I've added a new article to the wiki.


Jacob Christ

Fri, 28 Sep 2012 13:12:38 +0000

Very cool! Thanks for adding this.

Jacob