Recent Posts

Pages: [1] 2 3 ... 10
1
Quote
Common base is not so useful with single supply or in DC amplifiers.
Wrong on both counts.
I have only ever used it on a single supply, and I have used in amplifiers that are of DC.

It is used a lot in high frequency amplifiers, however the main use in digital electronics is in logic level conversion ( voltage shift ) from 3V3 to 5V without any signal inversion.
2
Programming Questions / Re: guys i need some helps
Last post by GERhashim - Today at 02:26 pm
i keep my finger 1s something like this but the problem
the lcd show me just 2
if i click on it will be like change and it will back again to 2 .that just a frame then it will be 2
3
Programming Questions / Re: Do functions leak memory i...
Last post by KenF - Today at 02:24 pm
I sure will. But it is better to find the bugs now than later.
You can assume that this bug doesn't exist.
4
Hardware / Pantalla táctil para Arduino M...
Last post by Gertru - Today at 02:23 pm
Buenos días,

He buscado bastante en diferentes sitios por internet y he leído varios foros, pero aun así no he logrado aclararme.

Estoy buscando una pantalla táctil para conectar a mi Arduino Mega 2560 y no consigo decidirme por cuál será la apropiada. Para mi proyecto me gustaría que fuera de un tamaño en torno a las 4" (aprox), y antes de comprarla me gustaría estar 100% seguro de que va a ser compatible con mi Arduino sin necesidad de hacer mil trucos o piruetas para conseguirlo...

¿Podéis por favor orientarme un poco?

Muchas gracias de antemano,
Un saludo
5

I have two simple questions for Arduino Yun board board.

1. I uploaded my program on Arduino Yun board via USB cable. The program on board doesn't starts automatically. My program starts "only" when I connect Serial Monitor to the board.

1a. I wanted to connect my board with external USB Power Supply (5v). I tries this but here also my program does not start.

2.  I have configured WiFi on my board. Is there any external way to know the IP address of the board so that I can use Putty. As of now, router logs is the only way I found.

For 1# - I tried Arduino reset but no luck. I am using simple LED blinking program.

I know these seems to be very silliy questions but I couldn't figure out by myself.

THanks in advance.

Regards,
Nagesh
6
Programming Questions / Re: Project Issue : powering w...
Last post by KenF - Today at 02:22 pm
It's the delays in your action function.  While your action function is running you're not paying attention to any HTML requests.
7
Programming Questions / Re: Do functions leak memory i...
Last post by LMI - Today at 02:21 pm
 
If you have any evidence that it does, you should post it as a bug. 
I sure will. But it is better to find the bugs now than later.
8
Portugues / Re: Enviar comandos via I2C
Last post by bubulindo - Today at 02:20 pm
acho que B nao funciona... mas nao tenho a certeza... se nao me engano, precisas de escrever 0b00010001 se queres definir algo em binario.

x nao e binario e como tal o Arduino nao vai aceitar.
9
Nederlands / Re: Wifi samen met 433 MHZ rec...
Last post by kxiniks - Today at 02:20 pm
Wederom dank voor je uitgebreide antwoord...;-)

hmmm... ik ben toch bang dat ik over moet naar een bekabeld utp shield. Wel jammer want ik heb het wifi shield wel werkend (de test sketch naar adafruit werkt), maar iedere keer als ik een voorbeeld sketch met internetconnectie 'probeer' loop ik vast.

Volgens mij is dit het enige probleem wat ik nog heb. Weet iemand hoe ik een sketch van een utp shield wired moet 'vertalen' naar de cc3000 wifi uitvoering??

Meer concreet, ik wil deze tutorial letterlijk nabouwen, maar dan met een wifi shield ipv een bekabeld shield.

http://randomnerdtutorials.com/arduino-control-220v-lamps-from-anywhere-in-the-world/
10
Software / Re: comunicazione tra 2 arduin...
Last post by rik93 - Today at 02:14 pm
ecco qua lo sketch ..
è abbastanza chiaro.
per qualsiasi cosa chiedetemi e provo a spegarvi..

