Author Topic: embedXcode Xcode for Arduino, chipKIT and more...  (Read 21383 times)

0 Members and 1 Guest are viewing this topic.

rei_vilo

embedXcode Xcode for Arduino, chipKIT and more...
« on: February 27, 2012, 08:17:43 AM »
Develop your sketches for Wiring using Xcode!

 

Direct links:
Website: http://embedxcode.weebly.com
Download: http://embedxcode.weebly.com/download
User guide: http://embedxcode.weebly.com/tutorial

Enjoy :)



Hi!

Enjoy the versatility of Arduino and chipKIT board with the power of Xcode!

mpideXcode
Embedded Computing Project with MPIDE on Xcode 4.3
https://github.com/rei-vilo/mpideXcode

embedXcode
Embedded Computing Template on Xcode 4.3
https://github.com/rei-vilo/embedXcode

Both projects rely on modular makefiles and each Processing-based IDE has its own dedicated makefile. Adding support for Wiring requires only writing the corresponding makefile.

But I don't own a Wiring board, so I can't do the tests. Feel free to experiment!  :)
« Last Edit: October 06, 2013, 05:40:05 AM by rei_vilo »

barragan

Re: embedXcode Xcode for Arduino, chipKIT and more...
« Reply #1 on: February 27, 2012, 11:58:43 AM »
hi Great work, you can test the Wiring Framework with any board, Wiring, Arduino, Sparkfun or just bare atmel micro controllers, have you tried the software? could you download it and try it? you'll find Wiring can program any available board from the Tools->Board->(your brand) menu. It would be nice to have your support, please let me know if this helps.

rei_vilo

Re: embedXcode Xcode for Arduino, chipKIT and more...
« Reply #2 on: February 28, 2012, 05:17:48 PM »
Thanks for the accolade.

Everything is possible, but I should go deep into Wiring.app internal structure, reverse-engineer it in order to write the makefile.

How different is Wiring from other IDE like Arduino and chipKIT MPIDE?

barragan

Re: embedXcode Xcode for Arduino, chipKIT and more...
« Reply #3 on: February 29, 2012, 10:11:21 PM »
The IDE is not so different, it comes from processing, we implemented a few things that were adopted later by arduino, like the process bar, the information about the current selected board etc. Main difference you'll are in the variety of hardware supported, the schematics button for sketches that include an schematics, reference etc. Also in the preferences menu where you can set whether or not starting the serial monitor automatically, or play a sound after compiling, building without uploading etc. Let me know if you need to know something else, we are very excited about your support : )

rei_vilo

Re: embedXcode Xcode for Arduino, chipKIT and more...
« Reply #4 on: March 01, 2012, 12:32:33 PM »
The IDE is very close to Arduino IDE and chipKIT MPIDE except for its inner structure and its hierarchy of folders and sub-folders.

What's really disturbing me is the complexity of the sub-folders: libraries are disseminated in multiple locations based on the boards!

Here are some examples:

Core libraries
For Wiring IDE - Wiring S board
Code: [Select]
/Applications/Wiring.app/Contents/Resources/Java/cores/Common
/Applications/Wiring.app/Contents/Resources/Java/cores/AVR8Bit
/Applications/Wiring.app/Contents/Resources/Java/hardware/Wiring/WiringS
For Arduino IDE - Arduino UNO board:
Code: [Select]
/Applications/Arduino.app/Contents/Resources/Java/hardware/arduino/cores/arduino
For chipKIT MPIDE - Arduino UNO board:
Code: [Select]
/Applications/Mpide.app/Contents/Resources/Java/hardware/arduino/cores/arduino
For chipKIT MPIDE - chipKIT UNO32 board:
Code: [Select]
/Applications/Mpide.app/Contents/Resources/Java/hardware/pic32/cores/pic32
/Applications/Mpide.app/Contents/Resources/Java/hardware/pic32/variants/Uno32

Application libraries
For Wiring IDE:
Code: [Select]
/Applications/Wiring.app/Contents/Resources/Java/libraries
/Applications/Wiring.app/Contents/Resources/Java/cores/AVR8Bit/libraries
For Arduino IDE:
Code: [Select]
/Applications/Arduino.app/Contents/Resources/Java/libraries
For chipKIT MPIDE - Arduino:
Code: [Select]
/Applications/Mpide.app/Contents/Resources/Java/libraries
For chipKIT MPIDE - chipKIT:
Code: [Select]
/Applications/Mpide.app/Contents/Resources/Java/hardware/pic32/libraries
Miscellaneous
Wiring IDE uses boardInit() in main.cpp instead of init() for Arduino IDE and chipKIT MPIDE. I need to duplicate main.cpp in order to have code-sense.
Wiring IDE uses build.hardware instead of build.variant in boards.txt.

Are there other specificities? Best to know them before and save time reverse-engineering the Wiring IDE structure!

