Every April, NYU holds a huge open-house event called NYU Day that draws 60,000+ visitors to the campus to view exhibits highlighting the research conducted at the university and participate in various events and activities. All of the event details are entered into a ColdFusion application, and one of those details is the GPS coordinates (latitude and longitude) of where each event is taking place so visitors to the website can see where the events are located on Google Maps.
Now that smartphones are becoming more prevalent, I wanted to see if it was possible to build a web application that would show the user where they were currently located and then show them on a map how to get from their current location to a particular event.
So I did some research and learned that HTML 5 comes with a Geolocation API. This API allows you to execute Javascript functions within the navigator.geolocation object built into the browser that retrieve the supposed latitude and longitude coordinates of where the browser is located (and, if available, the altitude, heading, and speed at which the browser is moving).
Using the code examples I found on the Gelocation API page on the W3C website and on Oliver Wehren's geolocation demo page, I was able to create my own test page for determining my location and marking it on Google Maps. I then tried using the page with my iPod Touch, and my friend's iPhone.
The default web browsers on all three devices implemented the Geolocation API ( the Dolphin Browser, did not). Each of the browsers displayed a confirmation dialog asking for permission to share my location information with the web page (as mandated by the standard), and once I permitted the information to be used, my test page was able to place a marker denoting my location on the map.
However, the location wasn't as accurate as I had hoped. Although the API was coded to accept location data from the on-board GPS system in a mobile device, neither the iPhone nor the Droid seem to provide GPS data to the browser. If I was connected to the campus wireless network, my location was determined via the network topography, and it could be off by as much as 150 feet or so. The accuracy was even worse if I was relying solely on 3G: in that scenario, but the iPhone and the Droid had me located on the side of a state road on the outskirts of campus, a good twenty minute walk from where I actually was. I have no idea what caused both devices to pick that particular spot, as there certainly wasn't a cell tower anywhere near that location.
So I came to the conclusion that while the Geolocation API could be used to determine what town, city, or general area a user was currently in, it wasn't accurate enough (at least with these browsers in these devices) to provide walking or driving directions within a small area, especially given the fact that many of the users for the service I had in mind would only have access to the Internet via a 3G connection.
But if someone knows of a way of increasing the location accuracy of the Geolocation API, a way that doesn't require the end-user to modify their mobile browser in order to make it work, I'd love to hear about it.
Keep Smiling,
Love and Respect,
Veswan
Geolocation with html5 and javascript
3:07 PM | | 0 Comments
The XCODE IDE
Seldom do people describe about the Xcode IDE.It is just left out in the corner, with the expectation that people will get used to its architecture, as they go along coding, but in my personal opinion, I believe that if you know the tips and tops of your IDE, you can code in any way you desire, with proper knowledge of error producing threads and the rest. You can even detect the compatibility and leaks and consistency of the code as desired.
Let's get started.
so this is what xcode logo looks like( if you've never seen one before)
There are multiple versions of xcode, the latest one being Xcode 4 released by apple on March 23,2011.
It is a complex programming platform for iphone and ipad development, where you can build and test your apps using the various possible simulator/emulator options available with the IDE.
As you tread along the Xcode IDE, you will come across a lot of new things which you are probably not familiar with. Let us go through them step by step :
As you can see in the figure, xcode 4 is also termed as single window IDE, where you can find different options in one place.
Xcode 4 presents an entirely new user interface and workflow for developers, along with new components for compiling, debugging and finding and correcting common errors. The result: better, faster code from more productive developers.
Rather than spawning new windows to search code, debug, build, and set parameters, everything can be done within a single window that echoes components of the design of iTunes, including a LCD-like status display.
The new window presents a dismissible Navigator control (akin to iTunes' Source List), with icon tabs that can present a variety of different types of development-related information within the same window column:
* a listing of projects and files
* a symbol listing of classes and methods
* a search feature that lists project-wide results
* an issues listing of build errors
* debugging information
* breakpoints
* a listing of build logs
The main area of the new Xcode windows is devoted to the document being viewed, whether code, a data model, or the project's graphical interface. This area can also be segmented to view multiple documents, presenting a comparison of their differences (such as for comparing two versions of the same code file). The content area also integrates support for viewing PDFs and other file types supported by the extendable Quick Look feature.
An integrated IB(interface builder) exists within this new xcode version.It's basic purpose is to add components to your project, including all simple functions like buttons and display of the UI. It will not only help developers code on the multiple window platform while looking at the existing code, but also help them achieve the goal of understanding the programming theme as they go along the project, which will in turn help in expediting the project at a much faster rate eventually.
This new comparison feature Will help people compare the codes in the project which will help them keep track of the flow of the programming parameters and the in general scenario as they tread along wiTh the project in the long run ,to understand where the error occurred and how it can be fixed.
besides these awesome features,another major feature delivered alongside Xcode 4 will be a new version of Instruments (originally code named Xray), Apple's graphical tool for code performance profiling based on Sun's DTrace technology.
The new Instruments adds new time profiler support for iOS development, and includes new features that help developers examine how their application code interacts with other apps and the system's kernel, in order to find where apps are spending their processing time and allocating their resources in a very complex computing environment.
This way xcode 4 IDE will make programming easy and make the whole process flow tracking, designing and coding experience fun, making project coding convenient for everyone involved in any given project at hand.
Thanks for reading,have a wonderful day !!!
Regards and smiles,
Vishwan Aranha :)
P.S: Instruments is also said to include support for identifying abandoned memory that has been referenced but not actually needed, enabling developers to reduce the memory footprint their apps demand. The tool will also add profiling analysis support for OpenGL ES, an important tool for iOS developers building high performance games and other apps that make use of sophisticated graphics.
8:43 AM | | 0 Comments