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
/* | |
LiquidCrystal Library - Serial Input | |
Demonstrates the use a 16x2 LCD display. The LiquidCrystal | |
library works with all LCD displays that are compatible with the | |
Hitachi HD44780 driver. There are many of them out there, and you | |
can usually tell them by the 16-pin interface. | |
This sketch displays text sent over the serial port | |
(e.g. from the Serial Monitor) on an attached LCD. |
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
song = ""; | |
setInterval(function() { | |
if (song != $('#track-name').find('a').text().replace(/ /g, "~") + '|' + $('#track-artist > a').text().replace(/ /g, "~")) { | |
song = $('#track-name').find('a').text().replace(/ /g, "~") + '|' + $('#track-artist > a').text().replace(/ /g, "~"); | |
$.ajax({ | |
//The URL to process the request | |
'url': 'https://your.webserver/relay.php?m=' + song, | |
'type': 'GET', | |
'success': function(data) { | |
if (data == "success") { |
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
//This app requires the express and serialport libraries for node. You can get them on NPM with: | |
//npm install express | |
//npm install serialport | |
var app = require('express')(); | |
var http = require('http').Server(app); | |
var SerialPort = require("serialport").SerialPort; | |
var serialPort = new SerialPort("COM3", { //change port to your Arduinos port | |
baudrate: 9600, |
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
<?php | |
header('Access-Control-Allow-Origin: *'); | |
// was used when API address moved but apps were live on app store. | |
// create curl resource | |
$ch = curl_init(); | |
error_log($_GET['m']); | |
// set url | |
curl_setopt($ch, CURLOPT_URL, "http://your.node.host:3000/sendmsg?m=" . $_GET['m']); |
NewerOlder