Sunday, August 22, 2021

Google Maps versus Here Maps versus OpenStreetMaps/Leaflet versus Tomtom maps

Since I think around 2012, I've been lucky enough to have been able to use Google Maps for free. My usage has been relatively low so there's not been an issue. More recently however one site I created (www.5kmRadius.com.au), to help people check the 5km radius they're allow to travel for exercise in lockdown, became very popular. Both Victoria and NSW went into lockdown and restricted people's movements. 

Now you'd think a site becoming popular would be good and normally it is, but unfortunately the site's popularity made Google notice and I needed to sign up on their Google Map's freemium service which basically means once my sites go over approximately 28,000 page views I start getting charged.

Normally I add Google AdSense to my sites but for maps there's two problems.

1. Google does not allow AdSense ads to be placed on this page. My guess is because it's a single page site, but really I don't know.

2. Even if I could place ads on the site, the cost per 1,000 transactions is greater (probably double) than ads generally pay, so I'd still be running at a loss.

This has meant I needed to check and test other mapping services. Here's a summary of my findings.

Google Maps

Google provides a $200 credit (in USD) which equates to around 28,000 transaction a month (which I estimate to be around 28-30,000 page views). After that there's a charge of  of around $7 USD per 1,000 calls. With no income coming from the site it's not possible to justify paying to provide a free service to others.

Pros

Best mapping service
$200 monthly credit
Ability to limit costs (in theory as have not tested)

Cons

Cost $7 (USD) per 1,000 calls

Google Maps is the service I'm used to the most but I also think it's the best service. Overall I've not really had problems with the service.

Here Maps

After reviewing a number of services I decided to try Here Maps. Here Maps has a fairly generous freemium plan where you don't have to provide a credit card up front and you get 150,000 transactions per month. 

Pros

Greater allowance of 150,000 transactions
No credit card needed to sign up.
Conversion from Google Maps wasn't too hard.

Cons

Maps don't always display correctly. E.g. zooming parts disappear
Account states 159,000 used but receive email the account was suspended with 253,000 transaction. That is you can't rely on their account page. Mine was about 4 days behind.

OpenStreetMaps/Leaflet

I decided to try OpenStreetMaps. You're almost lead to think of this as a free service, but that's not the case. In fact I'd suggest it's possibly more expensive than Here Maps. You're encouraged to use other service providers to serve maps and prices vary. I checked a few out (Mapbox, Thurderforest) and almost signed up to Mapbox. I decided not to as I couldn't find in their document an ability to limit cost and to me that is critical.

Pros

Converted fairly easily from Here Maps and Google Maps

Cons

Free data is one thing but you need to find a third party as a tile server and thus charge. Some have introductory level plans with free usage but I couldn't find a method to limit usage and thus potential for large costs.
Maps aren't as clear.
Maps were cut off when changing what the user could see so redesigned my page so couldn't resize.

Overall I felt there's little point in using OpenStreetMaps over Here Maps. Here Maps works out cheaper if you need to pay.

Tomtom 

Perhaps the most disappointing service. After spending quite a few hours over a number of days, I was not able to get even the most basic map to display. For such a strong brand name their tutorials are lacking

Pros

Higher free usage, 50,000 tile requests a day.
Clear crisp maps.
Like the full screen button available on desktop/laptops and Android.
Activity on dash up to date.

Cons

Poor documentation such that I couldn't get Tomtom maps to work.
A feature such as a circle on a map isn't included in the base API.
Difficult to get working.
Time consuming to get working.

In conclusion, and this should be prefaced that this is about what I need the maps for, Google Maps is good if your usage is low but if your usage increases then consider Here Maps. If however paying for your usage of maps is justified as you have a method to get a return on your usage, then Google Maps offers the best service.

This is a brief summary of what I found in using the various mapping products. My usage is fairly basic requiring the display of a map, markers, circles and lines. The ability to update the position of circles and markers on the map. The ability to return the GPS location clicked on. So really I would consider these features to be basic, but I suspect that perhaps many others may only need this level of product.

I hope this information is useful.

Kelvin Eldridge
www.OnlineConnections.com.au

