Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Performance do the test please....

Status
Not open for further replies.

TKS

New Member
Hi,

i'm new un the world of microcontrollers, i recentrly brought a oopic (www.oopic.com) this because it was easy to program in basic...

now i'm trying to measure rpm's (max 8000/min..) and i do it
in the way that i count in a time if a I/O line is high or low (pulse measure ments...)

when i programmed whit that i saw that my oopic only can do the

do

loop

24x times per second... this is very slowww...

so i programmed a do loop construcion only whit this..
(basic)

dim met as oWord
do

met=met+1

loop

when i did this it counts 250 per second..also very slowww..

can anybody do this test or tell me wy this is sow slowwly...??

my oopic has 8Kb of ram..(24LC64) and a PIC16F776 (microship...)

hope somebody can give me good advise...

or some people can test there one..(the performance...)
(i hope whit a other language..)


TKS

p.s. the way i know the values is because the oopic comes whit a program you can "talk" white the oopic...an read values of it...
 
TKS said:
Hi,

can anybody do this test or tell me wy this is sow slowwly...??


because you're using Basic...

use Real programming language, like Assembly

and make sure that the mcu has a fast sampling rate
 
oeps i have a PIC16F877

i have a PIC16F877

Data ram : 368
Speed MHz: 20
I/O Ports : 33
ADC : 8
Serial I/O : USART,I²C,SPI
CCP (PWM) : 2
Comparators : -
Timers 8/16 bit : 3+WDT
Brown Out : true
ICSP : true




TKS
 
slow processing speed

Hi TKS, I'm new to the OOPic stuff too, and I don't have one of the boards yet, so this comes from reading the OOPic book*.
You'll probably want to implement your rpm measurement with oopic objects, as they run about 100 times faster than your program code will. The "objects" actually consist of object code that is linked in to your main program through pointers. Program code is interpreted by a small program running in the background on the PIC, so it will run slowly. The book recommends using VCs (virtual circuits) whenever possible, which is kind of the whole idea to begin with (linking objects together to form a program). You will probably want to use the oTimer(X) and oChanged(O,C) objects for your rpm measurement program. - CAL

*The book I'm referring to is "Programming and Customizing the OOPic Microcontroller" by Dennis Clark (TAB books)
 
thanks..

first of all im gald to have response..

the of yours is a good one.

i bluid now my rpm whit a counter object and a odio1 object..

it's working fine...until 3000rpm. whit one pulse per rpm..

(today i'm gona test it whit a dremel...(15000rpm min..)

TKS
 
Status
Not open for further replies.

New Articles From Microcontroller Tips

Back
Top