The slides show the range of possible modifications to the PirateBox for Android, ranging form simple preference changes to the more advanced use of the Android API.
Here are the slides, more details and download links are available below the presentation.
The first slide shows the Basic Settings that can be changed inside the preferences of the PirateBox app.
These basic settings allow to change things like the SSID name, storage directory etc. without deeper knowledge of the PirateBox.
The next slide Content Modifications shows the settings needed to make basic changes to the HTML, CSS and JavaScript files. After ticking the Content to SD option, the app has to be restarted for the change to take effect. After the restart you should find a folder named piratebox on your SD card (or wherever your external storage file system is located).
Inside the piratebox folder you'll find a directory named html which contains all the HTML, CSS and JavaScript files. If you are making changes to files located inside the html directory, make sure that the option Enable Updates is not ticked to prevent the next update of the app to overwrite your changes.
You will also notice that the html directory contains files with the extension xhtml. These files are html files that, in addition to standard HTML, include dynamic content. Dynamic content is covered in the slides that follow.
The next five slide (Dynamic Pages, Using BeanShell, XHTML Example, XHTML Errors and BeanShell DIY) cover the use of dynamic pages by using BeanShell. The slide named BeanShell DIY contains a download link (available below) that offers you the possibility to execute BeanShell code directly on your device.
The last two slides (Using the Android API and Android API DIY) are targeted at developers that already know the Android API. The Adroid API DIY links to a ZIP file (download below) that contains an example that shows the use of the Android API to access the music stored on the Android device. After unzipping the files to the html directory you should have an additional menu entry named Media inside the menu of your PirateBox start page.
If you are interested in how that works you can inspect the xhtml files included inside the ZIP file. But event if you are not into development the sample might be a nice addition to your PirateBox.
Downloads
The files referred to inside the presentation are available on Google Drive:camp#2/beanshell.zip
camp#2/android_media.zip
No comments:
Post a Comment
Note: Only a member of this blog may post a comment.