|
xpci3xxx 1.00.00
|
Macros | |
| #define | CMD_xpci3xxx_InitTimer _IOR(xpci3xxx_MAGIC, 80,long) |
| Initialize the timer. | |
| #define | CMD_xpci3xxx_ReleaseTimer _IOR(xpci3xxx_MAGIC, 81,long) |
| Stop and free the timer. | |
| #define | CMD_xpci3xxx_StartTimer _IOR(xpci3xxx_MAGIC, 82,long) |
| Start selected timer. | |
| #define | CMD_xpci3xxx_StartAllTimers _IOR(xpci3xxx_MAGIC, 83,long) |
| Start all already initialized timers. | |
| #define | CMD_xpci3xxx_TriggerTimer _IOR(xpci3xxx_MAGIC, 84,long) |
| Triggers the selected timer. | |
| #define | CMD_xpci3xxx_TriggerAllTimers _IOR(xpci3xxx_MAGIC, 85,long) |
| Triggers all initialized timers. | |
| #define | CMD_xpci3xxx_StopTimer _IOR(xpci3xxx_MAGIC, 86,long) |
| Stop the selected timer. | |
| #define | CMD_xpci3xxx_StopAllTimers _IOR(xpci3xxx_MAGIC, 87,long) |
| Stop all started timers. | |
| #define | CMD_xpci3xxx_ReadTimerValue _IOR(xpci3xxx_MAGIC, 88,long) |
| Read the timer value. | |
| #define | CMD_xpci3xxx_ReadTimerStatus _IOR(xpci3xxx_MAGIC, 89,long) |
| Returns the timer status. | |
| #define | CMD_xpci3xxx_EnableDisableTimerInterrupt _IOR(xpci3xxx_MAGIC, 90,long) |
| Enable/disable the timer interrupt. | |
| #define | CMD_xpci3xxx_EnableDisableTimerHardwareOutput _IOR(xpci3xxx_MAGIC, 91,long) |
| Enable/disable the hardware timer output. | |
| #define | CMD_xpci3xxx_GetTimerHardwareOutputStatus _IOR(xpci3xxx_MAGIC, 92,long) |
| Returns the status of the output of the hardware timer. | |
| #define CMD_xpci3xxx_EnableDisableTimerHardwareOutput _IOR(xpci3xxx_MAGIC, 91,long) |
Enable/disable the hardware timer output.
| [in] | uint8_t | arg[3] Parameters |
ADDIDATA_LOW : If the counter overflows, the output is set to low
| 0 | : Success |
| 1 | : Internal error |
| 2 | : Timer not initialized |
| 3 | : Wrong Timer number |
| 4 | : Timer was initialized as counter |
| 5 | : Timer was initialized as watchdog |
| 6 | : Wrong output flag |
| 7 | : Wrong output level |
Definition at line 1331 of file xpci3xxx.h.
| #define CMD_xpci3xxx_EnableDisableTimerInterrupt _IOR(xpci3xxx_MAGIC, 90,long) |
Enable/disable the timer interrupt.
Controls if a timer will or not generate an interrupt.
| [in] | uint8_t | *arg Parameters |
| 0 | : Success |
| 1 | : Internal error |
| 2 | : Timer not initialized |
| 3 | : Wrong Timer number |
| 4 | : Timer was initialized as counter |
| 5 | : Timer was initialized as watchdog |
| 6 | : Wrong control flag |
| 7 | : Interrupt call-back not installed |
Definition at line 1309 of file xpci3xxx.h.
| #define CMD_xpci3xxx_GetTimerHardwareOutputStatus _IOR(xpci3xxx_MAGIC, 92,long) |
Returns the status of the output of the hardware timer.
| [in,out] | uint8_t | *arg Parameter and result |
| 0 | : Success |
| 1 | : Internal error |
| 2 | : Timer not initialized |
| 3 | : Wrong Timer number |
| 4 | : Timer was initialized as counter |
| 5 | : Timer was initialized as watchdog |
Definition at line 1348 of file xpci3xxx.h.
| #define CMD_xpci3xxx_InitTimer _IOR(xpci3xxx_MAGIC, 80,long) |
Initialize the timer.
| [in] | uint32_t | arg[4] Parameters |
| 0 | : Success |
| 1 | : Internal error |
| 2 | : Wrong Timer number |
| 3 | : Timer already used as counter |
| 4 | : Timer already used as watchdog |
| 5 | : Wrong Timer mode |
| 6 | : Wrong Timer time unit |
| 7 | : Wrong reload value |
Selected Mode description dw_ReloadValue Hardware gate
mode description input action
0 Mode 0 is typically used for event counting. After Start counting Hardware gate
the initialization, OUT is initially low, and remains value
low until the counter reaches 0. OUT goes high and
remains high until a new count is written.
1 Mode 1 is similar to mode 0 except for the gate Start counting Hardware
input action. value trigger
The gate input is not used to enable or disable the
timer (like in Mode 0), but to trigger it.
2 This mode functions like a divide-by- Divider factor Hardware gate
ul_ReloadValue counter. It is used to generate a real
time clock interrupt. OUT is initially high after the
initialization. When the initial count has
decremented to 1, OUT goes low for one CLK pulse.
OUT then goes high again, the counter reloads the
initial count (ul_ReloadValue) and the process is
repeated. This action can generate an interrupt.
3 Mode 3 is typically used for baud rate generation. Divider factor Hardware gate
This mode is similar to mode 2 except for the duty
cycle of OUT. OUT will initially be high after the
initialization. When the initial count
(ul_ReloadValue) has expired, OUT goes low for
the next sequence.then the initial count (ul_ReloadValue)
of that sequence has expired, OUT goes high again for
the following sequence.
The mode is periodic;
the sequence above is repeated indefinitely.
4 OUT is initially high after the initialization. When Start counting Hardware gate
the initial count expires, OUT will go low for one value
CLK pulse and then go high again. The counting
sequence is triggered by writing a new value. If a
new count is written during counting, it will be
loaded on the next CLK pulse.
5 Mode 5 is similar to mode 4 except for the gate input Start counting Hardware
action. value trigger
The gate input is not used to enable or disable the
timer, but to trigger it.
Definition at line 1159 of file xpci3xxx.h.
| #define CMD_xpci3xxx_ReadTimerStatus _IOR(xpci3xxx_MAGIC, 89,long) |
Returns the timer status.
| [in,out] | uint8_t | b_ArgTable[4] Parameter and results |
| 0 | : Success |
| 1 | : Internal error |
| 2 | : Timer not initialized |
| 3 | : Wrong Timer number |
| 4 | : Timer was initialized as counter |
| 5 | : Timer was initialized as watchdog |
Definition at line 1289 of file xpci3xxx.h.
| #define CMD_xpci3xxx_ReadTimerValue _IOR(xpci3xxx_MAGIC, 88,long) |
Read the timer value.
| [in,out] | uint32_t | arg[2] Parameters and result |
| 0 | : Success |
| 1 | : Internal error |
| 2 | : Timer not initialized |
| 3 | : Wrong Timer number |
| 4 | : Timer was initialized as counter |
| 5 | : Timer was initialized as watchdog |
Definition at line 1267 of file xpci3xxx.h.
| #define CMD_xpci3xxx_ReleaseTimer _IOR(xpci3xxx_MAGIC, 81,long) |
Stop and free the timer.
If a counter has been initialized, it can be reinitialized again only if this command is called before.
| [in] | uint8_t | *arg Select the timer |
| 0 | : Success |
| 1 | : Internal error |
| 2 | : Timer not initialized |
| 3 | : Wrong Timer number |
| 4 | : Timer is configured as counter |
| 5 | : Timer is configured as watchdog |
Definition at line 1176 of file xpci3xxx.h.
| #define CMD_xpci3xxx_StartAllTimers _IOR(xpci3xxx_MAGIC, 83,long) |
Start all already initialized timers.
| NULL | (ignored) |
| 0 | Success |
| 1 | Internal error |
Definition at line 1200 of file xpci3xxx.h.
| #define CMD_xpci3xxx_StartTimer _IOR(xpci3xxx_MAGIC, 82,long) |
Start selected timer.
| [in] | uint8_t | *arg Selected timer number |
| 0 | : Success |
| 1 | : Internal error |
| 2 | : Timer not initialized |
| 3 | : Wrong Timer number |
| 4 | : Timer was initialized as counter |
| 5 | : Timer was initialized as watchdog |
Definition at line 1190 of file xpci3xxx.h.
| #define CMD_xpci3xxx_StopAllTimers _IOR(xpci3xxx_MAGIC, 87,long) |
Stop all started timers.
| NULL | (ignored) |
| 0 | : Success |
| 1 | : Internal error |
Definition at line 1249 of file xpci3xxx.h.
| #define CMD_xpci3xxx_StopTimer _IOR(xpci3xxx_MAGIC, 86,long) |
Stop the selected timer.
| [in] | uint8_t | *arg Selected timer number |
| 0 | : Success |
| 1 | : Internal error |
| 2 | : Timer not initialized |
| 3 | : Wrong Timer number |
| 4 | : Timer was initialized as counter |
| 5 | : Timer was initialized as watchdog |
Definition at line 1238 of file xpci3xxx.h.
| #define CMD_xpci3xxx_TriggerAllTimers _IOR(xpci3xxx_MAGIC, 85,long) |
Triggers all initialized timers.
| NULL | (ignored) |
| 0 | : Success |
| 1 | : Internal error |
Definition at line 1224 of file xpci3xxx.h.
| #define CMD_xpci3xxx_TriggerTimer _IOR(xpci3xxx_MAGIC, 84,long) |
Triggers the selected timer.
| [in] | uint8_t | *arg Selected timer number |
| 0 | : Success |
| 1 | : Internal error |
| 2 | : Timer not initialized |
| 3 | : Wrong Timer number |
| 4 | : Timer was initialized as counter |
| 5 | : Timer was initialized as watchdog |
Definition at line 1214 of file xpci3xxx.h.