I have a site in html where the purpose was to update a half-second image in half a second with a new one. Same as video surveillance. But I needed to know how to call the function in html for the image to change. It may seem like a very weak question but I'm new to programming.
<!DOCTYPE html>
<html lang="en">
<head>
<title> Cam1 </title>
<meta http-equiv="Content-Language" content="text/html; charset=utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<script>
function GetImage(){
setTimeout(function(){
document.getElementById("img").src = "images/yyy.bmp?t="+Date.now();
},500);
}
</script>
</head>
<body>
<!-- não sei como fazer aqui-->
<img id="img" src="images/yyy.bmp" style="width:304px;height:228px;"/>
</body>
</html>