austriamicrosystems AG is now ams AG The technical content of this austriamicrosystems application note is still valid. Contact information: Headquarters: ams AG Tobelbaderstrasse 30 8141 Unterpremstaetten, Austria Tel: +43 (0) 3136 500 0 e-Mail: [email protected] Please visit our website at www.ams.com AS5311 Demoboard OPERATION MANUAL Application note 1 General Overview The AS5311 is a contactless high resolution magnetic linear encoder for accurate linear motion and off-axis rotary sensing with a resolution down to <0.5µm. It is a system-on-chip, combining integrated Hall elements, analog front end and digital signal processing on a single chip, packaged in a small 20-pin TSSOP package. al id A multipole magnetic strip or ring with a pole length of 1.0mm is required to sense the rotational or linear motion. The magnetic strip is placed above the IC at a distance of typ. 0.3mm. lv The absolute measurement provides instant indication of the magnet position within one pole pair with a resolution of 488nm per step (12-bit over 2.0mm). This digital data is available as a serial bit stream and as a PWM signal. Furthermore, an incremental output is available with a resolution of 1.95 µm per step. An index pulse is generated once for every pole pair (once per 2.0mm).The travelling speed in incremental mode is up to 650mm/second. An internal voltage regulator allows the AS5311 to operate at either 3.3 V or 5 V supplies. am lc s on A te G nt st il Depending on the application the AS5311 accepts multi-pole strip magnets as well as multi-pole ring magnets, both radial and axial magnetized. 2 The AS5311 Demoboard The AS5311 demoboard is a complete linear encoder system with built-in microcontroller, USB interface, graphical LCD display, incremental indicators, incremental counter serial communication and PWM output LED. The board is USB powered or externally supplied with a 9V battery for standalone operation. USB plug (power supply or PC communication) LCD display 9V battery connector (standalone only) J6: External Encoder SSI Connector ni ch SW1: Encoder selection - External (top) - Onboard (bottom) ca J4: PWM output and indicator J8: AS5311 status signals connector and indicators Slider with multipole magnet (1mm pole length) over AS5311 J7: AS5311 inceremental A/B and Index connector and indicators Te Slider guide S1: Incremental counter reset switch Figure 1: AS5311 Demoboard hardware with mounted magnet knob Revision 1.0, 09 April 2009 Page 1 of 9 www.austriamicrosystems.com 3 Operating the AS5311 Demoboard The AS5311 demoboard can be used in several ways: • As standalone unit supplied by a 9V battery Connect a 9V battery to the battery connector on the top right side of the board. No other connections are required. • As standalone unit supplied by an USB port Connect the demoboard to a PC using a USB/USB cable (included in demoboard shipment). The board is supplied by the 5V supply of the USB port. No other connections are required. 3.1.1 Hardware Indicators and Connectors Graphic LCD display al id 3.1 lv The LCD display shows the realtime absolute and relative position of the magnet: - The absolute position is read from the AS5311 serial output. The resolution is 0.488µm = 4096 positions per pole pair (2mm). To use this feature with the onboard encoder, switch SW1 must be on position INT. - The relative position is read from the incremental counter connected on the AB outputs of the AS5311. The resolution is 1.95µm / step. To use this feature with the onboard encoder, jumpers P1 and P2 (Bottom side) must be CLOSED. am lc s on A te G nt st il Moving the slider from right to left will increase the absolute value until 4095 (1999µm) with 0.488µm steps, then returns to 0. The incremental counter will increment on the same way with 1.95µm steps. To reset the relative position, press the push button S1. The magnet status indicator (magnet OK), U (magnet too close or too far, reduced accuracy), ± (magnet too close or too far , values not valid and display stopped) is related to the magnet position. ABSOLUTE POSITION 0.488µm/step Absolute position in a pole pair (2mm) 12 bit value (0 ~ 4095) 1 step = 0.488µm Absolute position in a pole pair 0 ~ 1999µm RELATIVE POSITION 1.95µm/step Relative position from quadrature AB counter 1 step = 1.95µm Relative position from quadrature AB counter in µm Absolute position bargraph 0~100% in a pole pair Magnetic field status: Figure 2: LCD display in standalone mode (9V battery or USB powered without GUI) U PWM LED ca ± 3.1.2 Magnet OK Magnet too far or too close, reduced accuracy Magnet too far or too close, value not valid Te ch ni This LED is connected to the PWM output of the AS5311. The PWM output is a pulse width that is proportional to the position of a pole-pair of the magnet The pulse width varies from 1μs to 4096μs typ with a repetition rate of 244 Hz typ.. When the position of the pole-pair is 0, the LED is almost dark, as it is 1μs on and 4095μs off. Moving the magnet to the left increases the brightness of the PWM LED, since the ON-pulse becomes longer and the OFF-pulse becomes shorter. The brightness of the PWM LED follows the absolute position bargraph. Likewise, the PWM output can be used as an analog output proportional to the angle, when the PWM signal is filtered by a RC (or active) lowpass filter. The PWM signal (0 ~ 3V3) can be directly taken from the connector J4. 3.1.3 Incremental quadrature AB-Index LED The phase shift between channel A and B indicates the direction of the magnet movement. Channel A leads channel B during a right-to-left movement of the magnet by 90 electrical degrees. Channel B leads channel A during a left-to-right movement. One Index pulse (3V3) is generated at each pole pair changes (see AS5311 datasheet Figure 9). The AB-Index LEDs are directly connected to the A B Index outputs of the AS5311. These quadrature signals (0 ~ 3V3) are available on connector J7. Revision 1.0, 09 April 2009 Page 2 of 9 www.austriamicrosystems.com AS5311 Demoboard OPERATIONAL MANUAL 3.1.4 MagINCn and MagDECn MagINCn and MagDECn are the magnetic field change indicators (magnetic field strength increase or decrease through variation of the distance between the magnet and the device). 3.1.5 al id These outputs can be used to detect the valid magnetic field range. LEDs MagINC and MagDEC OFF, the magnet is correctly positioned LCD indicator LED MagINC ON and MagDEC OFF, magnet too close or too far, reduced accuracy LCD indicator U LEDs MagINC and MagDEC ON, magnet too close or too far , values not valid and display stopped LCD indicator ± Encoder selection switch The switch SW1 selects the encoder which communicates with the microcontroller through the SSI bus (Absolute position): INT (Bottom position, default): Onboard AS5311 2. External AS5311 connected on J6 EXT (Top Position): The signals of the synchronous serial interface (DO, CLK, CSn) and the power supply (3.3V, GND) of an external device can be connected directly to J6. In this configuration, the data of the serial interface (absolute position) are displayed on the GUI or the LCD. am lc s on A te G nt st il lv 1. If the incremental AB position of the external encoder is used, remove the jumpers P1 and P2 (bottom side of the board), and connect the AB signals from the encoder to the jumpers as shown on figure 3 below. ca Serial Outputs (absolute) Demoboard switched to external encoder mode ch ni Demoboard TOP view Incremental Outputs (Relative) Te Demoboard BOTTOM view Figure 3: external AS5311 connection to the demoboard (top and bottom view) Revision 1.0, 03 April 2009 www.austriamicrosystems.com Page 3 of 9 AS5311 Demoboard OPERATIONAL MANUAL am lc s on A te G nt st il Battery lv SPI al id 4 AS5311 Demoboard bloc diagram, schematics, layout Figure 9: AS5311 bloc diagram C1 100n C2 10u U1 5V 7 RegIn P2.7 P2.6 P2.5 P2.4 P2.3 P2.2 P2.1 P2.0 3.3V 6 C5 1u GND 3 VDD GND GND J2 ISP 3.3V GND Header 4 J3 1 2 3 4 VBUS DD+ GND USB C2D 8 5 4 5 SHLD 9 10 C2CK 1 2 3 4 440478-1 GND P1.7 P1.6 P1.5 P1.4 P1.3 P1.2 P1.1 P1.0 RST/C2CK P3.0/C2D VBUS DD+ D7 D6 D5 D4 D3 D2 D1 D0 19 20 21 22 23 24 25 26 Index B A Prog LCD_E LCD_RW LCD_A0 Analog_in 27 28 29 30 31 32 1 2 P0.7 P0.6 P0.5 P0.4 P0.3 P0.2 P0.1 P0.0 3V 11 12 13 14 15 16 17 18 C3 3V R1 10k Int_CLK Ext_CLK DO CSn SS/ MOSI MISO SCK C8051F320 R9 1k DS3 LED_R LED_R Jumper2 P2 Jumper2 GND Header 4 DS7 GND DS6 DS5 LED_G R12 1k A R11 1k GND B D1 J5 R10 1k Ind R13 5V 33R DisplayTech32128a C26 15p nc MagINCn MagDECn A B nc Index VSS Prog nc nc VDD5V VDD3V3 nc nc PWM CSn CLK DO nc 20 19 18 17 16 15 14 13 12 11 R7 1M GND 3.3V Y1 20MHz C27 15p C19 1u SS/ SCK MISO MOSI J4 PWM GND R4 4.7k VDD CNT_EN A B INDEX/ DFLAG/ LFLAG/ 14 13 12 11 10 9 8 3.3V GND A 100n B Reset_CNT R15 47k S1 SW-PB GND J9 Reset_CNT Analog_in R3 68k GND GND R6 1k GND GND Fcko Fcki VSS SS/ SCK MISO MOSI 22k C18 1u DS1 LED3 AS5311 C17 U5 1 2 3 4 5 6 7 LS7366 R5 PWM Int_CSn Int_CLK Int_DO Int_DO SW1 J6 GND DO CLK CSn 3.3V 5V Prog GND D2 1 2 3 4 5 6 7 Header 7 Ext_DO Ext_CLK Ext_CSn Prog DO GND INT_CSn 3.3V 5V CSn MCLSS22_DPDT External encoder BAT54 U3 Vbat 3 1 2 C25 10n LED_Y ch LED_G 1 MagINCn 2 MagDECn 3 A_out 4 B_out 5 6 7 8 Prog 9 10 ni P1 A B Index BL_A LCD Backlight Inc DS4 U2 1 2 3 4 D3 BAS70-05 R8 1k 3.3V J7 68R GND ca Header 2 R14 Vbat 1 MagINCn MagDECn 2 1 100n 2 J8 C7 100n GND Shield 0 GND CS1n RESn A0 R/W E D0 D1 D2 D3 D4 D5 D6 D7 VDD VSS Vout Cap3Cap1+ Cap1Cap2Cap2+ V1 V2 V3 V4 V5 VDD C86 GND 3.3V Dec C6 J1 1 GND 2 GND LCD_A0 3 100n LCD_RW 4 D7..0 LCD_E 5 D0 6 D1 7 D2 8 D3 9 D4 10 C8 D5 11 1u/16V D6 12 GND D7 13 14 R2 3V C9 15 nc GND 1u/16V 16 C10 17 1u/16V 18 C11 19 1u/16V 20 21 22 23 24 25 26 C12 C13 C14 C15 C16 27 3V 28 1u/16V 1u/16V 1u/16V 1u/16V 1u/16V Vin Vout U4 5V 2 3 3V Vin Vout 2 LL4001 Te C22 22u AS1360-50 C23 10u C21 1u 9V Battery Revision 1.0, 03 April 2009 GND 1 GND GND 1 Header 2 AS1360-30 C24 1u GND Figure 7: AS5311 Demoboard schematics www.austriamicrosystems.com Page 4 of 9 am lc s on A te G nt st il lv al id AS5311 Demoboard OPERATIONAL MANUAL Te ch ni ca Figure 4: AS5311 Demoboard PCB Layout Revision 1.0, 03 April 2009 www.austriamicrosystems.com Page 5 of 9 AS5311 Demoboard OPERATIONAL MANUAL Index General Overview.............................................................................................................................................................. 1 The AS5311 Demoboard................................................................................................................................................... 1 Operating the AS5311 Demoboard ................................................................................................................................... 2 3.1 Hardware Indicators and Connectors ....................................................................................................................... 2 3.1.1 Graphic LCD display ........................................................................................................................................ 2 3.1.2 PWM LED ........................................................................................................................................................ 2 3.1.3 Incremental quadrature AB-Index LED ............................................................................................................ 2 3.1.4 MagINCn and MagDECn ................................................................................................................................. 3 3.1.5 Encoder selection switch.................................................................................................................................. 3 4 AS5311 Demoboard bloc diagram, schematics, layout..................................................................................................... 4 Index........................................................................................................................................................................................... 6 Revision History ......................................................................................................................................................................... 7 Contact ....................................................................................................................................................................................... 8 Copyright .................................................................................................................................................................................... 9 Te ch ni ca am lc s on A te G nt st il lv al id 1 2 3 Revision 1.0, 03 April 2009 www.austriamicrosystems.com Page 6 of 9 AS5311 Demoboard OPERATIONAL MANUAL Revision History Revision Date March.16, 2009 First version Te ch ni ca am lc s on A te G nt st il lv al id R1.0 Description Revision 1.0, 03 April 2009 www.austriamicrosystems.com Page 7 of 9 AS5311 Demoboard OPERATIONAL MANUAL Contact Headquarters austriamicrosystems USA, Inc. austriamicrosystems Germany GmbH 8601 Six Forks Road Tegernseer Landstrasse 85 Suite 400 D-81539 München, Germany Raleigh, NC 27615, USA Phone: +49 89 69 36 43 0 Phone: +1 919 676 5292 +49 89 69 36 43 66 Fax: +1 509 696 2713 Fax: austriamicrosystems USA, Inc. Via A. Volta, 18 4030 Moorpark Ave am lc s on A te G nt st il austriamicrosystems Italy S.r.l. lv Sales Offices al id austriamicrosystems AG A 8141 Schloss Premstätten, Austria Phone: +43 3136 500 0 Fax: +43 3136 525 01 [email protected] www.austriamicrosystems.com Suite 116 I-20094 Corsico (MI), Italy Phone: +39 02 4586 4364 Fax: +39 02 4585 773 San Jose, CA 95117, USA Phone: +1 408 345 1790 Fax: +1 509 696 2713 austriamicrosystems France S.A.R.L. austriamicrosystems AG 124, Avenue de Paris F-94300 Vincennes, France Phone: +33 1 43 74 00 90 Fax: +33 1 43 74 20 98 austriamicrosystems Switzerland AG Rietstrasse 4 Suite 811, Tsimshatsui Centre East Wing, 66 Mody Road Tsim Sha Tsui East, Kowloon, Hong Kong Phone: +852 2268 6899 Fax: +852 2268 6799 CH 8640 Rapperswil, Switzerland austriamicrosystems AG Phone: +41 55 220 9008 AIOS Gotanda Annex 5th Fl., 1-7-11, Fax: +41 55 220 9001 Higashi-Gotanda, Shinagawa-ku Tokyo 141-0022, Japan 88, Barkham Ride, ca austriamicrosystems UK, Ltd. Phone: +81 3 5792 4975 Fax: +81 3 5792 4976 Finchampstead, Wokingham austriamicrosystems AG Phone: +44 118 973 1797 #805, Dong Kyung Bldg., Fax: +44 118 973 5117 824-19, Yeok Sam Dong, Kang Nam Gu, Seoul austriamicrosystems AG Korea 135-080 ch ni Berkshire RG40 4ET, United Kingdom Klaavuntie 9 G 55 Phone: +82 2 557 8776 FI 00910 Helsinki, Finland Fax: +82 2 569 9823 +358 9 72688 170 Fax: +358 9 72688 171 Te Phone: austriamicrosystems AG Singapore Representative Office austriamicrosystems AG 83 Clemenceau Avenue, #02-01 UE Square Bivägen 3B 239920, Singapore S 19163 Sollentuna, Sweden Phone: +65 68 30 83 05 Phone: Fax: +65 62 34 31 20 +46 8 6231 710 Revision 1.0, 03 April 2009 www.austriamicrosystems.com Page 8 of 9 AS5311 Demoboard OPERATIONAL MANUAL Copyright Devices sold by austriamicrosystems are covered by the warranty and patent indemnification provisions appearing in its Term of Sale. austriamicrosystems makes no warranty, express, statutory, implied, or by description regarding the information set forth herein or regarding the freedom of the described devices from patent infringement. austriamicrosystems reserves the right to change specifications and prices at any time and without notice. Therefore, prior to designing this product into a system, it is necessary to check with austriamicrosystems for current information. This product is intended for use in normal commercial applications. Te ch ni ca am lc s on A te G nt st il lv al id Copyright © 2009 austriamicrosystems. Trademarks registered ®. All rights reserved. The material herein may not be reproduced, adapted, merged, translated, stored, or used without the prior written consent of the copyright owner. To the best of its knowledge, austriamicrosystems asserts that the information contained in this publication is accurate and correct. However, austriamicrosystems shall not be liable to recipient or any third party for any damages, including but not limited to personal injury, property damage, loss of profits, loss of use, interruption of business or indirect, special, incidental or consequential damages, of any kind, in connection with or arising out of the furnishing, performance or use of the technical data herein. No obligation or liability to recipient or any third party shall arise or flow out of austriamicrosystems rendering of technical or other services. Revision 1.0, 03 April 2009 www.austriamicrosystems.com Page 9 of 9