Update: 23 Aug 2021 (shortly after midnight)
After a few more hours, watching YouTube videos and comparing code samples, I was able to get a basic map up and going. At this point I could start testing. Able to display map, zoom in and out buttons (with full screen option) and add a marker. The next step was to add a circle which doesn't appear to be a built-in feature. I created a polygon so a circle really is just a polygon with more points. Two things I need is to create the function to create the points and then work out how to add and remove the circle. Certainly more work than other mapping software.

I'm not at this stage going to write off Tomtom maps as it provides another option.

Update: 23 Aug 2021 7:40pm
After working on the www.5kmRadius.com.au site using Tomtom maps I've completed all the features to make the Tomtom based version live. It's been time consuming but it's good to have nutted out all the issues. There's features I like about Tomtom maps plus Tomtom also provide 50,000 transactions free each day. Although what constitutes a transaction isn't always clear it means I can now further test out Tomtom's services.

Pricing for Tomtom usage

Tomtom provides 50,000 free map tiles per day. How many tiles are used each time there's a page view depends on your zoom level. According to the documentation, since I'm using zoom level 10 as the default, the map tile horizontally would cover 152.87 metres / pixel. With a HD screen having 1920 pixels  across, a map tile would cover 293 kilometres. If that's the case most people will only need to display one tile to see their 5km radius and those of their friends 5km radius. This potentially means 50,000 free tiles should be sufficient. We'll see how it goes.

If payment is required the charge is $0.05 per 1,000 requests. Not sure of the currency but suspect USD which equates to about 7 cents per 1,000 tiles. Tomtom has a prepaid credit option which starts at 25 euro which equates to around $40 AUD.

Normally usage isn't a problem for me as I have relatively low use sites displaying 5,000 or less page views a day. Because of Victoria and NSW locking down at the same time usage on my site has been what I consider huge. The usage is however tapering off. What is important however it by using each mapping product and reviewing their prices has left me better placed for whatever the future may hold.

Update: 23 Aug 21 11:48pm
The results of testing.
Time: 3 hours 44 minutes
Page views: 1,028
Tiles: 11,999
Approximately 12 tiles per page view
Thus 50,000 tiles served in this test correlates to approximately 4,167 page views.

Based on 12 tiles server per page, the cost per 1,000 page views is around 84 cents. Hopefully this figure helps others who are evaluating different mapping service options.

Update: 24 Aug 2021
Response from HERE.
I received support email with a link which states "It can take around 48 hours for usage data to be available on this page." This is 2 days. What I found is the usage data was around 4 days behind. When the account was suspend the usage data was not updated. This doesn't stop you from using HERE but it does allow you to factor in the slow updating of their information. It is probably better to determine a way to estimate usage from your own stats otherwise you could end up with excess charges.

Update: 24 Aug 2021
Response from Tomtom. I had a hard time getting their basic map to work. I have to eat humble pie. The basic example is provided here and I made multiple mistakes. One when I copied and paste the key where I left in "<" and ">" at either end. The second is I didn't read/understand the note "With a CDN: https://api.tomtom.com/maps-sdk-for-web/cdn/6.x/<version>/maps/maps-web.min.js - Note: Include latest version in the URL". You need to replace "<version>" in two places with the latest version number. Finding the latest version number is a bit obscure. So in essence the fault was mine, but to be fair, each other site provided examples where only the key needed to be replaced for the basic example to work. IT's easier to see your errors in hindsight. Hopefully my error may help others.

Update: 25 Aug 2021
Reviewing historical page views for the 14th of August the page views for the site was 43,633 and unique page views were 31,648.. The transactions according to HERE for the 14th of August was 37,930 total and 37,574 tiles. A quick correlation would indicate HERE transactions roughly equate to about 15% less than the number of page views. 

For the period from the  to29th July to 20th of August HERE reported 149,338. The page views on my sites totalled 185,067. My account account was suspended for the remaining of the month with an email stating 253,000 transactions.

