MWorks blog
Mac OSX, iOS & Android Development
Mac OSX, iOS & Android Development
Apr 8th
Both JellyfiSSH and JellyVNC will be getting an update this month (April 2012) to include menulets allowing for a quick “click->launch” of a bookmark. Combined with the previous versions ability to save passwords – sysadmin bliss!
These menulets are dynamically created during the life of the app using [NSStatusBar systemStatusBar]
Look out for these updates soon…
Feb 13th
Another year, another JellyfiSSH update. Version 5.2 has been submitted to the Mac AppStore, so barring any objections from Apple, it should be out in the next week or so. We have looked at all the feedback and concentrated on the top 3 requests being:
We also took the time to update the encodings and add in Cyrillic encodings and fixed a few small bugs.
JellyfiSSH was first launched in February 2002 – so this makes it 10 years of JellyfiSSH in the world!
Dec 17th
Most people are familiar with Godwin’s Law. ( http://en.wikipedia.org/wiki/Godwin’s_law ) Basically:
“As an online discussion grows longer, the probability of a comparison involving Nazis or Hitler approaches.”
Having been involved in a number of discussions lately I have noticed that a new law has emerged….
it is mrad’s law…it states:
“As an online discussion grows longer, the probability of being attacked with ‘fanboy’ increases dramatically.”
This is seen as the trump card in any discussion. You hold off until the right moment and then attack with the “you are just a fanboy” strike. There is little defense against the “fanboy” attack. Once labelled, you have very little chance of being taken seriously in that discussion again.
The attacks can be thinly veiled as “ifanboy” “androne” “winboy”.
Nov 12th
Since the release of the iPhone 4S into New Zealand, there have been a number of people lining up the Telecom and Vodafone plan pricing to make their choice. 200 minutes here, 1GB of data there, they have more texts, they have more data – it goes on and on!
But, this approach is flawed.
A mobile provider can only deliver your minutes, texts and data if they actually have signal in the places you most move in. I personally signed up to Vodafone a few years back on a 24 month contract only to find that my house is smack bang in the middle of a huge black spot. (Those in Milford/Takapuna will know what I mean)
So, my advice would be to first take advantage of the pre-pay sim cards from each provider, load them into your phone and see who gives you the best signal and best quality voice delivery. Check texts get through and generally see if you get good service. Do this at home and work and the few other places you might go (like, maybe Woodhill mountain bike park for example)
Once you have a winner (or both) – check the data speed. This can be done on Android and iPhone by downloading Speedtest.net from the AppStore or Market. It is free. Do these speed tests where you go – don’t rely on anyone elses supposed screenshots or attempts at youtube video promotions. They are simply not relevant to you.
By this time you will have a clearly better provider than the other. Now you can look at plans!
Telecom iPhone Plans and Vodafone iPhone Plans
NOTE: If your friends and family are on iOS5 devices, texts are free via iMessage. Very cool.
This may seem like a lot of work – and it might be, but don’t let me hear you complain that you don’t get good signal at home/work if you don’t follow this advice!
As most of you know, I lean towards Telecom XT for my own use due to the fact that data is really fast, signal is consistent and strong, I don’t get the “darth vader” sounding phone calls and then call drops like I used to on Vodafone. When I asked Vodafone for help they sent an engineer who said “tough” and then got a sales call a few months later trying to sell me their broadband and a ~$499 GSM signal booster. Bad experience guys. But, that’s just me.
My sister has a company maintaining forestry roads in the far north and she gets 5 bars of Vodafone and 1 bar on XT – so its best to try it out before you commit to 24 months of potential frustration!
Oct 3rd
We are on the verge of releasing an update to JellyfiSSH which brings through the top requested features and some fixes. On the list for 5.1 are:
So while the first two are pretty easy to understand, the legacy .term file thing isn’t. So, up until the Terminal.app in Leopard, Apple have been using .term files to store and export Terminal Settings. These have been relatively simple for us to support. Since Leopard however, they moved to .terminal settings files and started to only allow certain feature access from the .terminal settings file format – so we couldn’t give you some of the newer settings. For us to support .terminal settings files and give you access to the newer (and future) Terminal settings, we can’t get access to the Transparency or Background image settings – hence the new preference. If you want settings like emulation declaration – you have to turn off legacy .term files (and you lose Transparency and Background Images)
Now, the iTerm2 support is starting off with Width, Height, Auto-login and Tab support – we will add more as we discover more in future JellyfiSSH releases. This should get you started!
Look out for JellyfiSSH 5.1 very soon!
Aug 21st
Mark Andreessen wrote an article about how software is changing the planet. It is a great piece. A lot of people worldwide are sitting nodding knowingly – agreeing with Mark’s words. There are others who disagree. Such is the fabric which makes up the world.
For me, Mark is right on the money. I’m not sure about his timeframes, but what he describes is already well under way. When you put together this writing with the notions discussed by Kevin Slavin in his TED talk – you begin to form a picture that includes more software than you care to see.
The move by HP to basically ditch all of its hardware business and focus more on the software side has a lot not going for it – but there are some hints in their writings which give you a sense that software is the future – even seen by the big hardware companies like HP. On their purchase of Autonomy:
“After closing the transaction with Autonomy, HP plans to reinvent how unstructured and structured data is processed, analyzed, optimized, automated and protected.”
HP have a huge salary bill to pay every week and they are dropping one element which fuels the fire – hardware. HP are heading for the enterprise is a big way and are leading the charge with enterprise software, not hardware.
A lot of people I know work “in” software development coming up with ideas, writing code and generally doing very well from it – but I think more time spent working “on” the software business in terms of where software can take industries – or even create new industries will fuel the next generation of wealth creation.
[5 billion smartdevice owners in the next 10 years has to spark something - and I don't mean just another app...]
Think.
Aug 6th
Thinking about the demands from the business community for faster internet into NZ to keep us in the global marketplace, I wondered why we are spending so much money on getting the new fast broadband into all homes. It is important for us to have access in our houses to this new technology – but in my mind we should get this high speed data into our data centers and businesses first – then roll out the fast home broadband once this has been well and truly established.
Why? Well, whenever I speak with someone from Europe or Asia and discuss what they do with their mega fast broadband at home – the answer is watching media, buying stuff or getting updates for the iPhone or PC. It is never anything which is going to revolutionize the economy.
Businesses and the new economy of [something new] needs this mega fast broadband now! They need their servers to be on world class connections and be able to deliver the experience to the world market. Home users in NZ ultimately need fast broadband to buy stuff from the world market – but I don’t think it needs to be at the expense of providing our innovators a platform in NZ that they can launch from.
Food for thought.
May 14th
First, a bit of background. I’m a bit of a geek, I love command lines, if it has a CPU – I’m interested. I use Mac, Windows, Linux, Android, iOS … They are all fun!
I have written Mac OS X applications since its release (JellyfiSSH 1.0 was released on Mac OS X 10.1) and have written a number of iOS applications for myself and a few other companies. One of the larger iOS project owners requested that it be ported to Android – so we did. I thought I would put down a few notes on Android because you have all the twitter “experts” rambling on about how Android is fragmented and has multiple screen sizes and on and on – but the reality is – it’s actually not that hard. I now laugh out loud when I see those “twexperts” go on about Android – it is VERY clear they haven’t even opened the SDK.
I’ll probably break this up into this 101 intro to get people started, and then a more advanced blog post later on. This isn’t a tutorial or a how to guide – just a few comments to break down the barriers.
Get Started
First things first – install Eclipse and the SDKs. Follow the instructions here. Once you have Eclipse and the SDK installed, go to the Android SDK and AVD Manager under the WIndow menu and look at Available Packages. I installed all Android SDKs back to 2.0. Forget 1.x – support from 2.1 onward and you’ll cover the majority and you avoid the fragmentation issues completely.
While you are in the SDK and AVD Manager – go ahead and make yourself a nice little virtual machine to test code on. Use a screen of 480×800 should be a good all rounder.
Follow the instructions here on making your first hello world application and run it on the emulator. Yes, the emulator is really, really, really, really slow (it’s OK once it has booted). If you can fork out for a $299 Samsung 550 or even better – a Nexus. The Nexus is supplied by Google and is a plain vanilla install of Android which is the best way to develop. (and you get updates directly from Google rather than your carrier)
Projects
The project bar on the left (after making Hello World) has a few folders and files in it.
The src directory contains all the source code. The language is Java. I ported Objective C virtually line for line into Java. Some things in Java are not as nice as Objective C – some things are better. An example would be joining strings together.
Objective C: myString = [myString stringByAppendingString:@" hello kitty"];
Java: myString = myString + “hello kitty”;
The gen directory is where all the object files live. Not too interesting.
The Android 2.1-update1 directory has all the includes/libs for that SDK. Good to browse through as a beginner.
Assets is where you can put items such as images, sounds, SQL databases – anything which you want to call on to use. They have a file system path which means they can be referenced that way.
Res is like the Resources directory in XCode. It contains all sorts of things including layouts (covered later), high/medium/low res graphics directories and a values directory for storing strings and translations etc.
AndroidManifest.xml is a very important file – similar to info.plist in your XCode project
I didn’t really get into proguard – but it scrambles your byte code from what I could see in your final compile.
Res directory
Here is where a lot of the action takes place. (Well, except for the code – but I expect you can figure that out) Firstly, the directories for the various resolution images are optional to use. If you load up your graphics into drawable-hpdi (hi resolution) and don’t put graphics into mdpi or ldpi – it will still work. The results are just better if you put the graphics in. You also put your icon.png into here too and put in a reference to it in your manifest file (it will be there by default):
<application android:icon=”@drawable/icon” android:label=”@string/app_name”>
Next, layouts.
Lots of non-existent issues here. If you look into a layout directory, you will see something like this:
The XML files you see here are like XIB (NIB for old schoolers) files – but for each screen. If you double click on one of these, you will get a GUI editor and a raw XML editor. You can drag in objects and then right-click on them to set attributes and properties. Easy.
And you can even choose different device screensizes and orientations to see how it will behave. Not too dramatic.
You set a unique ID for each of the elements and then you can use the Android resource manager to get/set data and/or behaviors. I read a couple of tutorials and looked at some sample code – and it was done.
For example, when the application starts up, I wanted to show the splash screen. So, in the OnCreate() for the main thread, I added:
setContentView(R.layout.splash);
which uses the Resource manager (R) and looks into the layout directory and displays a layout called splash. (splash.xml)
The code for layouts themselves is just XML and if you have had experience with html, it isn’t too much harder than using tables and CSS etc. By using nested tables and layouts, you can get them to dynamically scale to any screen size. The very basic layout you see above scales down to 2.7inch screens right up to 10.1″ tablets. It actually works VERY well.
(TIP: NEVER specify px (pixels) in your layouts, use dp instead. It auto remaps the numbers for you. Example, if you want a button to be 38pixels high, use 38dp and Android will remap that to the various resolutions and sizes for you. It works.)
I think I’ll leave it there for now. I guess I wanted to illustrate that while different – they are similar and you shouldn’t think that it is a nightmare to develop for. If I believed the “twitterexperts” out there – I wouldn’t have started this project. Now it is finished – it wasn’t that hard! This project looks easy, but it does have an onboard SQLite database, macro conversion and display with images in the search results etc.
I might go and port this to Windows Phone 7 – just to see how that works…
May 5th
The AppleTV is brilliant. TV On Demand is (mostly) brilliant. But you can’t have both together….
But you can!
Follow these steps and your AppleTV will give you TV On Demand. These instructions are for NZ TV On Demand. (TVNZ, TV3 and others…)
To look through the onDemand content, go to Video->Video AddOns->NZ onDemand.
You will figure out the rest from there….
Apr 14th
We love mobile devices. So when Windows Phone 7 sprung onto the scene – we had to have a look! So, we went out and bought a HTC HD7 16GB and built up a nice fresh Windows 7 PC with the Windows Phone 7 SDK installed. Ready. Set…….Go!
But, before any development starts – lets see how it runs as a day-to-day phone. You know, calling, email, Twitter, Facebook, txts, maps….etc. So, we took Marcus’s iPhones and Androids off him and sent him on his way. 2 week later? What did he think?
“I like it. Its fast, everything works. No copy/paste is a bit painful – but that is supposed to be coming soon [edit: it's here now].”
So, if you ask Marcus of all his phones (he has 5) – what is the pecking order – he thinks:
1. iPhone 4 – The kingpin of smartphones.
2. HTC HD7 – Nice hardware, good OS.
3. iPhone 3GS – Still a great phone. Love the form factor. Fast. Reliable.
4. Nexus One – A good Android phone. The OS just doesn’t have the polish.
5. HTC Hero – The first Android phone we bought. Good phone – bit slow now.
All in all Windows Phone 7 is a HUGE leap ahead of the terrible Windows Mobiles before – but it still has a LONG way to go before people look at it seriously again. As soon as you mention “Windows Phone” – people think “Windows Mobile” and say “yuck – I’m all over my iPhone or Android already! Have you seen THIS app?”
Could be a long ride Microsoft….maybe the Nokia deal will boost numbers?