Show Posts
Pages: 1 ... 46 47 [48] 49 50 ... 86
706  Using Arduino / Installation & Troubleshooting / 022 uploads, but 1.0 fails on: June 16, 2012, 02:12:47 pm
Hi,

I can upload to my Arduino if I use the 022 version, but not when using the 1.0 (or 1.0.1) version. It comes back with a sync fail.

This is true for several Arduiono boards and on my two machines which us Win-XP and Win7(64) respectivly. So it isnt something simple like I forgot to plug it in smiley

As this works for thousands of other users there is something strange about my setup. I have both 022 and 1.0 (and now even 1.0.1) installed. I noticed the preferences file is the same - my settings are "transfered" between the versions. I have tried with a fresh preferences (delete the current one, it generates a new one)

Any clues where else to look?
707  International / Scandinavia / Re: Arduino + ethernet sende alarm ved indgang on: June 14, 2012, 04:55:11 pm
så ville jeg gerne have en computer til at stå et sted, som kunne opsamle de data, og sende en mail ved strømudfald.
Du har selvfølgeligt tænkt på at computeren kræver strøm ved dette strømudfald ... og det også gælder dine internet router, Arduinoen osv.

Du skal bare skaffe dig en Arduino med Ethernet f.eks. http://store.arduino.cc/eu/index.php?main_page=product_info&cPath=11&products_id=142

Nogle ting kan være nemmere end du tror:  Hvis det bare er en "enkel mail" så er mail protocollen tilpas enkel at Arduinoen kunne sende den selv (hvis alle detaljer er fast kodede i programmet, som navn, adresse, SMTP server m.m.)

Principerne i det du vil er nemme nok (hvis vi har forstået dig ret) - men detaljerne er besværlige. F.eks. de præcise måde Arduinoen kan se at det er HPFI der er faldet ud, og ikke bare en sikring er sprunget ...

Jeg har ikke set en færdig opskrift, men hvad har du fundet af del løsninger? Hvad mener du med "el tavlen har Ethernet"?
708  Using Arduino / Project Guidance / Re: Controlling a Thermoelectric heater/chiller for environmental chamber on: June 13, 2012, 02:55:10 pm
Why not just simply try it ?

The point of a temperature regulation is that you dont need to know the Watt/cm2/time/mm-glass whatever, it will hold the desired temperature (unless the unit is not big enough ... but again, the experiment will show it)

Written by someone who has forgotton all those heavy equations from collage a lifetime earlier....
709  Using Arduino / Project Guidance / Re: Controlling a Thermoelectric heater/chiller for environmental chamber on: June 12, 2012, 02:43:46 pm
The syntax is the if-then-else
Code:
if ( 06 < hour && hour <= 12 )
      { dosetpointstuff(75) }
else if ( 12 < hour && hour <= 18 )
      { dosetpointstuff(82) }
...  continue with above two lines for other intervals
else // no need to test for "remaining" hours in day
      { dosetpointstuff(48) }
 
Note that I use the "<=" on one of the tests. In your code, the code does not know what to do when the time is exactly 1200

Secondly, I usually rearrange the test so the value is visually between the boundaries ( X < value && value < Y )
710  Using Arduino / Project Guidance / Re: 7 inch led touchscreen on: June 10, 2012, 02:11:34 pm
I'd hazard a guess that 7" is more expensive as the main reason others use smaller displays - or the project has a size limit.

If the chip is the same, there should be no reason why more/fewer inches make any difference. Have you looked at the pixel count? The Arduino has to generate the pixels somehow, and it requiures some trickery with handling/expanding simple shapes to manage that with the RMA in the Arduino. If the 7" has many more pixels...
711  Using Arduino / Project Guidance / Re: Controlling a Thermoelectric heater/chiller for environmental chamber on: June 10, 2012, 01:59:19 pm
$70 H-bridge?!  It is only 8 Amp

As you do not need to switch quickly, I would use simple (cheap) relays. One relay to switch on/off and one to turn the current around (DPDT). Now your Arduino just needs a simple thermo device (choice are wide and varied, depends on how accurate you need to keep the temperature) and perhaps a RTC (realTimeClock) too so it konws the time of day even after a power glitch. (Otherwise it can just count seconds)

(NB: I am not a vivarium/aquarium owner at all)
712  Using Arduino / Motors, Mechanics, and Power / Re: Stepper motors and drivers problem on: June 07, 2012, 10:59:28 am
OK, here is some very simple code I have recently used to drive two steppers at the same time. I do not use any library, prefering to drive them directly. One is a Dir/Step type driver, the other a full H-bridge. The idea here is the StepCoil runs continuously (the MoveSteppers() is called as often) determined by "Slowdown", and the StepWireRatio() calls the other stepper (the one using dir/step) so I get the right kind of diagonal movement.
Code:
void MoveSteppers() {
 analogWrite(CoilPWM,45);
 if ( micros()/100-Timer > Slowdown ) {
    Timer=micros()/100 ;
    StepCoil() ;
    StepWireRatio() ;
  }
}

