file_3665.txtPlain text
Code from
/* IRsendScout: adds "ir.send(p,c,b)" scout script command
 * Version 1.5 June 2014
 * Copyright 2014 by Chris Young
 * Based upon "Bootstrap.ino" by the Pinoccio team
 * Parameters are from protocol number 0-7, Up to 32 bit data,
 *  and number of bits for the protocols that required.
 * You must use 3 parameters therefore number of bits 
 * should be 0 if not needed. 
#include <SPI.h>
#include <Wire.h>
#include <Scout.h>
#include <GS.h>
#include <bitlash.h>
#include <lwm.h>
#include <js0n.h>

#include "version.h"

#include <IRLib.h> //Add IRLib library

IRsend My_Sender; //Create a sending object

numvar irSend (void) {
  unsigned char protocol = getarg(1);
  unsigned long code     = getarg(2);
  unsigned char bits     = getarg(3);
  Led.setColor(255,0,0);      //just to confirm it works, turn on red LED
  My_Sender.send((IRTYPES)protocol,code,bits); //Send it
  Led.turnOff();              //turn it off

void setup() {
  addBitlashFunction("ir.send", (bitlash_function)irSend);

void loop() {


Chris Young

Are you Chris Young? Claim this project and add it to your profile.

This is mine
Posted by Tmp image 0?auto=compress%2cformat&w=40&h=40&fit=min Alex Glow


Did you replicate this project? Share it!

I made one

Love this project? Think it could be improved? Tell us what you think!

Give feedback


Similar projects you might like

DHT22 Sensor and Pinoccio
  • 1,623
  • 5

Full instructions

Using DHT22 Temperature and Humidity sensor with Pinoccio

Mesh Your Brain
  • 3,550
  • 22

Full instructions

Build your own Internet of Brains with this wireless EEG hack!

Human Presence Detection & Visualization
  • 1,071
  • 9

Full instructions

Team Cogitate's social radar displays people nearby as a set of glowing orbs

Hideous Arc Reactor Sweater (WIP)
  • 845
  • 7

Work in progress

Power through the holiday slump with this festive, EEG-reactive sweater!

Pinoccio Craft
  • 378
  • 5

Full instructions

Send Bitlash Pinoccio Commands through Minecraft.

Solar Powered Pinoccio Scout
  • 1,105
  • 9

Run your wireless mesh forever with Adafruit's solar LiPo charger

Add projectSign up / Login