Show Posts
Pages: [1] 2
1  Using Arduino / Sensors / IR Question, I need to find IR codes, not read them... on: May 05, 2011, 12:41:21 pm
Hi there, sorry the subject is worded strangely.

Right in my car I have a CD/DVD type radio and it is supposed to come with an IR Remote control. But as it was second hand the remote didn't come with it so my question is that could I hook up an IR emitter to my arduino and run a script to basically make up IR codes and send them via the IR emitter so that I can then use the codes that affect the radio (i.e. volume +/- etc) and then later make a sketch just to emit the codes I have found/need.

So basically... I want my arduino to send out IR codes and when it starts to control my radio (let's say turning the volume up) I then know that that code is used to turn up the volume (which I will use in a later project) the sketch then continues to generate codes and if a code controls something (as before, I'd write it down so that I can use it later)

If that doesn't make sense then I shall try to re-word it but if it does make sense then can you help me out please?

Thanks in advanced.
2  Using Arduino / Networking, Protocols, and Devices / HC-05 Bluetooth problems... on: April 01, 2011, 10:46:10 am
Hi there.

I am having problems with my HC-05 bluetooth module.

If i power it up and connect RX to arduino TX and TX to arduino RX. I can send values and the arduino reads them just fine.

The problem is that I can't get the bluetooth module into command mode so I can set its name and change passcode etc I set the PIO11 (pin number 34) high (to 3.3v) but I cannot then see the virtual bluetooth serial port any more? and it won't open the port?

Is there any way that I could use the arduino to send AT commands to the bluetooth module?

This is the module: http://cgi.ebay.co.uk/Wireless-Bluetooth-Transceiver-Module-RS232-TTL-2-4GHz_W0QQitemZ170610903066QQcategoryZ34165QQcmdZViewItemQQ_trksidZp5197.m7QQ_trkparmsZalgo%3DLVI%26itu%3DUCI%26otn%3D4%26po%3DLVI%26ps%3D63%26clkid%3D8150326821526789705#ht_1494wt_1084

Any help would be really nice.
3  Using Arduino / Motors, Mechanics, and Power / Re: In car power. on: March 24, 2011, 03:37:50 pm
Thanks for the reply.

The arduino isn't running much code to be honest, probably less than 50 lines? And the RF is used for unlocking and locking the doors, as is the bluetooth board so they will be used minimally to be honest. Unfortunately I don't have a multimeter to test how much it's actually drawing, do you reckon it should be okay and I'd be pretty much good to go? I could maybe borrow a multimeter at the weekend to actually check the current draw.
4  Using Arduino / Motors, Mechanics, and Power / In car power. on: March 24, 2011, 02:39:43 pm
Hi everyone.

Right I have my project all set up ...but... I need power, I thought it would be easy but after later calculations its harder than I thought.

Soo 12v in a car isn't usually 12v for very long at all. 14.4v or thereabouts whilst the engine is running and about 8v while the car is starting up etc.

I thought about using an in car charger that outputs 5v but i found out the one I have outputs 700ma which means my car battery would only last about 62 hours (about 2 and a half days).

Could I not use a voltage divider to take the 12v and convert it to 5v? Well something like this:

Vin: 14v | R1: 5KOhm | R2: 3KOhm | Vout: 5.25v = Power dissipated by circuit = 24.5mW (Which works out at about 2mA? Correct?)
Vin: 8v | R1: 5KOhm | R2: 3KOhm | Vout: 3v = Power dissipated by circuit = 8mW (Which works out at about 1mA? Correct?)

^ That info was calculated using Electrodroid for Android smiley-wink

So in this case, would it be okay to use a voltage divider or is it not such a good idea?