vi faccio ugualmente un piccolo riassunto:
Rem1=pulsante  che attiva la zona A
Rem2=pulsante  che attiva la zona B
entrambi non si interrompono in automatico e quindi vanno ripremuti (in automatico resetta l'arduino)

Rem3=pulsante  attiva la routin (è la stessa attivata dall'RTC)
Rem4=interruttore  modalità RUN/PAUSE (su pause l'arduino non fa niente, qualsiasi pulsante premuto non va, anche la routin con l'RTC) (su run funziona tutto come la normalità)

il tasto della piscina non l'ho mai collegato ma mi sembra che il comando funzioni


grazie ancora

Code: [Select]
#include <Wire.h>
#include <Time.h>
#include <DS1307RTC.h>
#include <avr/io.h>
#include <avr/wdt.h>

#define Reset_AVR() wdt_enable(WDTO_2S); while(1) {}

int rele[]    = {2, 3, 4, 5};
int igrometro = 6;
int remoto[]  = {11, 9, 12, 10, 8};
int led[]     = {17, 16, 15, 14};
boolean isOn1;
boolean isOn2;
boolean isOn3;
boolean acceso;
tmElements_t tm;
boolean accendiPiscina;
unsigned long timer;


void setup() {
  acceso = true; 
  isOn1 = false;
  isOn2 = false;
  isOn3 = false;
  accendiPiscina = false;
  Serial.begin(9600);
  while (!Serial) ; // wait for serial
 
  tmElements_t tm;

  if (RTC.read(tm)) {
    Serial.print("Ok, Time = ");
    print2digits(tm.Hour);
    Serial.write(':');
    print2digits(tm.Minute);
    Serial.write(':');
    print2digits(tm.Second);
    Serial.print(", Date (D/M/Y) = ");
    Serial.print(tm.Day);
    Serial.write('/');
    Serial.print(tm.Month);
    Serial.write('/');
    Serial.print(tmYearToCalendar(tm.Year));
    Serial.println();
      if (digitalRead(igrometro) == 1)
Serial.print("terreno secco");
  else
Serial.print("terreno umido");
}
 
  for(int i = 0; i < 4; i++) {
    pinMode(rele[i], OUTPUT);
    pinMode(remoto[i], INPUT);
    pinMode(led[i], OUTPUT);
  }
 
  pinMode(igrometro, INPUT);
}

static void rem1()
{
  delay(250);
  if(!isOn1)
  {
isOn2 = false;
    digitalWrite(led[1], LOW);
    digitalWrite(rele[2], HIGH);
    digitalWrite(rele[1], LOW);
    digitalWrite(rele[0], HIGH);
    digitalWrite(led[0], HIGH);
    isOn1 = true;
  } else{
      digitalWrite(rele[2], LOW);
      digitalWrite(rele[0], LOW);
      digitalWrite(led[0], LOW);
      isOn1 = false;
      digitalWrite(led[3], HIGH);
      delay(1000);
      Reset_AVR();
    }
  delay(250);
 
}

static void rem2()
{
  delay(250);
  if(!isOn2)
  {
isOn1 = false;
    digitalWrite(led[0], LOW);
    digitalWrite(rele[2], HIGH);
    digitalWrite(rele[0], LOW);
    digitalWrite(rele[1], HIGH);
    digitalWrite(led[1], HIGH);
    isOn2 = true;
  } else{
      digitalWrite(rele[2], LOW);
      digitalWrite(rele[1], LOW);
      digitalWrite(led[1], LOW);
      isOn2 = false;
      digitalWrite(led[3], HIGH);
      delay(1000);
      Reset_AVR();
    }
  delay(250);
}

static void routine()
{
  delay(100);
  int i;
  boolean controlloOn = false;
  digitalWrite(led[1], LOW);
  digitalWrite(rele[1], LOW);
  digitalWrite(led[2], HIGH);
  digitalWrite(rele[2], HIGH);
 
  for(i = 1; i <= 12 && !controlloOn; i++)
  {
digitalWrite(led[1], LOW);
    digitalWrite(rele[0], HIGH);
digitalWrite(led[0], HIGH);

timer = millis();
    while(!(millis()-timer >= 165000UL))    //durata
{
delay(50);
if(controllo())
{
controlloOn = true;
break;
}
    }
if(!controlloOn){
digitalWrite(led[0], LOW);
digitalWrite(rele[0], LOW);
digitalWrite(rele[1], HIGH);
digitalWrite(led[1], HIGH);
timer = millis();
while(!(millis()-timer >= 165000UL))      //durata
{
delay(50);
if(controllo())
{
controlloOn = true;
break;
}
}
  digitalWrite(rele[1], LOW);
  digitalWrite(led[1], LOW);
 }
  }

  delay(100);
  END: for(int k = 0; k < 3; k++)
  {
digitalWrite(led[k], LOW);
digitalWrite(rele[k], LOW);
  }
  delay(1000);
  if(!controlloOn)
  {
digitalWrite(led[2], HIGH);
delay(500);
digitalWrite(led[2], LOW);
delay(500);
digitalWrite(led[2], HIGH);
delay(500);
digitalWrite(led[2], LOW);
        digitalWrite(led[3], HIGH);
  }
  delay(100);
 
Reset_AVR();}

static boolean controllo()
{
if (premuto(3))
{
delay(100);
for(int i = 0; i < 4; i++)
{
digitalWrite(led[i], LOW);
digitalWrite(rele[i], LOW);
}
acceso = false;
isOn1 = false;
isOn2 = false;
return true;
}
acceso = true;
return false;
}

void loop() {
  controllo();
 
  if (acceso)
  {
if (premuto(0))
rem1();
else
if (premuto(1))
rem2();
else
if (premuto(2))
routine();
else
/*if (premuto(4))
{
accendiPiscina = !accendiPiscina;
if(accendiPiscina)
digitalWrite(led[3], HIGH);
else
digitalWrite(led[3], LOW);
}*/
if (RTC.read(tm))
{
if ((tm.Hour == 21) and (tm.Day%2 != 0) and (digitalRead(igrometro) == HIGH)) routine();  //durata totale routin 66min
if(accendiPiscina) if((tm.Minute == 0) and (tm.Second == 0)) piscina(); // se la routine e' in corso non va
}
  }
}

static void piscina()
{
if(!isOn3)
{
digitalWrite(rele[3], HIGH);
digitalWrite(led[0], HIGH);
digitalWrite(led[1], HIGH);
isOn3 = true;
}
else
{
digitalWrite(rele[3], LOW);
digitalWrite(led[0], LOW);
digitalWrite(led[1], LOW);
isOn3 = false;
}
}

static boolean premuto(int num)
{
for (int i = 0; i < 10; i++)
{
if (digitalRead(remoto[num]) == LOW)
return false;
delay(150);
}
delay(1000);
return true;

}

void print2digits(int number) {
  if (number >= 0 && number < 10) {
    Serial.write('0');
  }
  Serial.print(number);
}
Pages: [1] 2 3 ... 10