Hello, I'm developing a Simplenote port for Tizen, that allows me to read Simplenote notes on my Gear S2.
I'm using Simperium.js to download notes from Simplenote, and this library use sockJS.js to work.
The application works great, and can download notes from Simplenote database... but only when Gear is connected via wifi.
If I disconnect gear from wifi and use my phone data plan (or phone wifi) using BT connection, the program is unable to download data. I've got another app that download data using a simple XMLHttpRequest sentence, and that program works well.
Something like
var xmlhttp = new XMLHttpRequest(),
datos,
XML_ADDRESS = "http://*********",
XML_METHOD = "GET";
xmlhttp.open(XML_METHOD, XML_ADDRESS, false);
xmlhttp.onreadystatechange = function() {
if (xmlhttp.readyState === 4 && xmlhttp.status === 200) {
datos = xmlhttp.responseText;
document.getElementById("tags").innerHTML = datos;
xmlhttp = null;
} else {
console.log("Error"); } };
xmlhttp.send();
But when I use this:
var api = new Simperium('chalk-bump-f49', {token : 'fffffff'});
var bucket = api.bucket('note');
localStorage.clear();
bucket.on('notify', function(id, object) {
BLABLABLA
Nothing works over BT. What I'm doing wrong? Any idea?
Thanks in advance.