Monthly Archives: September 2013

Twitter App Tutorial

One of our assignments this semester is to create an App.net client for class. I have been looking for some clear-cut explanations about how to make a microblogging app utilizing an API, but it has been rather challenging. Most of the documentation out there has been about how to create a Twitter app.

I decided to spend today working with this tutorial explaining how to create a simple Twitter app.

I have to say, I am disappointed with some of these tutorials. Every time I try to run one it crashes on me with weird unknown errors. The debugger says that the code is fine but then when I try to run it the program crashes.

For this tutorial I was able to download a completed version of the code and run it on my machine. It looks like the same thing I have been doing, so I really don’t know. I am wondering if I have something set up incorrectly in the new Xcode.

One thing I will focus on soon (probably not today) is getting better at debugging things. I will add more NSLog statements and breakpoints to see exactly where my code is going off the rails.

Anyway, back to the point of this exercise. I hoped that doing this tutorial would give me ideas about how to do an App.net client. Sadly, this does not. There is a built-in framework for both Facebook and Twitter that was created by Apple with a lot of methods coded in to maximize productivity for coding clients for those two technologies.

Interestingly, there are three microblogging sites that the frameworks supports. The third one is Sina Weibo, or the Chinese equivalent of Twitter.

I did notice that the site I am going to for most of my tutorials has everything in either English or Mandarin. I guess this is fitting in with Apple’s apparent market strategy of targeting China. I should get my butt in gear and actually learn Mandarin one of these days. I just worry that knowing Chinese will be the equivalent of learning Japanese in the 80’s.

Final verdict: This tutorial would be fine for someone wanting to write a Twitter client but it doesn’t help me very much currently with my App.net client. It does give me an idea of what a social networking framework would include and it might indirectly help me when we get into ADNKit and some of the other user created frameworks out there.

I will probably come back to this one when I start delving deeper into the finer points of debugging. There is no reason that I can see why my code would have crashed and I need to delve deeper into figuring it out.

Auto Layout Tutorial

I have a list of things that have been integrated into Xcode that I have wanted to take a look at over the course of this semester. I randomly lit upon Auto Layout. It is something we kept disabling last semester and I wanted to get a feel for what it is like.

I chose this tutorial to explore auto layout. It is from iOS 6, but it isn’t like things change that much, right??

I ran into an issue with using this tutorial. This tutorial does not utilize storyboards. As far as I can see, .xib files are not really supported anymore. You don’t have the option to not include storyboards any longer.

I figured it wouldn’t really be that big of an issue. I would just follow the same directions that I would if this was a .xib and not a storyboard.

There have been other auto layout changes. It used to be that when you put an object on the view it would automatically create constraints. A lot of the tutorial was talking about how to deal with the automatically created restraints. Now that they don’t appear any longer, things are slightly more complicated.

I am not going to continue with the tutorial for the time being. I get an idea of what Auto Layout is like. I know I will need to mess around with it in the future.

It also isn’t a priority to me at my current moment. I am still in the process of coding my apps for functionality, not for aesthetics.

I feel confident that when I get to the point where this is relevant for me that it won’t be too difficult to grok.

Core Audio and Co-Working Space

Yesterday I spend my day working at Bendyworks, a Ruby/Coworking shop downtown. On Fridays they have a “Growth Day” where people can work on sharpening their tools. I have been told by people who work there that anyone can come to work on things, but I have asked one the owners if I can come in anyway.

I spent the day working through my Core Audio book. I decided about a week ago to pursue creating a Core Audio app this semester. I got behind on some of my other classes, so I spent a lot of time this week trying to catch up with where I am supposed to be (I still need to finish my Ajax project, which I hope to complete this weekend.)

I spent the day working on the chapter regarding recording. I have worked through about half the book before and I am finding the code to make more sense the second time through. I am planning to spend the next few days seeing how far I can get into the book before reassessing my application idea and solidifying its specifications.

I have found Bendyworks to be an ideally suited environment for working. It is a calm and peaceful place full of energetic, talented people. It is one of the most safe and comfortable places I have ever been.

I know that they charge a certain amount for co-working space. I can’t afford to rent co-working space at this junction of my career. I know that being able to code there would help me get through all of my projects this semester.

I am planning to reach out to the owners to see if it is possible for me to continue to code there. I would like to explore if it is possible to negotiate a reduced rate or something. I have heard that others have just showed up and basically run businesses out of their space without paying the fee, but I don’t want to do that. I would like to be upfront about what I am trying to accomplish and see if we can figure out a way I can set up and work.

So, the plan for the day is to set forth with Core Audio. I have several long-term projects that I need to work on and I am trying to balance the amount of time I spend on each aspect of the projects. I will post an update about my progress later.

Doing Tutorials

I am probably overloading my methods right now, but there are a lot of aspects of iOS programming that I hear about in passing that I would like to master or know better.

I would like to do one tutorial a week on some aspect of iOS that I want to know better. I will write about these tutorials on here and talk about what I thought about the skill I was learning.

