Show Posts
Pages: [1] 2 3 ... 31
1  Using Arduino / General Electronics / Re: 4-20ma output from Arduino on: September 23, 2014, 07:27:09 am
I think you misunderstand what I was getting at.
I don't want to to accept a 4-20ma input from a 4-20ms sensor into the arduino.
I want to use the arduino to simulate a 4-20ma sensor. e.g.

- Connect a microphone to the arduino and output a 4-20 output according to the volume.
or
- Connect a colour sensor to the arduino and output a 4-20 output according to the proportion of red light.
2  Using Arduino / Motors, Mechanics, and Power / Re: DC motor on: September 23, 2014, 07:09:31 am
An easier way is to open the Arduino IDE and under the "Tools" menu click on "Serial port".
This will list the available serial ports that you can then use in Putty.
3  Using Arduino / Project Guidance / Re: Amp options for remote apps on: September 23, 2014, 07:02:24 am
Post the circuit for the lm324 that you have been using (without success) so we can give some advice on resurrecting that.
4  Using Arduino / Project Guidance / Re: Amp options for remote apps on: September 17, 2014, 02:13:36 am
You can put a refernce voltage into the AREF pin of your Arduino using a voltage divider (trimpot?).

Set the reference referring to this page.

http://arduino.cc/en/Reference/AnalogReference

With such low values you may need to look at some filtering for noise.
5  Using Arduino / Programming Questions / Re: SIM900 programming problems, help needed on: September 13, 2014, 08:52:31 pm
looks like I have to learn  how to use string and find words inside a string to give a command.
Got any good sites?


You will see in the my example code a couple of posts back that I used the strtok() function to do just this.

Have a look at the example and look up the command using google.
6  Using Arduino / Networking, Protocols, and Devices / Re: Arduino and GPS - GSM module on: September 13, 2014, 07:53:03 pm
Have a look at the Simcom SIM908 module (and other models/makes) to see if it suits your providers frequencies.
It (and others) have the GPS integrated into the SMS/phone module at no apparent cost penalty and simplifies your code and connections to your Arduino.
7  Using Arduino / Motors, Mechanics, and Power / Re: controlling DC motor forward on: September 13, 2014, 07:42:08 pm
To send keystrokes in the serial monitor in the IDE you need to click the "Send" button.

You  should try another terminal program like the freeware "Putty" which sends the keystrokes  without you having to press enter or "Send". Just check that the typematic capability keeps sending chars when you hold a key on the keyboard. You will need to constantly check the incoming chars in your sketch to determine when the key is released.
8  Using Arduino / Microcontrollers / Re: Can an Arduino UNO output variable a voltage? on: September 13, 2014, 07:27:50 pm
By using a RC combination you will get a voltage drop across the resistor thereby not getting an accurate input into the LM3914.

What would the effect be of just using the capacitor and no resistor in this application?
9  Using Arduino / Programming Questions / Re: SIM900 programming problems, help needed on: August 19, 2014, 07:29:21 am
Here's a routine that I use to store the sms string from the 900 and break it up into its constituent parts. The message ends up in global vairable called "pumpcommand".  I connect to the 900 at 9600 baud so you may have to adjust the delays (to avoid buffer overflow) as you use 19200. I use  software serial to output debug messages.

