ST STEVAL-MKI132V1 Скачать руководство пользователя страница 14

UM1579

Supported commands

Doc ID 023744 Rev 1

13/26

4 Supported 

commands

The microcontroller mounted on the BlueMotion board is equipped with dedicated firmware 

that supports a set of commands which allows either the digital or the analog output MEMS 

sensor to be controlled and permits the acquisition of the measured data. The firmware also 

handles the communication between the board and the PC through a Bluetooth connection. 

These features allow the user to easily write their own applications to exploit the capabilities 

of the sensor chosen.

This section describes the commands that are supported by the firmware for the 

microcontroller of the BlueMotion demonstration board.

4.1 Getting 

started

Before using the commands supported by the firmware, the following procedure must be 

performed:

1.

Connect the BlueMotion to the PC using Bluetooth.

2. 

Launch an application which allows commands to be sent through the virtual serial 

port. The remainder of this document assumes the use of the “Microsoft

® 

HyperTerminal” program available with the Windows

®

 XP operating system.

3. 

Create a new connection, enter a name (e.g. “BlueMotion”), and click “OK”.

4. 

In the “Connect Using” field, select the Bluetooth serial COM port to which the 

BlueMotion has been connected, and click “OK”.

5. 

In port settings, set bits per second to 115200, data bits to 8, parity to none, stop bits to 

1, and flow control to none. Click “OK”.

6. 

On the “HyperTerminal” application window choose “files” > “properties” > “settings”, 

then click on the “ASCII Setup” button.

7. 

Select “Send line ends with line feeds” and “Echo typed characters locally”.

8. 

Click the “OK” button to close the “ASCII Setup” window.

9. 

Click the “OK” button to close the “Properties” window.

Once this procedure has been completed the user can utilize the commands described in 

the following sections by typing them into the “HyperTerminal” window.

4.2 Supported 

commands

The firmware supports a wide range of MEMS adapters; the next section reports the 

complete list of supported commands (see 

Table 2

) and their description.

Then, the list of commands (split into sections) available for each sensor supported by the 

BlueMotion firmware is reported.

Содержание STEVAL-MKI132V1

Страница 1: ...the information therein All referenced brands product names service names and trademarks are the property of their respective owners 00000005981LF 000 EOS Power Buy Now We have 45 000 LP502030 PCM NT...

Страница 2: ...etooth module it functions as a bridge between the sensor on the adapter board and the PC It is possible to connect the BlueMotion to the PC using the Bluetooth module and using the Unico graphical us...

Страница 3: ...er boards 12 4 Supported commands 13 4 1 Getting started 13 4 2 Supported commands 13 4 2 1 Commands list and description 14 4 2 2 Digital output accelerometers supported commands 19 4 2 3 Digital out...

Страница 4: ...ata coming from the MEMS sensor connected to the board can be read through the PC GUI provided with the board The BlueMotion can be flashed with compatible firmware using an SWD connector or a UART co...

Страница 5: ...ev 1 Figure 2 Connecting BlueMotion using UART Download the hexadecimal file of the firmware on BlueMotion using the STM32 flash loader utility For further details refer to the utility s user manual F...

Страница 6: ...onnecting BlueMotion using UART The BlueMotion also integrates one general purpose LED and two LEDs connected directly to the interrupt pins of the digital adapters The top view and the bottom view of...

Страница 7: ...The BlueMotion demonstration board can be used with the Unico GUI interface which allows simple interaction with the sensor The steps required for establishing a Bluetooth connection with the board an...

Страница 8: ...ef 2 be used to program the BlueMotion board Jumper JP1 allows the user to measure the sensor current consumption by connecting a multimeter in series with its terminals when a 1 5 V power supply is u...

Страница 9: ...le that can be flashed to the board The section below describes the procedure for establishing a Bluetooth connection with the BlueMotion board 2 1 Establishing Bluetooth connection A Bluetooth connec...

Страница 10: ...tion Doc ID 023744 Rev 1 9 26 Figure 7 Searching the BlueMotion board To pair the device right click on the icon eMotion BT and select Pair Enter 1234 in the Passkey field in the dialogue box shown in...

Страница 11: ...The next step is to connect to the BlueMotion board Click on the eMotion BT icon and then click on the Bluetooth Serial Port icon as shown in Figure 9 In this example the board is assigned the port CO...

