Skip to content

Instantly share code, notes, and snippets.

@oscarfonts
Last active February 23, 2017 10:33
Show Gist options
  • Save oscarfonts/5ad801cf830d421e55eb to your computer and use it in GitHub Desktop.
Save oscarfonts/5ad801cf830d421e55eb to your computer and use it in GitHub Desktop.
Sensor Widget Integration Example
<html>
<head>
<title>Sensor Widgets Simple Example</title>
<script src="http://sensors.fonts.cat/js/SensorWidgets.js"></script>
<script>
SensorWidget('compass', {
service: 'http://sensors.portdebarcelona.cat/sos/json',
offering: 'http://sensors.portdebarcelona.cat/def/weather/offerings#1m',
feature: 'http://sensors.portdebarcelona.cat/def/weather/features#02',
property: 'http://sensors.portdebarcelona.cat/def/weather/properties#31',
refresh_interval: 15
}, document.getElementById('widget-container'));
</script>
</head>
<body>
<div id="widget-container"></div>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment