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
| function serializeForm(form) { | |
| form = document.getElementById(form) || document.forms[0]; | |
| var elems = form.elements; | |
| var serialized = [], i, len = elems.length, str=''; | |
| for(i = 0; i < len; i += 1) { | |
| var element = elems[i]; | |
| var type = element.type; | |
| var name = element.name; |
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
| // formToJSON: Encapsula el formulario en un objeto JSOM | |
| // params: un objeto DOM o vacio para el primer formulario del documento | |
| // return: un objeto JSON con el contenido del formulario | |
| function formToJSON( form ) { | |
| form = document.querySelector( form ) || document.forms[0]; | |
| var elems = form.elements; | |
| var i, len = elems.length; | |
| var jsonForm = {}; | |
| for( i = 0 ; i < len ; i++ ) { |
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 express = require('express'); | |
| var app = express(); | |
| var http = require('http').Server(app); | |
| var io = require('socket.io')(http); | |
| var serialport = require("serialport"); | |
| var SerialPort = serialport.SerialPort; | |
| // Constantes | |
| // el valor SERIALPORT varia puedes usar como referencia el puerto |
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
| <!DOCTYPE html> | |
| <html> | |
| <head> | |
| <title>Conociendo el DOM</title> | |
| <style> | |
| body{ | |
| color: red; | |
| } |
#ESP8266 Firmware Update ##SDK V0.9.4 19.12.2014 + AT v0.20
Iddar Olivares para The Inventor’s House
Gracias a nuestros amigos de rusos del sitio esp8266.ru nos enteramos que junto con la ultima version del SDK de Espressif para el ESP8266 nos encontramos un nuevo firmware AT el cual incluye como característica mas notable la posibilidad de cambiar la velocidad de transmisión de modulo serial gracias al comando AT+IPR.
Entes de poder disfrutar de esta novedad debemos flashear la nueva versión del firmware AT, en esta ocasión utilizaremos la herramienta esptool.py de Fredrik Ahlberg (@themadinventor) para poder cargar las imágenes a nuestro modulo.
###Dependencias
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 addon = require('./build/Release/hello'); | |
| console.log("hola " + addon.hello()); // Salida: 'Hola noders' |
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
| /^([A-Z,Ñ,&]{3,4}([0-9]{2})(0[1-9]|1[0-2])(0[1-9]|1[0-9]|2[0-9]|3[0-1])[A-Z|\d]{3})$/ |
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
| (function ($) { | |
| // Name: sendGoogleForm | |
| // params: | |
| // url: url to GoogleForm.php file | |
| // ej: 'path/otherFolder/GoogleForm.php' | |
| // callback: object content tow functions | |
| // ej: {error: function(){...}, success: function(){...}} | |
| $.fn.sendGoogleForm = function(url, callback) { | |
| this.submit(function(event){ | |
| event.preventDefault(); |
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
| * { | |
| font-size: 12pt; | |
| font-family: monospace; | |
| font-weight: normal; | |
| font-style: normal; | |
| text-decoration: none; | |
| color: black; | |
| cursor: default; | |
| } |