Go Down

Topic: Xcode and Arduino (Read 929 times) previous topic - next topic



I have a Mac and own a copy of Xcode.  I would like to create a Mac application that I cab use to wirelessly control my Arduino.  For example, when I click a button in the application on my Mac, the servo on the Arduino moves. Does anyone know what additional hardware I would need an how to program the software accordingly?  Thanks!




Does anyone know what additional hardware I would need

In addition to what? Clearly, you need a Mac and an Arduino, along with a USB cable to connect them, and a servo. Depending on the type of servo, and what it is doing, you may need an external power source for it.

how to program the software accordingly?

Open a serial port, and write to it.
The art of getting good answers lies in asking good questions.


You should start with just a USB cable.
Find which port did the Arduino connected to and write to it. If you look for POSIX serial port programming, you should find plenty of examples on how to do it. Once that is done, you can either put an XBee on the Arduino and on the USB port and use the same software, or if you want to go hi-tech, you can get a wi-fly for the Arduino, open a socket on your software and write to it.

Not so sure if there's an XCode equivalent to the serial port object in Visual Studio... don't think so at least. :(
This... is a hobby.

Go Up