Страница 12: ...UM1579 BlueMotion board installation Doc ID 023744 Rev 1 11 26 Figure 9 Connecting to the BlueMotion board AM14731V1...

Страница 13: ...f supported MEMS adapter boards Adapter board Device STEVAL MKI089V1 LIS331DLH STEVAL MKI105V1 LIS3DH STEVAL MKI106V1 LSM303DLHC STEVAL MKI107V1 L3G4200D STEVAL MKI107V2 L3GD20 STEVAL MKI108V1 9AXISMO...

Страница 14: ...t assumes the use of the Microsoft HyperTerminal program available with the Windows XP operating system 3 Create a new connection enter a name e g BlueMotion and click OK 4 In the Connect Using field...

Страница 15: ...ad e g MRAAhDDh mwAADD Magnetometer register write single It gets a single X Y and Z data acquisition see Table 4 list Prints the list of MKIs supported e g MKI105V1 listdev Prints the list of devices...

Страница 16: ...SW1 is pressed otherwise 0 Bit 1 has the same behavior but is dedicated to the SW2 Before sending the start command the device must be out from 3 state and some registers must be configured according...

Страница 17: ...on the lines are in 3 state mode and the user is required to send the Zoff command to allow communication between the sensor and the microcontroller If Zoff has not been launched the firmware ignores...

Страница 18: ...is the address sent by the user and DD is the data present in the register For example to read the register at address 0x20 the user issues the command gr20 which returns e g GR20hC7h Gyroscope regis...

Страница 19: ...read of the register just written This function is useful to check if the write has succeeded For instance if the echoon command is launched after a w2027 it results R2027 Echo off The echooff command...

Страница 20: ...ter connected start Starts continuous data acquisition see Table 3 debug Returns the output data in readable text format see Table 4 stop Stops data acquisition Zon Forces 3 state Zoff Exits from 3 st...

Страница 21: ...t data in readable text format see Table 4 stop Stops data acquisition Zon Forces 3 state Zoff Exits from 3 state dev Device name e g LIS3DH ver Firmware version e g V1 0 grAA Gyroscope register read...

Страница 22: ...set the data rate to 50 Hz 4 Send the debug command to get the X Y and Z data measured by the sensor 5 Send stop to end the continuous acquisition and visualization Table 7 Digital output magnetometer...

Страница 23: ...DC8 15 PB1 ADC9 16 STM32F103TB U3 Vin 1 Gnd 2 EN 3 BYPASS 4 Vout 5 lds3985xx30 U2 33nF C10 1uF C7 1 2 Current_Measure JP2 Vdd_dut VDD 18pF Cosc2 18pF Cosc1 1M R10 OSCOUT 1 2 3 4 16MHz Osc1 OSCOUT VDD...

Страница 24: ...7 F 0603 C12 1 CAP 10 nF 0402 C13 1 CAP 100 nF 0402 Cosc1 1 CAP 18 pF 0402 Cosc2 1 CAP 18 pF 0402 D1 1 LED_SMD LED_SMDg LED_SMD_0603 D4 1 LED_SMD LED_SMDr LED_SMD_0603 D5 1 LED_SMD LED_SMDg LED_SMD_0...

Страница 25: ...Res1 1 M 0402 R11 1 Res1 130R 0402 R12 1 Res1 130R 0402 R13 1 Res1 130R 0402 U1 1 L6920 L6920DC L6920DC U2 1 Component_1 lds3985xx30 SOT23 5 U3 1 STM32F103TB_VF QFPN36 STM32F103TB VFQFPN36 U4 1 Blueto...

Страница 26: ...UM1579 Revision history Doc ID 023744 Rev 1 25 26 7 Revision history Table 9 Document revision history Date Revision Changes 29 Jan 2013 1 Initial release...

Страница 27: ...RRANTIES OF MERCHANTABILITY FITNESS FOR A PARTICULAR PURPOSE AND THEIR EQUIVALENTS UNDER THE LAWS OF ANY JURISDICTION OR INFRINGEMENT OF ANY PATENT COPYRIGHT OR OTHER INTELLECTUAL PROPERTY RIGHT UNLES...

Отзывы: