Show Posts
Pages: [1] 2 3
1  Using Arduino / Programming Questions / (SOLVED) how to turn an output on, and keep on till other event (time related) on: January 27, 2014, 06:10:22 am
Hi PaulS

Thanks for the help,, always forget to look at the reverse way,,
2  Using Arduino / Programming Questions / Re: how to turn an output on, and keep on till other event (time related) on: January 27, 2014, 05:58:32 am
Hi PaulS

Like

 look at my Alarm 0 time , then if not match time turn on light

then  look at Alarm 1 time , then if not match time turn off light.

3  Using Arduino / Programming Questions / Re: how to turn an output on, and keep on till other event (time related) on: January 27, 2014, 12:39:28 am
hope code is attached now
4  Using Arduino / Programming Questions / Re: Programming issues with a model rocket ejection timer on: January 26, 2014, 09:13:51 pm
Hi George

Thought about using one on these, even sample code


http://www.adafruit.com/products/1603
5  Using Arduino / Programming Questions / Re: how to turn an output on, and keep on till other event (time related) on: January 26, 2014, 09:02:37 pm
sw is attached
6  Using Arduino / Programming Questions / (SOLVED) how to turn an output on, and keep on till other event (time related) on: January 26, 2014, 08:10:46 pm
Hello All,,

Can anyone help ?

I have an alarm clock , that when the alarm time is same as clock time will hold an output high only as long as the time and alarm time match (one minute).then returns to off / low.

Can any one explain the best way to keep the output pin high (latch it on)keep it on(after tripped on by alarm 1 ), till another event (  alarm 2 ) will turn it off and keep it off till the first alarm will turn it back on again..

in a nut shell... alarm 1 will turn lights on and alarm 2 will turn them off..

PS..have  tried                 main time >=alarm time      ,      main time ==alarm time    (still only hold for one minute)

Help appreciated.. this is my hobby..not much experience..



Here is the code by Eric Ayars

File attached..

I want to use it to turn pet Snake lights on / off , and i/R light on/off


  
7  Using Arduino / General Electronics / Re: Hall Effect Sensor A3144 with Arduino on: December 27, 2013, 08:55:22 pm
Quote
And it is not the code I know since I also measured the voltage at the output pin, and I even hooked up an LED directly to the output pin and ground, and the output voltage just stays stuck at HIGH.  I think the sensor is bad, but I had like 3 sensors and I tried all of them, and all behaved the same.  Maybe a bad batch.

Following your idea of changing sensors to test hardware, changing software is also a good way to test.  Whenever possible, try a sketch provided by the hardware manufacturer or the distributor (Sparkfun, Adafruit, etc.). Otherwise, extract enough code from a working sketch to try using the sensor differently.

Maybes a bad batch.  I seriously doubt this.

Ray
  HI ... Had a quick look at the hall effect data sheet, said min operation voltage is 4.5v . could your power supply be low ?
8  Using Arduino / Programming Questions / turn a pin on with trigger 1 and turn off with trigger 2 ( time related) on: August 31, 2013, 11:05:16 pm
Hello All

Thanks for any suggestions in advance.

My question is .. from my cut of code below which is how I have been checking the alarms have been triggered ... What would be the best way to  get AlarmHour 1 & AlarmMinute 1 to turn on a output and keep it on till AlarmHour 2 & AlarmMinute 2 comes around and turns it off. of course will stay off till AlarmHour 1 & AlarmMinute 1 turns it on again.


Code:
if ((AlarmHour[1]==Hour) && (AlarmMinute[1]==Minute)) {
  Serial.println ("alarm 1 is rininging"),delay(250);
}
else
{
  Serial.println (" Alarm 1 is off"),delay(250);

  if ((AlarmHour[2]==Hour) && (AlarmMinute[2]==Minute)) {
    Serial.println ("alarm 2 is rininging"),delay(250);
  }
  else
  {
    Serial.println (" Alarm 2 is off"),delay(250);

    if ((AlarmHour[3]==Hour) && (AlarmMinute[3]==Minute)) {
      Serial.println ("alarm 3 is rininging"),delay(250);
    }
    else
    {
      Serial.println (" Alarm 3 is off"),delay(250);


      if ((AlarmHour[4]==Hour) && (AlarmMinute[4]==Minute)) {
        Serial.println ("alarm 4 is rininging"),delay(250);
      }
      else
      {
        Serial.println (" Alarm 4 is off"),delay(250);




      }

    }
  }
}

9  Using Arduino / Project Guidance / Re: Linear Actuator, Servo, ESC, Leonardo on: April 14, 2013, 06:27:02 am
Want a simple way of adjusting actuator stroke... just add a motor run time,, eg if runs for 5 seconds will be 75% of stroke .

PS an easy way to control the actuator is with two relays , one to swap polarity over ( move in or out) the other to turn the power on/off to the actuator.

