Angle 5 Click Board
Angle 5 Click Board
The Angle 5 Click Board™ is a compact add-on board that detects the absolute angular position of a permanent magnet, typically a diametrically magnetized cylinder on a rotating shaft. This board features the MA302, a 12-bit digital contactless angle sensor with ABZ and UVW incremental outputs from Monolithic Power Systems. The MA302 features an ABZ encoder, UVW pole pair emulation, fast data acquisition, and processing which provides accurate angle measurement at speeds from 0 to 60,000 rpm, and a magnetic field strength detection with programmable thresholds. This Click Board™ is suitable for various applications such as detecting the absolute rotor position of a brushless motor in real-time, even without a target magnet, by measuring the fringe field of the rotor.
Note: DC Motor doesn't come with this Click Board™, if you are interested you can find 2207V-2500KV BLDC Motor in our shop.
The Angle 5 Click Board™ is supported by a mikroSDK compliant library, which includes functions that simplify software development. This Click Board™ comes as a fully tested product, ready to be used on a system equipped with the mikroBUS™ socket.
How Does The Angle 5 Click Board™ Work?
The Angle 5 Click Board™ is based on the MA302, a 12-bit digital contactless angle sensor with ABZ and UVW incremental outputs from Monolithic Power Systems. This Click board™ can detect the absolute rotor position of a Brushless motor in real-time, even without a target magnet, by measuring the fringe field of the rotor. The sensor must be positioned at the correct place (in this case below the rotor) to get the maximum value of the rotor magnetic field without being disturbed by other fields. The rotor magnetic field is then measured, and an adequate position was determined from that information. It uses the SPI serial interface for digital angle readout and configuration, alongside with programmable magnetic field strength detection function for diagnostic checks.
The magnetic field is detected with integrated Hall devices located in the centre of the package. The angle is measured using the Spinaxis™ method, based on phase detection and generates a sinusoidal signal with a phase that represents the angle of the magnetic field. The angle is then obtained by a time-to-digital converter, which measures the time between the zero-crossing of the sinusoidal signal and the edge of a constant waveform. The time-to-digital represents an output from the front-end to the digital conditioning block. This output delivers a digital number proportional to the angle of the magnetic field at the rate of 1MHz in a straightforward and open-loop manner.
The Angle 5 Click Board™ communicates with MCU using the standard SPI serial interface for angle reading and register programming, which supports SPI Mode 0 and 3 and operates at clock rates up to 25 MHz. It also has the magnetic flags used for indication when the magnetic field at the sensor position is out of range, defined by the lower and upper magnetic field thresholds, routed on the PWM and INT pin of the mikroBUS™ socket labeled as MGH and MGL.
The Angle 5 Click Board™ possesses an incremental encoder and block commutation function that uses three output pins each: ABZ and UVW. The ABZ output emulates a 10-bit incremental encoder (such as an optical encoder) providing logic pulses in quadrature, while the UVW output emulates the three Hall switches usually used for the block commutation of a three-phase electric motor. The ABZ and UVW pins of the MA302 are routed on two standard 2.54 mm (0.1 inches) pitch 1x3 header, mounted on the Angle 5 Click, so it can be easily accessed by an external application.
The Angle 5 Click Board™ is designed to be operated only with a 3.3V logic voltage level. A proper logic voltage level conversion should be performed before the Click board™ is used with MCUs with different logic levels. However, the Click board™ comes equipped with a library that contains easy to use functions and an example code that can be used as a reference for further development.
SPECIFICATIONS
Type | Magnetic |
Applications | Can be used for various applications such as detecting the absolute rotor position of a brushless motor in real-time, even without a target magnet, by measuring the fringe field of the rotor. |
On-board modules | The Angle 5 Click Board™ is based on the MA302, a 12-bit digital contactless angle sensor with ABZ and UVW incremental outputs from Monolithic Power Systems. |
Key Features | Fast data acquisition, magnetic field strength detection, contactless sensing for long life, supported both end-of-shaft and off-axis, and many more. |
Interface | SPI |
Compatibility | mikroBUS |
Click board size | L (57.15 x 25.4 mm) |
Input Voltage | 3.3V |
PINOUT DIAGRAM
This table shows how the pinout on the Angle 5 Click Board™ corresponds to the pinout on the mikroBUS™ socket (the latter shown in the two middle columns).
Notes | Pin | Pin | Notes | ||||
---|---|---|---|---|---|---|---|
NC | 1 | AN | PWM | 16 | MGH |
Magnetic Field |
|
NC | 2 | RST | INT | 15 | MGL |
Magnetic Field |
|
SPI Chip Select | CS | 3 | CS | RX | 14 | NC | |
SPI Clock | SCK | 4 | SCK | TX | 13 | NC | |
SPI Data OUT | SDO | 5 | MISO | SCL | 12 | NC | |
SPI Data IN | SDI | 6 | MOSI | SDA | 11 | NC | |
Power Supply | 3.3V | 7 | 3.3V | 5V | 10 | NC | |
Ground | GND | 8 | GND | GND | 9 | GND | Ground |
ONBOARD SETTINGS AND INDICATORS
Label | Name | Default | Description |
---|---|---|---|
LD1 | PWR | - | Power LED Indicator |
J1 | M1x3 | - | A, B, Z incremental encoder outputs |
J2 | M1x3 | - | U, V, W block commutation outputs |
ANGLE 5 CLICK ELECTRICAL SPECIFICATIONS
Description | Min | Typ | Max | Unit |
---|---|---|---|---|
Supply Voltage | -0.5 | 3.3 | +4.6 | V |
Applied Magnetic Filed | 30 | 60 | - | mT |
Magnetic Field Detection Accuracy | - | 5 | - | mT |
Effective resolution | 11 | 11.8 | 12.8 | bit |
Operating Temperature Range | -40 | - | +125 | °C |
Software Support
We provide a library for the Angle 5 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
The library contains a basic functions for using the Angle 5 Click Board™.
Key Functions
uint16_t angle5_read_raw_angle ( void )
- Reads Raw Angle datafloat angle5_read_angle_deg ( void )
- Reads Angle data in deg
Example Description
The application is composed of three sections :
- System Initialization - Initializes the SPI module and all necessary GPIO pins.
- Application Initialization - Initializes dvicer init
- Application Task - Reads the angle position of the magnet and log data to USB UART
void application_task ( ) { char demo_text[ 20 ]; char log_txt[ 2 ] = { 13, 0 }; float new_angle = 0; mikrobus_logWrite( log_txt, _LOG_TEXT ); mikrobus_logWrite( " ", _LOG_TEXT ); mikrobus_logWrite( log_txt, _LOG_TEXT ); new_angle = angle5_read_angle_deg( ); FloatToStr( new_angle, demo_text ); mikrobus_logWrite( " Angle: ", _LOG_TEXT ); mikrobus_logWrite( demo_text, _LOG_TEXT ); Delay_ms( 100 ); }
The full application code, and ready to use projects can be found on our LibStock page.
Other mikroE Libraries used in the example:
- SPI Library
- UART Library
- Conversions Library
Additional Notes and Information
Depending on the development board you are using, you may need a USB UART click, USB UART 2 click or RS232 click 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 5 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.
Software Support
We provide a library for the Angle 5 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
The library contains a basic functions for using the Angle 5 Click Board™.
Key Functions
uint16_t angle5_read_raw_angle ( void )
- Reads Raw Angle datafloat angle5_read_angle_deg ( void )
- Reads Angle data in deg
Example Description
The application is composed of three sections :
- System Initialization - Initializes the SPI module and all necessary GPIO pins.
- Application Initialization - Initializes dvicer init
- Application Task - Reads the angle position of the magnet and log data to USB UART
void application_task ( ) { char demo_text[ 20 ]; char log_txt[ 2 ] = { 13, 0 }; float new_angle = 0; mikrobus_logWrite( log_txt, _LOG_TEXT ); mikrobus_logWrite( " ", _LOG_TEXT ); mikrobus_logWrite( log_txt, _LOG_TEXT ); new_angle = angle5_read_angle_deg( ); FloatToStr( new_angle, demo_text ); mikrobus_logWrite( " Angle: ", _LOG_TEXT ); mikrobus_logWrite( demo_text, _LOG_TEXT ); Delay_ms( 100 ); }
The full application code, and ready to use projects can be found on our LibStock page.
Other mikroE Libraries used in the example:
- SPI Library
- UART Library
- Conversions Library
Additional Notes and Information
Depending on the development board you are using, you may need a USB UART click, USB UART 2 click or RS232 click 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 5 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 5 Click Board
Frequently Asked Questions
Have a Question?
Be the first to ask a question about this.