Recent Posts

Pages: 1 ... 7 8 [9] 10
81
At first, it looked like the dried grease caused motor to jam.  Or this dry-rotted rubber "thing" connecting the leadscrew to the acme nut - rubber get caught in threads.  Then I found JUNK thrust-bearing, where the leadscrew mounts to the motor, I had to take to my machine shop and baffled my friend on how were were going to take THAT apart without spending an hour or locking it into a vice and pick a section of it to sacrifice.  The thrust bearing definitely is wasted and was like trying to spin two melted pieces of plastic - to give you an idea...

The commutator contacts were tarnished and there is some micro surface grooves.  I have access to a lathe where I can polish the copper contacts to a C3PO grade shine.  I sanitized the whole armature, and re-assembled the motor.  I would not have spent so much time with this, except the construction of the whole thing is impressive.  Unfortunately, the 3 sets of planetary gears reduce the RPM so low, it is unacceptable movement to use for a remote steering control arm.

So - the CAUSE of BRUSH material melting is over current, yes?  If this motor jams, gets hot - it will turn the contacts into a saw and run through the brushes.  Curious, what would happen if I filled in these GROOVES with an epoxy or something, so that brush material CAN NOT get caught between the contacts.
82
Deutsch / Re: Servos + Stromversorgungen...
Last post by HotSystems - Oct 19, 2017, 11:42 pm
Niemand...? :(
Wie ???

Ich vermute, deine Spannung bricht zusammen.

Du solltest di mal mit einem Oszi messen, dann siehst du mehr.

Was für Netzteile verwendest du ?
Zeige doch mal dein Schaltbild.
83
Deutsch / Re: Deckenlampenschaltung
Last post by flexcon - Oct 19, 2017, 11:41 pm
ich habe es geschafft.
im prinzip einfach und es funktioniert.

ich habe auch das beispiel von ardubu probiert anzupassen und aus zu probieren
leider hatte es nicht funktioniert. im nachgang habe ich gesehen das ich beim anpassen fehler gemacht habe.
egal.

ich habe nun eine lösung gefunden und würde sie gerne noch zur verfügung stellen.

Code: [Select]
#include <IRremote.h>

int RECV_PIN = 11;  //ir pin
int dl1=2;        //relais ausgang
int dl2=3;        //relais ausgang

int lampe1=0;     //status
int lampe2=0;     //status

int wtaster1=5;   //Pin 5 eingang für Wandtaster1
int wtaster2=6;   //Pin 6 eingang für Wandtaster2

IRrecv irrecv(RECV_PIN);

decode_results results;

void setup()
{
Serial.begin(115200);

pinMode (dl1, OUTPUT);   //Deckenlampe 1
pinMode (dl2, OUTPUT);   //Deckenlampe 2

pinMode (wtaster1, INPUT);     //wandschalter oben
pinMode (wtaster2, INPUT);     //wandschalter unten

digitalWrite(dl1, LOW);    //Diese soll zunächst aus sein
digitalWrite(dl2, LOW);   //Diese soll zunächst aus sein

irrecv.enableIRIn(); 

}

void loop() {

//IR Abfragen
if (irrecv.decode(&results)) {

Serial.println(results.value, HEX);

if (results.value == 0xf7c03f)
  if (lampe1==1)
  {
    lampe1=0;
  }
  else
  {
    lampe1=1;
  }

if (results.value == 0xf740bf)
  if (lampe2==1)
  {
    lampe2=0;
  }
  else
  {
    lampe2=1;
  }

irrecv.resume();
}
//--------------

//Ausgang Schalten
if (lampe1==1){
  digitalWrite(dl1,HIGH);
}
if (lampe1==0){
  digitalWrite(dl1,LOW);
}
if (lampe2==1){
  digitalWrite(dl2,HIGH);
}
if (lampe2==0){
  digitalWrite(dl2,LOW);
}
//--------------

//Wandtaster abfragen
if (digitalRead(wtaster1) == HIGH)
  if (lampe1==1)
  {
    lampe1=0;
    delay(1000);
  }
  else
  {
    lampe1=1;
    delay(1000);
  }

  if (digitalRead(wtaster2) == HIGH)
  if (lampe2==1)
  {
    lampe2=0;
    delay(1000);
  }
  else
  {
    lampe2=1;
    delay(1000);
  }
}
//--------------


danke trotzdem an alle
84
Software / Re: I2C
Last post by Miky - Oct 19, 2017, 11:39 pm
Non so se funziona per lunghe distanze, però per l'inviare l'array ho fatto così

Master

Code: [Select]

#include <Wire.h>

int array[] = {200, 250, 500, 000, 000, 000};


void setup() {
 
Wire.begin();
Serial.begin(9600);
}
 
  void loop() {
Wire.beginTransmission(3);

    Wire.write(stepsMatrix2,6);
 
   Wire.endTransmission();

 
  }


I valori raggiungono massimo 255 (e devo capire come mandare un valore superiore a 255, se qualcuno lo sa , ascolto volentieri)

per lo slave ho fatto così



Code: [Select]
#include <Wire.h>


void setup() {

Serial.begin(9600);
Wire.begin(3);
Wire.onReceive(ricevi);
}
 
  void loop() {
 
    delay(100);
  }

  void ricevi(){
 while(Wire.available()>0){
    int long a = Wire.read();
    Serial.println(a);
 }

  }
 


così invia e riceve i valori dell'array.

Il mio problema è come inviare i valori di una matrice, se qualcuno sa come fare, ri-ascolto volentirei :) )
85
Deutsch / Re: Funkmodul 433 MHz
Last post by HotSystems - Oct 19, 2017, 11:39 pm
Zum Beispiel beim Empfang den Spreu vom Weizen trennen, Chekcsums berechnen, aus den Empfangene Daten wieder ein Neutzsignal berechnen. Währendessen kann er nichts anderes sinnvolles machen, da er ein striktes Timing einhalten muss.
Auch da langweilt sich mein Atmega. ;)
86
Programming Questions / Re: trying to get common anode...
Last post by khashurst - Oct 19, 2017, 11:38 pm
gfvalvo...Bingo

