IPod touch

From Better Practices

Jump to: navigation, search

Contents

[edit] Can i(Pod) Touch the Math?

--some reflections by Lila Roberts

In late September, Apple released the iPod Touch. Touted to be "iPhone without the phone," iPod Touch fell short. Reviewers commented on the sparseness of the screen icons as compared to iPhone (see for yourself--visit the Apple website External link to Apple Website). The calendar on the iPod Touch could not be edited on the fly and there was no Notes application, no Google Maps, and no Mail (other than webmail). Although there is a robust mobile Safari browser, neither Java nor Flash are implemented as of the latest update (1.1.2 released November 9, 2007). In the article Hippogriff, the partial transcript of an interview with Steve Jobs indicates that while Flash is a possibility, Java is basically dead as far as he is concerned. Other sources indicated that a Flash plug-in was expected in September, but that prediction did not materialize.

So what can a crippled iPod Touch do other than show videos and photos, and play music?

[edit] Taking Advantage of mobile Safari--Web Apps

Web apps make use of the internet and the multitouch interface to bring web-based "applications" to the iPod Touch (and iPhone). The Apple website (Web Apps) gives instructions for developers of web-based applications optimized for the 3.5 inch screen of the iPod Touch. Web apps include games, productivity tools, calculators, news, entertainment, etc. One of the calculator apps, Conspiracy, claims to be a graphing calculator that gets (surprising) decent user reviews. It is powered by Javascript, but is undocumented (e.g., it is not clear to this user how to enter x^2, other than to use x*x). It has rudimentary 3-d graphing capabilities. The application is not without bugs, as the figures below illustrate. Note: These are actual screen captures of the iPod touch.

Image:conspiracy_1.jpg Image:conspiracy_bug.jpg Image:conspiracy_3d.jpg

There are a couple of scientific calculators, which are better than the very limited native calculator app.

A growing number of web pages are being optimized for mobile devices, in particular, for iPhone and iPod Touch. Recently at GCSU the faculty/staff directory has been adapted as illustrated in the figures below. The first image is the "normal" view; the second is the i-mobile version.
Image:Directory_page_portrait.jpg Image:gcsu_mobile_directory.jpg

From a mobile accessibility standpoint, it makes sense to think about developing mobile versions of at least some of our web pages.

[edit] jsMath and Graphics

[edit] jsMath

A visit to Davide Cervone's jsMath web site at Union yielded the (surprising?) result that jsMath displays in mobile Safari. The screenshots illustrate that the rendition is not perfect, but pretty much acceptable in most cases. It is not possible, as far as I know, to download fonts to the iPod Touch, but while the image fonts render more slowly, it is not unacceptably slow on a reasonably fast wireless connection.

Image:jsMath1.jpg Image:jsMath2.jpg Image:jsMath3.jpg

[edit] Graphics: SVG and Canvas

I incorrectly reported that mobile Safari supports SVG. It turns out that on some pages that have examples, images are also generated and so I could not tell that it wasn't SVG I was seeing. Although disappointing, the rumor among groups that are interested in such things is that an update is forthcoming that will support SVG, since mobile Safari is based on Safari 3.0.

Mobile Safari does support the (Apple created, as best I can tell) html canvas tag. I am just learning about some of the differences, but in many cases the displays are very impressive. For some of you who know more about these things, this is probably not news for you, but for those of us who may not be familiar, some links are given below.


One of the biggest drawbacks is that as far as I can tell, graphics are displayed as images and so they are not scalable, as with SVG. I am certain there are other significant issues, but I am not familiar enough with SVG coding to understand all of them.

With canvas, you can do animations that are quite nice and it does not seem very hard to do them. And they run on Safari and mobile Safari, the latter of which does not support animated gifs and versions earlier than 3.0 of the former have partial support for animated gifs. Here are some examples with appropriate references. The first example does run on iPod Touch, the second does not. My experiments indicate that there are issues with superimposing image files. The sun, earth, and moon are png files.

  • Animated Clock: [1] Adapted from [2]
  • Sun, Earth, & Moon: [3] Adapted from the same source above.

