This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var fileSystemModule = require("file-system"); | |
var fileName = "persistedFile.json"; | |
var file = fileSystemModule.knownFolders.documents().getFile(fileName); | |
var data = [{"id": "1", "value": "NativeScript"}, ...]; | |
// write data to the file, converted to a JSON string first | |
file.writeText(JSON.stringify(data)); | |
// read data from the file |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* TypeScript definition file for the Movilizer.js file needed for Movilizer HTML5 views. | |
* The documentation in this file has been adapted from the documentation in the original Movilizer.js file, | |
* presumably written by Jesus de Mula Cano. | |
* | |
* @author Arjan Boschman | |
*/ | |
/** | |
* This declares the global variable movilizer of type Movilizer. The class Movilizer is declared below. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import requests | |
import schedule | |
import time | |
import RPi.GPIO as GPIO | |
HTTP_PREFIX = 'http://' | |
BRIDGE_IP = '192.168.178.101' | |
API_PREFIX = '/api' | |
USERNAME = 'x-M0aZsE-oQVjKTpmv8EfbUKXcIW7S8kTXvX3Mlb' | |
GROUPS = '/groups' |