传感器知识库

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

Sensors Knowledge Base

讨论

排序依据:
My friend Matt Muddiman of Freescale gave this presentation as part of the MEMS Education Series (hosted by Arizona Technology Council and MEMS Industry Group) in Scottsdale Arizona earlier this week.
查看全文
This time, I would like to share with you an example project using the MPL115A1, the NXP digital barometer.   The MPL115A1 is a simple barometer with digital output for cost-effective applications. It employs a MEMS pressure sensor with a conditioning integrated circuit to provide accurate pressure data. An integrated analog-to-digital converter (ADC) provides digitized temperature and pressure sensor outputs via serial peripheral interface (SPI), with bus speeds up to 8 Mbps.   You may find more information at: MPL115A: 50 to 115kPa, Absolute Digital Pressure Sensor.   I created this project using the FRDM-KL25Z platform and the MPL115A1 absolute digital pressure sensor. The complete source code is written in KDS IDE. You may find the complete project attached to this post.   This document gives you an introduction of the MPL115A1 pressure sensor as well as the different configurations and guides you through the initialization process and how to appreciate the demonstration.   Introduction to the example project This example is based on the application note AN3785 -How to Implement the Freescale MPL115A Digital Barometer. I recommend using it as a reference.   Through this example project, the MCU is configured to use the SPI interface and the PIT module. The local pressure is read every second.   There are MPL115A1 SPI commands to read coefficients, execute Pressure and Temperature conversions, and to read Pressure and Temperature data. The sequence of the commands for the interaction is given as an example to operate the MPL115A1. Initialization of the MKL25Z128 MCU.   Sequence flow chart. The MPL115A1 interfaces to a host (or system) microcontroller in the user’s application. All communications are via SPI. A typical usage sequence is as follows: Every stage of the flow chart is applied on this example and explained below.   Reading coefficient data These are MPL115A2 SPI commands to read coefficients. The coefficients are usually stored in the host microcontoller local memory but can be re-read at any time.   Reading of the coefficients may be executed only once and the values stored in the host microcontroller. It is not necessary to read this multiple times because the coefficients within a device are constant and do not change.   Read Coefficients: [CS=0], [0x88], [0x00], [0x8A], [0x00], [0x8C], [0x00], [0x8E], [0x00], [0x90], [0x00], [0x92], [0x00], [0x94], [0x00], [0x96], [0x00], [0x00], [CS=1] Once the coefficients are obtained, they are computed inside the MPL115A1_Read_Preassure function.     Data conversion This is the MPL115A2 SPI commands to start conversion.   This is the first step that is performed each time a new pressure reading is required which is initiated by the host sending the CONVERT command. The main system circuits are activated (wake) in response to the command and after the conversion completes, the result is placed into the Pressure and Temperature ADC output registers.   Start conversion: [CS=0], [0x24], [0x00], [CS=1], [13 ms Delay]     This is the MPL115A2 SPI commands to read raw temperature and pressure data.     Start Read raw data: [CS=0], [0x80], [0x00], [0x82], [0x00], [0x84], [0x00,] [0x86], [0x00], [0x00], [CS=1]   Compensated pressure reading Once the raw rata is obtained, the compensation procedure is applied as follow:     Local pressure   Once the steps mentioned above are followed, the MPL115A1_Read_Preassure function returns the local pressure value into the local_pressure variable. I recommend evaluating this variable in order to know the final result.     I hope you find the information useful and funny.   Regards, David  
查看全文
Hi Everyone, This tutorial is a detailed guide on how to import an ISSDK based example project (e.g. mma845x_interrupt) into MCUXpresso IDE, build and run it on the Freedom board (e.g. FRDM-KL27Z). If you intend to use another ISSDK example project/board, you can always follow this guide. A complete list of MCU boards, sensor kits and sensors supported by ISSDK is available in the ISSDK Release notes. 1. Download the FRDM-KL27Z SDK Open a web browser, navigate to the MCUXpresso homepage and select “Login to view configurations” to start a new configuration. You will be redirected to login to nxp.com. Enter your account information or register for a new account. Back on the MCUXpresso homepage, select the drop-down box to create a New Configuration. Select the board (FRDM-KL27Z) from the list and provide a name for the configuration. Select “Specify Additional Configuration Settings” to choose the Host OS, Toolchain (MCUXpresso IDE) and Middleware (ISSDK). Select Configuration Settings: Host OS (example: Windows) Toolchain/IDE (MCUXpresso IDE) Middleware (ISSDK) Once the configurations are set, select “Go to SDK Builder”.   Select “Request Build” to download the SDK. Once the build request is completed, download the SDK. Agree to Software Terms and Conditions. Unzip SDK to a folder (e.g. SDK_2.2.1_FRDM-KL27Z). 2. Import the SDK_2.1.1_FRDM-KL27Z into MCUXpresso IDE Open MCUXpresso IDE. Set the workspace directory of your choice and click on OK. Switch to the Installed SDKs view within the MCUXpresso IDE window. Open Windows Explorer, and drag and drop the SDK_2.2.1_FRDM-KL27Z (unzipped) file into the installed SDKs view. You will get the following pop-up so click on OK to continue the import.   The installed SDK will appear in the Installed SDKs view. 3. Import and build the ISSDK based mma845x_interrupt example project Find the Quickstart Panel in the lower left hand corner and select Import SDK example(s) Click on the FRDM-KL27Z board and then click on Next. Use the arrow button to expand the issdk_examples category, and then click the checkbox next to mma845x_interrupt to select that project. Then, click on Next. On the next screen, click the checkbox to Redirect printf/scanf to UART so that the terminal output gets sent out the UART instead of using semi-hosting through the debugger. Then click on Finish. Now build the project by clicking on the project name in the Project Explorer view and then click on the Build icon in the Quickstart Panel. You can see the status of the build in the Console view. 4. Run the mma845x_interrupt example project   Now that the project has been compiled, we can flash it to the board and run it. Make sure the FRDM-KL27Z board is plugged in, and click on Debug ‘frdmkl27z_issdk_examples_sensors_mma8451q_mma845x_interrupt’ [Debug] MCUXpresso will probe for connected boards and should find the OpenSDA debug probe that is part of the integrated OpenSDA circuit on the FRDM-KL27Z board. Click on OK to continue. The firmware will be downloaded to the board and the debugger started. Open a Terminal program (e.g. Tera Term) and connect to the FRDM-KL27Z COM port that it enumerated as. Use 115200 baud, 8 data, 1 stop, no parity. Start the application in the MCUXpresso IDE by clicking the "Resume" button. The application is now running and signed 14-bit accelerometer output values are displayed on the terminal. To modify the initial register settings of the MMA8451 accelerometer, find the mma845x_Config_Isr[] structure and change it according to your needs. Well done if you managed to follow along and get it all working. If there are any questions, do not hesitate to ask below. Your feedback or suggestions are also welcome. Regards, Tomas
查看全文
Hello community, As continuation of the Different pin styles in pressure sensors post, I would like to add some useful information about the pin styles mentioned on the datasheets. Some pressure sensors shows the following pin style configuration: But… What do V1, V2 and VEx actually mean? How should I connect those pins? Answer: V1, V2 and VEX pins are used for factory trimming and it is recommended to leave these pins unconnected. So, in case of unibody package, you will require only pin #1 (Vout), pin #2 (Ground), and pin #3 (Vs) as follow: I hope you find useful this information. Regards, David
查看全文
I am occasionally asked for the source code for the Android version of our Sensor Fusion Toolbox.  Well, here it is, complete with new NXP graphics and updated links.
查看全文
************************************************************************************************************* * This simple example code has been written for the NXP FRDM-KL25Z + FRDMSTBC-A8471 * boards and demonstrates how to use the embedded transient detection function * in conjunction with the auto-wake/sleep mode for reducing current consumption * of the FXLS8471Q. * * The transient threshold is set to 312.5mg (5 counts) on the X and Y axis. * Once this threshold is exceeded, the FXLS8471Q is waken up and an interrupt * is generated on the INT1 pin. If the acceleration is below this threshold * within the 1s period, the FXLS8471Q goes back to sleep mode and also * generates an interrupt on the INT1 pin. *************************************************************************************************************
查看全文
Presented at Sensors Expo, 25 June 2014
查看全文
Hi, The FXAS2100x, is a small, low-power, yaw, pitch, and roll angular rate gyroscope with 16 bit ADC resolution. The full-scale range is adjustable from ±250°/s to ±2000°/s. It features both I2C and SPI interfaces. Here is a Render of the FXAS2100x Breakout- Board downloaded from OSH Park: Layout Design for this board: In the Attachments section, you can find the Schematic Source File (SCH), Schematic PDF File, Layout Source File (BRD), Gerber Files (GTL, GBL, GTS, GBS, GTO, GBO, GKO, XLN) and BOM files. If you're interested in more designs like this breakout board for other sensors, please go to Freescale Sensors Breakout Boards Designs – HOME
查看全文
Hi Everyone, I would like to share here one of my examples I created for the MPL3115A2 while working with the NXP FRDM-KL25Z platform and FRDMSTBC-P3115 shield board. It illustrates the use of the embedded FIFO buffer to collect either pressure/temperature or altitude/temperature data that are read from the FIFO using an interrupt technique through the I2C interface. The FIFO is set to store the maximum number of samples (32). Each sample consists of 3 bytes of pressure (or altitude) data and 2 bytes of temperature data. Therefore 160 bytes (32 x (3 + 2)) in total are read from the FIFO when the FIFO is full and the FIFO interrupt is asserted. The MPL3115A2 is initialized as follows. /****************************************************************************** * MPL3115A2 initialization function ****************************************************************************** void MPL3115A2_Init (void) { I2C_WriteRegister(MPL3115A2_I2C_ADDRESS, CTRL_REG1, 0x04); // Reset all registers to POR values Pause(0x631); // ~1ms delay I2C_WriteRegister(MPL3115A2_I2C_ADDRESS, F_SETUP_REG, 0xA0); // FIFO Fill mode, 32 samples I2C_WriteRegister(MPL3115A2_I2C_ADDRESS, CTRL_REG4, 0x40); // Enable FIFO interrupt I2C_WriteRegister(MPL3115A2_I2C_ADDRESS, CTRL_REG5, 0x40); // Route the FIFO interrupt to INT1 - PTA5 I2C_WriteRegister(MPL3115A2_I2C_ADDRESS, CTRL_REG2, 0x00); // Time step = ~1s I2C_WriteRegister(MPL3115A2_I2C_ADDRESS, CTRL_REG3, 0x00); // Push-pull, active low interrupt I2C_WriteRegister(MPL3115A2_I2C_ADDRESS, CTRL_REG1, 0x39); // Active barometer mode, OSR = 128 //I2C_WriteRegister(MPL3115A2_I2C_ADDRESS, CTRL_REG1, 0xB9); // Active altimeter mode, OSR = 128 }‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍ In the ISR, only the interrupt flag is cleared and the FIFO_DataReady variable is set to indicate that the FIFO is full. /****************************************************************************** * PORT A Interrupt handler ******************************************************************************/ void PORTA_IRQHandler() { PORTA_PCR5 |= PORT_PCR_ISF_MASK; FIFO_DataReady = 1; }‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍ Once the FIFO_DataReady variable is set, the STATUS register (0x00) is read to clear the FIFO interrupt status bit and deassert the INT1 pin. Afterwars the FIFO is read using a 160-byte (5 x 32 bytes) burst read starting from the OUT_P_MSB register (0x01). Then the raw pressure (or altitude) and temperature data are converted to real values. if (FIFO_DataReady) { FIFO_DataReady = 0; FIFO_Status = I2C_ReadRegister(MPL3115A2_I2C_ADDRESS, STATUS_REG); // Read the Status register to clear the FIFO interrupt status bit I2C_ReadMultiRegisters(MPL3115A2_I2C_ADDRESS, OUT_P_MSB_REG, 5*Watermark_Val, RawData); // Read the FIFO using a burst read for (i = 0; i < Watermark_Val; i++) { /* Get pressure, the 20-bit measurement in Pascals is comprised of an unsigned integer component and a fractional component. The unsigned 18-bit integer component is located in OUT_P_MSB, OUT_P_CSB and bits 7-6 of OUT_P_LSB. The fractional component is located in bits 5-4 of OUT_P_LSB. Bits 3-0 of OUT_P_LSB are not used. */ Pressure[i] = (float) (((RawData[0 + i*5] << 16) | (RawData[1 + i*5] << 8) | (RawData[2 + i*5] & 0xC0)) >> 6) + (float) ((RawData[2 + i*5] & 0x30) >> 4) * 0.25; /* Get temperature, the 12-bit temperature measurement in °C is comprised of a signed integer component and a fractional component. The signed 8-bit integer component is located in OUT_T_MSB. The fractional component is located in bits 7-4 of OUT_T_LSB. Bits 3-0 of OUT_T_LSB are not used. */ Temperature[i] = (float) ((short)((RawData[3 + i*5] << 8) | (RawData[4 + i*5] & 0xF0)) >> 4) * 0.0625; /* Get altitude, the 20-bit measurement in meters is comprised of a signed integer component and a fractional component. The signed 16-bit integer component is located in OUT_P_MSB and OUT_P_CSB. The fraction component is located in bits 7-4 of OUT_P_LSB. Bits 3-0 of OUT_P_LSB are not used */ //Altitude[i] = (float) ((short) ((RawData[0 + i*5] << 8) | RawData[1 + i*5])) + (float) (RawData[2 + i*5] >> 4) * 0.0625; } } ‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍ Deassertion of the INT1 pin after reading the STATUS register (0x00). The auto acquisition time step is set in this example to the lowest possible value (1s), so the FIFO is read every ~32s. The calculated values can be watched in the "Variables" window on the top right of the Debug perspective. Attached you can find the complete source code. If there are any questions regarding this simple example project, please feel free to ask below. Your feedback or suggestions are also welcome.   Regards, Tomas
查看全文
SOP Top Side Port Package_1369-01  
查看全文
MEMS sensors are mechanical structure chips and easily damaged by shock or huge vibration. Sensor package trend is going to small size, and it is not easy to solder by hand on pcb to verify. In order to do sensor verification before FA process, it is necessary to use a tool to load the failed chips and use I2C/SPI to access sensor registers to check sensor function. This document introduces to use sensor fixture and toolbox for a simple sensor verify tool. It is easy to provide precise failed spec items by this tool and to speed-up FA process.
查看全文
The attached is a copy of a presentation given 24 June 2014 at the Sensors Expo Conference in Rosemont IL.
查看全文
All, We've had some problems with migration of Freescale blogs over to the NXP domain.  One set of listings that gets requested a fair bit are the postings on orientation representations.  The attached is a PDF version of the same material which will be contained in the upcoming Sensor Fusion Version 7.00 User Guide.
查看全文
You saw it here first! The attached zip file contains full documentation and source code (both CodeWarrior and KDS) for Version 5 of Freescale's Sensor Fusion Library for Kinetis MCUs. The 6 and 9-axis Kalman filters have been rewritten from scratch by fusion expert Mark Pedley.  The new versions have improved dynamic tracking and at-rest stability.  All documentation has been updated, and full implementation details are included.  We continue to use the BSD 3-clause software license, so you are virtually unlimited in how you use the library.   I will note that due to the Kalman filter changes, Mark made some changes to the undocumented Kalman filter packets which are utilized by the Windows Version of the Freescale Sensor Fusion Toolbox.  This breaks compatibility with older versions of the toolbox.  I will be posting a pre-release of the new one immediately after completing this post.  The Android version of the toolbox does not make use of the Kalman filter packet, and should be forward compatible - although an updated version of that is in the works as well.   Structure of the new library is very similar to Version 4.22, which was the previous production version.  There are changes, but I don't expect anyone to have problems adapting existing projects to the new version of the library.  I think you will get improved performance if you do.   Regards, Mike Stanley
查看全文
This is a pre-release version of the Sensor Fusion Toolbox for Windows.  It is essentially the same tool you already know and love.  It differs in terms of the binary images that can be downloaded to your development board.  Clicking File->Flash from the toolbar will present you with a set up updated binaries.  These were built using a brand new set of 6- and 9-axis Kalman filter algorithms.  We expect these to consume much less power (2X or 3X) and to have better gyro tracking.  We are soliciting feedback from existing users of the toolkit with regard to performance of the new filters.  We do not expect to formally release until later in Q2, primarily to give the community time to try them and give us feedback.  We are not releasing source just yet, for the same reason.
查看全文
Current errata for ISF 2.1
查看全文
Posted here in response to a query by Michael Smorto. Regards, Mike Stanley
查看全文
clicktaleID