I have done this somewhat with UICollectionView. I am compiling a list of things I hope I can do a quick, several hour tutorial on to get a taste of what the skill is like.

Here is my list so far:

  • Storyboards
  • Auto Layout
  • Unit Testing

If anyone reading this has any recommendations of things they would recommend I become familiar with drop me a tweet! My Twitter handle is @redqueencoder. It is also the same on ADN.

My ADN Client Project

One of the goals I have had this semester was learning how to create an app utilizing an API. There are a lot of things I keep hearing about that I don’t really have familiarity with that I want to understand better. Using an API is at the top of that list.

My understanding of our class assignments is that we are primarily working on two different long-term app projects. One of them is one of our choosing (which will be my Core Audio app) and one that will be an App.net client. We are being given permission to use the API to develop an ADN client for educational purposes. If we want to publish our client we need to pay the developer license, but for the time being we can see what it is like to practice making a client app.

App.net has a tremendous amount of functionality. There is a large variety of various different types of app clients released for ADN. Initially a few of them caught my eye. Ohai looked interesting because it was different than a lot of the other straightforward apps that just republished a stream. Ohai is a journaling app that will allow you to record where you are and what you are doing utilizing the ADN framework.

Rivr also looks interesting. I like the design and the feel that it conveys. Yawp! also caught my eye, but that was just because of the name.

The one I decided to model my project off of is Photolicious. I have been interested in using the GPUImage framework for a long time. When I was deciding what I wanted to focus my energy on this summer it was between Core Audio and GPUImage. It was a tough decision but I chose Core Audio. I am glad that I am being afforded an opportunity to use both of these technologies.

I need to spend some time looking through the ADN documentation and messing around with GPUImage. I will catalogue what I learn from these things as they progress.

Learning UICollectionView

The first concept we were assigned to learn for class this semester was the UICollectionView. Last semester we dedicated a great deal of time to learning UITableView. This seemed like a good first project since this was similar to the table views.

It was recommended that we look at the slides from the 2012 WWDC presentation on the collection views. I downloaded these presentations, but I had trouble focusing on them. I also opened the documentation from Apple. Both of these sources were rather dry and I wanted to find a tutorial.

The first tutorial I found was this one. This tutorial appealed to me because it also utilized two other concepts I have not learned or played around with yet: Storyboards and Auto Layout. I thought this would be a safe opportunity to play around with these things.

The tutorial is fantastic. I realized as I was working through the tutorial that it also utilized an API from Flickr. I applied for a developer key and I worked through the first part of the tutorial.

I realized that this was a little bit of overkill for the assignment we have been given. I looked for a simpler tutorial and I came across this one. This tutorial was written by the author of the book “Pro iOS Table Views”. I looked through this book earlier in the year when I was learning table views and the guy knows his stuff.

I have worked through the tutorial and reached a point where the program doesn’t work and I am uncertain as to why. I was waiting to write this post until I figured it out, but I have a deadline to show I have made a modicum of progress this semester. I am uploading the program to BitBucket later tonight and I will continue to work on debugging the project. Later I will post an update as to why the project was not working.

Redefining my Semester Project

My semester programming project has undergone some changes since I conceived of it and posted my plans on my blog.

My teacher came back with some notes saying that the primary purpose of the project was to chronicle my learning process of creating the app. Since the app was technically done and just needed some polish, I decided to be bold and go in another direction.

I have wanted to learn Core Audio for a year or so now. I have either not had enough programming experience or been too busy to dedicate much time to learning it. I am also now required to complete and independent project in lieu of an internship for that requirement. I decided to dedicate a lot of time to making a Core Audio app and to kill both of those birds with one stone.

I made this decision a week ago. My initial thought was to create a subtractive synthesizer. I really enjoy using Reason and I wanted to make a synth modeled on their Subtractor synthesizer. It is modeled on an old analog synth rack and I really like the aesthetic feel of the analog synth.

On Monday I met a person at my CocoaHeads user group who has been programming audio for the last 25 years. He invited me to get coffee with him so that I could look at his project.

So yesterday he and I met up and I saw what he was doing. His synth is incredibly ambitious. He showed me the code he used to generate a simple square wave. In Core Audio that would have been a few lines of code. In his this was several classes worth of code.

I asked him how long he had been working on this . He told me he started it four years ago. He said he has been “almost done” with it for the last two years.

This was very daunting information. I want to make a synth, but I don’t think it would be a good project for my semester. Even if I just got one component done (which isn’t really likely) then I really wouldn’t have a lot to show for it.

I went to Chris Adamson and asked for advice about how long it takes to program a Core Audio app that does something. Part of this issue with Core Audio is learning the technology and looking through the header files. I wanted to get an idea of whether it was feasible for me to learn enough Core Audio to make something functional by the end of the year as a portfolio piece. He and my teacher Eric both gave me some ideas for a much less ambitious project.

At this point in time I am thinking about attempting either a streaming app or a recording app. I want to work my way all the way through the book at least once before I firmly commit myself to a project.

