Show Posts
Pages: [1] 2 3 ... 5
1  Using Arduino / Project Guidance / My first real project, atmega/arduino based on: November 21, 2011, 05:11:52 pm
Hi

I have startet my small project until my Uno arrives :-)
The project is to learn some basics:
PCB/schematic program, like Eagle or DesignSpark
Manufacture a PCB, using either toner transfer or UV Circuit board
What parts is needed, and how they work, transistors, mosfets, relays and power supply unit
Interface with 12 volt parts
Programming it

So here is what i want it to do:
Turn on either the foglight, or lowbeam when you unlock the car( Leaving home light)
The same function, when the engine is off and the car door is opened( Coming home light)
Turn on the foglight in fx left side, when you blink left and the speed is under a certain treshold( Cornering light)
Have 1 or 2 optional outputs, to relays or similar, so when you lock your car twice with under 3 sec between, it triggers this output, can be used for parking heater control, sun roof or trunk opening.


Here is the PCB i have begun to design:
http://zeecue.dk/pcb.pcb
It is designed with DesignSpark.

What i need help with:
Selecting/making a power supply, with as low as possible standby current, so it dont drain the car battery
Selecting the right parts for the outputs, one 12v car bulb is 55 watt, so the parts need to hande this
Checking my PCB for errors and such
2  Using Arduino / LEDs and Multiplexing / Re: How to wire up a TLC5916 led driver chip on: July 06, 2011, 09:43:45 am
Okay, weird i got it working with one chip without doing that.
But you where right, it did solve my problems by setting it to LOW, send data, HIGH and then LOW again, thanks again :-D
3  Using Arduino / Project Guidance / Re: Mood lamp/clock with some gimmics on: July 04, 2011, 03:35:23 pm
First part of this moodlamp is done, figuring out how to use the TLC5916 chips.
So now i wanna make something with LCD, but what LCD should i look for? it needs to be easy to read at night, i allready have a cheap 16x2 LCD, but its viewing angle is like 15 degress.
And it should be big enough to incorporate a simple menu system.
4  Using Arduino / LEDs and Multiplexing / Re: How to wire up a TLC5916 led driver chip on: July 04, 2011, 01:53:14 pm
Okay, well when i only have that one TLC connected it works just fine without the output enable part.
But when i have 2, they both blink the same way, and i have tried to incorporate the OE pins.
The TLC chips, share ground, MOSI, CLK and 5v, they have individual wires to the SS and OE and current limiting resistor.
I must be doing some newbie errors :-)
Code:
#include "SPI.h"
int ss=11; // using digital pin 10 for SPI slave select
int ss2=10; // using digital pin 10 for SPI slave select - 2
int oe=7; // output enable
int oe2=6; // output enable - 2

void setup()
{
  pinMode(ss, OUTPUT); // we use this for SS pin
  pinMode(ss2, OUTPUT); // use use this for SS pin - 2
  pinMode(oe, OUTPUT);
  pinMode(oe2, OUTPUT);
  SPI.begin(); // wake up the SPI bus.
  SPI.setBitOrder(LSBFIRST);
  }

void setBLUE(int Bluevalue)
{
  digitalWrite(oe, HIGH);
  digitalWrite(ss, LOW);
  SPI.transfer(0); // send command byte
  SPI.transfer(Bluevalue); // send value (0~255)
  digitalWrite(ss, HIGH);
  digitalWrite(oe, LOW);
}
 
  void setRED(int Redvalue)
{
  digitalWrite(oe2, HIGH);
  digitalWrite(ss2, LOW);
  SPI.transfer(0); // send command byte
  SPI.transfer(Redvalue); // send value (0~255)
  digitalWrite(ss2, HIGH);
  digitalWrite(oe2, LOW);
}

void loop()
{
      setBLUE(255); // Turn all 8 leds on
      delay(500);
      setBLUE(0); // Turn all 8 leds off
      setRED(255); // Turn all 8 leds on
      delay(500);
      setRED(0); // Turn all 8 leds off
      delay(500);
     
     
     
}
5  Using Arduino / LEDs and Multiplexing / Re: How to wire up a TLC5916 led driver chip on: July 04, 2011, 12:40:24 pm
Well i only need the OE/Output enable pin, if i wanna turn off the TLC chip :-D so nothing i wanna mess with right now.
And i figured out how to change the leds now, and i have cleaned up my code a bit.
Thanks alot for helping me on my way :-D its the first time i ever used the SPI.
Code:
#include "SPI.h"
int ss=10; // using digital pin 10 for SPI slave select

void setup()
{
  pinMode(ss, OUTPUT); // we use this for SS pin
  SPI.begin(); // wake up the SPI bus.
  SPI.setBitOrder(LSBFIRST);
  }

void setValue(int value)
{
  digitalWrite(ss, LOW);
  SPI.transfer(0); // send command byte
  SPI.transfer(value); // send value (0~255)
  digitalWrite(ss, HIGH);
}

void loop()
{
      setValue(255); // Turn all 8 leds on 11111111
      delay(1000);
      setValue(170); // Turn 4 leds on 10101010
      delay(1000);
      setValue(147); // Turn 4 leds on 10010011
      delay(1000);
}
6  Using Arduino / LEDs and Multiplexing / Re: How to wire up a TLC5916 led driver chip on: July 04, 2011, 12:16:07 pm
I know, but it didnt really change anything doing so, guess ill have to mess around with it some more :-D
7  Using Arduino / LEDs and Multiplexing / Re: How to wire up a TLC5916 led driver chip on: July 04, 2011, 11:45:03 am
Thank you, i think i understand it now.

