We took another run at ARKit during this meetup. I wanted to focus on this great tutorial series called ARKit by Example. The code was originally written in Objective C so I ported it to Swift.
Preparing for this talk was an excellent opportunity. I was able to learn how to integrate SceneKit with physics. It was also great to have Adam there in attendance to fill in some of the gaps in my knowledge regarding ARKit.
For example, when you create a SCNNode in SceneKit you leave the shape argument as nil. This is standard practice that allows SceneKit to figure out the shape of the node it is creating based on the simple geometry we initialized the node with.
I’m learning so much from the other developers. I hope there are other ways I can give back for everything that I have learned by doing this meetup every Thursday.
Worked on ARKit dominoes this weekend with the knew knowledge I gained from this ARKit meetup. This week O’Neil is back in the mix. He’ll be giving a talk on Instruments in Xcode to do memory and battery profiling. Please RSVP if you’re interested in attending!
Adam Smith discussed “Architecture 101” with regards to building iOS apps during this week’s meetup. We develop apps and we tend to leave all the code in the View Controller class. This is not a good practice. Adam shared that each of our classes should ideally have a single responsibility (and therefore should only do one thing).
The single responsibility principle is a computer programming principle that states that every module or class should have responsibility over a single part of the functionality provided by the software, and that responsibility should be entirely encapsulated by the class. All its services should be narrowly aligned with that responsibility. Robert C. Martin expresses the principle as, “A class should have only one reason to change.” – Wikipedia
So how does the SRP relate to iOS programming? Well Adam shared a simple app that he built that downloaded Game of Thrones data and images from the apple website. He had created a Table View that all the devs know well: TableViewControllerDelegate.
Any usage of TableViewDelegates requires certain TableView methods in order to fulfill the contract of the TableViewDelegates protocol. Through the course of his presentation Adam refactored the TableViewController so that it only took care of the aspects of being a view controller. He completely extracted the functionality of networking and TableViewControllerDelegate out of the ViewController.
When Adam puts together a talk, I like how he leaves in common mistakes so we can watch him take them out as he explains what and why he is doing what he is doing in the code. And he’s really approachable with questions.
During this meetup we also had 3 new Hawaii iOS Developers attend. I met Leo, Jerome, and Jordan. After the meetup I showed some apps that I had written the week before we ARKit. Looking forward to the next meetup where I will be discussing ARKit further.
Still thinking about the comment Chae made when I was discussing the shortcomings of ARKit (namely that you have to map the room before ARKit works). Chae added that ARKit is an attempt by Apple to make this technology easy to use. The real value of ARKit will come when it is successfully combined with other technologies like Machine Learning and Computer Vision.
If you’re interested in attending the next meetup, please RSVP!
We’ve all been waiting to try it out. All I needed was a deadline to give me the push into installing Xcode 9 beta 4 and upgrading iOS on my iPhone from 10.3.3 to iOS 11. The gains are huge. Perhaps the best thing I’ve noticed on iOS 11 has been the screen recording feature. Amazing!
During this meetup we had a chance to cover ARKit. I’m floored. Absolutely floored by this technology. I set up the this session so that we could have witness the tech hands-on. In order to prepare for this session I watched the WWDC 2017 video on ARKit. Then I searched YouTube for a tutorial video from Jared Davison.
While I was searching for tutorials I was busy installing Xcode 9 and iOS 11 on my devices. Both of these pieces of software are needed to develop and play with Augmented Reality for the iPhone.
I really like how ARKit projects have a very interesting screen lag. Sounds strange but, this is starting to feel like the future.
Next week Adam Smith will be covering Architecture 101 at the meetup. Please RSVP if you’re interested in attending. Don’t forget, we’re meeting at the iLab on Thursdays at 6pm!
During this meetup I prepared a tutorial on setting up Firebase Realtime Databases. We hit a snag in the set up of the database when I put the configuration call in the wrong place in the App Delegate. Good thing the one of the developers had done the tutorial before. As a group we were able to debug the connection and get the tutorial to work as expected.
During the group debugging session Adam commented that he wished we could always have a group of developers programming together as we located the bug much faster. 10 eyes are better than 2!
If you’re interested in attending the next Hawaii iOS developer meetup, we’ll be covering ARKit to do augmented reality with the iPhone. Please RSVP if you’re interested in attending!
Focus Grouping at Water Conference in Punalu’u in August 7-9
Follow our progress on Github
But first, who am I?
My name is David Neely. I am the Technology and Web Coordinator at the Manoa Career Center. I am most proud of the Pocket Workshops we recently created to allow students to view career development workshops on their mobile devices wherever and whenever they want.
I believe in leveraging the ubiquity of mobile phones to provide every person with superpowers unique to their needs.
I am also the organizer of the Hawaii iOS Developer Meetup. We are a group of nearly 100 developers who meet every Thursday at the iLab here at UHM to discuss the evolving best practices of developing apps for the iPhone, iPad, Mac, and Apple Watch. Next week we’re going to discuss ARKit for the iPhone to do some Augmented Reality on the iPhone with iOS 11. If you’re interested in attending the meetup or have questions about iOS development, please come and see me after the talk.
Finding a need at Purple Mai’a’s Native Hawaiian Tech Conference
One of the developers at the Hawaii iOS Developer Meetup shared that she would be attending the Purple Mai’a Contest on March 25, 2017 and asked me if I’d be interested. The contest brought together Native Hawaiian Water Management caretakers and app makers.
I checked out their website and watched the video from the contest the year before. It looked awesome! So I signed up.
The contest provided an excellent opportunity to do service work at the Kanewai, the loi near the dorms, and learn more about the most pressing Native Hawaiian water issues. I learned from the many talks at the conference that “Water dictates the cultural practices of the land.”
They had a few white boards around the space for writing thoughts to share with other attendees. I wrote on the wall just before getting in line for lunch, “If the water could talk, what would it say?”
Discovering startlingly steep drops in the cost of water management sensors
Brian shared that he was working on a project that leverages the falling price of water sensors that presents a outstanding opportunity to democratize water sensor data. Here’s how he pitched it:
Expensive water sensors used to cost up to $20,000 to purchase
Now those sensors can be had for less than $100!
Brian’s team installed those sensors to monitor tides at He’eia Fish Pond in Kaneohe
They also have a web interface to show the real-time data on desktop computers
But there’s a problem
If you’re working at the He’eia Fish Pond, you’re not going to have access to a desktop computer. They needed an app to display real-time data to allow the caretakers of the findpond to know exactly how much water was flowing from each of the makahas.
Lucky me, I had an opportunity to join the team and I jumped at it.
We met a bunch of times to discuss the state of He’eia Fishpond and the cultural practices that are informed by the flow of both fresh and salt water into the pond.
But why does Hawaiian Fishpond tide data matter so much?
Hawaiian fishponds are unique and advanced forms of aquaculture found nowhere else in the world. The techniques of herding or trapping adult fish with rocks in shallow tidal areas is found elsewhere but the six styles of Hawaiian fishponds, especially large walled ponds, were technologically advanced and efficient as their purpose was to cultivate pua, baby fish, to maturity.
Fishponds provided Hawaiians with a regular supply of fish when ocean fishing was not possible or did not yield sufficient supply (Kelly, 1976).
The compact style of wall slows water flow, allows the pond to maintain a base water level even at the lowest tides, and forces more water to the mākāhā or sluice gates. He’eia Fishpond has six mākāhā – three along the seaward edge that regulate salt water input and three along He`eia stream that regulate fresh water input.
By allowing both fresh and salt water to enter the pond, the pond environment is brackish and therefore conducive to certain types of limu. By cultivating limu, much like a rancher grows grass, the caretaker could easily raise plant-eating fish and not have to feed them.
Leveraging Open Source Software (OSS) to build a rapid prototype
As I designed the app, I identified 3 pain points. In order to build the app I would need to query the datapoint with a network call, validate and parse the returned JSON, and display that data in an interactive chart.
Luckily I had some experience with open source software and managed to find 3 libraries that would make my job much easier. Here is a list of the OSS I used for this project:
SwiftyJSON is an open source library written in Swift for iOS that allows developers to validate and parse JSON with very clean and simple calls.
AlamoFire is an open source library written in Swift for iOS that allows for clean and simple asynchronous network requests. Errors and callbacks are easy to structure and respond to with this library.
SwiftCharts is an open source library written in Swift for iOS that gives developers deep control over how they present JSON data in a nice, very customizable, interactive graph.
By leveraging the open source software libraries SwiftyJSON, AlamoFire, and SwiftCharts, I was able to build the minimum viable product that queried the endpoint, validated and parsed the JSON, and displayed 24 hours of tide data in an interactive chart for the iPhone.
Here’s a gallery of screenshots that shows the progressive development of the app:
Focus Grouping at Water Conference in Punalu’u on August 7-9
On Aug 7-9 we will be conducting a makers conference in Punalu’u where fish pond owners for each of the neighbor islands will come to Oahu to learn how to build and maintain their very own inexpensive water sensors. They will each build their own sensor to take them back to their fish ponds.
Now that we have version 1.0 of the app, we can show them that they will be able to see their real-time data on their phone.
During the water workshop, I’m planning to ask the fishpond owners what features they want in the app and what matters most. I am a big believer in Eric Ries’s Lean Startup Methodology. I want the fishpond owners to validate the product before we build it out.
I love it when other developers present at the meetup. It represents a real buy-in to me. And it allows me to focus on someone else’s struggles and eventual victories over the code they are presenting.
Last week Ryan presented a talk on Threading in Swift. I learned a lot and got a chance to ask some questions. The main takeaway from this talk was that Apple’s Grand Central Dispatch (GDC) does not necessarily manage threads but queues.
So what does that mean you might ask. That means that we, the programmers, don’t have to worry about threads locking up because they are trying to access the same memory resource. GCD allows us to set up priority queues to manage which parts of the code will execute before other parts of the code.
This week I’ll be covering Realtime Databases with Firebase. If you’re interested in attending, please RSVP!
Aristotle once said, “You don’t find an audience. You make an audience.” I never really understood that saying until this meetup.
I prepared a long talk on debugging for this meetup. I spent extra time setting up a project that would leverage the step debugger for the meetup attendees and did light research on the visual debugging features in Xcode.
When I started the meetup, I took a show of hands to find out if any of the developers had done step debugging in the past. I was expecting maybe 1 or 2 hands to go up. Unfortunately, all the hands went up. I had planned the right talk for the wrong audience.
In the future I’m going to pursue more feedback from the attending developers to “make the audience.” I’m glad to have these kinds of experiences.
This week Ryan Hanson will be conducting a talk on “Threads in Swift.” Threads are definitely not in my list of strengths. I’m looking forward to learning how Ryan handles threads in this talk. Please RSVP if you are interested in attending!