On the Preparation front
Nothing really - I'm ready for action:
Apple developer tick
Mac present tick
xCode and iPhone SDK loaded tick
On the objective C front
Finished reading Kochan. It was a well structured and written book and I think I'm ready to get on do the iPhones example - my task today. It took about a week - so for your hardcore VB programmers out there, if that's all it needs to atleast get started, then it's not too bad. Of course we've done nothing on data handling, COM or anything really other than the underlying programming language. Still, it's the basis of it all.
In summary, Objective C (and C for that matter) is pretty tedious with loads of ways of going wrong with pointers, arrays etc. It seems very inconsistent compared to VB. But we'll see how it performs with the iphone programming.
C u with my first iphone program....on the simulator to begin with as I don't have my own phone activated yet.
Friday, April 30, 2010
Wednesday, April 28, 2010
Week 2: which version of leopard
I should have read the readme file!
Preparation front: The software
At the apple site (https://developer.apple.com/iphone/index.action) after establishing a new developer ID (I now have 191 logins to remember) I tried to download the SDK, all 2.3GB of it.
I failed twice (maxing out my download allowance of 2.3GB). So I called my local apple shop and asked them to help - as you can imagine, I wasn't the first customer on their list so I was left having to email them my request and hope they would download it for me for a small fee.
I dumped this idea and upgraded my broadband plan to 20GB and then promptly downloaded the lot on my sparking new MacBook. I pressed the install button and ....
bingo - I didn't have the right version of Operating System. I should have read the read-me file!!!
Of course I needed 10.6.2 or later of the so-called MAC OS Snow leopard. Of course my Mac doesn't tell me if it's snow leopard or not, it just says 10.6.1. Can you believe it - it's brand new and I'm already running old software. The lady at the shop told me it is leopard, so atleast that's one thing.
Thank god I took the big broadband upgrade as I had to search the web for updates from my Mac and then another 900MB later I have the latest install. I am yet to run this and then run the SDK. May god be with me.
Objective C front:
I have now read most of the Objective C book. The book is very good - well done Steve. the language....still a little unimpressed.
The C language has complex elements, such as pointers, structs the whole array thing, but then Objective C is meant to make it a bit easier. I really get the feeling that they are trying to make it more like VB, but VB is for babies, yet why not use && or AND and || for OR, it makes so much more sense....and so much more readable.
For all it's purported Object Oriented-ness, you can pretty much do anything you like to bypass the lot and in the most complex ways, for example all sorts of different kinds of global variables. Nasty operators such as # which bypasses the whole compilation routines and then of course the pointers themselves where & and * can mean a whole host of things, depending on where you put them.
int *intptr is an integer pointer
int p
intptr = &p (why not - knowing the address is really helpful?)
p = *intptr (i.e. p gets the variable stored at the location intptr is pointing to)
don't even get me started with ->
What's the problem with simple dot operators and declaring arguments as either by reference or by value - it works. Should we really understand or even need to think about what is stored at what computer address? Of course not - it's a complete waste of good brain time.
But if I want to program the iphone, i have to know it - so onward ho.
I'm starting the foundation framework in the next day or so - is that cocoa? I will find out soon.....
I better go check to see if my updated operating systems has downloaded
ps: kids found the photobox program on the apple - it was a hit. Don't get me wrong, there is some really fun stuff on apples.
Preparation front: The software
At the apple site (https://developer.apple.com/iphone/index.action) after establishing a new developer ID (I now have 191 logins to remember) I tried to download the SDK, all 2.3GB of it.
I failed twice (maxing out my download allowance of 2.3GB). So I called my local apple shop and asked them to help - as you can imagine, I wasn't the first customer on their list so I was left having to email them my request and hope they would download it for me for a small fee.
I dumped this idea and upgraded my broadband plan to 20GB and then promptly downloaded the lot on my sparking new MacBook. I pressed the install button and ....
bingo - I didn't have the right version of Operating System. I should have read the read-me file!!!
Of course I needed 10.6.2 or later of the so-called MAC OS Snow leopard. Of course my Mac doesn't tell me if it's snow leopard or not, it just says 10.6.1. Can you believe it - it's brand new and I'm already running old software. The lady at the shop told me it is leopard, so atleast that's one thing.
Thank god I took the big broadband upgrade as I had to search the web for updates from my Mac and then another 900MB later I have the latest install. I am yet to run this and then run the SDK. May god be with me.
Objective C front:
I have now read most of the Objective C book. The book is very good - well done Steve. the language....still a little unimpressed.
The C language has complex elements, such as pointers, structs the whole array thing, but then Objective C is meant to make it a bit easier. I really get the feeling that they are trying to make it more like VB, but VB is for babies, yet why not use && or AND and || for OR, it makes so much more sense....and so much more readable.
For all it's purported Object Oriented-ness, you can pretty much do anything you like to bypass the lot and in the most complex ways, for example all sorts of different kinds of global variables. Nasty operators such as # which bypasses the whole compilation routines and then of course the pointers themselves where & and * can mean a whole host of things, depending on where you put them.
int *intptr is an integer pointer
int p
intptr = &p (why not - knowing the address is really helpful?)
p = *intptr (i.e. p gets the variable stored at the location intptr is pointing to)
don't even get me started with ->
What's the problem with simple dot operators and declaring arguments as either by reference or by value - it works. Should we really understand or even need to think about what is stored at what computer address? Of course not - it's a complete waste of good brain time.
But if I want to program the iphone, i have to know it - so onward ho.
I'm starting the foundation framework in the next day or so - is that cocoa? I will find out soon.....
I better go check to see if my updated operating systems has downloaded
ps: kids found the photobox program on the apple - it was a hit. Don't get me wrong, there is some really fun stuff on apples.
Tuesday, April 27, 2010
Week 2: Getting up and running
I now have a Macbook - purchase price AUD$1099.
Plan for this week
1. Get xCode up and running
2. Get through most of Objective C
On the getting xCode up and running front
Item 1 sounds easy - i already have a love hate relationship with Macs. Love the look of it - but it seems to be built in such an idiot proof fashion, that all the good stuff that i want to see is simply hidden.
xCode cannot be found anywhere on my system so I think, ok, i'll download it. I found it for 2.3gb (did someone say bloatware?) on the apple developer site, together with the iPhone SDK. I tried downloading it at 2 sites and hit my download limit at both places (which i now know is 2GB and then my pipes slow down to narrowband - it could take all night at that rate. There has to be a better way.
dropped into my local mac shop who told me it would be on the cd that came with the laptop. It was - i loaded it and am now ready to go.
On the learning Objective C front
I'm reading the book: 'Programming in Objective-C 2.0', 2nd edition by Stephen G. Kochan.
So far, so good. I picked this one because its focus is objective c without all the other who-har of iphone/cocoa etc. It assumes no knowledge of any language. I've read about a third of it (yes the easy bits) and so far i'm less than impressed with objective c. To me it was designed by someone who wanted to make programming complicated, when there was no need to. Ii'm sure it's powerful, but let's face it, if you can write a line of code like this -(int) set: (int) n: (int) d; then something is wrong. That's a setter method declaration
I can hear myself each day say - oh VB is so much easier to do exactly the same thing - but I will try to hold off and reserve my judgement because I'm sure there are better and easier ways of doing everything as I learn more about the language.
One last needle though. Class member declarations...what for? I really don't see the purpose of this separation at all - for big or small programs/classes etc. In my view it only leads to update mistakes between the definition and the declaration and additional coding....but that's C for you.
It's interesting to note that the additions that Objective C has introduced into the C language seem to make it more like VB, for example the dot operator when using instance member variables....but i still haven't worked out how to make them read only...stay tuned.
Plan for this week
1. Get xCode up and running
2. Get through most of Objective C
On the getting xCode up and running front
Item 1 sounds easy - i already have a love hate relationship with Macs. Love the look of it - but it seems to be built in such an idiot proof fashion, that all the good stuff that i want to see is simply hidden.
xCode cannot be found anywhere on my system so I think, ok, i'll download it. I found it for 2.3gb (did someone say bloatware?) on the apple developer site, together with the iPhone SDK. I tried downloading it at 2 sites and hit my download limit at both places (which i now know is 2GB and then my pipes slow down to narrowband - it could take all night at that rate. There has to be a better way.
dropped into my local mac shop who told me it would be on the cd that came with the laptop. It was - i loaded it and am now ready to go.
On the learning Objective C front
I'm reading the book: 'Programming in Objective-C 2.0', 2nd edition by Stephen G. Kochan.
So far, so good. I picked this one because its focus is objective c without all the other who-har of iphone/cocoa etc. It assumes no knowledge of any language. I've read about a third of it (yes the easy bits) and so far i'm less than impressed with objective c. To me it was designed by someone who wanted to make programming complicated, when there was no need to. Ii'm sure it's powerful, but let's face it, if you can write a line of code like this -(int) set: (int) n: (int) d; then something is wrong. That's a setter method declaration
I can hear myself each day say - oh VB is so much easier to do exactly the same thing - but I will try to hold off and reserve my judgement because I'm sure there are better and easier ways of doing everything as I learn more about the language.
One last needle though. Class member declarations...what for? I really don't see the purpose of this separation at all - for big or small programs/classes etc. In my view it only leads to update mistakes between the definition and the declaration and additional coding....but that's C for you.
It's interesting to note that the additions that Objective C has introduced into the C language seem to make it more like VB, for example the dot operator when using instance member variables....but i still haven't worked out how to make them read only...stay tuned.
Friday, April 23, 2010
Day 1 - I purchased the Apple Mac
If you are like me (sorry for you), you have been working in the land of Microsoft since MS DOS was born. But today I had to buy an apple Mac. It arrived in a box and, i have to say, it looks good from the outside, rather than my Dell i'm using now.
why?
well I'm a hardened VB programmer who wants to develop programs on the iPhone. I've developed on Windows mobile, but it just doesn't cut the mustard - nobody wants to buy an old samsung and get it programmed for business. Everyone wants to buy an iPhone.
So here I am - faced with a new life decision at 40. I must convert my 20 years of experience in programming in Microsoft, visual studio, VB programming language to: Apple, Objective C, Cocoa iPhone development.
I think lots of programmers want to do this - so I think that if i'm going to learn to do it, I may as well help others do the same, so I'll assemble an e-book at the end for other people to use. For VB programmers who are changing their stripes.
Today is day 1: Tasks
* I've bought three books to help me get going - one on Objective C, one on Cocoa and one on iPhone programming - i'll spell them out shortly
* Get internet happening on apple laptop then i'm ready to download the apple IDE xCode and the iPhone SDK.
why?
well I'm a hardened VB programmer who wants to develop programs on the iPhone. I've developed on Windows mobile, but it just doesn't cut the mustard - nobody wants to buy an old samsung and get it programmed for business. Everyone wants to buy an iPhone.
So here I am - faced with a new life decision at 40. I must convert my 20 years of experience in programming in Microsoft, visual studio, VB programming language to: Apple, Objective C, Cocoa iPhone development.
I think lots of programmers want to do this - so I think that if i'm going to learn to do it, I may as well help others do the same, so I'll assemble an e-book at the end for other people to use. For VB programmers who are changing their stripes.
Today is day 1: Tasks
* I've bought three books to help me get going - one on Objective C, one on Cocoa and one on iPhone programming - i'll spell them out shortly
* Get internet happening on apple laptop then i'm ready to download the apple IDE xCode and the iPhone SDK.
Subscribe to:
Comments (Atom)