I allready knew the R-ext, to change the current.
Next problem is to understand how to send a "command" to the TLC chip, because i cant seem to understand how to do that :-D
Code:
/*
#include "SPI.h" // necessary library
int ss=10;
int oe=11;

void setup()
{
  pinMode(ss, OUTPUT);
  pinMode(oe, OUTPUT);
  SPI.begin(); // wake up the SPI bus.
  SPI.setBitOrder(LSBFIRST);
}

void setValue(int value)
{
  digitalWrite(ss, LOW);
  SPI.transfer(0); // send command byte
  SPI.transfer(value); // send value (0~255)
  digitalWrite(ss, HIGH);
}

void loop()
{
    setValue(1111111);
    delay(1000);
    setValue(00000000);
    delay(1000);
    setValue(00000001);
    delay(1000);
    setValue(00000011);
    delay(1000);
    setValue(11000000);
    delay(1000);
    setValue(10101010);
    delay(1000);
    setValue(1000000);
    delay(1000);
    setValue(1000);
    delay(1000);
}

This code makes the LEDs blink like crazy, but its a crude code, i know, im a beginner.
8  Using Arduino / LEDs and Multiplexing / How to wire up a TLC5916 led driver chip on: July 02, 2011, 05:27:45 am
Hi

Just got me some TLV5916 chips, and im having some hard time to figure out to how to wire it to my arduino megas(actually a seeeduino mega) SPI pins, because the datasheet kinda confuses me, especially the LE(ED1) and OE(ED2) pins on the TLC5916 chip.
This is what i have figured out on my own, please correct me if they are wrong.
Arduino pin - TLC5916 pin
51 MOSI - 2 SDI
52 SCK - 3 CLK
And here is a breadboard drawing and some data over the chip:

And the datasheet if you need that:
http://focus.ti.com/docs/prod/folders/print/tlc5916.html

Best regards
Morten
9  Using Arduino / Project Guidance / Re: Mood lamp/clock with some gimmics on: June 27, 2011, 02:26:38 pm
I've got one of these... http://www.ikea.com/au/en/catalog/products/60096373 and am gonna replace the light inside it with an arduino controlling some RGB LED's with a bluetooth module. I'll probably make a nice varnished wooden box to mount the glass ball on top - a kind of steampunk look. Will then have an app on an android phone to control the colour of the light and have it flash and pulse etc.
The 'animations' will be pre-programmed in the arduino so the android / bluetooth will effectively be an incredibly overengineered remote control :-)
Thats also a thing i might incorporate, im not gonna use RGB leds, but a bunch of white, red, blue, green and yellow ones, lets me have a higher resolution if i wanna make it as a display.
10  Using Arduino / Project Guidance / Re: Mood lamp/clock with some gimmics on: June 27, 2011, 01:56:22 pm
Growler, never did any coding for atmegas in other than the Arduino IDE, and the reason i might "split" it up on multiple MCUs, is that i just got some MSP430s i might wanna incorporate, so i can learn something about them :-D
11  Using Arduino / Project Guidance / Re: Mood lamp/clock with some gimmics on: June 27, 2011, 01:26:58 pm
Thanks for the replys, great ones also  :-)
The clock and the bluetooth parts dont need to be on the same arduino, i guess its easier to make the clock part on one atmega, and then the bluetooth/serial and led controller on another, and just let them communicate over serial or SPI, even a simple high signal on a pin from the clock atmega to the led controller atmega, could let it do its stuff.
The bluetooth module im thinking about using is this
http://www.dealextreme.com/p/wireless-bluetooth-rs232-ttl-transceiver-module-80711 its cheap, the only con about it is its a slave only module, but perfect for this type of thing.
12  Using Arduino / Project Guidance / Mood lamp/clock with some gimmics on: June 27, 2011, 12:55:15 pm
Hi

I have for some time wanted to make a mood lamp(actually thats why i got a arduino), and i have used some code examples of the net and such, but i kinda want a more advanced mood lamp.
What i want it to do is something like this:
Have a clock/alarm, with buzzer, using RTC, thinking a backlit 20*4 screen or some cheap graphics LCD.
Have a bunch of leds, i have some samples of this chip on its way for it TLC5916 - 8-Bit Constant-Current LED Sink Driver, from TI
Have bluetooth capabilities, so i can fx pair it to my android phone and let fx smileys in a recieved sms change how the leds are lit up, maybe even show a smiley on the lamp, or maybe even more advanced, show the text on the LCD.(All these things would need some android programming wich i dont know how to do  smiley-confuse)
Selectable led modes, either using a single button or a menu system on the LCD.

Is this possible to do with a arduino?
13  Forum 2005-2010 (read only) / Troubleshooting / Re: Arduino-0017 trojan detected? on: December 13, 2009, 06:31:58 am
Here is a analysis from Virus total of the dd.exe file:
http://www.virustotal.com/dk/analisis/a36b284459e9cdec84feddd8e08cccda935a56cc4e86ef78c775a9ac64af5645-1228854550

Only 2 programs see it as trojan or virus.

Best Regards
14  Forum 2005-2010 (read only) / Troubleshooting / Re: Windows 7 problems on: December 08, 2009, 12:17:54 pm
I have the newest 0017 to work both on 64 bit and 32 bit Windows 7, without any problems at all.
Even the drivers are 64bit approved/signed, which made me glad, because it can be really hard to install a non signed driver to a 64 bit machine.

Best Regards
15  Forum 2005-2010 (read only) / Scandinavia / Re: Xbee on: March 12, 2010, 12:39:08 pm
Xbee er da kun til trådløs kommunikation mellem andre Xbee enheder.
Iphonen har da kun normal WIFI.
Pages: [1] 2 3 ... 5