You are welcome,
I changed it now at my site.. I do a lot of small changes as well.
The sitemap is regenerated as normal and the pinging occurs now at 1 am (as soon as somebody hits the website after 1 am).. and the crawler also reads the sitemap himself as well.
no more excessive pinging now.. several events will be scheduled now at the same time and only one is fired..
I could use your code also but then you still get a ping for each change, all with the same sitemap, but all 24 hours later, and not within the original 5 minutes.