void StepWireRatio() { // Step according to ratio and respect limits
  TFC_Ratio += TFC_Ratio_Nom ;
  if ( TFC_Ratio > TFC_Ratio_Den ) {
    TFC_Ratio -= TFC_Ratio_Den ;
    if (TFC<TFC_Left) TFC_Dir=HIGH ;
    if (TFC>TFC_Right) TFC_Dir=LOW ;
    StepWire() ;
  }
}

void StepWire() { //step always
  digitalWrite(WireDir,TFC_Dir); // adjust direction as needed
  delayMicroseconds(50);
  digitalWrite(WireStp,(TFC%2>0)?HIGH:LOW) ;  // Step the Wire motor
  TFC = (TFC_Dir==HIGH)?TFC+1:TFC-1 ;
  CursorGoto(3,12);
  if (TFC_Dir==HIGH)
    Serial.print(TFC-TFC_Left);
  else
    Serial.print(TFC_Right-TFC) ;
  Kolon();
  Serial.print((TFC-TFC_Left)*100/(TFC_Right-TFC_Left));
  Serial.print(TFC_Dir==LOW?" <":" >");Space(3);
}

void StepCoil() {
  // Change to next Coil state
  TurnState++ ; CursorGoto(2,13);
    Serial.print(TurnState/CoilTickTurn);
    Kolon();
    Serial.print((TurnState%CoilTickTurn)*100/CoilTickTurn);
    Space(2);
  switch (TurnState%4) {
    case 0:    // 1010
      digitalWrite(Coil_A, HIGH);
      digitalWrite(Coil_B, LOW);
      digitalWrite(Coil_C, HIGH);
      digitalWrite(Coil_D, LOW);
      break;
    case 1:    // 0110
      digitalWrite(Coil_A, LOW);
      digitalWrite(Coil_B, HIGH);
      digitalWrite(Coil_C, HIGH);
      digitalWrite(Coil_D, LOW);
      break;
    case 2:    //0101
      digitalWrite(Coil_A, LOW);
      digitalWrite(Coil_B, HIGH);
      digitalWrite(Coil_C, LOW);
      digitalWrite(Coil_D, HIGH);
      break;
    case 3:    //1001
      digitalWrite(Coil_A, HIGH);
      digitalWrite(Coil_B, LOW);
      digitalWrite(Coil_C, LOW);
      digitalWrite(Coil_D, HIGH);
    }
}
You Milage may vary. No Garantees smiley
713  Using Arduino / Motors, Mechanics, and Power / Re: Stepper motors and drivers problem on: June 06, 2012, 05:56:15 pm
Try entering "57BYGH115-003 " in your google search. That usually gets you several web pages where the specfications (voltage, amperes etc ) are shown.

In your Arduino IDE try the menu File - Examples - Stepper - One revolution. There is the code fo one stepper. You only need to replicate the line defining the Stepper varaible (with a new name) and one call to each steper variable's move at different speeds. I also suggest you Google for "Arduino Stepper nonblocking " to run them simlultaneously.

Running at max speed depends on the load, and a bit of tweaking the (software) acceleration and driver current "curves" (if the DQ-542MA supports that)
714  Using Arduino / Programming Questions / Re: PC Keyboard on: June 06, 2012, 05:21:43 pm
Your code seems to use the numeric keypad as a simple joystik operation. You should look at the switch ( n )  case construct, it is more fitting for this type of code.

Servos stop on their own. Your code tells the "lijevi"servo to move to position "85" when you push "2". If you hold "2" down, it will receive this command repeatedly, and not move (after the first move has completed). If you mean for it to keep moving away from "90" as long as you hold "2", then you must do something linke
servo_lijevi.write(servoe_lijevi.read()-5) which will move it another 5 degrees for as long as you send "2" from the keyboard.

If the servos are continous, then your code will set the servo speed to "85" (a slow move in one direction) and keep doing that for every "2" (it is already moving, so additional "2"s have no effect, like before). BUT letting go of "2" will keep not stop it (as it remembers the last write). In your loop you should do an "else" to act on (Serial.available is not >0) and send the servo_x.write(nn) that makes it stop.

Another hint: If you hold a key on a pc keyboard for a few seconds, it will send many "2"-characters very quickly, which ar buffered in the Arduino input buffer, so even if you let go, it may still have lots more movement to go.

The English is OK smiley-wink
715  Community / Bar Sport / Re: The How Long Post on: June 06, 2012, 05:01:08 pm
Three projects that were collaborative with others had a definte delivery deadline - they took "all the time that was available". If we started the project and it was 2 weeks to "showtime" we spent 1.999 weeks on it, calender time. The amount of man hours .. dont want to think about that .. but the usual exponential curve with hours/day as dead line approached. These projects have been between 1 week and 1 month.