PS.... a little tip,, to make the actuator stop quicker, when you turn the power off , short out the actuator terminals , this acts like a break..

all the best
10  Using Arduino / Project Guidance / freetronics lcd + ds3232 rtc on: April 14, 2013, 06:15:05 am
hello all, I have looked for a sample of code  using the freetronics lcd ( button for a menu type) for clock setting (rtc ds3232), but can not find any ..

can any one point me in the direction ? I should be heading , I have the RTC working, and reading/ setting via serial monitor, but would like to have the clock on the lcd, and adjust via the buttons... Any hints

Thanks...in advance
11  Using Arduino / Programming Questions / Re: Connect Arduino with Bluetooth JY-MCU and Andoid on: December 28, 2012, 05:04:15 am
Hello , I am using my nextus 7 tablet and both blueterm and bluetooth spp both work. I have included my sw below that will show what you send on a lcd so you can see what you do send ....

Code:
Quote


#include <SoftwareSerial.h>

#include <LiquidCrystal.h>

LiquidCrystal lcd(8, 9, 4, 5, 6, 7);

SoftwareSerial mySerial(3, 2); // RX, TX
#define text
#define text=myserial

void setup() 
{
  
   // set up the LCD's number of columns and rows:
  lcd.begin(16, 2);//added
 // Open serial communications and wait for port to open:
  Serial.begin(115200);
   while (!Serial) {
    ; // wait for serial port to connect. Needed for Leonardo only
  }

  mySerial.begin(115200);
  mySerial.println("test comms");
  delay(500);
}

void loop()
{

  if (Serial.available())
  delay(100);
    mySerial.write(Serial.read());
    delay(500);
    lcd.clear();
     if (mySerial.available())
    lcd.write(mySerial.read());
       }
  



12  Using Arduino / Programming Questions / Re: how to get lcd to show soft serial received text ? on: December 28, 2012, 05:00:05 am
Thanks Karma,,,, I needed to add a delay also so could see the display..
Cheers.
13  Using Arduino / Programming Questions / how to get lcd to show soft serial received text ? on: December 27, 2012, 07:36:43 am
Hello All ,programming is not my strength ( electronics is)... I would like to display what i have coming out of my soft serial port so i can see on the lcd... I have been able to type into serial monitor and shows on lcd, but how to show what is coming out of soft serial seems to avoid me...

I want to make a small device that i can send a command ( text or number to my Bluetooth on the uno and be able to check what it receives on the lcd, works ok at present i can monitor on the serial monitor , just want to add lcd so was portable.... My code below ( I bet it is something very easy I am just missing) ?

Code:
Quote


#include <SoftwareSerial.h>

#include <LiquidCrystal.h>

LiquidCrystal lcd(8, 9, 4, 5, 6, 7);

SoftwareSerial mySerial(3, 2); // RX, TX
#define text
#define text=myserial

void setup() 
{

  // set up the LCD's number of columns and rows:
  lcd.begin(16, 2);//added
  // Open serial communications and wait for port to open:
  Serial.begin(115200);
  while (!Serial) {
    ; // wait for serial port to connect. Needed for Leonardo only
  }

  mySerial.begin(115200);
  mySerial.println("test comms");
}

void loop()
{
  if (mySerial.available())
    Serial.write(mySerial.read());
  if (Serial.available())
    mySerial.write(Serial.read());
  delay(100);
  lcd.clear();
  lcd.print("need to see what bluetooth received ");// this is where i would like to send soft serial so i can see it on the lcd ???
}


14  Using Arduino / Programming Questions / Re: Connect Arduino with Bluetooth JY-MCU and Andoid on: December 27, 2012, 07:05:17 am
Hello.

I am doing some thing like this, I have been able to send comms to the blue tooth and monitor via the serial monitor. I use the Blue term in google apps (free).

I am using soft serial for another serial port to Rx / Tx  for the blue tooth unit.. as I am using the original hw version to monitor the comms on the pc.

you can use the  soft serial example included in the library.

WARNING..... the unit you wish to purchase only runs of 3.3v....check the max voltage for your tx/rx pins..as most that run off 3.3 will only take 3.3v serial signals, any higher will damage them..( uno will put out 5V).

15  Topics / Home Automation and Networked Objects / bluetooth to xbee on one uno ? ? ? on: November 17, 2012, 07:42:35 pm
hello all... this may be a strange question and may be simple to answer... just call me a new be.
May question is can you have a bluetooth modual talking to your phone and an xbee then talking to somthing else..

I am thinking of talking to the bluetooth modual to turn someting of... intern the bluetooth modual send a code to the xbee wich then talks to another xbee and turn the thing of, and then send a return code yes i am off.

can it be done as should be able but the serial comms may be a problem.. any suguestions ?
 smiley-mr-green




Pages: [1] 2 3