Go to the source code of this file.
|
enum | QDEC_InputAchTypeDef {
PA2A,
PA3A,
PB6A,
PB7A,
PC2A,
PC3A,
PD6A,
PD7A
} |
|
enum | QDEC_InputBchTypeDef {
PA2B,
PA3B,
PB6B,
PB7B,
PC2B,
PC3B,
PD6B,
PD7B
} |
|
enum | QDEC_ModeTypeDef { COMMON_MODE,
DOUBLE_ACCURACY_MODE
} |
|
◆ reg_qdec_set
#define reg_qdec_set 0xd1 |
◆ reg_qdec_channel_a
#define reg_qdec_channel_a 0xd2 |
◆ reg_qdec_channel_b
#define reg_qdec_channel_b 0xd3 |
◆ reg_qdec_mode
#define reg_qdec_mode 0xd7 |
◆ rge_qdec_load
#define rge_qdec_load 0xd8 |
◆ reg_qdec_count
#define reg_qdec_count 0xd0 |
◆ reg_qdec_reset
#define reg_qdec_reset 0xd6 |
◆ QDEC_InputAchTypeDef
qedc input channel type of A
Enumerator |
---|
PA2A | |
PA3A | |
PB6A | |
PB7A | |
PC2A | |
PC3A | |
PD6A | |
PD7A | |
◆ QDEC_InputBchTypeDef
qedc input channel type of A
Enumerator |
---|
PA2B | |
PA3B | |
PB6B | |
PB7B | |
PC2B | |
PC3B | |
PD6B | |
PD7B | |
◆ QDEC_ModeTypeDef
qedc mode
Enumerator |
---|
COMMON_MODE | |
DOUBLE_ACCURACY_MODE | |
◆ qdec_set_pin()
This function servers to set input port.
- Parameters
-
[in] | QDEC_InputAchTypeDef | - input types of A channel. |
[in] | QDEC_InputBchTypeDef | - input types of A channel. |
- Returns
- none.
◆ qdec_set_mode()
This function servers to set qdec's mode.
- Parameters
-
[in] | QDEC_ModeTypeDef | - mode type to select. |
- Returns
- none.
◆ qdec_clk_en()
void qdec_clk_en |
( |
void |
| ) |
|
This function servers to initials qedc source clock.
- Parameters
-
- Returns
- none.
◆ qdec_get_count_value()
unsigned char qdec_get_count_value |
( |
void |
| ) |
|
This function servers to read hardware counting value.
- Parameters
-
- Returns
- hardware counting value.
◆ qdec_clear_conuter()
void qdec_clear_conuter |
( |
void |
| ) |
|
This function servers to reset the counter.
- Parameters
-
- Returns
- none.
◆ qdec_set_debouncing()
void qdec_set_debouncing |
( |
char |
thrsh | ) |
|
This function servers to set hardware debouncing.
- Parameters
-
[in] | thrsh | - lower the value of thrsh,will be regard as jitter. |
- Returns
- none.