MotorWare f2806x Module API Documentation

- Main Page
- Modules
- Data Structures
- Files

- File List
- Globals

Functions
enc.c File Reference

Portable C fixed point code. These functions define the. More...

`#include "sw/modules/enc/src/32b/enc.h"`

Go to the source code of this file.

## Functions
ENC_Handle | ENC_init (void *pMemory, const size_t numBytes)
| Initializes the encoder object. More...
void | ENC_setup (ENC_Handle encHandle, const int16_t sample_period, const uint16_t num_pole_pairs, const uint16_t num_enc_slots, const uint32_t enc_zero_offset, const float_t full_scale_freq, const float_t speed_update_freq, const float_t speed_cutoff)
| Initializes encoder object parameters. More...
void | ENC_calcElecAngle (ENC_Handle encHandle, uint32_t posnCounts)
| Reads encoder and returns the electrical degrees in Q24 format. More...
void | ENC_run (ENC_Handle encHandle, uint32_t posnCounts, uint16_t indextFlag, uint16_t dirFlag, int16_t log_flag)
| Based on the encoder reading, computes the electrical angle and the electrical "speed". More...
int16_t | ENC_getSpeedRPM (ENC_Handle encHandle)
| Returns the filtered speed in RPM. More...

## Detailed Description

Portable C fixed point code. These functions define the.

encoder routines.

(C) Copyright 2011, Texas Instruments, Inc.

Definition in file enc.c.