Pololu Robotics & Electronics
My account Comments or questions? About Pololu Contact Ordering information Distributors

Xcode - how to "Run" "Build"


For weeks googling and searching can not get Xcode (Apple iMac) any meaningful information or guidance. Xcode configured, checked for AVR (Orangutan) as per tutorials.
The icons Run, Build are not highlighted - clicking on them does nothing.
Can compile from terminal ( i.e. command line ), can create assembler code so can inspect how the program is executed.
Are there any Amtel chips simulators running on iMac (osx 10.5 - iMac reach “use by date” time).
Help please…Kris


Hello, Kris.

I found an excellent article that helped me set up my mac for AVR development (assoc.tumblr.com/post/4641357963 … ng-on-os-x).

Instead of using Xcode, I just use emacs to edit my C files and run make in that project directory to generate a .hex file. I can then open that .hex file in MacSim.

Xcode changes all the time and I think it is not the best editor for writing and running C Code. When Xcode refers to ‘running’ or ‘building’ it is usually within the context of an .xcodeproj, which in your case would probably be a new ‘Command Line’ Project. If not, how are you opening the file in Xcode?

For what it’s worth there could be an issue with your AVR environment. I use homebrew and used this formula github.com/larsimmisch/homebrew-avr. Homebrew is my favorite package manager for installing command-line tools.

I typed the following into the command line:

sudo brew update sudo brew tap larsimmisch/avr sudo brew install avr-libc (this may take a while) sudo brew untap larsimmisch/avr