Canada Post Workers May Strike on Monday October 22. See our blog for updates. Consider FedEx as an alternative.

News

September 16, 2016

0 comments

Posted in neopixel, projects


NeoPixel Colour Picker

The lighting in my garage was pretty poor, and since we sell lots of NeoPixels, naturally I had a strip lying around!  So I figured NeoPixel LED's would be an efficient and bright way to light the garage!

The lighting in my garage was pretty poor, and since we sell lots of NeoPixels, naturally I had a strip lying around!  So I figured NeoPixel LED's would be an efficient and bright way to light the garage!

Of course I didn't want just an on / off switch, it would be way more fun to be able to pick colours.  So, I grabbed a set of round tactile buttons, and luckily there were red, green, blue, yellow, and gray.  I decided red, green and blue would control the colour, yellow would be "white", and gray would be off.

To control everything I used a Pro Trinket 5V, which is like an Arduino Mini with more pins and USB.  I  used 5 input pins for the switches and one output pin for the NeoPixel Strip.

The buttons are wired to ground, meaning, when you press the button the switch closes and sends a ground (LOW) signal to the Trinket.  I wrote the code so it constantly loops to see what buttons are pressed.  What's nice about this is that I was able to have it see if more than one button is pressed, so you can make more than just Red, Green and Blue!

Programming the Pro Trinket is easy via a microUSB cable.  More details on programming the Pro Trinket can be found in the Adafruit Learning System.

On my first prototype I used a basic solderless breadboard with some hookup wires, but to really finish it off i used an Adafruit Perma-Proto board.  This was a good choice because i could easily mount it to the wall and wire up all the connections.  

Adafruit has a great tutorial on how to use NeoPixels, so I will not get into much detail on how they work.  The important thing to know is that they need a good amount of power if you are using a bunch of them, so I used a hefty 10 amp 5V power supply to run 150 NeoPixels.  Also pay attention to the guide's suggestions regarding capacitors and resistors to avoid damaging your NeoPixels.

You'll want to make sure you install Adafruit's NeoPixel Library and also set your Arduino IDE up for the Pro Trinket.

See below for my Arduino code.  Basically I just took the Adafruit NeoPixel strandtest code and added some logic for the buttons.  Super simple!  

 

 

#include <Adafruit_NeoPixel.h>

#define PIN 4
#define HIGH 1
#define LOW 0

// Parameter 1 = number of pixels in strip
// Parameter 2 = Arduino pin number (most are valid)
// Parameter 3 = pixel type flags, add together as needed:
// NEO_KHZ800 800 KHz bitstream (most NeoPixel products w/WS2812 LEDs)
// NEO_KHZ400 400 KHz (classic 'v1' (not v2) FLORA pixels, WS2811 drivers)
// NEO_GRB Pixels are wired for GRB bitstream (most NeoPixel products)
// NEO_RGB Pixels are wired for RGB bitstream (v1 FLORA pixels, not v2)
Adafruit_NeoPixel strip = Adafruit_NeoPixel(150, PIN, NEO_GRB + NEO_KHZ800);

// IMPORTANT: To reduce NeoPixel burnout risk, add 1000 uF capacitor across
// pixel power leads, add 300 - 500 Ohm resistor on first pixel's data input
// and minimize distance between Arduino and first pixel. Avoid connecting
// on a live circuit...if you must, connect GND first.

// constants won't change. They're used here to
// set pin numbers:
const int offPin = 10; // the number of the pushbutton pin
const int whitePin = 13;
const int greenPin = 6;
const int redPin = 8;
const int bluePin = 5;

// variables will change:
int offState = 0; // variable for reading the pushbutton status
int whiteState = 0;
int greenState = 0;
int redState = 0;
int blueState = 0;
int pixelSpeed = 10;

