1st Arduino Project

Ask and answer questions, share tips and resources for installing lighting and other electronics in your models.

Moderators: Sparky, Moderators

Post Reply
User avatar
rossjr
Posts: 3280
Joined: Mon Jul 15, 2002 10:33 am
Location: Minneapolis, MN - Grandkids are Great!

1st Arduino Project

Post by rossjr »

I am working on the Mobieus Galactica and want to find some way to do the landing lights in the bay, so I turned to Arduino for the circuitry

http://www.youtube.com/watch?v=YoFC6kuO ... QP7SDsf2Gs

Now I just need to figure out how to minaturize this with Surface Mount LED's like you see on the board. The make a board that is about 1/4 the size. The sketch for this is really simple... Here is the sketch if you are into that...

// Example 01: Blinking LED

const int LED = 13; // LED connected to digital pin 13
const int LED2 = 12; // LED connected to digital pin 12
const int LED3 = 11; // LED connected to digital pin 11

void setup()
{
pinMode(LED, OUTPUT); // sets the digital pin as output
pinMode(LED2, OUTPUT); // sets the digital pin as output
pinMode(LED3, OUTPUT); // sets the digital pin as output
}

void loop()
{
digitalWrite(LED, HIGH); // turns LED on
delay(250); // waits for a second
digitalWrite(LED, LOW); // turns LED off
delay(125); // waits for a second
digitalWrite(LED2, HIGH); // turns LED on
delay(250); // waits for a second
digitalWrite(LED2, LOW); // turns LED off
delay(125); // waits for a second
digitalWrite(LED3, HIGH); // turns LED on
delay(250); // waits for a second
digitalWrite(LED3, LOW); // turns LED off
delay(250); // waits for a second
}
User avatar
Underlord
Posts: 220
Joined: Mon Jan 28, 2008 3:49 pm
Location: Connecticut, USA
Contact:

Post by Underlord »

I plan on using Arduino mini and Arduino nano boards for inside the models. if you're going with fiber and want to use surface mount LEDs, you might look into an Arduino *EDIT* LiteWing (was light shield) *EDIT* wired to a nano. Nano and mini boards can be had for between $10 and $18 depending on where you search outside of the "official" Arduino Italian boards. I've seen light shields for around $6-10, but they are a bit harder to find.

I'm glad to see others using the Arduino for lighting projects. I've prototyped a Star Trek Federation blinker with bluetooth remote control, and I just started a robot beer retriever project with a friend. Fun stuff!
Your mileage may vary, void where prohibited, if it lasts more than 4 hours, see a doctor. All prosecutors will be violated. Only fools are certain. Substantial penalty for early withdrawal. The best advice I ever received was "Don't take anyone's advice. Listen to what everyone says, then make up your own damned mind."
Madman Lighting
Posts: 1816
Joined: Sat Mar 05, 2005 9:16 am
Location: Serenity.
Contact:

Post by Madman Lighting »

Hey John,

Neat little project there. Damn, I remember my first little micro project, it was with an MIT HandyBoard (I never went to MIT). I got it because a couple of guys had greenboards of the unit made and someone else got all the parts into a big kit. Then I soldered it all together myself. I had that sucker driving around my apt on a little LEGO robot, tweaking the ferrets.

Ah, fun days!
That Madman Who Lit Up Deep Space Nine
User avatar
opal_1970
Posts: 57
Joined: Mon Oct 31, 2011 4:17 pm

Post by opal_1970 »

I am also doing a Galactica (the TOS version) and I have the Arduino but I did not want to put an Arduino in the model... seemed to me like a little overkill, I am exporting the code to a couple microcontrollers. the Atmel ATtiny85 is about the size of your fingertip, costs about 2 cents and has 5 output pins, the Atmel Attiny2313 has 7 outputs. and if you want to control a whole bucketload of LEDs then the Texas Instrament TLC5940 (about $1) is the only way to go, it is the same size as the ATmega328 chip mounted on the Arduino and has 16 Output pins and can be daisychained to other TLC5940s to get a max of something over 200 output pins.

The whole process is acually very easy.

check out my thread over at theRPF for more details and links. It took me a while to get everything up and running, mainly due to my own stupidity, :) but it works excellent and really reduces the needed space and also the costs... the best part is you can keep your Arduino to use on the next project.
-------------------------------------------
"I honor those who have gone where I have yet to go, who have seen what I have yet to see; for they are the true pioneers. May your journey be an adventure." -- Nomad farewell to the dead


Current build: TOS Galactica (Take 2)
Post Reply