An application that could be a stop gap between now and when SVG (or a mobile version of SVG) is implemented on mobile Safari is CanvaSVG SVG to Canvas. The current goal of CanvaSVG is to "provide as much of a mapping of <canvas> functionalities using the SVG Tiny 1.2 grammar as possible." Here are links to a couple of examples. In each, one rendering is SVG, the other is generated by CanvaSVG.


Here is how Lion and Test look on iPod Touch. Resizing the iPod Touch display does not cause degradation in the images. The tiger image caused mobile Safari to time out before the image could be displayed.
Image:test.jpg Image:lion.jpg

Another example is from Kyle's article "A Basic Article Combining MathML and SVG."[4] The SVG code from the article was put into a document that called the CanvaSVG utility. CanvaSVG contains parsers and parser handlers for paths and transforms. The result, as seen on iPod Touch is shown below. The image was enlarged on iPod Touch display prior to capture. CanvaSVG does not make any conversion for opacity. Also the SVG code had to be modified because the SVG "style" attributes did not convert. For example, the SVG code
<svg:circle style="stroke:red; stroke-width:2; fill: yellow; opacity: 0.5" cx="100" cy="80" r="75" />
was modified to
<svg:circle stroke="red" stroke-width="2" fill="yellow" opacity="0.5" cx="100" cy="80" r="75" />
The opacity attribute had no effect but also did not cause the conversion to fail.
Image:SVG_Siegrist.jpg
I also added a border around the curved object.

The down side is that with browsers that display both canvas and SVG, two images appear. Here is a link to the test page on my server: Link to CanvaSVG test page at GCSU

[edit] MathML on mobile Safari?

A Google search on MathML led me to a page that gave some information about MathML on Opera and Safari (CSS Warrior). Being the curious one, I pointed my mobile Safari to the page to the MathML stress test MathML Stress Test. The following screen shots illustrate that MathML is alive and well on Safari (even on mobile Safari)--without a plug-in. The down side is that the page looks pretty crappy in Firefox AND the code looks even more horrific than what we're accustomed to.

Image:Safari_MathML_1.jpg Image:Safari_MathML_4.jpg Image:Safari_MathML_5.jpg Image:Safari_MathML_6.jpg Image:Safari_MathML_7.jpg


[edit] iPod Touch--Jailbreak!

All of the above examples (aside from actually making the screen shots) work on an iPod Touch (or iPhone) right out of the box, but the greatest potential comes from hacking the un-hackable OSX implementation on iPod Touch. (Fortunately)It did not take long for some young pups to exploit some security issues and crack the iPod Touch (a process called, appropriately, "jailbreaking") so that 3rd party native applications could be installed. The jailbreak for firmware 1.1.1 was very polished and involved pointing mobile Safari to one website and clicking a button. The jailbreak for firmware update 1.1.2 was out before the actual update was available for download on iTunes.

Most iPhone apps work on iPod Touch. Actual screenshots of my jailbroken iPod Touch (with firmware 1.1.2) showing the variety of apps are shown below.

Image:Lilas_iPod_Touch_p1.jpg Image:Lilas_iPod_Touch_p2.jpg

Of course, each new firmware update from Apple cripples the apps until some other 13-year old finds the way around Apple's closed system. A jailbroken iPod Touch runs OS X (and thus a subset of unix); it is possible to access the file system and develop applications.

An application that could have some value in an educational setting is the iStudy flash card application.

So far there are no real native applications for math except for basic scientific calculators. But this is likely to change.


[edit] YouTube?

YouTube may have some utility in (and out of) the math class. iPod Touch has a searchable, bookmark-able, YouTube widget. Examples coming soon.

[edit] Hello Java!

Who knew it would happen before the SDK is out in February? Jay Freeman External Link to iPhone Dev Wiki has ported JamVM External Link to JamVM site to iPod Touch and iPhone, a compact open source Java Virtual Machine.
Image:HelloWorld.jpg Image:addintegers.jpg


Another positive development is that java applications work in the UI of the iPod touch. HelloJava is an application (Jay Freeman) which opens up the Contact List.


Image:HelloJava.jpg Image:ContactList.jpg



Obviously, there is a long way to go, but this is a start. Java applets don't work yet, but it is only a matter of time.

Oh, and another thing...
Image:FakeSVG.jpg (The controls for Java and SVG are fake, so far)

NOTE: See anything funny about some of these screenshots???

Personal tools