Loading...
  Show Posts
Pages: 1 ... 43 44 [45] 46 47 ... 58
661  Development / Suggestions for the Arduino Project / Re: please remove auto format keyboard short cut on: May 02, 2011, 05:25:13 pm
I think we should be able to edit our hot keys, what works for one person sucks for another...
... or is impossible on some national keyboards. On my DK keyboard the "/" is a shift-7. And SHIFT-CTRL-/ is not the (un-)comment command  smiley-mad
662  Using Arduino / LEDs and Multiplexing / Re: need 13 outputs from arduino uno on: May 02, 2011, 04:56:34 pm
Yes to everything. The analog pins work as digital, if you address them as 14, 15 ..., ie digitalWrite(14) will output on analog 0. (Remember to set pinMode() first, of course)

pin 0 and 1 work fine as digital pins ... as long as you do not use the USB or Serial stuff. Usually they are not used as plain digital pins.
663  Using Arduino / LEDs and Multiplexing / Re: servo and power source on: May 02, 2011, 04:51:05 pm
Do not use the 9v.

The servos typically need 6V. Your USB only gives 5V which is enough (but not really enough)
664  Using Arduino / Programming Questions / Re: Ardumoto - Motor Driver Shield on: April 30, 2011, 05:29:08 pm
" i cant seem to get is to work" does not say what does not work. Do the motors not turn at all? Or do they turn to fast/wrong way or what?

Your subject mentions "Motor shield". How have you verified that the wiring is correct? - perhaps including a schematic here might help resolve the problem.

665  Community / Bar Sport / Re: Your latest purchase on: April 30, 2011, 04:34:30 pm
Spark Fun Electronics
1.0" Single Digit Alphanumeric Display - Green/Yellow x1
5-way Tactile Switch x2
N-Channel MOSFET 60V 30A x10
MOSFET Power Control Kit x3

The switch and display is just for fun, The switch is SMD - didnt expect that - but here is a test

The MOSFETs (RFP30N06LE) are GREAT! I had a problem to control high Amp load with MOSFETS (getting a high enough gate voltage) but these MOSFETs turn fully on at Arduinos 5V output. My local (web-)stores dont carry them, so I previously used others, less well suited ones. Maybe I buy a 100 and sell them  smiley-wink
666  Community / Bar Sport / Re: Please HELP me NOW!!!!!! on: April 30, 2011, 04:13:38 pm
You need to set it as an output though or it's not properly turned on.
Well, there you go. All this chit chat and yet, another interesting fact creeps up. I thought from this (and some other stuff done previously) that all pins start as INPUT (re)boot, except #13 because of its LED wiring basically only is usable as OUTPUT.

Hmmm. digitalWrite to an input pin is supposed to put a 20K resistor to Vcc and if the other end of the LED is at GND then yes, I get 0.2mA through the LED. It glows a lot brighter than that. <Gets out the DVM> And measures 4.8V ... So I tried different INPUT, OUTPUT LOW and HIGH, and yes: With INPUT the 20K pullup just barley makes the onboard LED glow. It has to be OUTPUT. And that is what pin 13 is, by default. I think I am right here. Oh well, we could look at the init code at github, but I cant be bothered now.

Constructive critism is always welcome. If the worst happens I learn someting.
667  Using Arduino / Programming Questions / Re: Digital imput via arduino to processing on: April 30, 2011, 03:51:06 pm
Zenolin, in reply to the message you sent me
Quote
plese help me.
Here not mistake, bet do not work good.

void loop() {
 
  if (digitalRead(switchPin) == HIGH) {  // If switch is ON,
    Serial.print(1, BYTE);               // send 1 to Processing
  } else {                               // If the switch is not ON,
    Serial.print(0, BYTE);               // send 0 to Processing
  }
    delay(100);
}

if (digitalRead(ZZZZ) == HIGH) {  // If switch is ON,
    Serial.print(2, BYTE);               // send 2 to Processing
  } else {                               // If the switch is not ON,
    Serial.print(0, BYTE);               // send 0 to Processing
  }
//  delay(100);                            // Wait 100 milliseconds
Bad English is excusable, I can understand despite numerous spelling mistakes, wrong grammer and worse.

It is that you still have not said what it is that does not work. You expect me (or other Forum users), from the program and your cryptic "bet do not work good" to guess what you are expecting to happen, from what I can derive that the program actually does (and that is not always easy). In this case, is it showing the wrong colurs on your Processing or too briefly? Are your buttons something that is held down a long time or something that happens very quickly?

(1) What are you doing (2) What are wanting to happen (3) what is actually happening

