Objective C for Max 5

POSTED BY niklas on Apr 26 under Music/Technology, Technology

I bought my upgrade of Max 5 yesterday, and I’m of course eagerly waiting for my license code. :-) Trying to put Objective-C and Cocoa into all that I do, I found Rémy Muller’s blogpost about writing Objective-C externals for Max. Also, Electrotap has posted ObjectiveMax on Google Code. It’s dual-licensed GPL/Commercial which of course make BSD licensed code and closed-source-but-free a non-option. I’ll probably try out both and port much of my Java stuff over to have it working at greater speed and tested with Max 5

On the same page, Rémy writes about Bonjour for Max/MSP, and with my iPhone development efforts such as Lighting Matrix I’m planning on implementing a Bonjour interface as an option to UDP. (I’d also like to try out bluetooth just like the Wii interface aka.wiiremote, but that’s not a near-future plan as I’m not sure it’s supported through the official SDK yet)

Lighting Matrix for Max

POSTED BY niklas on Apr 25 under General

I’m still a Max/MSP junkie (Max 5 was released today!!) and so I’m happy to present my new interface for Max: LightingMatrix

As you can see, LightingMatrix is a matrix of black buttons that light up when you press them and then fade down. When I get my certificate and get to put it on the iTunes App Store, you’ll see that you can use multiple fingers. The values are sent via UDP to Max where you can use it just like any other control. I look forward to seeing what splendid software-synth, lighting, moving robot or other fun stuff you’re going to be making with this. The power of tapping with many fingers is available, now also for Max/MSP (and Jitter) :-)

“Unknown architecture” with iPhone development

POSTED BY niklas on Apr 25 under General

Every now and again I get “Unknown architecture” when trying to compile. I found this post that has the solution in the bottom:

From the “Project” menu, choose Edit Active Target “ “. Select the “Build” tab. In the search box, look for FRAMEWORK_SEARCH_PATH. Highlight the row with a search path in it. Press to completely wipe out the path.

I don’t know quite why there sometimes are more paths there that I don’t want, but it helps anyways.

DashBoard

POSTED BY niklas on Apr 25 under Technology, Work

It’s been a while since I wrote about what I’m doing, but nothing much has changed: I’m working with the iPhone SDK making different applications. Today I’d like to demo the application that made me start working with the iPhone: DashBoard. I first got interested with dashboards when I tried to make something userfriendly with Performance Point and found IMA’s dashboard. Now I’ve created a simple, easily customizable dashboard for the iPhone. Because of Apple’s NDA I cannot release it, but I believe I can show it to you, running on the simulator:

In this video you see a logo on top and nine KPI buttons below. Each KPI button has a logo, a number, a unit, a last-updated date and a colour to indicate if it’s as it should be, falling below target or significantly below target (in other words, if there is a problem), using green, yellow and red. When you tap a KPI button, the report is displayed. The report is just a webpage, so I’ve linked up a webpage for every KPI button showing just a normal webpage, but more interestingly I think: PDF reports. As you can see, it works beautiful with 154 page reports, even though I guess for actually using this, you’d use a page or three with lots of graphs. :-)

PS, yes, my conservatory exam preparations are going well ;-)

Debugging Cocoa

POSTED BY niklas on Apr 3 under Technology

Debugging Autorelease is a great wiki entry at CocoaDev. EXC_BAD_ACCESS, meaning accessing an object you’ve already released (most likely) or have not yet instantiated (it happens) isn’t that fun to debug. Luckily, the NSZombie environment variable works when developing for iPhone as well, and I could find the error that had cost me most of my day. Yay! :-) Other good resources for debugging are Debugging Techniques and Mac OS X Debugging Magic

The iPhone shortage

POSTED BY niklas on Apr 2 under Technology

The mac world is high on expectations because of what is apparently a shortage of iPhones. New version coming up soon? Yes, probably. People hope for a 3G version. I hope for one too. I expect it to be announced in June and available end August. People think of a 32gb version. Sounds logical. But didn’t people notice Intel’s announcement of their Atom processor? Here’s ZDNet’s take on it. I would expect this to mean that an iPhone based on this architecture would be launched, perhaps silently even. Just a bit more horse power, very fitting for iPhone OS 2.0. Perhaps with a 32gb option. But still EDGE, no 3G. Then a 32gb version with 3G could be announced in June and become widely available in august.

NASA cuts Spirit

POSTED BY niklas on Mar 25 under Technology