Update: 26 Aug 2021
It's a new month for my account with HERE maps but unfortunately the account is still suspended. Waiting for a response. This means if you're using the Freemium account and reach roughly 12,500 page views your account could get suspended and your site effectively become useless. The problem with HERE is once you exceed your plan the only option appears to provide your credit card details. Since they have no controls for you to limit usage it's possible to end up with huge bills. That's not a risk I'm prepared to take.

Tomtom's limitation of 50,000 transactions per day (about 4,000-5,000 page views) is working well. Once the quota is reach the map stops working, but by the next morning it is working again. Whilst I'm OK with my site stopping once the quota is reached (at least 4-5K people each day get value from the site) if I did want to pay, there's a prepaid option starting at 25 Euro or around $40AUD. At around 84 cents per 1,000 view that would provide approximately 47,000 page views and no exposure should the amount be used up quickly. Unfortunately the site has no form of income so I'm not able to fund the activity. I am continuing to research options so I can help more people but that will take time.

Updated my code so the Tomtom service is used up to 4,000 page views a day and after that OpenStreetMaps is used. The service is now operational 24/7 but there's still a possibility of OpenStreetMaps suspending the service.

Update: 27 Aug 2021
Didn't hear back from HERE maps so service is still suspended. Wondered what would happen if I opened another account. Deactivated suspended account and opened new account with different email address, created the key and pasted into code. Site is now up and running again. Doesn't give me a great deal of confidence in HERE maps but we'll see how it goes.

Update: 2 Sep 2021
In order to keep the www.5kmradius.com.au active once quotas are reached, I've programmed the site to change providers once a certain number of page views is reached. The problem I've now come up against is the time Tomtom uses isn't Australian local time and thus their count does not match the local time period and maps can stop displaying. Tomtom is based in Amsterdam but that doesn't appear to be their time base either. I suppose only time will tell!

Update: 14 Sep 2021
After quite a bit of testing I feel Tomtom's stats base the time in UTC, which I'd equate to GMT (Greenwich Mean Time).. By setting the default time as UTC the page views and the Tomtom activity page should now match. In other words 10am in Australia, which is 0:00 GMT or UTC is when the counting of tile requests reset. As a quick guide I now feel one page view equates to around 15 tile requests.



Monday, August 16, 2021

GPS logger app on Android Samsung Galaxy S21 5G mobile phone versus GoPro Max GPS data

