Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   C/C++ (http://www.chiefdelphi.com/forums/forumdisplay.php?f=183)
-   -   Digital IO in C++ (http://www.chiefdelphi.com/forums/showthread.php?t=72154)

EricGoodchild 15-01-2009 10:53

Digital IO in C++
 
Hey does anyone know if there is a class for measuring pulse width in the WinLib library?

byteit101 15-01-2009 15:25

Re: Digital IO in C++
 
Quote:

Hey does anyone know if there is a class for measuring pulse width in the WinLib library?
You mean WPILib?
Pulse width of?

BradAMiller 15-01-2009 17:49

Re: Digital IO in C++
 
I'm not sure what you're application is, but you can measure pulse widths using the Counter objects in semi-period mode. That is exactly what the ultrasonic sensors do and you can look at the Ultrasonic class source code as an example.

There is one problem though - there is currently a bug in the FPGA that will prevent accurate results, but it will be fixed in the next update.

biojae 15-01-2009 23:05

Re: Digital IO in C++
 
Our application is to find the angle of a PWM compass that automatically pulses in. What we were wondering is if there was a way to get the interrupt easily to get the pulse width length.


All times are GMT -5. The time now is 02:30.

Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi