A ridiculous race is going on in the world of Smartphones, with each competitor boasting about the number of available apps for his platform. With Apple talking of 200’000 apps and Android claiming 50’000 apps (similar to what Palm offered in earlier years, and probably similar to Symbian), a new platform such as Maemo 5 sometimes faces a difficult stand, with casual users coming from other platforms complaining about too few apps (only hundreds…)
Planet maemo: category "feed:26249a1a7af71c9eb987f48eaef6cf1d"
Another of my single-button widgets for the Nokia N900 got into Maemo Extras this week: Bluezwitch, a simple widget to turn Bluetooth on/off (saving you 3 clicks compared to the original way). Apparently, this widget is a great thing for many users, as it already got 12’000 downloads in just six days!
For me, the main work in this was to find out on how to programmatically enable/disable Bluetooth with Bluez 4.x using D-Bus – all the examples I found online only talked about the older Bluez 3.x versions. After digging through the Bluez Docs and some experimenting, here is how it works in Python:
- Find the default Bluetooth adapter.
- Modify the “Powered” property of the adapter.
The following snippet of code toggles the adapter on/off on each run:
import dbus
self.bus = dbus.SystemBus();
self.root = self.bus.get_object('org.bluez', '/')
self.manager = dbus.Interface(self.root, 'org.bluez.Manager')
self.defaultAdapter = self.manager.DefaultAdapter()
print "Default adapter is at", self.defaultAdapter
self.obj = self.bus.get_object('org.bluez', self.defaultAdapter)
self.adapter = dbus.Interface(self.obj, 'org.bluez.Adapter')
props = self.adapter.GetProperties()
powered = props['Powered']
if powered:
self.adapter.SetProperty('Powered',False)
else:
self.adapter.SetProperty('Powered',True)
Accidentally, “Bluezwitch” (Bluez-Switch :-) was rather a byproduct on my quest to another widget I’m currently working on: “Carmode” is a widget that toggles a number of things when entering the car. But more about that in another post of my “series”.
And BTW: From now on, I’m changing the button icon size on all my widgets from “Finger” (48px) to the “Thumb” (64px) size, as apparently the smaller icons were just too small for many people (dragging these icons became a mini-game in itself ;-). Bluezwitch has been updated today to version 1.0.0 to accommodate this change – it will show up in your favourite repository soon.
I just LOVE making widgets for Maemo, but sometimes it’s hard to get back after the initial release to clean up and finalize the software. Luckily, I found the time and energy to do it last weekend for the Sleeper widget, which allows your N900 to pause the music player (or the Panucci audiobook player) after a defined amount of time, e.g. 15 or 30 minutes – It’s really handy when listening to music (or now audio books!) while falling asleep.
Therefore, you can now find version 1.1 in Extras-Testing, in desperate need for testing and votes :-) I think it’s well worth your time, as it now not only features Panucci support, but also extensive layout settings (orientation, number of sleep values/buttons) plus Help/Licence/Donate information buttons. I took the time to build me a nice framework based on the work done by Brent Chiodo with TouchSearch, as I really want to clean up all my widgets and add configuration options to a number of them (e.g. Multi DSLR brand support in Shutter).
In addition, this also made me do something I’ve wanted to do for a long time: test using the maemo wiki as a help framework for applications. Therefore, I’ve created a wiki page for my app and am linking to that from the “Help” button using the Maemo browser. I will try to do that for all my apps from now on and believe something like that should be included with every app we do in the community. Having a help page is really valuable in many cases, and having it in the wiki allows other users to add help information / tutorials / tips & tricks.
And yes, I also added a Donate (through Paypal) button as an experiment – netting me my first 5 Maemo-Dollars in 24 hours :-) Thanks Ryan! Now to find a sharing agreement with tpl ;-)
The power of the N900 continues to amaze me again and again. I’ve been a big fan of the gstreamer media framework since shortly after I got my N900 at the Amsterdam Summit, but the possibilites that this brings to Maemo are really extraordinary compared to every other handset. Here is the latest example:
The last few evenings, I spent putting together a very simple (one REC button!) recording widget called “recaller”. Now, it is available for test and comment in extras-devel (CAUTION – this is the repository for possibly highly unstable software). From the description:
A simple widget to record the current phone conversation (AAC, 1 MB/min). Please be aware of local laws guiding the recording of telephone conversations!
- Can also be used as a normal voice recorder.
- Press ‘REC’ to start recording, make your call or record anything else using the in-built mic, press ‘REC’ again to stop.
- Recordings are saved to MyDocs and can be played back through e.g. the File Manager.
Roadmap/ToDo (might get done someday):
- Make it look better
- Allow recording of bluetooth conversations
- Add option to choose saving location
- Add beeping option
Wishlist (no idea if possible or interest in doing it)
- Autostart
- Include contact info / phone number in filename
Once you have a good environment and package setup in place, making new Maemo widgets becomes easy :-) In the last 10 days, I’ve released a IR remote widget for the Nikon DSLR (“shutter”), a sleep timer for the Media Player (“sleeper”), and now “recaller”.
Time to polish or churn out even more? Ideas abound :-)
PS: If this is your first python-homewidget, you need to reboot before it will show up on your desktop. Sorry, not my mistake, but a bug in a library I’m using.
gst-launch playbin2 uri=file:///path/to/file.ts
It plays, but still low framerate and playbin2 bickering about “this computer is too slow.” :-)
Now looking for disabling scaling, improving pipeline and going fullscreen
If you want to work with gst-launch and gst-inspect on the N900, you need to “apt-get install gstreamer-tools” to install them on your device (or SDK).
Just a quick fix of the package to get it up and running again on Diablo (and add a larger desktop icon).
mclock-051-1_all
Mid-term target is to get it into the Extras repository one day…
The Nokia Internet Tablets include a handy “Internet Search Applet” on the desktop / home screen. By factory default, this applet includes Google and Wikipedia search. However, the list of search engines can easily be expanded through plugins.
I’ve put this feature together with a Google CSE (Custom Search Engine) defined and maintained by myself to create tabletSearch, the “perfect” search plugin for anything Nokia Internet Tablet and Maemo related. It includes searches on maemo.org, internettabletttalk.com and more.
You can download the plugin from this webpage that I created for the MIS plugins, making them hopefully easier to find and install for the average user. Go there to get tabletSearch and more (Amazon, Googlemaps, IMDB…).
An easy way to add more options to the Settings/Screen menu in Maemo (OS2007/Bora and OS2008/Chinook). Simply launches an appropriate .sh script to add more options for screen dimming and blanking timeouts (10, 30, 60 minutes, 8 hours, 24 hours).
Uninstalling will restore the original values.
[Does not install any application anywhere!]
Credits:
- ArnimS et. al. for the original idea and gconf example (internettablettalk.com)
- Khertan for PyPackager (khertan.net)’
Available for OS2007 and OS2008.
Screenshot:
mobile nirvana – everybody in need of some serious typing on the nokia internet tablets should take a peek at the new aluminium apple wireless keyboards (79$).
they are small and stylish, a perfect fit for Maemos. the design is absolutely marvelous. they easily find a place in a bag, are very light and just way cooooool.
now i only need a swissgerman keyboard layout on Maemo…
(post typed on the sofa, keyboard on my lap and N800 standing left of me on the sidestand)