On a recent bike ride (see map) I decided to test of the GPS logger app available on Android the gps in the GoPro Max. The GoPro Max wins by a long shot but if you don’t have gps in the GoPro (some lower cost models don't) you really don’t have any choice other than using an app with a mobile phone.

Overall I think the GPS logger app is more than sufficient for mapping out the trail. It’s only when you zoom right in do you notice the difference. I think the real limitation is the mobile phone gps device, not so much the app. The mobile phone in this case was a Samsung Galaxy S21 5G, which you'd expect to have the latest GPS technology.


The above image is the start of the trip at the end of Hawtin Street, Templestowe near the tennis courts. I have to say I do like the precision of the GoPro Max. It actually looks like I’m on the right or left of the path or road. The very tight corner at Fitzsimons Lane and Porter Street near the car wash shows how the pole there forces you go down the centre of the path. This doesn’t show up on the GPS logger app.

The GPS logger app has the advantage it produces a single file that can be manipulate easily. The GoPro Max data takes quite a bit of time to generate. There's 10 files that need to be created from the videos, then these 10 files combined to create the single file required. A lot of work to get to the point that I could use the data. I’d be happy with either if I didn’t have a choice.

The GPS logger provided the following interesting stats which the GoPro Max doesn't.

Distance = 19.9 km
Duration = 01:14:17 | 01:10:59
Altitude Gap = -6 m
Max Speed = 39 km/h
Avg Speed = 16.1 | 16.9 km/h
Overall Dir = SSW
Track Stats based on: Total time | Time in Movement

Overall, depending on your needs, I feel both the GPS logger app and the GoPro Max produce quite reasonable GPS data. The GoPro Max is more precise, but getting at and using the data from the GoPro Max is far more time consuming. For my needs which is to produce a route shown on a map, as long as you don't zoom in too far, both are sufficient.

Kelvin Eldridge
www.OnlineConnections.com.au

How to check it port 25 for outgoing email is blocked.

One of my clients is having troubles connecting to their email server when they move from work to home. This is often assumed to be the ISP is blocking outgoing email from using port 25 but I decided to work out how to check if the port 25 for outgoing email is actually blocked.

Often I'll write up instructions but I found the following article was sufficient for my needs.

How to Check if Port 25 is Blocked - HostDime Knowledge Base

The following are the basic steps in case the article is no longer available in future.

Open a CMD window (type cmd and press Enter in the search area)
Type telnet and press Enter (if telnet is installed you'll start Telnet. Type q to exit)

If Telnet is not installed type the following in the cmd window.

Type pkgmgr /iu:”TelnetClient” and press Enter

Now to check if your port 25 is not blocked type the following using your SMTP details for your mail server. The SMTP details have the format smtp.yourdomain or mail.yourdomain.

Type telnet smtp.yourdomain and press Enter (where your domain includes the .com.au or .com)

You will either get a connection which starts with 220, or you'll get a connection error message of some sought.

If connected to quit communication with the mail server type QUIT and press Enter. Then to exit Telnet type q and press Enter.

Hopefully this information will help others do some basic testing.

Kelvin Eldridge
www.OnlineConnections.com.au

Update: 17 August 2021
I'm not a fan of leaving features turned on in Windows 10 so I decided to work out how to turn the Telnet client off. This is done as follows.
Click Windows Start
Click Settings
Select Apps
Select Programs and Features (top right of screen)
Select Turn Windows features on or off (to l of screen eft)
Locate Telnet Client and remove tick
Click OK

Having found this option this can also be used to turn the Telnet client on.

Wednesday, August 11, 2021

Census - There is a problem - The Census number or password is incorrect.

Received my first support call from an older family member having issues signing in to do the Census.

When I looked at what they'd entered I realised many people are going to make the same mistake and the form we all receive lacks clarity.

The problem is the number and password have been provided with spaces to make it easier to read the number or password in shorter sections. Much like we break up telephone numbers into groups of numbers to help us remember them.

In this case however when entering the Census number and/or password the spaces have to be left out. There is no information to let people know the spaces shouldn't be entered. A simple oversight on the designers of the Census form but one I'm sure will cause many people a lot of trouble.

Kelvin Eldridge
www.OnlineConnections.com.au

Tuesday, August 3, 2021

Telstra payphone calls within Australian to landlines and mobiles now free.

I must admit I was quite surprised to read today Telstra has made calls within Australian from their payphones free, nada, zip.

Why we're making payphones free for calls around Australia (telstra.com.au)

I often wonder, what is really happening behind such moves. I honestly would love to know but suspect that may never happen.

It is interesting Telstra have said they number of payphones present has halved since the introduction of mobile phones. To me that's interesting because payphones often occupy prime position and are good reminders of Telstra services and in some cases advertising may be a good money spinner so losing half of that presence is something to think about. What if all the payphones went?

Then we have to keep in mind Universal Service Obligations, which Telstra appears to be responsible for and there's a large contract for providing such services.

Universal Service Obligation | Department of Infrastructure, Transport, Regional Development and Communications

Telecommunications contract and grant registers | Department of Infrastructure, Transport, Regional Development and Communications

From these documents we can see the Universal Service Obligations for payphones is $44 million per year over 20 years which is $880 million. 

There's 15,000 payphones across Australia so each payphone we could say is worth $2,933 per annum.

There's around 11 million calls a year so each call is effectively costing tax payers around $4 plus up until now, the cost the person paid for the call.

The payphones, if I recall correctly, now help Telstra provide Wi-Fi access (Telstra Air)  to their many users and those users pay for their Telstra services.

Whatever Telstra's reasons for making payphones free to use, I for one think it is a good thing. At least we know if you're stuck and need to call someone (you've lost your mobile, battery is flat, etc.) you now have an option. Of course still have to remember the number you want to call and that may not be as easy as you think!

One aspect that I also felt was interesting is SMS is free. Now there's something I didn't know. I never knew it was possible to send SMS messages from a payphone. I must check out a payphone next time I'm passing one.

Kelvin Eldridge
www.OnlineConnections.com.au