void setup() {
strip.begin();
strip.show(); // Initialize all pixels to 'off'
pinMode(offPin, INPUT_PULLUP);
pinMode(whitePin, INPUT_PULLUP);
pinMode(greenPin, INPUT_PULLUP);
pinMode(bluePin, INPUT_PULLUP);
pinMode(redPin, INPUT_PULLUP);
pinMode(13, OUTPUT);
}

void loop() {
// Some example procedures showing how to display to the pixels:
whiteState = digitalRead(whitePin);
offState = digitalRead(offPin);
greenState = digitalRead (greenPin);
blueState = digitalRead (bluePin);
redState = digitalRead (redPin);
if (greenState == LOW | redState == LOW | blueState == LOW) {
colorWipe(strip.Color(255 * (1-redState), 255 * (1-greenState), 255 * (1-blueState)), pixelSpeed); // RGB
}
else if (whiteState == LOW) {
colorWipe(strip.Color(255, 255, 255), pixelSpeed); // WHITE
}
else if (offState == LOW) {
colorWipe(strip.Color(0, 0, 0), pixelSpeed); // WHITE
}
}

// Fill the dots one after the other with a color
void colorWipe(uint32_t c, uint8_t wait) {
for(uint16_t i=0; i<strip.numPixels(); i++) {
strip.setPixelColor(i, c);
strip.show();
delay(wait);
}
}

 

 

September 15, 2016

0 comments

Posted in store news


AdaBox

Are you bummed that Adafruit is not selling AdaBox subscriptions to Canadians?  We are too! 

We are evaluating the possibility of distributing AdaBox in Canada for Adafruit.  Please email us if you are interested in learning more.  

July 14, 2016

0 comments

Posted in


PyCom WiPy Unboxing

We are excited to offer the WiPy and Expansion Board from PyCom!  Today we will do an unboxing and show you how to get the board up and running.

The devices come in very nice reusable packaging.  The boxes are great for storage when the device is not in use.

WiPy Packaging

Next, we power up the device.  If you have the Expansion Board, you can easily power it up via microUSB.  If not, you can power the pins directly with 3.6 to 5.5 VDC by connecting to V_IN and Ground.

Once the device is connected, search for a WiFi network called wipy-wlan.  Connect to this network using www.wipy.io as the password.

Next, connect via Telnet to 192.168.1.1 using login "micro" and password "python".  On most machines, you can telnet from the command line or terminal.  Here is an example from a Mac:

You are now at a MicroPython command prompt!

Let's write our first MicroPython code:

Well that was easy!  

There is a whole lot more we want to do with this board, and you can learn more by reading the WiPy MicroPython documentation.  

If you have any ideas for projects with the WiPy or you have already made something cool, let us know!  We would love to hear about it.

July 05, 2016

0 comments

Posted in


Maker Festival Toronto

We're so excited, and we just can't hide it!

Come see us at Maker Festival Toronto this weekend!  

We are a proud sponsor of the event and cannot wait to meet more of our customers.  We will bring an assortment of Maker Electronics including Raspberry Pi and Arduino kits, and we will have demonstrations of our favourite products.  We will also have the best from Adafruit, SpikenzieLabs, PyCom and more!

The Maker Festival is on July 9 and 10 from 10:00 to 5:00 at the Toronto Reference Library, 789 Yonge Street.

November 01, 2015

0 comments

Posted in store news


Hello

Welcome to our store!  I wanted to share a bit about our vision for Elmwood Electronics.

While we are new to Canada we are not new to the Maker Electronics world.  Our founder, Craig LeMoyne, started Chicago Electronic Distributors in 2013 and the company continues to be very successful.  As we surveyed the Canadian landscape for Maker Electronics, we thought there was an opportunity to offer a wider selection of products from partners like Adafruit.   With the buying power of our US and Canadian affiliates, we are able to offer great prices.

In addition to great prices and a wide selection, we are also experts in Arduino and Raspberry Pi.  We regularly work on special projects for our customers, let us know an we would be happy to provide a quotation.

Thank you for your business!

« Previous 1 7 8 9