Show Posts
Pages: [1] 2 3
1  Using Arduino / LEDs and Multiplexing / Re: Pcb UV Light Box on: May 08, 2014, 02:27:07 pm
Thanks crossroads for your help, i will make the enclosure with makerbeam, i will put here some fotos with i finish the project:).
2  Using Arduino / LEDs and Multiplexing / Re: Pcb UV Light Box on: May 08, 2014, 05:10:18 am
Thanks CrossRoads,

I will use the P2N2222A Transistor, based in what you told me:

- In the data sheet of P2N2222A i see the Base−Emitter Saturation min Voltage Vbe is 0.6V, so (5-0.6)/.02=220, i will use a 220ohm resistor between arduino output and the base of each transistor.

- This transistor can handle with 600mA between C and E, for 20mA for each Leds, 6 Leds in each string give me the same 20mA because they are in serie in the string, i have 18 string it will be 20mA*18=360mA so i can use only 1 transistor. i will the use 3 transistor to divide better the circuit and also i can drive the 3 parts of Leds separately in the arduino.

3  Using Arduino / LEDs and Multiplexing / Re: Pcb UV Light Box on: May 07, 2014, 05:37:08 pm
Hi CrossRoads,

I take your advice and finally i finishing the circuit in fritzing, i don´t have any experience in PCB design but i´m starting some video tutorials for Eagle software.

Can you take a look please, i´m a little worried about the current in the lines GND and 24V, maybe i need to put this lines bigger...

I see a few switch transistors circuits in internet and all of them have a resistor between the base of the transistor and the arduino, do you think i will needed?

I make the PCB design in two circuit, one for the Leds and the other one for the resistances and transistores (the second one have two layers), in the first stage i will dismiss the red Leds.
4  Using Arduino / LEDs and Multiplexing / Re: Pcb UV Light Box on: May 07, 2014, 02:30:25 am
Hi CrossRoads,
 I will use the Transistor, i have on at home.

I have one doubt +, i understand the part in the transistor is working like a switch but i don´t really understand the calculation, can you explain a little bit or a link with explanation?

I see a fee tutorials in internet where there are using one resistor in the base of the transistor, do you think i will needed?
5  Using Arduino / LEDs and Multiplexing / Re: Pcb UV Light Box on: May 06, 2014, 04:45:00 pm
Ok i make the math:

- the power supply will be 24V
- the Vf for the Led im to buy are between 3.0V and 3.4V, i use 3.4V
- 0.7V for transistor
- 20mA for each Led

With this i have a resistor of 145ohm but i only can use 6 leds in each string

I see arduino Uno can handle with 40mA in I/O Pin, if i have the 20ma into the base of 2n2222A i can use two strings for each Output of my Arduino Uno.

For 96 Leds i will need 16 String and 8 Output in my arduino, i can use the others output for my Red Leds.

What do you think?

if i can increase the power supply i will be able to put more Leds in each string and also decrease the ports i will need in arduino board, i am right?


6  Using Arduino / LEDs and Multiplexing / Re: Pcb UV Light Box on: May 06, 2014, 02:12:31 pm
Hi CrossRoads,

You already help me in the passed and i just want to say thank to always be ready to help newbies like me:)

Your idea is to connect the Leds in parallels? do you think the voltage will increase a lot?
I am also able to use a relay shield with 10A, i have two of them. One the red Leds and other one for the UV Leds.

I have been thinking a little about this project and i decide to change a little:

- Only one side with 100 UV Leds, for the PCB with two side i will do the job in two step
- i think 50 Red Led it´s enough, it´s just to help the alignment of PCB and transparency paper in a dark room.
- i will use a switch to cut off the UV Light in case of opening the box in service.
7  Using Arduino / LEDs and Multiplexing / Pcb UV Light Box on: May 06, 2014, 01:06:50 pm
Hi,

Im planning to make an PCB UV Light Box for pcb fabrication.

I have seen some tutorials in internet and i have an ideia of what i need to do that.

Im thinking about 100 UV led, 50 in each side and another 100 red leds to help with the alignment process.

I have no experience with this amount of leds, if anyone has some experience with this kind of project i will be grateful with your help.

My problem is how to control all this leds (20mA each one)
8  Using Arduino / Networking, Protocols, and Devices / Re: Xbee with arduino pro mini 5v on: May 17, 2012, 09:41:08 am
I know i can use a Voltage Regulator - 3.3V to power the xbee, what i don´t know is if i can use normaly the pin comunucation RX/TX directly?
9  Using Arduino / Networking, Protocols, and Devices / Xbee with arduino pro mini 5v on: May 17, 2012, 02:15:33 am
Hi,

I have one xbee Serie 2 to connect in one arduino pro mini 5v, for this i have one Breakout Board for XBee Module:
http://www.hobbytronics.co.uk/xbee-breakout?keyword=BOB-08276

My problem is the 5V, i know the xbee only accept 3.3V, can i use a voltage regulator between 5v in arduino to vcc in my xbee?can i have problems with RX/TX Pins?

