Show Posts
Pages: 1 ... 382 383 [384] 385 386 ... 592
5746  Using Arduino / Installation & Troubleshooting / Re: 'digitalwrite' was not declared in this scope on: April 09, 2012, 09:55:02 pm
It's spelled "digitalWrite".  Identifiers are case sensitive.
5747  Using Arduino / Installation & Troubleshooting / Re: Bootloader installation problems - mega2560 - ARVISP mkII on: April 09, 2012, 09:48:08 pm
The Mega has too much memory to run a bootloader that speaks STK500V1.  You need an STK500V2 bootloader.

How long a WDT interval do you need?  As long as the bootloader gives control to setup() before the WDT times out again you should not have a problem with the bootloader.

Have you tried the WDT with the standard bootloader?

Here is a WDT test sketch.  It blinks slower and slower until the toggle delay grows beyond the WDT limit. At that point the WDT times out and resets the system.
#include <avr/wdt.h>

unsigned long ToggleDelay;

const int LEDpin = 13;

void toggle_led()
  digitalWrite(LEDpin, !digitalRead(LEDpin));

void setup()
  ToggleDelay = 1;
  pinMode(LEDpin, OUTPUT);
  wdt_enable(WDTO_250MS);  // Set watchdog to 1/4 second

void loop()
  ToggleDelay += 5;
5748  Using Arduino / Storage / Re: SD card pins on Arduino Mega problem on: April 09, 2012, 09:37:21 pm
The SD card uses the SPI interface pins (50-53?)  Perhaps you can get around the need for a true "Ground" pin next to six digital pins by using a 7th digital pin set to "LOW" as a "Ground".  Should work as long as the LCD uses less than 40 mA.
5749  Using Arduino / Project Guidance / Re: Person tracking robot guidance system on: April 08, 2012, 02:39:46 pm
A few weeks ago the Ben Heck Show was about building a rolling luggage robot that would follow its owner.
5750  Using Arduino / Project Guidance / Re: Crazy Erratic servo operation on: April 05, 2012, 12:54:50 pm
You must have the Arduino and Servo(s) share a Ground so that's not the problem.

The code looks fine assuming your pots are wired correctly: +5, A0/A5, Gnd.

My guess would be a wiring error of some kind.  The servos should have +Power on Red, -Power and Arduino Ground on Black and Signal on White (or Yellow).
5751  Using Arduino / Project Guidance / Re: Solenoid or Servo for Drum Arm on: April 05, 2012, 12:47:05 pm
I think solenoids would give faster response.
5752  Using Arduino / Networking, Protocols, and Devices / Re: Receiving 2.4GHz signal on: April 05, 2012, 12:09:08 pm
Since the owner's manual gives no technical information beyond what size battery it takes it's very hard to say what frequency range is uses.  Perhaps if you open the watch there will be a chip with an ID number you can look up.
5753  Using Arduino / Microcontrollers / Re: ATmega328P on 8Mhz internal clock, serial comm, and libraries question on: April 05, 2012, 11:38:47 am
The processor leaves the factory with the internal oscillator calibrated to ±10%. 

Note: That's ±10% at Vcc=3V and temperature=25°C.  The frequency will change with voltage and temperature.  At 3V the nominal frequency goes from under 7.7 MHz at -40°C to 8.2 MHz at 85°C.  At 5V the frequency is roughly 100 KHz higher (8.1 MHz at 25°C).
5754  Using Arduino / Programming Questions / Re: Increasing PWM frequency and resolution on: April 04, 2012, 06:08:28 pm
If you re-program the timer to get 10-bit PWM you can't use analogWrite() anymore.  You have to write to the timer registers directly.
5755  Using Arduino / Microcontrollers / Re: ATmega328P on 8Mhz internal clock, serial comm, and libraries question on: April 04, 2012, 06:02:52 pm
Standard libraries will work fine at 8 MHz.
5756  Using Arduino / Installation & Troubleshooting / Re: Sketch may be uploaded only once, then takes botloader update on: April 04, 2012, 05:59:03 pm
Maybe the coupling capacitor is too small or the pull-up resistor on your reset line is to low a value.
5757  Using Arduino / Microcontrollers / Re: ATmega328p with 8MHz internal clock on: April 04, 2012, 12:21:26 pm
Arduino 1.0 has serial buffers that are small enough that they cause failures in the ArduinoISP sketch.  You might be able to work around that problem by setting the baud rate lower in ArduinoISP and in programmers.txt.

If you get a factory fresh ATmega 328 chip you should be able to burn an 8MHz no-crystal bootloader into it.  If you got a 328 with an Arduino bootloader on it you will need the crystal and capacitors to use a serial programmer on it (ISP won't work without a functioning processor clock).  If you have a second Ardiuno with a removable 328 processor you can use that as a temporary host system to provide the crystal clock, program your chip to use the internal clock, THEN move the chip to a breadboard.
5758  Using Arduino / Sensors / Re: Magnetic Shaft Encoders on: April 04, 2012, 12:07:17 pm
Do you have a oscilloscope you could use to check the pulse output of the device?  Perhaps some kind of electrical noise is getting into the data stream/
5759  Using Arduino / Installation & Troubleshooting / Re: Problem uploading sketch to arduino mega 2560 on: April 04, 2012, 10:20:14 am
The bootloader of some Mega's has a 'monitor' program that lets you read and write memory from the Serial Monitor.  The monitor program is activated by sending '!!!'.  Unfortunately that means that any sketch containing three or more consecutive '!' characters will fail to upload.  smiley-sad
5760  Using Arduino / LEDs and Multiplexing / Re: Somebody know it??? LED STRIP with stange pinout 10 pin on: April 03, 2012, 08:53:36 pm
The big trace is most likely ground.  You might be able to tell what the others do by connecting 3V between Ground and one of the other pins to see what lights up.  Perhaps there are thee sets of R, G and B inputs so that chase patterns can be produced.
Pages: 1 ... 382 383 [384] 385 386 ... 592