My other projects seem to get stuck at the 85% or 95% complete - usually a case of finish the coverbox, or make it a little more sturdy for moving about, or replacing the glue with proper screws. The small projects take 3 days - but two projects are in eternal POC, tweak and redesign now for the 2nd year.

So to answer the OP - any number between 2 to 2000 hours.

Tips for reducing time? Let me ask a contra-question: Why? It is my hobby, I do it for enjoyment, why shorten it? OK, producing more finished project to show off to friends and family would be nice, too. ( Hmmmm-- food for thought. )
716  Development / Other Software Development / Re: #include documentation on: June 04, 2012, 06:53:17 pm
The documentation on http://arduino.cc/it/Reference/Include is rather sparse.
Yep.

Doing multifile programs in the Arduino IDE is not easy - despite the fact that it is good programming practice. On the other hand, most Arduino projects are only 50 or 200 lines. For a single project getting to big, just write several .PDE/.INO files, and have them in the same sketchbook folder. When you compile the IDE will compile them as one file. (The IDE also "cheats", compared to pure "C" - it rearranges the functions so they are defined before being called - thus the order of the PDE files is irrelevant). No need to use .h

I have found that you must have a subfolder called LIbraries in your Arduino sketch folder, and in there you can have folders wich contain a .h and .cpp files. This is a proper library. The IDE looks both in this "user-library" folder and in the system library folder (and I think also in a subfolder to the compiler). As far as I know it makes no difference if you use " or <>

717  Community / Bar Sport / Re: Congratulations to the Latest Two Members to the 10K Club! on: June 04, 2012, 06:17:50 pm
Congrats!

(This post got me another tiny step closer to achieving the same smiley-wink smiley-wink )
718  Community / Bar Sport / Re: Your latest purchase on: June 04, 2012, 06:08:57 pm
Bought a 3D print at Shapeways.com - just a tiny test shape. The picture shows the same shape done on the now rather old MendelRepRap at the club, and another done on a friends Ultramaker. You may guess which is which smiley Price info:
500$ machine
20¢2000$ machine
10$ plus shipping50000(?)$ machine
719  Using Arduino / LEDs and Multiplexing / Re: general question: NxM RGB LED matrix with PWM on: May 23, 2012, 03:10:21 pm
Why is everyone using additional hardware like shift registers od led control ics?
Shiftregisters: Because there are not enough pins on the Arduino. LED control:For good LED control you want constant current. (More reasons below)

M Digital IO pins for the cathodes (my case 10) and N*3 PWM pins  (my case 9)
I can not see any obvious flaws in that argument. Remember that you still need a transistor/FET on all (your case, 19) lines - the  microcontroller can NOT give enough current. Worst case the top transistor/FET needs to cope with 10 LEDs (about 0.5 A, maybe 1 A depending on your LEDs) the bottom transsitor likewise.

As far as i have read one scans the whole matrix row by row (M=10). Inside the active row one scans again over all leds (N*3). What scan times can i expect from an arduino mega 2560 and how do i calculate it?
Each LED can at most only be ON a 10th of the time, when you scan the rows. You can then parallel control your 9 column lines. Or the other way round. You define the scan rate, as fast as possible to avoid flicker, ie 100Hz+. The standard PWM runs at 400Hz, so you may get odd "beats" between your scan rate and the PWM. An LED ic will do the PWM at a higher rate, and you can tweak the Arduino core likewise.

To get the LED to seem bright enough, when the scanning limits it to a 10th ON, you can overdrive it so the "average" is within specs. The circuits get a little tricky, you dont want the overdrive to happen if the program stops and one row remains lit ... so the LED ics are nice.
720  International / Scandinavia / Re: arduino uno alarm on: May 21, 2012, 04:32:16 pm
Velkommen til!

Når du læser lidt af de andre indlæg, så kan du se at du er nødt til at fortælle lidt mere end kun "nemt og hurtigt alarm".

Hvad er den "nemme" del : Konstruktion? Kredsløbet? Softwaren? Brugen af det?

Men begynd med at fortælle
1) Hvad det er du overvåger (temperatur, vandniveau, antal fodtrin på et følsomt område)
2) hvordan du måler det (eller har tænkt at måle det, sensor type)
3) Hvad alarmen består af (blink, lyd, mail, SMS ...)
Og måske hvorfor du mener du behøver en Arduino involveret (kompliceret niveau/antal sensor input, kompliceret alarm (sende en SMS))

(Istedet for en lang beskrivelse kan du attache en tegning, muligvis en indscannet en)
Pages: 1 ... 46 47 [48] 49 50 ... 86