Here are two Python scripts for getting latitude and longitude position from Google based on GSM cell tower ID numbers:
The proper way to do this, then, is using the second bit of code, which accesses Google's JSON-based services. The primary function in that file, gGSMLocation(), is actually not specific to S60. It takes as its only argument the four components of a GSM cell tower ID in a tuple: the mobile country code, mobile network code, local area code, and cell ID, in that order. It returns the Google JSON object as a string. I left the return format serialized because working with JSON on PyS60 (or, as far as I can tell, any Python) can be a real hassle, and you may have a favorite approach. In Python 2.3 or later (S60 uses 2.2), you should just be able to use json.load() from the included modules.
The second function in the file, gGSM(), is useful only on Nokia phones. It's just a simple wrapper that feeds location.gsm_location() directly into gGSMLocation(), no arguments needed.
Working on this kind of code is frustrating in equal parts due to Nokia's design decisions and the limitations of Python itself. On Nokia's part, its idiotic code-signing initiative means that loading new libraries (such as JSON or XML parsing) into Python without cracking the signature check is way more trouble than it's worth. If you've broken the signature, you can just copy .py modules to c:\\resource\\, and .pyd modules to c:\\sys\\bin\\, but you can still run into platform security errors.
Python actually has a quirk, I think, in that it's often pitched as a good learning language due (in part) to its lack of punctuation for blocks and line endings. But the flip side to that approach is that advanced code contains underscores (which are used to signal metaprogramming and low-level functions) and weird punctuation in direct proportion to its complexity. I feel like the learning curve goes from flat to nearly vertical the moment those underscores make their appearance, which seems like a serious flaw in a teaching language. Perhaps it's different when you're not teaching yourself.
In any case, I don't know what you might want to do with your latitude and longitude, but I hope people might find it useful. I have a few ideas I'd like to try, like creating a lost-phone-locator over SMS and a geotagged link generator, that could be useful for some work and hobby projects coming up. But these kinds of scripts are useful for all kinds of problems--Ethan Zuckerman recently wrote about farmers in Kenya who are using phones and GSM IDs to track elephant movement and protect their crops from pachyderm predation. You never know what you could do, given a little latitude (and longitude).