Comments (1)
Aah, I found the "generic-TCP"-server script. I can use this to upload to my local server or external just editing to fit my needs. Once again, nice work!
if UBIDOTS == 1:
try:
dbgprint(repr(addr) + ' - sending to ubidots')
import urllib2
outdata = {
'tilt' : angle,
'temperature' : temperature,
'battery' : battery,
'gravity' : gravity
}
out = json.dumps(outdata)
dbgprint(repr(addr) + ' - sending: ' + out)
url = 'http://things.ubidots.com/api/v1.6/devices/' + spindle_name + '?token=' + UBI_TOKEN
req = urllib2.Request(url)
req.add_header('Content-Type', 'application/json')
req.add_header('User-Agent', spindle_name)
response = urllib2.urlopen(req, out)
dbgprint(repr(addr) + ' - received: ' + str(response))
except Exception as e:
dbgprint(repr(addr) + ' Ubidots Error: ' + str(e))
from ispindel.
Related Issues (20)
- iSpindel HOT 2
- Doc link do not exist: https://www.ispindel.de/docs/tools/TestServer/Readme.md HOT 4
- Is it possible to reduce the accuracy of "battery" and keep 2-3 digits after the decimal point? HOT 10
- Wemos V4 HOT 10
- Proposition: Have a project able to route the messages HOT 3
- Discussion: What about using a ispindel github org (e.g.: https://github.com/ispindel, ...) ? HOT 5
- Issue with Ubidots API HOT 3
- Create new release :tada: HOT 3
- Firmware 7.2.0 identifies itself as 7.1.4 HOT 2
- History of tilt entity in HA not shown as line graph HOT 5
- Same issue as Issue #571 - Issue with Ubidots API HOT 2
- HTTP404 when clicking "Delete WiFi configuration and reboot" /r HOT 7
- Wrong tilt value HOT 4
- Holder for the PCB card in the container HOT 15
- Changes in ArduinoJson broke Sender.cpp HOT 1
- MQTT topic to force iSpindel in configuration (AP) mode? HOT 6
- Exception (28) on plain modules HOT 2
- SSL support for MQTT HOT 2
- Biradefteri HOT 1
- If gyro sensor is mounted inverted, the offset calibration does something that makes the unit not read less than 60 degrees when orientated vertically HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ispindel.