It’s all over the news: due to budget problems, NASA puts Spirit into hibernation and cuts back on the activity for Opportunity. Where do I sign the protest list?!

No atos(1) in the iPhone dev kit?

POSTED BY niklas on Mar 24 under Technology

One thing I love about Java development is the ease of finding bugs through stack traces. Unfortunately, it doesn’t seem that Cocoa likes being so verbose about it, it prefers just giving memory addresses to the function. CocoaDev has a nice article about how to add this that’s based on Apple’s documentation, but it requires /usr/bin/atos that I cannot find in the iPhone SDK. That doesn’t mean it’s not installed, but at this time I have no way of knowing that it is. I have no idea how I should let people beta-test my products and sending automatically back intelligent bug reports without this tool. Ok, I have no idea on how Apple plans to allow for betatesting applications if the AppStore is the only application distribution method, and I have no idea how people do this otherwise as atos(1) isn’t included with the default OS X system either. ;-) But I would really, really like to include stack traces with bugreports from beta testers.

Exception handling in Cocoa

POSTED BY niklas on Mar 24 under Technology

Being fairly new to Cocoa I enjoyed reading O’Reilly’s MacDevCenter’s article on exception handling with Cocoa.

Getting info on private Cocoa frameworks

POSTED BY niklas on Mar 23 under Technology

class-dump is a great tool for getting information about how private frameworks work that you may want to use. For example, iPhotoAccess.framework gave among other classes the following:

@interface Base64 : NSObject
{
}

+ (id)stringForBase64:(id)fp8;
+ (id)base64ForString:(id)fp8;

@end

iPhone dev continues

POSTED BY niklas on Mar 23 under Technology, Work

My work with the iPhone SDK continues, working on three clients to our backend services at the moment. I’m very much looking forward to blogging about this as it’s cleared at work. But as you probably have noticed from my posts, working locally and synchronizing with the back-end is what I believe most iPhone applications are about. Do quick and stuff you need to remember on the iPhone, work out the details from your computer, keep everything in sync. That’s why I’m excited about Google’s data integration. That’s why I’m excited about integrating SQLite. That’s why I spend a lot of time working with SOAP integration. And of course, it’s all good fun. I’m tempted to say that working with a back-end is a lot easier than doing everything local. At least the satisfaction of seeing the work you do on the little screen influencing the real world is a lot better than it just influencing that screen. :-)

One thing I’m miffed about, though, is the NDA. They’ve got a 100,000 downloads, and if 1/20t of this is developers, then that’s still 5,000 developers. Where are they all? I can’t find much going on on discussion boards, forums, mailing-lists or whatever. And Apple is only slowly letting them in to their community. I hope they’ll let us in soon, I want to discuss problems I’m having without having people with briefcases coming after me, I want to know what other people are working on, I want the development to be more social. Right now, it’s mostly a one-man game, and that’ll get old very soon

Google Data for Cocoa/iPhone

POSTED BY niklas on Mar 23 under Technology

According to iPhone Atlas, Google has pushed out a new release of its GData Objective-C Client Library that can be used with the iPhone SDK. Yay for Google! :-) Check it out! For my last job I used Google Spreadsheets and Google Documents quite a bit, and it’s great being able to integrate it. Making a little word processor with synchronization to GDocs should be fairly trivial now. :-)

SQLite for iPhone SDK

POSTED BY niklas on Mar 14 under Technology

After asking on the MacRumors forums I was pointed back to FMDB that I had looked at a couple of days ago. FMDB is a Cocoa wrapper for SQLite3. I had a look at it, and after my initial difficulties, I found that I was trying a way to complicated way to use it for my iPhone applications. To add FMDB, simply do the following:

Mono on iPhone

POSTED BY niklas on Mar 11 under Technology

Way cool, a composer/musician/LDAP-developer has made Mono run on iPhone. Jailbreaked, by the look of it, looking forward to seeing it compile with the official iPhone SDK as well and a Mono Touch library. :-)

iPhone SDK questions and comments

POSTED BY niklas on Mar 9 under Technology

So, two days of implementing ideas, trying stuff out, reading discussions, documentation and watching videos have passed since the iPhone SDK was launched. My dayjob has become developing for the platform, which is great. It’s a fun platform to work with and developing for it is quick. I’m really looking forward to Apple delivering those certificates soon so I can try it out on the iPod Touch (no iPhone in Denmark yet).

