Show Posts
Pages: 1 ... 1295 1296 [1297] 1298 1299 ... 1917
19441  Using Arduino / Programming Questions / Re: portOutputRegister() on: October 20, 2011, 08:46:35 am
Code:
find / -name "*.[ch]" | xargs grep portOutputRegister -l

Might take a while.
19442  Using Arduino / Project Guidance / Re: Using ultrasonic transducers. (again) :( ) on: October 20, 2011, 08:16:00 am
Quote
the circuit is just too hard
But it has been around a long time, and it works.
Unless you have, and know how to use, an oscilloscope, I'd advise against building your own.
19443  Using Arduino / Project Guidance / Re: Using ultrasonic transducers. (again) :( ) on: October 20, 2011, 08:02:28 am
Google must be broken where you are.

http://www.google.co.uk/search?q=Devantech+SRF04+schematic&ie=utf-8&oe=utf-8&aq=t&rls=org.mozilla:en-US:official&client=firefox-a

First hit.
19444  Using Arduino / Project Guidance / Re: Using ultrasonic transducers. (again) :( ) on: October 20, 2011, 07:55:02 am
There used to be a set of schematics for the Devantech SRF04 online.
That uses a PIC (IIRC) and a MAX232 to drive, but you could dump the PIC and use a 555.
Can't remember what the rx amplifier is, though.
19445  Using Arduino / Programming Questions / Re: Error handling on: October 20, 2011, 07:37:49 am
Quote
Is there anything which could harm it programmatically?
If you're really clever, you could probably get it to erase all the program memory, but physical damage? No.
19446  Using Arduino / Programming Questions / Re: Error handling on: October 20, 2011, 07:27:55 am
Quote
i would have expected the loop to return or something like that.
Return to where?
19447  Using Arduino / Programming Questions / Re: Error handling on: October 20, 2011, 07:13:49 am
Quote
what would happened in my Arduino in the case of a division by zero?
Why not try it, and see?
Nothing bad will happen, promise.
19448  Using Arduino / Programming Questions / Re: Please need help from mentors. on: October 20, 2011, 07:10:34 am
Why would Serial.print use delay?
Think about it - an interrupt is meant to be FAST, but serial comms are SLOOOOOOOW
19449  Using Arduino / Programming Questions / Re: Error handling on: October 20, 2011, 07:09:02 am
The simple way to handle a divide-by-zero is not to allow it to happen.
This is a microcontroller - there is no exception mechanism for stuff like this.

Quote
PICS
Wash your mouth out!
19450  Using Arduino / Programming Questions / Re: Please need help from mentors. on: October 20, 2011, 07:03:56 am
Quote
In the case of using my debug function in an ISR,
But you wouldn't ever be doing that, would you?
19451  Using Arduino / Programming Questions / Re: How to make the serial read more than one value? on: October 20, 2011, 06:51:17 am
Quote
In case the op doesn't know... "1" = 49.
sp. '1'       smiley-wink
19452  Using Arduino / Programming Questions / Re: Please need help from mentors. on: October 20, 2011, 06:48:27 am
What buffer?
If all you're doing is printing (and that's about all the debug needs to do), when you copy from PROGMEM, you only need a single character buffer.

Think about the architecture.
The only permanent storage is the flash.
Before "main" runs, all strings are copied from flash to RAM, unless you've qualified them with PROGMEM.
19453  Using Arduino / Project Guidance / Re: Advice on my project on: October 20, 2011, 06:37:34 am
Sorry, can't help with psychosomatic bugs.
19454  Using Arduino / Project Guidance / Re: Advice on my project on: October 20, 2011, 06:29:02 am
No, what I meant was "can you describe the problem".
Just saying you've got a problem doesn't describe what you observe happening and what you expect to happen, and how the two differ.
19455  Using Arduino / Programming Questions / Re: Please need help from mentors. on: October 20, 2011, 06:24:51 am
Quote
What exactly would that change over a const char[] being declared on the fly?
It saves a lot of RAM that you may wish to use for other things.
It doesn't matter if you qualify a string with const, the compiler will cause it to be copied to RAM.
The AVR is a Harvard architecture processor, with separate address spaces for RAM and program memory.
Pages: 1 ... 1295 1296 [1297] 1298 1299 ... 1917