Now you can download a copy of these docs so you can use them offline! Download now
InterruptableSensorBase.h
1 /*----------------------------------------------------------------------------*/
2 /* Copyright (c) FIRST 2008. All Rights Reserved. */
3 /* Open Source Software - may be modified and shared by FRC teams. The code */
4 /* must be accompanied by the FIRST BSD license file in $(WIND_BASE)/WPILib. */
5 /*----------------------------------------------------------------------------*/
6 
7 #ifndef INTERRUPTABLE_SENSORBASE_H_
8 #define INTERRUPTABLE_SENSORBASE_H_
9 
10 #include "ChipObject.h"
11 #include "SensorBase.h"
12 
14 {
15 public:
17  virtual ~InterruptableSensorBase();
18  virtual void RequestInterrupts(tInterruptHandler handler, void *param) = 0;
19  virtual void RequestInterrupts() = 0;
20  virtual void CancelInterrupts();
21  virtual void WaitForInterrupt(float timeout);
22  virtual void EnableInterrupts();
23  virtual void DisableInterrupts();
24  virtual double ReadInterruptTimestamp();
25 protected:
26  tInterrupt *m_interrupt;
27  tInterruptManager *m_manager;
28  uint32_t m_interruptIndex;
29  void AllocateInterrupts(bool watcher);
30 };
31 
32 #endif
33 
virtual void DisableInterrupts()
Disable, but don't deallocate.
virtual void CancelInterrupts()
Free up the underlying chipobject functions.
virtual void RequestInterrupts()=0
Synchronus Wait version.
virtual void WaitForInterrupt(float timeout)
Synchronus version.
virtual double ReadInterruptTimestamp()
Return the timestamp for the interrupt that occurred.
virtual void EnableInterrupts()
Enable interrupts - after finishing setup.

Generated on Sat Apr 26 2014 12:26:45 for WPILibC++ by doxygen 1.8.6