Web application for traffic road using open street map

Hello,
I’m working to develop a web application for road traffic…
In fact, I’m thinking to use open street map…
But I don’t have any knowledge about it…
I want to know how to create a car that circule randomly on it ?
and how to extract a specific part of the map on xml format and deploy it
Thanks