Angle 4 Click Board
Angle 4 Click Board
The Angle 4 Click Board™ is an angular magnetic rotary sensor, which can be used as a rotary encoder. With the help of the AEAT-8800-Q24, an integrated 10 to 16-bit programmable angular magnetic encoder, the Angle 4 Click Board™ can sense the magnetic field rotation aligned with the centre of the sensor, over the whole range of 360°. The absolute angular position can be read from the SPI interface.
The sensor IC itself offers a versatile contactless rotation sensing platform, with the ability to fine-tune several important working parameters, such as the resolution, zero position, direction, hysteresis, and more.
Software Support
Software Support
We provide a library for the Angle 4 Click Board™ on our LibStock page, as well as a demo application (example), developed using MikroElektronika compilers. The demo can run on all the main MikroElektronika development boards.
Library Description
Library initializes and defines SPI bus driver and driver functions which offer a choice to write data in registers and to read data from registers. Library also offers a choice to sets absolute resolution read data and sets the direction. A user has an angle-reading function, a function for starting the measurement, and starting the chip calibration that is necessary for operation.
Key Functions
vuint8_t angle4_getNewAngle(uint16_t *dataOut)
- Functions for read Anglevoid angle4_startMesuremenet()
- Functions for start measurementvoid angle4_calibration(uint8_t dir, uint8_t data_resolution)
- Functions for calibration chip
Example Description
The application is composed of three sections:
- System Initialization - Initializes SPI module and set CS pin as OUTPUT
- Application Initialization - Driver initialization, standard configurations, and start measurement
- Application Task - (code snippet) - Reads Angle in degrees and logs data to USBUART every 200 ms.
void applicationTask() { angle4_getNewAngle(&Angle); IntToStr(Angle, demoText); mikroBUS_logWrite(" Angle : ", _LOG_TEXT); mikroBUS_logWrite(demoText, _LOG_TEXT ); mikroBUS_logWrite(" deg", _LOG_LINE); Delay_ms( 200 ); }
The full application code, and ready to use projects can be found on our Libstock page.
Other MikroElektronika libraries used in the example:
- SPI
- Conversions
ADDITIONAL NOTES AND INFORMATION
Depending on the development board you are using, you may need a USB UART Click Board™, USB UART 2 Click Board™ or RS232 Click Board™ to connect to your PC, for development systems with no UART to USB interface available on the board. The terminal available in all MikroElektronika compilers, or any other terminal application of your choice, can be used to read the message.
MIKROSDK
The Angle 4 Click Board™ is supported with mikroSDK - MikroElektronika Software Development Kit. To ensure proper operation of mikroSDK compliant Click Board™ demo applications, mikroSDK should be downloaded from the LibStock and installed for the compiler you are using.
Angle 4 Click Board
Frequently Asked Questions
Have a Question?
Be the first to ask a question about this.