So that was rant number one, certificates. Why-oh-why do I need them when I do software development? I would also very much like to be able to share my apps with friends, perhaps even beam them wirelessly over to them. And I should be able to do this with a self-signed certificate like with SSL. Self-signed for development, signed by an authority for production, that’s a good scheme.

What’s up with Bluetooth? Has anyone been able to access it through the SDK yet?

I write applications that want to synchronize with a repository of files on the computer. How can I arrange such a synchronization without making a web service that the user first can synchronize with his computer and then with his ipod/iphone?

Multitasking. Sure, I can save and restore my application for most things. But if I have to download the files I need from the network, the user is going to switch applications. (I’m still looking forward to see how I best should work with webservices) Good thing that
ramond has gotten background-running apps to work, but this will break with Apple’s license, so no idea if this would kill the product on the iTunes App store. We’ll have to wait and see for that

.

The videos refer to the XCode and Cocoa-dev mailinglists on lists.apple.com, but the moderator on the Cocoa-dev list has made it clear that iPhone development related discussions are not welcome

Funny little thing is the metronome app, clearly made by someone who does not play music. The last beat in the group is the accented one in this app. ;-) But it was a nice illustration as some of the first things I want to make are a metronome and a tuner. The tuner is going to be tricky with the floating point instruction set being reduced in the 16-bit Touch set, might have to recompile as ARM. I’m looking forward to seeing it outside the simulator (and finding out if the iPod touch has a microphone ;-) )

How do you unit test these apps? :-)

The apps are sandboxed, so no ssh into the phone without a jailbreak I guess. But ssh clients should be trivial now

So, I’m excited about this and working with it. I’m really looking forward to integrating it with our products at work, and I’m looking forward to writing music apps on my spare time (which is going to be limited until my exam June 9th is over). I guess all of these things will be answered shortly after my exam is done. :-)

iPod Touch development

POSTED BY niklas on Mar 7 under Technology

After yesterdays iPhone SDK release, my boss agreed that we should spend some time making a client for our apps with it and got me an iPod touch to work with. Good stuff. :-) The SDK and tutorials seem very good. Strange thing that many of the samples don’t run in the Aspen Simulator. Especially since I need a certificate to be able to deploy them on the iPod, and that certificate is right now not available outside the US. I didn’t expect to need a certificate to develop, I thought that was just for publishing on iTunes. So not being able to deploy those samples on a device and not being able to run them on the simluator, I’m stuck with guessing. I hope that is soon resolved as developing for it is good fun. :-)

Webkit and Webkit/Safari on Windows

POSTED BY niklas on Feb 28 under Technology

I have been using Webkit nightly for the past few weeks. I was not planning on using it much, just trying it out, but it’s so fast that without really intending to, I’ve stopped using Firefox. I never used Safari much because I like Firefox both speed- and feature-wise, but now I’m probably Webkit only. Until something better comes along, of course. Naturally, I’ve been wanting to use it at work, on the Windows Server 2003 R2 servers that I’m developing on. To start of with something safe, I tried out Safari while installing a Sharepoint server. It crashed when only it and the OS was installed. Jikes. On close inspection, Safari only claims to be XP and Vista compatible, but installed without a problem on WS2003R2. Replacing it with webkit was no hit either, both crashed when entering wikipedia.org in the address bar. Having fully installed the server, none of them run without crashing. So I guess it really is XP or Vista only on the Windows platform.

Setup visual studio for sharepoint development

POSTED BY niklas on Feb 27 under Work

A food obsessed IT developer writes about setting up visual studio to develop for sharepoint without having sharepoint installed on the development computer. Nice instructions and saved me quite a bit of time. :-)

PSF -> JPG converting

POSTED BY niklas on Feb 15 under Technology

FixPicture is a nice little site that helped me with converting a PSF file (ArcSoft PhotoStudio format) to JPG. I had received this file as an attachment by a user who couldn’t know this was a nonstandard format, and since I didn’t have any software that could read it (as far as I know), this site was very useful. :-)

Airtunes is back

POSTED BY niklas on Feb 13 under Technology

Macrumors reports that AppleTV Take Two includes airtunes support! Yay! Finally some light in this dark tunnel. And here I was thinking that Apple had abandoned the technology after leaving it out of new Airports. I’m looking forward to hearing just what it will do. :-) Stream? Play back? Both ways? Bridge?

Copyright Niklas Saers, 2000-2008