Which route to reliable midi sequencing in Audiokit 4.9.3? - swift

Looking to sequence with Audiokit 4.9.3 in Swift and ultimately would like to implement Ableton Link so I came across this post:
AKSequencer with Ableton Link
When I look at the linked example in that answer I don't see the use of AKTimeline, the example seems to rely on AVAudioTime. AKTimelineTap sounds very interesting but hasn't made the docs yet. Additionally AKSequencer has been replaced since that question was answered.
So...
What is the currently recommended accurate sequencing solution and is there an example for getting it running?
Thanks for any input and thanks too for AudioKit, it's got my app spitting out great melodies in just a couple of days.
Update: I've got AKSequencer up and running nicely for my purposes so far. No attempt yet to use Link. It seems at least as good as an old test I did with old AKSequencer (now AKAppleSequencer). When I get to Link I'll explore the other options further and hopefully uncover some more AKTimeline and AKTimelineTap discoveries...

Related

ASIHTTPRequest vs AFNetworking framework

I am about to develop an application for iPad and it has enormous amount of background thread network calls.
I would like to know which one will be better? ASIHTTPRequest still works but not maintained. However few sources says AFNetworking framework creates lots of complications.
Update (September 2013)
It's been nearly two years since I originally wrote this answer, and quite a lot has changed. AFNetworking is about to go into version 2.0 and has a thriving developer community, whereas ASIHTTPRequest is pretty much dead. Additionally, AFNetworking has dozens of great helper libraries and classes available for handling things like OAuth, Amazon S3, and the like. It's so popular that there's several books available on it.
Given this, there's no reason at all to keep using ASIHTTPRequest. My original answer is below, so if you're still interested do read on - just bear in mind I would now recommend without a doubt not using ASIHTTPRequest and going with something more modern (namely, AFNetworking, but other options are available).
Original Answer (December 2011)
How much time have you got? Here's my thoughts, although as a subjective question I don't think there's a right or wrong answer.
I lead a development team that works on commercial apps for sizeable clients, and some of my colleagues are always on the look-out for new libraries that can make things easier. Currently I guess the vast majority of our networking uses ASIHTTP. We took a look at AFNetworking about six months ago, and decided at the time we'd stick with what we know. ASI has been around for a while, and there is far more documentation and helpful advice available online for it. It is a solid codebase, and been around long enough to have gained a lot of traction and respect.
That said (and hopefully people who disagree with everything I've said above will read on!), I think if you're starting afresh now is the time to move on to something else. Even the developer of ASI thinks so. Given all of the changes that have come with iOS 5, I think a modern actively maintained framework like AFNetworking (and there are other options, like RestKit) is a good choice.
Now, you're right to say some people have trouble using AFNetworking in their application. But equally, a quick google reveals many people who had problems with ASI (valid or not)! I think whatever framework you go with, someone somewhere will have had trouble with it, either through something genuine wrong with the framework or their own limitations.
So with all this in mind I think I'd dive in to AFNetworking, and see how you get on! One of my new year resolutions will be to migrate over to a new networking library, and I think it will probably be AFNetworking.
From Author's Comment:
A little update: I've actually really enjoyed using AFNetworking, and in many ways it's considerably better (probably not the right word: 'refined', maybe) than ASI. That said, you shouldn't go into it expecting a 'like for like' replacement, and there are certain things you may want to consider other options for (Amazon S3, which ASI supported out of the box for example). But I'm generally really pleased, and find it a clear, well documented library. So if you're looking to move from ASI to something else, you really can't go wrong with AFNetworking...
https://github.com/BoydYang/BYRequest
BYRequest based on MKNetowrkKit, but it works like ASIHttpRequest, so you can easily migrate your project from ASIHttpRequest to BYRequest and also enjoy ARC.

HTML5 video call, possible?

I am just curious the question above. I try to google it but most of the tutorial appear with video support related topic. So i guess stackoverflow could possible ans my curiosity.
:)
Been looking around for this a little myself, and it seems to be an interesting but still up-and-coming topic around the web.
The most concrete example I found was here where they talk of a HTML5 Video Call experiment via WebKit-GTK.
Looking into it a bit further, the actual experiment details with some coding info can be found on Ericsson Labs page here. Maybe that'll give you something to go on.
There's also talk of HTML5 video calling coming to Facebook and all, though those are just rumors. To answer your question, if these few examples are solid, I guess that Video Calling on HTML5 seems possible, though in its very early stages perhaps.

Has anyone had much success recently using the Cappuccino Framework?

