Go to the source code of this file.
Functions | |
void | encoders_microb_init (void) |
void | encoders_microb_manage (void *dummy) |
int32_t | encoders_microb_get_value (void *data) |
void | encoders_microb_set_value (void *data, int32_t c) |
int32_t encoders_microb_get_value | ( | void * | number | ) |
Extract encoder value.
data | : a (void *) that is casted in (uint8_t) containing the number of the encoder to be read. |
number | : a (void *) that is casted in (int) containing the number of the encoder to be read. |
Definition at line 230 of file encoders_microb.c.
References g_encoders_microb_values, IRQ_LOCK, and IRQ_UNLOCK.
void encoders_microb_init | ( | void | ) |
Initialisation of encoders, variables
Definition at line 104 of file encoders_microb.c.
References DDR, encoders_microb_manage(), INIT, IRQ_LOCK, IRQ_UNLOCK, sbi, SEL_A, SEL_B, and wait_4cyc.
void encoders_microb_manage | ( | void * | dummy | ) |
Update encoders values, need to be done quite often (Fmax_encoders/64). First, encoders 0 2 4 6 are read, and at next call encoders 1 3 5 7.
dummy | : a (void *) pointer that is not used. It is here according to the encoders interface. |
Definition at line 166 of file encoders_microb.c.
References IRQ_LOCK, IRQ_UNLOCK, READ, SEL_A, and SEL_B.
Referenced by encoders_microb_init().
void encoders_microb_set_value | ( | void * | number, | |
int32_t | v | |||
) |
Set an encoder value
data | : a (void *) that is casted in (uint8_t) containing the number of the encoder to be read. | |
v | : the value |
number | : a (void *) that is casted in (int) containing the number of the encoder to be read. | |
v | : the value |
Definition at line 248 of file encoders_microb.c.
References g_encoders_microb_values, IRQ_LOCK, and IRQ_UNLOCK.