Problems with distance calculation

If I set these coordinates to OSM Routing I get all data including distances. As per the link below:

https://map.project-osrm.org/?z=17&center=45.652850%2C13.781325&loc=45.654233%2C13.787443&loc=45.661534%2C13.771603&hl=en&alt=0&srv=0

If, on the other hand, I insert it on the site to obtain the corresponding json instead, the data is all zero, as in the link below.

http://router.project-osrm.org/route/v1/driving/45.654233,13.787443;45.661534,13.771603

Am I doing something wrong?

I also tried to decrease the precision but I always get the same result.

You’ve mixed up lat and lon in your direct request.

This is what you want:

https://router.project-osrm.org/route/v1/driving/13.787443,45.654233;13.771603,45.661534

2 Likes

Ah ok… :man_facepalming:

Thank you very much indeed

2 Likes