Thank you...does the reason have something to do with LED being common anode rather than common cathode? 255 is 0 and 0 is 255.
87
Software / Re: I2C
Last post by enrico24 - Oct 19, 2017, 11:32 pm
Grazie uwefed.

Ero convinto che arrivasse fino a ca. 200 mt! Errore mio.

Dovrei trasferire da un Uno a 2 Mega delle semplici istruzioni. Ho provato lo nRF24l01 con risultati troppo incerti.

Cosa mi consiglieresti di utilizzare? La distanza lineare che dovrei raggiungere è di ca. 100 mt, in linea d'aria ca. 70 mt. (scusa in anticipo se non sono passato nella sezione Hardware)

Saluti.
88
Project Guidance / Re: Automated water level cont...
Last post by Boardburner2 - Oct 19, 2017, 11:30 pm
Hi,
I was wondering if it would be possible to make automated water level controller with water level sensor and Arduino UNO.
I was thinking to make Ardunio UNO to turno on motor (water pump) when water level is low, and to open valve
Quite easy to do.

If this is a tank then all you need is a couple of cheap float sensors.

Knowing the absolute level of the water is not needed normally.

Do you neeed to control the head (water pressure ) or usage ?
89
Français / Re: Problème de transmission n...
Last post by kedoeweth - Oct 19, 2017, 11:29 pm
oui je chope un 100 nano demain au taff, pour torsader, je fait une tresse avec tous les cables ? pas un par un
90
Hi guys. :(

In my company we get information from electric meters with modbus protocol on Kepware OPC Server. Some devices do not have this protocol. So i think  we can use arduino for these situations.

By now I can get analog values from device. I have to send these values to Kepware Opc Server.

In our system we are using RS485 cables for get information from devices and end of the line we have TCP/ IP Converter to switch.

I m using RS485 TTL Convertor.

When I use below code other devices on this line can't read from OPC server and so my system with arduino is crushed.

My code is:


#include <modbus.h>
#include <modbusDevice.h>
#include <modbusRegBank.h>
#include <modbusSlave.h>

/* PINS
Add more registers if needed
Digital input pins 2,3,4,5,6,7
Digital output pins 8,9,12,13
Analog output pins 10,11 (PWM)
Analog input pins 0,1,2,3,4,5
*/


modbusDevice regBank;
modbusSlave slave;

int AI0,AI1,AI2,AI3,AI4,AI5;


void setup()
{  
 regBank.setId(1); ///Set Slave ID

//Add Digital Input registers
 regBank.add(10002);
 regBank.add(10003);
 regBank.add(10004);
 regBank.add(10005);
 regBank.add(10006);
 regBank.add(10007);
// Add Digital Output registers
 regBank.add(8);
 regBank.add(9);
 regBank.add(12);
 regBank.add(13);
//Analog input registers
 regBank.add(30001);
 regBank.add(30002);
 regBank.add(30003);
 regBank.add(30004);
 regBank.add(30005);
 regBank.add(30006);
//Analog Output registers
 regBank.add(40010);  
 regBank.add(40011);  

 slave._device = &regBank;  
 slave.setBaud(9600);  
 
 pinMode(2,INPUT);
 pinMode(3,INPUT);
 pinMode(4,INPUT);
 pinMode(5,INPUT);
 pinMode(6,INPUT);
 pinMode(7,INPUT);
 pinMode(8,OUTPUT);
 pinMode(9,OUTPUT);
 pinMode(12,OUTPUT);
 pinMode(13,OUTPUT);
 
}
void loop(){

 while(1){  
 //Digital Input
   byte DI2 = digitalRead(2);
   if (DI2 >= 1)regBank.set(10002,1);
   if (DI2 <= 0)regBank.set(10002,0);
   byte DI3 = digitalRead(3);
   if (DI3 >= 1)regBank.set(10003,1);
   if (DI3 <= 0)regBank.set(10003,0);
   byte DI4 = digitalRead(4);
   if (DI4 >= 1)regBank.set(10004,1);
   if (DI4 <= 0)regBank.set(10004,0);
   byte DI5 = digitalRead(5);
   if (DI5 >= 1)regBank.set(10005,1);
   if (DI5 <= 0)regBank.set(10005,0);
   byte DI6 = digitalRead(6);
   if (DI6 >= 1)regBank.set(10006,1);
   if (DI6 <= 0)regBank.set(10006,0);
   byte DI7 = digitalRead(7);
   if (DI7 >= 1)regBank.set(10007,1);
   if (DI7 <= 0)regBank.set(10007,0);
                               
 //Digital output
   int DO8 = regBank.get(8);
     if (DO8 <= 0 && digitalRead(8) == HIGH)digitalWrite(8,LOW);
     if (DO8 >= 1 && digitalRead(8) == LOW)digitalWrite(8,HIGH);
   int DO9 = regBank.get(9);
     if (DO9 <= 0 && digitalRead(9) == HIGH)digitalWrite(9,LOW);
     if (DO9 >= 1 && digitalRead(9) == LOW)digitalWrite(9,HIGH);
   int DO12 = regBank.get(12);
     if (DO12 <= 0 && digitalRead(12) == HIGH)digitalWrite(12,LOW);
     if (DO12 >= 1 && digitalRead(12) == LOW)digitalWrite(12,HIGH);
   int DO13 = regBank.get(13);
     if (DO13 <= 0 && digitalRead(13) == HIGH)digitalWrite(13,LOW);
     if (DO13 >= 1 && digitalRead(13) == LOW)digitalWrite(13,HIGH);
           
 //Analog input  ***READ Twice deliberately
   AI0 = analogRead(0);
   delay(10);
   AI0 = analogRead(0);
   regBank.set(30001, (word) AI0);
   delay(10);
   
   AI1 = analogRead(1);
   delay(10);
   AI1 = analogRead(1);
   regBank.set(30002, (word) AI1);
   delay(10);
   
   AI2 = analogRead(2);
   delay(10);
   AI2 = analogRead(2);
   regBank.set(30003, (word) AI2);
   delay(10);
   
   AI3 = analogRead(3);
   delay(10);
   AI3 = analogRead(3);
   regBank.set(30004, (word) AI3);
   delay(10);
   
   AI4 = analogRead(4);
   delay(10);
   AI4 = analogRead(4);
   regBank.set(30005, (word) AI4);
   delay(10);
   
   AI5 = analogRead(5);
   delay(10);
   AI5 = analogRead(5);
   regBank.set(30006, (word) AI5);
   delay(10);
       
 //Analog output
   word AO10 = regBank.get(40010);
   analogWrite(10,AO10);
   delay(10);
   word AO11 = regBank.get(40011);
   analogWrite(11,AO11);
   delay(10);
       
 slave.run();  
 }
}



I try to read slave code. What ı have do wrong. If u have code for this job, Please help me, I m newbie. :(

Pages: 1 ... 7 8 [9] 10