Show Posts
Pages: [1] 2
1  Using Arduino / Programming Questions / Re: Scaling analog readings to stable values on: April 20, 2014, 08:43:28 pm
Code:
int value;

void setup() {
}

void loop() {
  value = map(analogRead(0), 0, 1023, 50, 250);
  show_me_on_display(value);
}

there is nothing else then what i've already described
2  Using Arduino / Programming Questions / Scaling analog readings to stable values on: April 20, 2014, 08:27:25 pm
Hello,

I am trying to scale my analog readings and I get into a problem of 'unstable' values.
My goal is to scale 0-1023 to 50-250. I am using the map function – map(A0, 0, 1023, 50, 250). I have set up a display to check the values.

The problem is that sometimes I run into 'middle' values, where the display is flickering between two – for example 69 and 70.
How would you approach this topic? Some DSP low-pass filtering?

Thanks for any help!
3  Using Arduino / Project Guidance / Accurate 100 Hz square wave generator on: March 09, 2014, 10:37:12 pm
Hello,

trying to get accurate 100Hz from Arduino, but having a bit of trouble.
So my first approach was to set pin high, wait 5ms, set it low and wait another 5ms.
The problem is, the resulting frequency is a actually a bit higher (102,4) - according to various frequency counters.
Why is that? If anything, I would actually expect it to be slower (didn't counting on the instruction time for setting the registers).
Anyone has a solution?

Thanks,
Jonas
4  Using Arduino / Programming Questions / Re: Generating separate square-wave oscillators on: January 28, 2013, 07:36:19 pm
Sorry for the confusion. I would indeed welcome timer-based solution to this. If I can use only one timer (16-bit - because of the speed reasons), how can I easily deliver 4 different frequencies? Lets say they are not related - 1.3, 2.0, 2.7 Hz?
5  Using Arduino / Programming Questions / Re: Generating separate square-wave oscillators on: January 28, 2013, 06:57:43 pm
That is not helpful - I don't want to use delays (as mentioned in previous post).
6  Using Arduino / Programming Questions / Re: Generating separate square-wave oscillators on: January 28, 2013, 06:54:48 pm
Well indeed, amplitude is defined by the digital outputs of the Atmega. Frequencies, lets say 1, 1.5, 2 and 2.5 Hz.
Ideally without using delays.
7  Using Arduino / Programming Questions / Generating separate square-wave oscillators on: January 28, 2013, 06:39:54 pm
Hello,

I would like to generate 4 different square-wave oscillators on separate pins. What would be the best approach? I need to have them as accurate as possible? I am already using one (16bit timer).

Regards,
Jonas
8  Using Arduino / Installation & Troubleshooting / Re: Arduino restarts my computer on: January 21, 2013, 03:10:29 am
this has happened to me twice with the Leonardo and Arduino 1.03 - once on a Mac Pro running 10.7 and once on a Macbook Pro running 10.8 - in the case of the latter the Leonardo was externally powered.

both times it was during the uploading phase - didn't get a kernel panic message, just a hard reboot all of a sudden

Uff, 'glad' I am not alone. I feel your pain!
9  Using Arduino / Installation & Troubleshooting / Re: Arduino restarts my computer on: January 07, 2013, 04:02:53 pm
Yeah, I know that might be an issue sometimes. But now the arduino wasn't connected to anything, powered from the computer. I guess it must be fault on the motherboard of the computer.
10  Using Arduino / Installation & Troubleshooting / Re: Arduino restarts my computer on: January 07, 2013, 03:37:14 pm
I don't understand. It doesn't happen when verifying. It happens when uploading - during the 'uploading' part of the process.
11  Using Arduino / Installation & Troubleshooting / Re: Arduino restarts my computer on: January 07, 2013, 03:32:49 pm
Only when uploading?
What about verify (upload is not performed)?
No, only when uploading. I don't think this is a software issue.
12  Using Arduino / Installation & Troubleshooting / Re: Arduino restarts my computer on: January 07, 2013, 03:27:10 pm
It is indeed very weird. Sometimes the reset is immediate, last time the video I was watching started stuttering and than the computer restarted.
13  Using Arduino / Installation & Troubleshooting / Re: Arduino restarts my computer on: January 07, 2013, 03:25:45 pm
Nothing is attached.
14  Using Arduino / Installation & Troubleshooting / Arduino restarts my computer on: January 07, 2013, 03:22:20 pm
Hey,

it happend to me few times already and I am really starting to hate it. I have few Arduino Boards (UNO, Duemanilove, Leonardo), and all of them sometimes restart my computer when uploading the program.
I have Macbook Pro 13" mid 2010. No other devices are attached. Anyone has an idea?

Regards
15  Using Arduino / Programming Questions / Re: Leonardo + MIDI + Interrupts on: November 23, 2012, 05:52:56 am
One more question:
I am using LCD display using pins 4, 5, 6, 7, 8 and 9, and I'd also like to use one timer for triggering interrupts. What would be the best way to approach this?

Thank you
Pages: [1] 2