I can't be bothered with so little info. Sorry.
668  Community / Bar Sport / Re: Please HELP me NOW!!!!!! on: April 30, 2011, 03:25:37 pm
bld:  Undskyld.
669  Community / Bar Sport / Re: Please HELP me NOW!!!!!! on: April 30, 2011, 02:56:21 pm
Tested as the shortest possible program to turn on LED13 (measured using normal Arduino source)
Code:
void setup(){}void loop(){digitalWrite(13,HIGH);}
To the rest of you readers, there is this "thing" between those Danes from the mainland and those on the main island ... sorry about that  smiley
670  Community / Bar Sport / Re: Please HELP me NOW!!!!!! on: April 30, 2011, 01:37:45 pm
Well, just because ... and for no particular reason at all, and the "cheering up" by the link of AWOL <shudder>, I now did test it. With the correction pointed out by CrossRoads, and the strange stuff (-->  ) that bld mentions ... the correct program. It does turn on the onboard LED!!!!!!!!!!!!!!!!!!!!!! (damn, that sticky Shift-1 key)
Code:
/* Lighting a LED */
#define LED_dig1 10
#define LED_dig2 3
int LED_pin = LED_dig1+LED_dig2 ;

void setup() {
  Serial.begin(9600) ;
  int LED_Mode ;
  LED_Mode=OUTPUT ;
  pinMode(LED_pin,LED_Mode) ;
  if (LED_Mode == OUTPUT) Serial.println("LED mode set correct") ;
}

void loop () {
  if (LED_pin==13) { // check we are using the right pin
    digitalWrite(LED_dig1+LED_dig2,!digitalRead(13)) ;
  }
}
671  Using Arduino / General Electronics / Re: 12v sensor needs a ground? on: April 30, 2011, 11:03:47 am
hah.  I don't speak Finnish.  Man, my grammar is that bad?  It is 4am. smiley-wink
No, not particulary. I just noticed your location.

(OT: And it is MayDay tomorrow. I've been to Helsinki a number of Maydays, but not this year  smiley-sad )
672  Using Arduino / General Electronics / Re: 12v sensor needs a ground? on: April 30, 2011, 06:08:45 am
A resistor does not "smooth" a fluctating voltage. A resistor-Capacitor circuit will do so.

IF (I am making assumptions here) the voltage meter is showing a steady voltage, and the Arduino is showing erratic values I can think of two possible causes: You ar not using the right pins (and the program is reporting an opencircuit/nonsense value) or your physical construction of the circuit is not solid enough, there is a loose connection.

We might get this kind of problem if the sensor is not outputting a single steady voltage level, but some pulsetrain or there is some other "noise" on the line. The voltage meter takes long samples, ie. it sort of shows an average voltage level. The Arduino ADC is a lot faster and might truly sample the voltage. Only way to know is to use an oscilloscope. (Or use an RC circuit...but then we move into a whole new set of problems)

Could you get your friend to write a little/short description of how/what his sensor is doing, which you then include here?

(NB: Have you tried the Scandianvian Forum where you can write in Finnish?)
673  Using Arduino / Programming Questions / Re: Digital imput via arduino to processing on: April 30, 2011, 05:49:19 am
I am fed up. Please make me happy.
674  Using Arduino / Programming Questions / Re: Digital imput via arduino to processing on: April 30, 2011, 04:37:21 am
It is always instructive to see the other posts made by a person asking... So, I gather you finally have gotten the Processing/Arduino distiction sorted out (earlier thread)

Lets see what you are doing. The Arduino code is sending two bytes roughly ten times a second. It can be sending 00, 10, 02 or 12 depending on the state of the switches.

The Processing colours a rectangle : IF "2" then white, if "1" then gray, else brown.

So.... if you only press one button on the Arduino then the other button's "0" signal will colour the rectangle ... (that is a hint)

Please please, when asking question make it clear which bit is not working. You may find - I have a few times - that explaining precisly what goes wrong, makes you find the error yourself (usually while writing the post, which then does not have to be sent  smiley )

EACH time you ask include three things:
1: What did you do?That is the code, the circuit diagram, what commands, button pushes you do.
2: What did you want to happen? (f.ex: The LED blinks 5 times at left button push; the LED turns Green on temperature exceeding 20C)
3: What actually did happen? (f.ex: The LED blinked once; The RGB-LED turn Yellow instead of Green at 20C and turned Green at 30C)

BTW, there is a Processing forum, too.
675  Using Arduino / General Electronics / Re: Sequence Of EE Subjects on: April 30, 2011, 03:40:47 am
The advice is: "Get a job you love, and you won't have to work a single day in your life." 
Deserves to be highlighted. It's what I did: choose to study exactly what I liked, got a series of jobs in the same field and after 40 years (really? that long already?) I still look forward to Monday.
Pages: 1 ... 43 44 [45] 46 47 ... 58