Borrar filtros
Borrar filtros

Digital acquisiton speed, it misses pulses

3 visualizaciones (últimos 30 días)
Alejandro Martín
Alejandro Martín el 30 de Ag. de 2012
Hi everyone,
I am trying to make a very simple acquisiton program in wich I read a low frequency digital signal and plot the results. The problem I have is that the acquisition doesn't seem to be fast enough for the application, as it misses many pulses at 80 Hz approximately. I don't understand why, the frecuency is very low and with an Advantech PCI 1711 Board this should't be happening.
Here is the program
dio = digitalio ('advantech',0)
hwlines = addline(dio,2,'In')
tic
for i=1:600
out(i)= getvalue (dio)
save('datos.txt','out')
end
tiempo=toc
stairs (out)
Thanks a lot in advance
Alejandro
  8 comentarios
ayam mohsen
ayam mohsen el 24 de Abr. de 2013
what version of matlab you see to used with pci-1711u notice ,i found just matlab 2008 and 2007 can see the pci-1711u using real time window target simulink
Alejandro Martín
Alejandro Martín el 3 de Jun. de 2013
Hi Ayam, I use a R2010a version of Matlab in a 32 bits Windows XP, and it works with PCI 1711 (note that PCI 1711U is different from PCI 1711). It also works with real time windows target. I don´t know what you are trying to do but if you let me know maybe I can help you if you are stuck in something.

Iniciar sesión para comentar.

Respuesta aceptada

Walter Roberson
Walter Roberson el 30 de Ag. de 2012
It is not recommended to save() within the loop. save() can take a fair bit of time.
  1 comentario
Alejandro Martín
Alejandro Martín el 30 de Ag. de 2012
Editada: Alejandro Martín el 30 de Ag. de 2012
Thanks a lot Walter, I worked with your suggestion.

Iniciar sesión para comentar.

Más respuestas (0)

Categorías

Más información sobre Data Acquisition Toolbox Supported Hardware en Help Center y File Exchange.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by