Code:
boolean CheckSMS()
{
  SS1.println("CheckSMS"); 
  int BufferLength = 80;
  char InBuffer[BufferLength];
  InBuffer[0] = '\0'; 
  while(Serial.available() > 0) Serial.read(); 
  char temp;
  int i = 0;
  Serial.print("AT+CMGR=1\r"); 
  unsigned long startTime = millis();
  while(Serial.available() < 10 && ((millis() - startTime ) < 500)); 
  while(Serial.available() > 0 && i < BufferLength)
  {
    temp = Serial.read();
    //SS1.print(temp);   
    if(temp != 0x0A && temp != 0x22)
    {
      if(temp == 0x0D)
      {
        InBuffer[i++] = ',';
      }
      else
      {
        InBuffer[i++] = temp;
      }       
    }
    delay(1);
  }
  InBuffer[i] = '\0'; 
  SS1.print("InBuffer: ");
  SS1.println(InBuffer);
  if(strcmp(InBuffer, ",+CMS ERROR: 321") == 0)
  {
    SS1.println("No Messages");
  }
  else if (strlen(InBuffer) < 40)
  {
    SS1.println("No Messages");
  }
  else if(InBuffer[0]==',' && strlen(InBuffer) > 40)
  {
    Command = strtok(InBuffer, delimiters);   
    PhoneNo = strtok(NULL, delimiters);   
    Date = strtok(NULL, delimiters);
    Time = strtok(NULL, delimiters);
    Sundry = strtok(NULL, delimiters);
    Text = strtok(NULL, delimiters);
    Status = strtok(NULL, delimiters);
    SS1.print("Command/Status: ");
    SS1.println(Command);   
    SS1.print("Phone No.: ");
    SS1.println(PhoneNo);   
    SS1.print("Date: ");
    SS1.println(Date);
    SS1.print("Time: ");
    SS1.println(Time);   
    SS1.print("Sundry: ");
    SS1.println(Sundry);
    SS1.print("Text: ");
    SS1.println(Text);
    SS1.print("Status: ");
    SS1.println(Status);
    SS1.print("Deleting Message..");
    Serial.print("AT+CMGD=1\r");   //("AT+CMGD=1,4"); // delete all SMS
    delay(500);
    SS1.println("Done!");
    if(strlen(Text) < 8) strcpy(PumpCommand, Text);
    strcpy(Sender, PhoneNo);
    while(Serial.available() > 0) Serial.read();     // getting rid of "OK" to deletion   
    return true;
  }
  return false;
}
10  Using Arduino / General Electronics / Re: N-power Mosfet pc fan control. on: August 05, 2014, 12:51:14 am
I think that diode is meant to be a schottky diode. The schotty and zener symbols are a bit similar. The symbol in the diagram in the OP is not strictly a zenner or schottky symbol but is probably meant to be schottky (without the little 'hooks') as the zenner will let the current past.
11  Using Arduino / Programming Questions / Re: Trying to get single button to start / stop a show - non-blocking on: July 14, 2014, 06:58:25 pm
The point that I was trying to make was not the variable names (even though I "corrected" their spelling in my example) but rather the ShowStarted!==showStated is an evaluation type statement. As such it should have something like "if(ShowStarted!==showStated)...." wrapped around it.

However, I had assumed that you made the mistake of using "=="  instead of "=" for the assertion of the value of one variable to another. Right or wrong, that was the point I was making. 
12  Using Arduino / General Electronics / Re: 4-20ma output from Arduino on: July 13, 2014, 06:18:35 pm
Accidently revisited this thread and saw thats its still alive.

but the author (as always on a forum) never gives the thumps up for what he/she did, that actually works.

I put it in the too hard basket and delayed the project, but I am now looking to revive it.
I have done a lot of Googling since and am leaning towards a simple  op-amp/transistor setup. Like the diagram below, but using an analogue pin and smoothing cap instead of the zenner to provide the input voltage.

I will prototype it in the coming days and  will make up my mind then.
13  Using Arduino / Programming Questions / Re: Trying to get single button to start / stop a show - non-blocking on: July 12, 2014, 07:36:47 pm
Quote
ShowStarted !== showStated

Is that meant to read "ShowStarted != ShowStarted" ?
14  Using Arduino / General Electronics / Re: 230V hakko FX-888D? on: July 12, 2014, 07:30:18 pm
Quote
..most cannot ship to me, or the shipping costs are stupid.

Buy the iron from the link above (https://www.sparkfun.com/products/11704) and it will cost $100 US with shipping to NZ of $42.60 economy or $56.60 expedited. Chuck in the transformer that I listed above (from NZ distributor) at $20. Total cost around $170.
Not bad for a quality iron. Sure its not as cheap as if we lived in US but you know that we have to pay more for living around this side of the world.
15  Using Arduino / General Electronics / Re: 230V hakko FX-888D? on: July 12, 2014, 04:48:06 am
Quote
Can anyone recommend where I should buy from.

For the Hako try

http://www.adafruit.com/products/1204

For the power coverter try Jaycar

http://www.jaycar.co.nz/productResults.asp?w=power+converter&keyform=KEYWORD&SUBMIT=Search

Scroll half way down the page.

OR

http://www.wallcann.com.au/100w-240v-to-120v-stepdown-voltage-converter.html?___store=default

It seems very cheap but is made in Australia and therefore has to comply with Aus safety standards (probably similar to NZ).
Says at the bottom of page " Servicing online and through outlets in Australia, New Zealand, USA and Canada."
Pages: [1] 2 3 ... 31