I have the arduino, an RF receiver board and a bluetooth board to power (RF board is taking power from an arduino pin thats set High and the bluetooth is using the arduino's 3.3v supply.)

Any help is much appreciated.
Thanks.
5  Using Arduino / General Electronics / Re: Which transistor? on: March 07, 2011, 02:19:12 am
Quick google searched turned up:



So I'd use this setup but with a 1kohm resister between the arduino and the base? And what value would the resisitor be between the output at the collector and +12v be? around 1k again?
6  Using Arduino / General Electronics / Re: Which transistor? on: March 06, 2011, 02:16:53 pm
What I am using the PWM for worked fine connected directly to the arduino using 5v but its supposed to work with 12v so it worked using whatever current the arduino can supply so very minial I believe.
7  Using Arduino / General Electronics / Which transistor? on: March 06, 2011, 02:07:01 pm
Hi everyone, hopefully someone can give me a quick trouble free answer.

I would like to know which transistor I require?

The signal is a pwm pulse of about 300hz from the arduino (244.4hz i think) obviously at 5v. I would like this to be at 12v though?

Can anyone help me? Also how would I wire it up? PWM pulse to Base, and then would it be 12v to collector and the 12v pwm would be output from the emitter?

Thanks.
8  Using Arduino / Project Guidance / Re: If button pressed once...If button pressed twice? on: February 24, 2011, 04:18:21 pm
Removed. - Didn't read your code properly.
9  Using Arduino / Project Guidance / Re: If button pressed once...If button pressed twice? on: February 24, 2011, 03:32:08 pm
at the top of your sketch where your const int variable are add this:

Code:
int buttonstate = 0;
int buttonPresses = 0;

Then let us know what happens.
10  Using Arduino / Programming Questions / Re: Could someone advise on tidying up my code? on: February 24, 2011, 02:11:49 pm
So my code is fine as it stands? If your saying it is thanks for the help  smiley-grin

I will have a read up on interrupts for the next time I need one.

Thanks again.
11  Using Arduino / Project Guidance / Re: If button pressed once...If button pressed twice? on: February 24, 2011, 02:09:02 pm
Could you not just have the button be a set value, say 5 for the 5 seconds you need.

And then wait for say 200 ms after the button has been pressed to see how many times the button has been pressed.

Basically I am trying to say, have the button add 5000 to the delay part of the code so if it pressed twice it would ad 10,000 (10 seconds)

This would also let you have the button be pressed 3 times which would light the led for 15 seconds and so on.

Sorry if this post is totally useless and you don't understand, I could make a sketch if required.

Bert.
12  Using Arduino / Programming Questions / Re: Could someone advise on tidying up my code? on: February 24, 2011, 02:03:53 pm
How would that setup work? With the 4 trigger wires? and the interupt?

I'll be adding a bluetooth module aswell that will receive bytes via serial and these can also print the letters A B C and D to serial.

Just a note: The serial print of A B C and D will be replaced with outputs to relays, I am using print line just to test the code until my relay board arrives.

Thank you.
13  Using Arduino / Programming Questions / Could someone advise on tidying up my code? on: February 24, 2011, 01:33:57 pm
Hi there, could someone please help me. I either need a better way (if there is one) or can my code not be improved?

I have an RF reciever witch operates off of 5v and the switching voltage is also 5v. The switched pins go to my arduino pins 9,10,11 and 12.

I possible I would like to read the pins and then jump to a section if the pin goes high? So the sketch isn't running through every line of code, it is just watching for the pin to go high.

Here is my code:

Code:
int aPin = 12;  // choose the input pin (for a A signal)
int aVal = 0;  // variable for reading the pin status
int bPin = 11;  // choose the input pin (for a B signal)
int bVal = 0;  // variable for reading the pin status
int cPin = 10;  // choose the input pin (for a C signal)
int cVal = 0;  // variable for reading the pin status
int dPin = 9;  // choose the input pin (for a D signal)
int dVal = 0;  // variable for reading the pin status

void setup() {
  Serial.begin(9600);
  pinMode(aPin, INPUT);    // declare input
  pinMode(bPin, INPUT);    // declare input
  pinMode(cPin, INPUT);    // declare input
  pinMode(dPin, INPUT);    // declare input
}

void loop(){
  aVal = digitalRead(aPin);  // read input value
  if (aVal == HIGH) {         // check if the input is HIGH (A)
    Serial.println("A");  // output A
  }
  bVal = digitalRead(bPin);  // read input value
  if (bVal == HIGH) {         // check if the input is HIGH (B)
    Serial.println("B");  // output B
  }
  cVal = digitalRead(cPin);  // read input value
  if (cVal == HIGH) {         // check if the input is HIGH (C)
    Serial.println("C");  // output C
  }
  dVal = digitalRead(dPin);  // read input value
  if (dVal == HIGH) {         // check if the input is HIGH (D)
    Serial.println("D");  // output D
  }
}


Thanks.
Bert.
14  Using Arduino / General Electronics / Anyone work out whats on here? on: February 08, 2011, 09:57:13 am
Hi there,

I am trying to figure out exactly whats happening on this board?

It is used to generate a frequency at a voltage which is 12v DC I believe but can anyone work out the components?

Yes I know its in B&W, this is the problem.





Thanks in advance smiley-grin
15  Using Arduino / Networking, Protocols, and Devices / Re: RF keyfob linked to arduino? is this possible? on: February 03, 2011, 04:01:00 pm
This is the documentation I have, except that the frequency is RF315A - that's what it sais on the fob anyway.

My application is to basically make a central conveniance system for my car using the arduino because then I can say for example press ubtton C on the fob and the  headlights will come on and stay on for 30 seconds (like coming home lights so you can see your front door) or press C then D in sequence and the boot will open etc.

....or just so I can use my arduino in my car smiley-grin haha.
Pages: [1] 2