Thansk,
10  Using Arduino / General Electronics / Re: Voltage divider for lipo on: May 13, 2012, 01:47:33 pm
And for possible noise from the esc the best to do is to put one capacitor between analog input and Gnd?what is the diference between resistance like R1=10k and R2=1K with R1=27k and r2=2.7k with same ratio?

thanks,
11  Using Arduino / General Electronics / Voltage divider for lipo on: May 13, 2012, 01:28:24 am
Hi,

I went to read the voltage value of my 2s lipo 7.4V in my arduino, i thinking do this with one voltage divider but don´t know if i use lower resistance like 1Kohm and 10Kohm or resistance with highter values.

I use the lipo to powering the arduino and an Esc from an RC car.

What do you think?
12  Using Arduino / Project Guidance / Re: Trying get RPM Value with IR LED on: May 08, 2012, 09:45:18 am
ok is good but without Cap, with the cap in High speed the QDR don´t detect the blank mark, i don´t know why.

Just a little question, im learning C with Arduino and don´t understand the syntax of this line:
Code:
  int rpm = (copyTime != 0) ? 60000/copyTime : 0;

is an equal with conditions?for what is the "?"
 
13  Using Arduino / Project Guidance / Re: Trying get RPM Value with IR LED on: May 08, 2012, 08:05:35 am
Sorry but what is the functions enable() and disable()? you call the function but don´t appear on your code
14  Using Arduino / Project Guidance / Re: Trying get RPM Value with IR LED on: May 08, 2012, 05:39:46 am
I think have found the solution:
I use the 4.7Kohm resistor and 220ohm, is the best value i have found...
And i make on shunt between pin 2 and A0 to can read the analog value at the same time i use interupt, and i say if i found one interupt, check also the anolog value before count the sample:

Code:
#define PwmPinMotorB 11
#define DirectionPinMotorB 13

unsigned long time[1];
unsigned long timeBetweenRising=0;
int index=0;
int count=0;
int Led=0;
int lastrpm=0;


//---------------------------------------------------------
void setup(){

  Serial.begin(9600);

  pinMode(PwmPinMotorB, OUTPUT);
  pinMode(DirectionPinMotorB, OUTPUT);
  digitalWrite(DirectionPinMotorB, LOW);
  analogWrite(PwmPinMotorB, 255);

  attachInterrupt(0, sample, RISING);

  pinMode(6,OUTPUT);

}

//---------------------------------------------------------
void loop(){




  int rpm=2*60000/(timeBetweenRising);

//If i have a crazy value, replace by last good rpm
if (rpm<0) rpm=lastrpm;
  lastrpm=rpm;
Serial.println(rpm);

delay(500);



}

//---------------------------------------------------------
void sample(){

int valueQDR=analogRead(A0);
if (valueQDR<=600){
    if (Led==0){
      digitalWrite(6,HIGH);
      Led=1;
    }
    else
    {
      digitalWrite(6,LOW);
      Led=0;
    }

    if (count==1){
      index=1;
      time[index]=millis();
      timeBetweenRising=time[1]-time[0]; 
      time[0]=time[1];
    }

    if (count==0){
      time[index]=millis();
      count++;
    }
}

}


now i have good values for high and low speed:

Code:
0
0
1518
1518
1666
1690
1690
1666
1666
1714
1666
1690
1690
1714
1739
1690
1690
1714
1690
1690
1714
1714
1714
1714
1690


Please comment.
15  Using Arduino / Project Guidance / Re: Trying get RPM Value with IR LED on: May 08, 2012, 04:13:01 am
Hi,

Thanks for your reply, i have write a new sketch based on your advice:

Code:
#define PwmPinMotorB 11
#define DirectionPinMotorB 13

unsigned long time[1];
unsigned long timeBetweenRising=0;
int index=0;
int count=0;
int Led=0;



//---------------------------------------------------------
void setup(){

  Serial.begin(9600);

  pinMode(PwmPinMotorB, OUTPUT);
  pinMode(DirectionPinMotorB, OUTPUT);
  digitalWrite(DirectionPinMotorB, LOW);
  analogWrite(PwmPinMotorB, 35);

  attachInterrupt(0, sample, RISING);

  pinMode(6,OUTPUT);

}

//---------------------------------------------------------
void loop(){



  Serial.println(timeBetweenRising);
  double rpm=2.0*60000.0/(timeBetweenRising);
  Serial.println(rpm);

  delay(500);


}

//---------------------------------------------------------
void sample(){



    if (Led==0){
      digitalWrite(6,HIGH);
      Led=1;
    }
    else
    {
      digitalWrite(6,LOW);
      Led=0;
    }

    if (count==1){
      index=1;
      time[index]=millis();
      timeBetweenRising=time[1]-time[0];  
      time[0]=time[1];
    }

    if (count==0){
      time[index]=millis();
      count++;
    }
  

}


I have put one LED to on/off each time the interrupt is On at low speed, i can see the led blink when the QRD pass on blank mark but i think is too sensible because the LED blink inconstant out of blank mark.

i think is because the resistance i use, or can i use on interrupt based in analog Value from QRD?

Edit: If i change the resistor 4.7K for 2.2k i have better results but it´s not enough, in 10 samples i have 2 false:(

if i use the 4.7Kohm in 10 samples i have 5/6 false...
Pages: [1] 2 3