I'm just creating my first project in Cappuccino without a lot of success. Looking for examples and documentation, there isn't a lot out there...
The differences from real Objective-C and the lack of libraries mean you cannot easily convert code directly from say a OS X desktop app. to Cappuccino.
As an experienced PHP, and RoR developer (besides the Java, VB, VC.....) I can't quite see the logic of abstracting/wrapping JavaScript in another language.
Any comments or suggestions for a more efficient framework?
If you have specific questions that can't be answered in the IRC channel (it just depends who's in there) you should post the question to the mailing list and someone will help you.
As for why you would want objective-j I'll point you to this blog post which contains several reasons why objj exists. http://cappuccino.org/discuss/2008/12/08/on-leaky-abstractions-and-objective-j/
I have converted several Objective-C classes nearly line for line into Cappuccino. Mostly it's a matter of changing NS to CP and changing pointers to non-pointers. What differences between Objective-C are you thinking about?
Indeed you could even take your existing XIB files from your Cocoa desktop app and convert them to Cappuccino using nib2cib. Here's how to work with Interface Builder using XCode 4: http://groups.google.com/group/objectivej/browse_thread/thread/786331dbcbc9c7b1.
I also recently started a project in Cappuccino and what I could say is: definitely it worth it. I'm used with javascript as well as (but less) cocoa (which helps). In short, the javascript is very fine, probably one of my favorite language because of it's flexibility. But it does lack of structure. For example there is no class in javascript and you have to trick with object inheritances, prototyping and so on. By using the Cappuccino framework at first you have all those very convenient facilities but also you do not reinvent the wheel each time. This is cross browser standardized so that you only have to focus on your code and not on the IE whims. As it is based on cocoa, cappuccino also comes with the MCV scheme in mind which again let you structure your project in an efficient way.
Ok you probably already know all this. What I could tell now about the learning curve is that I had to find the right tools to really get in. i.e.Installing cappuccino (sudo Starter/bootstrap.sh), creating a simple nib application (capp gen -t NibApplication YourApplication) then using xcodecapp-cocoa to listen, convert and open the project into Xcode what probably the hardest part of this learning curve to me…
Now if you are still not satisfied with cappuccino, I can only suggest to look at another framework like http://javascriptmvc.com/ , www.grooveshark.com used it to do their amazing webapp-site but I personally would never go back to html for building a web application. (conversely I would not use cappuccino for a webpage neither, "The cobbler should stick to his last")
I began writing cappuccino a couple of months ago and had a lot of difficulty when it came to setting up the proper development environment. I also had numerous problems writing working client server code that worked well.
I eventually broke through and started doing better with Cappuccino and then I found these video tutorials that would have helped so much earlier on. They did cost me $30 but I really wished I had watched these at the start because they help you get set up properly as a developer and get you started on the right learning curve.
I actually discovered these videos when using Cappuccinos IRC which has helped me a couple of times when I couldn't find an answer.
Info on the videos here: http://cappuccino.org/discuss/2011/10/19/cappuccino-training-course-ideveloper-tv/

How to write a code-generator/compiler

I would like to know how you would generate some kind of bytecode from an abstract syntax tree.
I've searched the internet but I cannot find anything helpful.
I've seen some mention of using templates but cannot find someone that actually explains what it is, how it works or how to implement it.
Just one thing though, I don't have any real programming experience and I'm completely self-taught so I'm not looking for an 800 page book on the theory of writing a compiler, I'm looking for something a little more practical, some kind of tutorial working through an actual example.
I learned a lot by following Let's Build a Compiler, by Jack Crenshaw many moons ago. It uses Turbo Pascal for implementation and generates 68000 assembler, so there is some steps to get it running on a modern host but it works through a lot of steps that is still valid.
Take a look at Kaleidoscope tutorial in LLVM: http://llvm.org/docs/tutorial/
and for a somewhat different perspective, http://community.schemewiki.org/?90min-scheme2c

understanding an API

I know that there are many API's like json,Facebook,twitter etc for developing related applications on iphone....but how to understand an API?This might be scilly question but I want to know how? what would you suggest for for a beginner?
You should find relevant documentation and read through some code examples utilizing the API.
If you are looking for information about the iphone, as the tag suggests, then read through the information here. There is an entire section dedicated to sample code. If you really can't understand how to make something work after some effort and some googling, then you can always ask on StackOverflow.
When ever I came through adding new API in my project I usually scan though documentation to find relevant topic to my project then after looking at the some sample code I usually start experimenting with the code to get the desired results and thats it because API is for short term use, you should not waste your precious time on just one API. So steps are, 1) find the relevant topic then 2) read sample code and 3) write your own code to get the desired results. 4) through away that API.
Cheers
Ayaz Alavi
If it's open source, read the code from beginning to end. Or to see why things were designed in a certain way, maybe try reimplementing parts of the API.