From time to time I need to create a utility that will work on one of my customer’s messaging systems to monitor something about it.  Since Ruby isn’t on a lot of these systems (yet) I usually end up having to use Perl to create these utilities.  Once nice thing about Perl is that there are lots and lots of packages out there that already do all sorts of functions. So after I have found the package that I need, I go out and see if its already on the messaging system.  Since a standard Perl installation has any number of places where the package could be, I wrote this quick little Perl script to go parse through the @INC directories and print out all the package names it can find.  The output can then be grep’d for the package in question quite easily.

Here’s the code:

#!/opt/perl/bin/perl
#
#  ShowLibs.pl  --  Print out all the packages in the @INC paths.
#     Useful if you want to see if a particular package is on your system or not.
#
#  John D. Allen, June 2009
#

use File::Find;

$cdir = "";
find(\&wanted, @INC);

sub wanted {
   if (/\.pm$/) {
      if ($cdir ne $File::Find::dir) {
         $cdir = $File::Find::dir;
         print "\n$cdir:\n";
      }

      open(PM, $File::Find::name);
      while(<PM>) {
         if (/^\s*package\s*(.*);/) {
            print "$1\n";
         }
      }
      close (PM);
   }
}

exit;
1;

You may need to change the first line, as my Perl home directory is not in a default location.

SociBook del.icio.us Digg Facebook Google Yahoo Buzz StumbleUpon
 | Posted by MobileDataGuy | Categories: Code, OtherStuff | Tagged: , |

A new survey by the Center for Disease Control (why is the CDC doing a cellphone survey?!?) finds that 20% of US homes now only have Cellphones … no land lines. It would be nice if they were also asking how they got onto the internet…via cellphone?  WIth more data options being provided by the cell phone companies, the days of having a modem to get onto the Internet are dwindling even faster now! 

SociBook del.icio.us Digg Facebook Google Yahoo Buzz StumbleUpon
 | Posted by MobileDataGuy | Categories: OtherStuff |

iPhone to get MMS Client

18 March 2009

Finally!  One of the great pains about the iPhone (besides the lack of cut/paste) was the absence of an MMS client.  Sending an MMS to an iPhone user entailed the iPhone user going to a website on a PC and entering in a password and picture id to retrieve it. Yesterday they announced that iPhone 3.0 was going to have an MMS client…among other things. Now lets hope they have their upgrade process working better this time than the day they launched the 2.2 upgrade!!

SociBook del.icio.us Digg Facebook Google Yahoo Buzz StumbleUpon
 | Posted by MobileDataGuy | Categories: OtherStuff | Tagged: , |

I needed to write a Ruby SOAP client that would call a Perl based SOAP server for one of my clients, so I searched and serched on the Internet and never could find an example.  Maybe I’m a bad searcher or something, but in the off chance that this example can help someone else, I’m posting it here.

This is actually a couple of examples:

  1. Ruby SOAP client calling Perl SOAP server
  2. Remotely starting up the SOAP sever using ssh from Ruby
  3. Executing a SQL query against an Informix database using the ‘dbaccess’ CLI.

Here’s the Perl Server:
continue reading »

SociBook del.icio.us Digg Facebook Google Yahoo Buzz StumbleUpon
 | Posted by MobileDataGuy | Categories: Code, OtherStuff | Tagged: , , |

iFires

10 July 2008

So today marks the launch the 3G version of the iPhone.  Working around the folks that have been very busy working to launch this new phone, I’ve been exposed to a new set of nouns that I never knew existed before.

As a rule, most new phones don’t require a lot of extra work on the part of the cellular carrier.  You need to make sure that the device capabilities are entered and working in your SMSCs (text messages or SMS), your WAP Gateways (Internet web pages, although a lot of phone go direct now a days), and your MMSCs (picture messages). That the radio side of the network will work with the handset…all the usual things. Other than that is just the usual amount of coordination to make sure all the stores have the new phones in time.

But iPhones are a bit different.  There is a belief that they are going to be flying off the shelves and be selling at a phenomenal rate….like more and faster than last time.  So we have all been busy with meetings to make sure everything in the system can handled the anticipated load.  But these aren’t just any meetings….they are iMeetings. With iAgendas on iConference iCalls.

The closer we got to today, the more iMeetings we had.  Some were iFires in that someone felt some parts of the system needed to be corrected ASAP before today.  I guess when I have my iLunch today I’ll take a peek at the iSystem and see if it iCrashed. :)

Now if only Mr. Jobs would put an MMS client on the iPhone…..or is that an iMMS iClient ;)

SociBook del.icio.us Digg Facebook Google Yahoo Buzz StumbleUpon
 | Posted by MobileDataGuy | Categories: Cellphones, Opinions, OtherStuff |