I can't test the upload because I don't have a Wiring S board.
« Last Edit: March 01, 2012, 01:32:59 PM by rei_vilo »

barragan

Re: embedXcode Xcode for Arduino, chipKIT and more...
« Reply #5 on: March 02, 2012, 11:23:07 PM »
I believe this is it,

/Applications/Wiring.app/Contents/Resources/Java/cores/Common (common to all possible hardware)
/Applications/Wiring.app/Contents/Resources/Java/cores/AVR8Bit (avr8bit core specific framework implementation)
/Applications/Wiring.app/Contents/Resources/Java/hardware/Wiring/WiringS (just definitions for the wiring S board)

/Applications/Wiring.app/Contents/Resources/Java/libraries (cross-platform libraries, no hardware dependency)
/Applications/Wiring.app/Contents/Resources/Java/cores/AVR8Bit/libraries (avr8bit specific libraries)

rei_vilo

Re: embedXcode Xcode for Arduino, chipKIT and more...
« Reply #6 on: March 04, 2012, 05:33:37 PM »
Why is there a full program in /Applications/Wiring.app/Contents/Resources/Java/cores/AVR8Bit/program.cpp for Wiring 1.0 (100)?

Code: [Select]
#include <Wiring.h>

float x = 0;
float y = 0;
char c = 'A';
int d;

void setup()
{
  pinMode(48, OUTPUT);
}

void loop()
{
  x = 20 * sin(0.2);   
  y = 20 * cos(0.1); 
  d = toLowerCase(c);
  digitalWrite(48, HIGH);
  delay(500);
  digitalWrite(48, LOW);
  delay(500);

}

This is really messy  :(

rei_vilo

Re: embedXcode Xcode for Arduino, chipKIT and more...
« Reply #7 on: March 05, 2012, 04:46:11 PM »
New releases add Arduino 1.0 support.

embedXcode Mar 06, 2012 release 4 - Arduino 1.0 support
mpideXcode Mar 06, 2012 release 7 - Arduino 1.0 support

Code is here and documentation there.

Next step is to add Wiring, if I find a Wiring S board to test the upload.

barragan

Re: embedXcode Xcode for Arduino, chipKIT and more...
« Reply #8 on: March 06, 2012, 09:48:23 AM »
hi, please remove that program.cpp and makefile, those are old testing pieces no longer used. I've accepted the defect on the issues.

rei_vilo

Re: embedXcode Xcode for Arduino, chipKIT and more...
« Reply #9 on: March 06, 2012, 10:06:47 AM »
Hi!

Thank for the answer. It confirms what I have already done. It's cleaner now and compilation works.

rei_vilo

Re: embedXcode Xcode for Arduino, chipKIT and more...
« Reply #10 on: April 14, 2012, 03:45:21 AM »
Critical Decision Ahead

Most of the open points on embedXcode are about Xcode, especially keywords on the template.

Despite numerous calls for help, they're still unresolved. The Xcode template remains undocumented and there's no sign of openness from Apple. Apple seems to restrict Xcode to OS X and iOS platforms only.

So I'm considering to change for another IDE, with NetBeans as most probable solution. It's open, and documentation is available.

What do you think?

barragan

Re: embedXcode Xcode for Arduino, chipKIT and more...
« Reply #11 on: April 14, 2012, 06:01:45 PM »
Definitely a nice thing to try, Netbeans will allow the Wiring Framework to work on all platforms : )

rei_vilo

« Last Edit: April 14, 2012, 06:21:21 PM by rei_vilo »

rei_vilo

Re: embedXcode Xcode for Arduino, chipKIT and more...
« Reply #13 on: April 21, 2012, 05:21:37 PM »
I tested the same makefiles with Xcode and NetBeans successfully.

I guess other standard IDEs may use them with no problem.

cver65

Re: embedXcode Xcode for Arduino, chipKIT and more...
« Reply #14 on: April 22, 2012, 08:42:34 AM »
The IDE is not so different, it comes from processing, we implemented a few things that were adopted later by arduino, like the process bar, the information about the current selected board etc. Main difference you'll are in the variety of hardware supported, the schematics button for sketches that include an schematics, reference etc. Also in the preferences menu where you can set whether or not starting the serial monitor automatically, or play a sound after compiling, building without uploading etc. Let me know if you need to know something else, we are very excited about your support : )

Could you document a bit the above please ? I'm interested in a serial monitor that starts automatically, doesn't generate 1000s of Java erors, etc.

About the variety of HW : there are a few people that made the effort to enhance/augment the Arduino IDE to support their board, including Teensyduino. Could you give us a few arguments why they should better do this with Wiring ?

Another example : LCD support : there are many alternatives, character or graphic, etc. the power / ease of use of Libraries could make the difference ! It's also a big opportunity to make use of the core/cross platform concept. I'm afraid a half-broken potentimeter HAL won't... I was in the process of getting some nice LCD library for ITDB24, but I burned my MEGA/LCD stack (mains on 3V3) ... :-(