Category Archives: blackberry

Taking photos in Java with the Blackberry

According to this press release, RIM has released the APIs needed to take photos with the Blackberry camera in Java apps.  As far as I have figured out, they have enabled the API to start the camera app, but not an API to listen for new photos.  That isn’t particularly horrible, because you can use the File Connection API to open the Blackberry filesystem and monitor for new photos.  The only tricky part is knowing when the camera app has relinquished control back to your app, so you can start looking for the new photos.

Blackberry dev gripes

I’ve been working on a project to port a GPS enabled MIDP app to the Blackberry 8800. This is the first Blackberry work I’ve done since the Nextel blackberry 7520 and 7100i’s. Things have changed a bit, but not that much. The dev environment works pretty well, but I do have a couple gripes. I think some of my issues have to do with not using the “JDE” they provide. RIM should really come to grips with the reality that people write apps for many MIDP devices, and it would rarely be practical to use a Blackberry specific IDE. Anyway, here’s my list at the moment:

  • The 8800 randomly reboots sometimes when you use javaloader to install an app. I’ve heard that something similar happens on the 8820, but it prompts you before rebooting. This really slows down the turnaround on the compile-install-test cycle.
  • The 4.2.1 JDE comes with a JDWP debugger, which apparently lets you do on-device debugging. I’ve gotten it to attach to a device via Eclipse, but it doesn’t stop on my breakpoints. It does output the System.out.println()s to the console though.
  • Over the air provisioning is clunky on Blackberry. You have to provide a JAD (which you don’t for cable loading, so why is it needed here?), and you have to split the COD file into a bunch of little ones (which I guess explains the need for a JAD).

I think I have a few others, but I can’t remember them now. I’ll have to add them later…