I have the next four days to just focus on Core Audio. I am through the first two and a half chapters and I need to see how much progress I make over the “long” weekend.

So, my current plan is to spend a few days getting up to speed on Core Audio and then redefine my semester project. That is where I am at right now for the independent project. I will update later with my progress.

My Semester Project

Background

Back in Fall of 2010 I came back to school to learn computer programming. I came in hopping to achieve a skill in something like Java so that I could get a decent job doing computer programming for a health insurance company.

I waffled my way through the first year and a half of the program. I treated it very much like my Journalism degree where you could blow off the assigned reading and ace the midterm without studying to much. This was a very bad idea. After four semesters I had unofficially dropped out of the program and wasn’t really sure what I was going to do with my life.

I decided a year ago to dedicate myself to programming. I wanted to master it. I wanted to be one of those programmers like Andy Hertzfeld who was one of the top people in the field who helped create the Macintosh operating system.

I gave myself a year and a half to get there. I had three semesters left to finish school. I buckled down and turned learning programming into a full time job.

This is the last semester. This is the semester where I need to begin the process of leaving school and entering the workforce.

Advanced iOS

One of my classes is Advanced iOS Development. One of the requirements we have is to create an app with the idea that we will be able to submit it to the App Store.

I really wanted to work on a Core Audio app. One of my goals is to master Core Audio. I haven’t had a chance to learn this as quickly as I wanted to, so I figured, “Great! Now I have to learn it because it is my semester project!”

I have since figured out that this is a really bad idea. I am super busy this semester and trying to learn something difficult on top of that would result in bad things happening.

What I am planning to do is to refactor my WWDC app submission. I applied for a scholarship with an app I wrote in two weeks. The app is a Portable Wine Journal.

I have the original version of this at Github.

The app “works”, but it doesn’t work the way I would like it to work. It needs a lot of refactoring.

I have a massive list of things that need to be added, upgraded, or fixed:

  • Change to Universal from iPad only
  • Add Apple Docs
  • Change how the data is stored to Core Data
  • Change the point at which data is stored, now if you navigate away from the page the data won’t save
  • Create a picker for grape type rather than make the user type each one in, allow the user to add grape or fruit types
  • Create a picker for region type, also allow the user to add ones they commonly use
  • Figure out how to locate the winery on a map and store the information
  • Figure out how to set the text box up to search specifically for wineries and allow people to see them in a list when they start typing
  • Put a slider in for dryness level rather than typing a label
  • Put a switch in so user can choose to label the wine by name or grape type (wines usually don’t have both)
  • Allow the user to select the wine in the table to modify the form
  • Allow for editing and deletion
  • Format date better
  • Figure out a better way of tracking wine ratings
  • Make the view grouped and figure out how to get the background to show up
  • Do some more general design things to customize the app and polish it

I will be using this blog to track all of the changes I make to this app. I will figure out how to show the changed I make in my GitHub account so that you can go through and see all of the changes as they progress.

I am also going to document other projects, classes, and processes in this blog that I am currently working on. I have let the ball drop on this blog for a few months and now it’s time to get back to work. Geronimo!

The Road Not Taken

I probably spoke earlier in the year about my various disappointments regarding WWDC 2013. I applied for a scholarship and I did not win.

Someone I met somewhere I can’t remember who talks to me on Twitter told me about another conference happening at the same time, GLS 2013. GLS stands for Games Learning Society. It is an interdisciplinary group at the University of Wisconsin-Madison. It is made up of tech people and education majors who are trying to create a learning experience through games

This conference opened my eyes to a multitude of things I had never considered. They showed me tools that others had developed with the express purpose of teaching children how to code by creating their own games.

This spoke to two things that I hold very dear: Gaming and using games to learn.

I grew up playing “Where in the World is Carmen Sandiego” and “Oregon Trail”. I never had a video game console or any of the “fun” games my peers had growing up, but I had games. I loved games.

I can only learn is something is interesting to me. I am very compelled by story. The only reason I know anything about astronomy is because of the vast multitude of celestial object that are named for mythological characters.

For me, the GLS conference was a life-changing experience. It really focused my attitude towards not just becoming a developer, but becoming a game developer.

I wonder how different things would have been had I gone to WWDC.

There was some focus on gaming at WWDC, but the vast majority was focused on grand-master programming. They focus on people who want to scale a code version of Mt. Everest.

I go back and forth. Sometimes I really want to be an elite-grand master programmer who scales Everest because it is there. Other time, I just really want to share my thoughts and ideas with the world and create nice tools that other people can use.

I am beginning my last full semester of school for programming. I am on a track that I hope to continue to take. Right now I am kind of taking inventory of where I am, where I want to be, and who I am right now.

I had a very turbulent summer that I intend to write about at some point. It is still hard for me to talk about, so I hope that if you read my blog you will be patient with my lack of responsiveness over the summer.

I am planning to write here more regularly. I have been advised to keep a public blog of my projects for my development class and this one is already established. Stay tuned for the next few months. Where we’re going, we don’t need roads!