Welcome, Guest
Username: Password: Remember me

TOPIC: Arduino and Proview

Re:Arduino and Proview 12 years 11 months ago #2231

  • marc
  • marc's Avatar
  • OFFLINE
  • Platinum Boarder
  • Posts: 710
  • Thank you received: 70
  • Karma: 24
Hi Ivo,

Thanks, I had some nice days.

This morning I did some tests:

In all the tests are:
baud rate: 115200
scantime: 5 ms
priority: 22


Test 1:

arduino.pde from git (feb 2011)

1 analog in (Ai0)

Result: ScanTimeMean: 9 ms

Test 2:

arduino.pde from git (feb 2011)

1 analog in (Ai0)
1 digital input (Di2)
1 analog out (Ao3)
1 digital input (Di4)

Result: ScanTimeMean: 15 ms


Test 3:

sketch_may21a.pde

1 analog in (Ai0 pin 0)

Result: ScanTimeMean: 9 ms


Test 4:

sketch_may21a.pde

1 analog in (Ai0)
1 digital input (Di2)
1 analog out (Ao3)
1 digital input (Di4)

Result: ScanTimeMean: 15 ms


Test 5:

pde.hex (19-may-2011)

1 analog in (Ai0 pin 0)

Result: ScanTimeMean: 9 ms

Of course it can be I am completely wrong but I can't see a difference between the standard sketch and the \"avr versions\".
Are you sure, for example the analog read speeds, limits are not limited of the 328p?
For example the convertion wait from 1600 clocks sounds a lot but we are running 16Mhz/prescale.

If the limitation is in the 328p itself isn't the only way to speed up by choose a lower prescaling factor?
But then we can't keep 10 bit resolution.....

Sounds very interesting your low budget shield.
Thanks for all your input and I wish you good luck whatever you do....
One thing is for sure. You have brains. Take care of them!

Greetings,

Marc

Post edited by: marc, at: 2011/05/23 19:14
Please, use the Wiki if you succeeded your project or solved your problem. Share your work, so we can learn from each other.
The administrator has disabled public write access.

Re:Arduino and Proview 12 years 11 months ago #2244

  • ivo1204
  • ivo1204's Avatar
  • OFFLINE
  • Senior Boarder
  • Posts: 44
  • Karma: 2
Hi Marc,

So nice that you found time for these tests because I really had no idea how to assess the real situation.
There are significant changes in the latest version,\"sketch_may21a\" and they are not to increase the speed, but to make software extensible.
So, I tried this version 'sketch_may21b', and gives a very good time.(see picture)
With 1 Ao I think you can try to control the stepper motors directly from PROVIEW.
Greetings,


rem:
the last two parentheses should be moved here
630 ADCSRA | = _BV (ADSC); / * start conversion, will read value next time * /
==>}}
631 PORTB = Do [1];

Post edited by: ivo1204, at: 2011/05/24 19:38
Last Edit: 12 years 2 months ago by ivo1204.
The administrator has disabled public write access.

Re:Arduino and Proview 12 years 11 months ago #2248

  • marc
  • marc's Avatar
  • OFFLINE
  • Platinum Boarder
  • Posts: 710
  • Thank you received: 70
  • Karma: 24
Hi Ivo,

It seems to be you did it, decreasing the scan time.
Tomorrow I will have a better look.
And believe me, there have been a couple of forum member lurking and scratching their heads looking at the way you are \"playing\".....

Thanks,

/Marc
Please, use the Wiki if you succeeded your project or solved your problem. Share your work, so we can learn from each other.
The administrator has disabled public write access.

Re:Arduino and Proview 12 years 11 months ago #2249

  • ivo1204
  • ivo1204's Avatar
  • OFFLINE
  • Senior Boarder
  • Posts: 44
  • Karma: 2
Hi Marc,

I think that is not connected to my Arduino or other code that is in the work of PROVIEW - when writes only Ao, then the chance is very high speed. And that's fine, because in each Arduino. pde you can write DDRB = value of Ao and it will come out of Port B..

Post edited by: ivo1204, at: 2011/05/25 01:00
The administrator has disabled public write access.

Re:Arduino and Proview 12 years 11 months ago #2260

  • marc
  • marc's Avatar
  • OFFLINE
  • Platinum Boarder
  • Posts: 710
  • Thank you received: 70
  • Karma: 24
Hi Ivo,

I have tried to use an Out2P block, Claes suggested a while ago, in combination with a digital output and a 180-degrees servo motor.
But our oscilloscope is in use today.....
It looks promising.

/Marc

Post edited by: marc, at: 2011/05/25 16:23
Please, use the Wiki if you succeeded your project or solved your problem. Share your work, so we can learn from each other.
The administrator has disabled public write access.

Re:Arduino and Proview 12 years 11 months ago #2261

  • ivo1204
  • ivo1204's Avatar
  • OFFLINE
  • Senior Boarder
  • Posts: 44
  • Karma: 2
Hi Marc,

I tried to take the maximum speed for two Arduino stepper motor.
This version is very simple, but you have to have exactly two Ao.
they are now and Ao0 Ao1 as voltage pin 6 and 5.
Have no problem with speed, so you can try.
Last Edit: 12 years 2 months ago by ivo1204.
The administrator has disabled public write access.
Time to create page: 8.529 seconds