# Patent application title: PARAMETER ESTIMATION FOR ACCELEROMETERS, PROCESSES, CIRCUITS, DEVICES AND SYSTEMS

##
Inventors:
Goutam Dutta (Bangalore, IN)
Goutam Dutta (Bangalore, IN)
Reetesh Mukul (Bangalore, IN)
Hemanth M. Srikantaiah (Bangalore, IN)
Venkatesh B A (Bangalore, IN)

Assignees:
TEXAS INSTRUMENTS INCORPORATED

IPC8 Class: AG01P2100FI

USPC Class:
702 85

Class name: Data processing: measuring, calibrating, or testing calibration or correction system

Publication date: 2009-10-15

Patent application number: 20090259424

Sign up to receive free email alerts when patent applications with chosen keywords are published SIGN UP

## Abstract:

An electronic circuit includes accelerometer (1140) sensors mounted on
different axes, memory circuitry (1024) and an electronic processor
(1030) coupled to the accelerometer (1140) sensors and to the memory
circuitry (1024), the electronic processor (1030) operable to generate
signals representing at least one calibration parameter for the
accelerometer (1140) sensors from signals representing data resulting
from the accelerometer (1140) sensors in an imprecise orientation of the
accelerometer (1140) sensors. Information storage media, systems for
measuring acceleration, and processes of operation and processes of
manufacture are also disclosed.## Claims:

**1.**An electronic circuit comprising:accelerometer sensors mounted on different axes;memory circuitry; andan electronic processor coupled to said accelerometer sensors and to said memory circuitry, said electronic processor operable to generate signals representing at least one calibration parameter for the accelerometer sensors from signals representing data resulting from said accelerometer sensors in an imprecise orientation of said accelerometer sensors.

**2.**The electronic circuit claimed in claim 1 wherein said memory circuitry holds physical representations of instructions executable by said electronic processor to generate the signals representing the calibration parameter through an electronic process representing gradient-related matrix multiplication.

**3.**The electronic circuit claimed in claim 1 wherein said electronic processor has multiply-accumulate circuitry and is operable to perform an electronic process representing gradient-related matrix multiplication.

**4.**The electronic circuit claimed in claim 1 further comprising a satellite positioning decoder situated and coupled to said electronic processor on a same single chip.

**5.**The electronic circuit claimed in claim 1 wherein at least one of the accelerometer sensors is situated and coupled on a same single chip to said electronic processor.

**6.**The electronic circuit claimed in claim 1 further comprising an environmental sensor coupled to said electronic processor.

**7.**An information storage medium holding a set of physical representations of instructions executable by an electronic processor to generate signals representing accelerometer calibration parameters from accelerometer data from different imprecise orientations.

**8.**The information storage medium claimed in claim 7 wherein the instructions include instructions to generate the parameters by gradient-related matrix multiplication.

**9.**The information storage medium claimed in claim 7 wherein the instructions include instructions for performing a recursive mean square minimization process to generate the accelerometer calibration parameters.

**10.**A process of accelerometer calibration, the process comprising generating signals representing accelerometer calibration parameters from signals representing multi-axes accelerometer data from different imprecise accelerometer orientations.

**11.**The process claimed in claim 10 wherein the generating includes generating the signals representing parameters through an electronic process representing gradient-related matrix multiplication.

**12.**The process claimed in claim 11 wherein the electronic process representing gradient related matrix multiplication includes a gradient of a function of gravitational acceleration with respect to the calibration parameters.

**13.**The process claimed in claim 10 further comprising executing a first mode to issue a prompt signal for reorientation and a second mode to occasionally acquire signals representing unprompted accelerometer data and automatically generate signals representing updated calibration parameters.

**14.**The process claimed in claim 10 wherein the generating includes performing an electronic process representing a recursive mean square minimization to generate the signals representing accelerometer calibration parameters.

**15.**The process claimed in claim 10 further comprising electronically utilizing signals representing environmental sensor data to determine when to perform the generating.

**16.**A system for measuring acceleration, comprising:a portable device having accelerometer sensors mounted on different axes and operable to supply accelerometer signals representing accelerometer data;a transducer associated with the portable device and operable to emit a user-perceptible prompt; andan electronic processor coupled to said accelerometer sensors and to said transducer, said electronic processor operable to cause said transducer to emit the user-perceptible prompt, and said electronic processor operable to generate signals representing at least one calibration parameter for the accelerometer sensors in response to the accelerometer signals in different freely-establishable orientations of said portable device.

**17.**The system claimed in claim 16 wherein said signals representing calibration parameters include signals representing bias parameters and axes gain parameters.

**18.**The system claimed in claim 16 wherein said electronic processor is operable to perform an electronic process representing error feedback-minimization to generate the signals representing calibration parameters for the accelerometer sensors from the accelerometer signals.

**19.**The system claimed in claim 16 wherein said electronic processor is operable to perform a gradient-related generation of the signals representing calibration parameters for the accelerometer sensors from the accelerometer signals.

**20.**The system claimed in claim 16 further comprising a timer circuit coupled to said processor and wherein said electronic processor has an additional mode independent of said transducer and responsive at least in part to said timer circuit to occasionally acquire signals representing accelerometer data and automatically generate updated signals representing calibration parameters.

**21.**The system claimed in claim 16 wherein said processor is operable to ascertain when the signals representing accelerometer data are sufficiently stable in determining whether the signals representing accelerometer data are acceptable to generate calibration parameters.

**22.**The system claimed in claim 16 wherein said processor is operable to ascertain when the signals representing accelerometer data substantially accord with gravitational acceleration in determining whether the signals representing accelerometer data are acceptable to generate the signals representing calibration parameters.

**23.**The system claimed in claim 16 further comprising an environmental sensor coupled to said electronic processor, said electronic processor responsive to said environmental sensor for initiation of accelerometer calibration.

**24.**The system claimed in claim 16 further comprising a satellite positioning decoder coupled to said electronic processor wherein said processor is operable as an electronic position engine to blend signals representing information from said satellite positioning decoder and the signals representing accelerometer data.

**25.**The system claimed in claim 16 further comprising an electronic compass coupled to said electronic processor wherein said electronic processor is responsive to said accelerometer sensors and to the calibration parameters for tilt compensation of said electronic compass.

**26.**A process of manufacture comprising attaching to a printed wiring board an electronic processor and an accelerometer and a flash memory holding a set of physical representations of instructions executable by the electronic processor to generate signals representing accelerometer calibration parameters from accelerometer data from different imprecise orientations.

## Description:

**CROSS**-REFERENCE TO RELATED APPLICATIONS

**[0001]**This application is related to India Patent Application Number 567/CHE/2008 filed Mar. 6, 2008, titled "Estimation Of Bias Error And Axes Gain For Mems Tri-Axes Accelerometers Implemented On Cell Phone Platform For Vehicle Navigation" and priority is claimed under the Paris Convention and 35 U.S.C. 119 and all other applicable law.

**[0002]**This application is related to India Patent Application Number 565/CHE/2008 filed Mar. 6, 2008, titled "Accurately Calibrating E-Compass For Tilt Error In A Suboptimal IMU System Comprising Of Accelerometer And E-Compass Mounted On Cell Phones" and priority is claimed under the Paris Convention and 35 U.S.C. 119 and all other applicable law.

**[0003]**This application is related to the US patent application titled "Processes for More Accurately Calibrating E-Compass for Tilt Error, Circuits, and Systems" Ser. No. ______ (TI-65997) filed on even date herewith, and said U.S. patent application is incorporated herein by reference in its entirety.

**[0004]**This application is related to US patent application publication US 2009/0054075 dated Feb. 26, 2009, and U.S. patent application Ser. No. 11/844,006 (TI-38194) filed Aug. 23, 2007, titled "Satellite (GPS) Assisted Clock Apparatus, Circuits, Systems And Processes For Cellular Terminals On Asynchronous Networks" and said U.S. patent application documents are incorporated herein by reference.

**STATEMENT REGARDING FEDERALLY SPONSORED RESEARCH OR DEVELOPMENT**

**[0005]**Not applicable.

**COPYRIGHT NOTIFICATION**

**[0006]**Portions of this patent application contain materials that are subject to copyright protection. The copyright owner has no objection to the facsimile reproduction by anyone of the patent document, or the patent disclosure, as it appears in the United States Patent and Trademark Office, but otherwise reserves all copyright rights whatsoever.

**BACKGROUND OF THE INVENTION**

**[0007]**This invention is in the fields of electronic computing hardware and software, navigation and communications, and processes of operating and making such circuits, devices and systems. Without limitation, the background is further described in connection with accelerometer-based applications, circuits, devices and systems, such as for portable, including mobile, applications.

**[0008]**Mobile telephony can communicate video and digital data, and voice over packet (VoP or VoIP), in addition to cellular voice. Streams of information such as video, voice, audio content, images of all kinds, and data should be flexibly handled by such mobile devices and platforms. But power dissipation can limit time between battery recharges and limit the features and number of applications running. And system latency might cause various kinds of delays and lapses in desirable application operation.

**[0009]**Processors of various types, including DSP (digital signal processing) chips, RISC (reduced instruction set computing), information storage memories and/or other integrated circuit blocks and devices are important to these systems and applications. Containing or reducing energy dissipation, system latency and the cost of manufacture while providing a variety of circuit, device and system products with performance features for different market segments are important goals in integrated circuits generally and system-on-a-chip (SOC) design.

**[0010]**MEMS (micro-electromechanical structure) accelerometers can be used in portable platforms such as cellular phones, personal assistants, positioning devices, and other applications. The platforms are useful such as for freefall detection, tilt sensing, position sensing, velocity measurement, gaming applications, elderly monitoring systems, and Inertial Navigation systems (INS as an assistance to GPS) in vehicular and pedestrian navigation generally, and e-compass supported navigation. MEMS accelerometers can be used for Inertial Navigation (INS) Assistance to GPS in GPS challenged environments.

**[0011]**MEMS accelerometers suffer from bias error and axes gain errors which should be estimated precisely for applications like tilt sensing, inertial navigation and vehicular and pedestrian navigation. Estimation of accelerometer parameters, such as bias errors and axes gains, of MEMS accelerometers can be problematic. It is difficult for a cell phone user to estimate and calibrate gain and bias errors in accelerometers on-the-fly. Accordingly, new solutions that provide more fully user-friendly embodiments to evaluate accelerometer bias errors and gain errors would be highly desirable.

**SUMMARY OF THE INVENTION**

**[0012]**Generally and in one form of the invention, an electronic circuit includes accelerometer sensors mounted on different axes, memory circuitry, and an electronic processor coupled to the accelerometer sensors and to the memory circuitry, the electronic processor operable to generate signals representing at least one calibration parameter for the accelerometer sensors from signals representing data resulting from the accelerometer sensors in an imprecise orientation of the accelerometer sensors.

**[0013]**Generally, another form of the invention involves an information storage medium holding a set of physical representations of instructions executable by an electronic processor to generate signals representing accelerometer calibration parameters from accelerometer data from different imprecise orientations.

**[0014]**Generally, a process form of the invention involves a process of accelerometer calibration, and the process includes generating signals representing accelerometer calibration parameters from signals representing multi-axes accelerometer data from different imprecise accelerometer orientations.

**[0015]**Generally, a system form of the invention for measuring acceleration includes a portable device having accelerometer sensors mounted on different axes and operable to supply accelerometer signals representing accelerometer data, a transducer associated with the portable device and operable to emit a user-perceptible prompt, and an electronic processor coupled to the accelerometer sensors and to the transducer, the electronic processor operable to cause the transducer to emit the user-perceptible prompt, and the electronic processor operable to generate signals representing at least one calibration parameter for the accelerometer sensors in response to the accelerometer signals in different freely-establishable orientations of the portable device.

**[0016]**Generally, and in a process of manufacture form of the invention, a process of manufacture includes attaching to a printed wiring board an electronic processor and an accelerometer and a flash memory holding a set of physical representations of instructions executable by the electronic processor to generate signals representing accelerometer calibration parameters from accelerometer data from different imprecise orientations.

**[0017]**These and other forms of circuit, device, system, information storage medium, apparatus, process, and other forms of the invention are disclosed and claimed.

**BRIEF DESCRIPTION OF THE DRAWINGS**

**[0018]**FIG. 1 is a pictorial diagram of a communications system embodiment including system blocks, for example a cellular base station, a DVB video station, a WLAN AP (wireless local area network access point), a WLAN gateway, a personal computer, a set top box and television unit, and two cellular telephone handsets, any one, some or all of the foregoing inventively improved as in the other Figures.

**[0019]**FIG. 2 is a block diagram of an electronic system such as for a system on a chip (SoC) inventively improved as shown in the other Figures.

**[0020]**FIG. 3 is a block diagram of an inventive system including a satellite positioning engine or GPS engine GE inventively coupled with a processor integrated circuit in FIG. 2 operating as a cellular engine CE.

**[0021]**FIG. 4 is a flow diagram of an inventive process and structure for obtaining accelerometer data for calibration purposes and determining whether recalibration is recommended.

**[0022]**FIG. 5 is a flow diagram of an inventive process and structure for obtaining accelerometer data and accelerometer pre-calibration.

**[0023]**FIG. 6A is a flow diagram of an inventive process and structure for obtaining accelerometer data for subsequent use in calibration.

**[0024]**FIG. 6B is a flow diagram of an inventive process and structure for recalibration using accelerometer data from FIG. 6A.

**[0025]**FIG. 6C is a flow diagram of another inventive process and structure for recalibration using accelerometer data from FIG. 6A.

**[0026]**FIG. 7A is a flow diagram of another inventive process and structure for obtaining and pre-qualifying accelerometer measurements data for subsequent use in calibration.

**[0027]**FIG. 7B is a flow diagram of an inventive process and structure for providing and managing sets of measurements for recalibrating an accelerometer.

**[0028]**FIG. 8 is a flow diagram of an inventive process for selectively determining modes of recalibration.

**[0029]**FIG. 9 is a block diagram of an inventive process and structure for generating accelerometer parameters as in any of the other Figures and using them in a position engine.

**[0030]**FIG. 10 is a block diagram of an inventive process and structure for generating accelerometer parameters as in any of the other Figures and using them in a tilt compensation engine for supporting an e-compass.

**[0031]**FIG. 11 is a flow diagram of an inventive process of manufacturing the inventive systems shown in other Figures.

**[0032]**FIG. 12 is a flow diagram of an inventive process of manufacturing inventive integrated circuit chips having circuits and operations shown in the other Figures.

**[0033]**FIGS. 12A, 12B, and 12C are respective layout diagrams of various example forms of inventive integrated circuit chips provided with circuits and operations shown in the other Figures.

**[0034]**Corresponding numerals in different figures indicate corresponding parts except where the context indicates otherwise.

**DETAILED DESCRIPTION OF EMBODIMENTS**

**[0035]**In FIG. 1, an improved communications system 2000 has system blocks as described next and improved with any one, some or all of the circuits and subsystems and processes shown in various Figures of the drawing. Any or all of the system blocks, such as cellular mobile telephone and data handsets 2010 and 2010', a cellular (telephony and data) base station 2050, a WLAN AP (wireless local area network access point, IEEE 802.11 or otherwise) and/or a Voice over WLAN Gateway 2060 with user voice over packet telephone 2085 (not shown), and a voice enabled personal computer (PC) 2070 with another user voice over packet telephone (not shown), communicate with each other in communications system 2000. Worldwide web 2065 with website 2055 is readily accessible.

**[0036]**"Navigation" as used herein includes any one, some or all of position, direction, heading, tilt, altitude, azimuth, velocity and acceleration sensing and/or location-based applications, position-based applications, map-related applications, trajectory control, braking control, cruise control, steering control, engine control, course monitoring and completion, maneuvering, free fall detection, image acquisition control, image stabilization, and other applications combining or benefiting from any of the foregoing. "Portable device" as used herein includes any device, apparatus, or system, such as those stated herein as well as others, that is sufficiently movable in orientation to utilize and benefit from the embodiments and teachings herein.

**[0037]**In FIG. 1, personal and/or vehicular navigation is supported by an accelerometer 1140 and an electronic compass (e-compass) 1150. An environmental sensor 1160 is provided to check any one, some, or all of the temperature, humidity, pressure and/or other environmental physical variables. A miniature Gyro 1170 (gyroscopic inertial assembly) can be provided, with dimensions compatible with the form factor of the portable device. As part of a display screen or in addition, prompting transducers 1180 are provided for emitting flashing light signals, audible speech, and/or audible sounds such as calibration orientation prompts and distinct calibration confirmation prompts to the user. Processor integrated circuit 1022 is coupled to a satellite positioning integrated circuit 1190 for GPS or otherwise. GPS (Global Positioning System) is an earth-satellite-based electronic system for enabling GPS receivers in ships, aircraft, land vehicles and land stations to determine their geographic and spatial position such as in latitude, longitude, and altitude. Discussion of GPS herein is without limitation to other analogous satellite-based electronic systems. The GPS circuit 1190 has an antenna 1195.

**[0038]**A camera 1490 provides video pickup for cell phone 2010 to send over the internet to cell phone 2010', personal digital assistant/personal entertainment unit PDA/PEU 2096, STB (set top box) 2092 and television TV 2094, automobile 2095 and to a monitor of PC 2070 via any one, some or all of cellular base station 2050, DVB (digital video broadcasting) station 2020, and WLAN AP/gateway 2060. Handsets 2010 and 2010' have a manual input 1050' such as a keyboard, a microphone 1055, a display 1060, and user prompt transducer(s) 1180 such as a flashing LED and/or audible transducer. Analogously, PDA/PEU 2096 has user prompt transducer(s) 2097, and a display 2098. Handsets 2010 and 2010' have a video storage and other information storage medium, such as hard drive, flash drive, high density memory, and/or compact disk (like CD 2075) in the handset or external thereto for installation of applications, etc. Digital video recording (DVR) is supported, such as for delayed reproduction, transcoding, and retransmission of video to other handsets and other destinations.

**[0039]**On a cell phone printed circuit board (PCB) 1020 in handset 2010, is provided a secure processor integrated circuit 1022, an external flash memory 1025 and SDRAM (synchronous dynamic random access memory) 1024, and a serial interface 1026. A Power, Resets, and Control Module PRCM 1050 (1770 of FIG. 2) is included to perform power and energy management and other support functions. Serial interface 1026 is suitably a wireline interface, such as a USB interface connected by a USB line to the personal computer 2070 and magnetic and/or optical media 2075.

**[0040]**Cell phone 2010 intercommunication also occurs via modems 1100, such as a cellular modem, WLAN, Bluetooth, and any other modem(s) and can access a website 2055 or 2065, television and physical layer (PHY) or other such circuitry 1100'. A WLAN and/or WiMax portion includes MAC (media access controller), PHY (physical layer) and AFE (analog front end). A MIMO UWB (ultra wideband) MAC/PHY supports OFDM in 3-10 GHz. UWB bands for communications in some embodiments. A digital video integrated circuit provides television antenna tuning, antenna selection, filtering, and RF input stage for recovering video/audio/controls from DVB station 2020.

**[0041]**Processor integrated circuit 1022 has MPU (or CPU) block 1030 coupled to an internal (on-chip read-only memory) ROM 1032, an internal random access memory RAM 1034, and flash memory 1036. A security logic circuit 1038 is coupled to secure-or-general-purpose-identification value (Security/GPI) bits 1037 of a non-volatile one-time alterable Production ID register or array of electronic fuses (E-Fuses), for enhancing secure e-commerce and system security generally. Depending on the Security/GPI bits, boot code residing in ROM 1032 responds differently to a Power-On Reset (POR) circuit 1042 and to a secure watchdog circuit 1044 coupled to processor 1030. Secure Demand Paging 1040 supports the system and increases the effective size of secure memory.

**[0042]**In this way, advanced networking capability for services, software, and content, such as cellular telephony and data, navigation applications, audio, music, voice, video, e-mail, gaming, security, e-commerce, file transfer and other data services, internet, world wide web browsing, TCP/IP (transmission control protocol/Internet protocol), voice over packet and voice over Internet protocol (VoP/VoIP), robotics, medical-related services, and other services accommodates and provides security for secure utilization and entertainment appropriate to the just-listed and other particular applications.

**[0043]**The embodiments, applications and system blocks disclosed herein are suitably implemented in fixed and portable devices such as for mobile, automotive 2095, seaborne, and airborne, communications, control, set top box 2092, television 2094 (receiver or two-way TV), and other apparatus. DLP® display technology from Texas Instruments Incorporated, or liquid crystal display LCD or other video display technology is coupled to any of the system blocks of FIGS. 1 and 2. A transparent organic semiconductor display is provided on one or more windows of the vehicle 2095 of FIG. 1 and wirelessly or wireline-coupled to the video feed from the system 1700 of FIG. 2. The personal computer (PC) 2070 is suitably implemented in any form factor such as desktop, docking station, laptop, palmtop, organizer, mobile phone handset, PDA personal digital assistant 2096, internet appliance, wearable computer, content player, TV/appliance handheld remote control device, wireless pointer for game displays and other computer displays, still camera and other camera stabilization and display image stabilization, wearable personal safety monitor, personal area network, or other type and usable with media 2075 such as optical disk, flash drive, and other media.

**[0044]**In combination with the GPS circuit 1190, and the video display, the RISC processor 1422 and/or IVA (imaging and video applications unit) DSP 1424 support location-based embodiments and services of various types. These services provide roadmaps and directions thereon to a destination, pictorials of nearby commercial establishments, offices, and residences of friends, various family supervision applications, position sending to friends or to emergency E911 service, and other location based services now known or yet to be devised. For such services, fast time of position fixing, low system power consumption, and reliability of accurate timekeeping to support position-based services even during power management operations and cellular network base station handover or handoff operations are all desirable for improved technology such as supported by various embodiments herein.

**[0045]**It is contemplated that the skilled worker uses each of the integrated circuits shown in FIGS. 1 and 2, or such selection from the complement of blocks therein provided into appropriate other integrated circuit chips, or provided into one single integrated circuit chip, in a manner optimally combined or partitioned between the chips, to the extent needed by any of the applications supported by the cellular handsets 2010 and 2010', DVB station 2020, cellular telephone base station 2050, personal computer(s) 2070 equipped with WLAN, Voice WLAN access point/gateway 2060, as well as radios and televisions, Internet audio/video content players, fixed and portable entertainment units, routers, pagers, personal digital assistants (PDA), organizers, scanners, faxes, copiers, household appliances, office appliances, microcontrollers coupled to controlled mechanisms for personal, robotic and/or automotive use, combinations thereof, and other application products now known or hereafter devised for increased, partitioned or selectively determinable advantages.

**[0046]**In FIG. 2, a system 1700 for use in FIG. 1 has a MPU (microprocessor unit) subsystem 1705 with MPU core(s) 1422, an IVA subsystem 1424, and DMA (Direct Memory Access) subsystems 1710.i. Personal and/or vehicular navigation is supported by accelerometer 1140 and/or gyro 1170 and/or electronic compass (e-compass) 1150. The MPU subsystem 1705 suitably has one or more processor cores 1422 with RISC or CISC or other suitable central processing units CPUs such as with superscalar processor pipeline(s) with L1 and L2 caches. Either or both of the MPU subsystem 1705 and IVA subsystem 1424 has hardware for single cycle multiply-accumulates for matrix processing and fast loop execution, image processing, video processing, and audio processing. IVA 1424 provides one or more programmable digital signal processors (DSPs) for multi-standard (MPEG4, WMV9, RealVideo®, H.263, H.264) encode/decode at D1 (720×480 pixels), and 720p MPEG4 decode, for some examples. Also integrated are a 2D/3D graphics engine, a Mobile DDR Interface, and numerous integrated peripherals as selected for a particular system solution. The IVA subsystem 1424 has L1 and L2 caches, RAM and ROM, and hardware accelerators as desired such as for motion estimation, variable length codec, and other processing. DMA (direct memory access) subsystems 1710.i perform target accesses via target firewalls 1722.i and 1712.i of FIG. 1 connected on interconnects 1721, 1734. A target is a circuit block targeted or accessed by another circuit block operating as an Initiator. Some Initiators are MPU 1422, DMA subsystems 1710.i, Universal Serial Bus USB HS, and a secure debug access port to an emulation block EMU. In order to perform such accesses the DMA channels in DMA subsystems 1710.i are programmed. Each DMA channel specifies the source location of the Data to be transferred from an Initiator and the destination location of the Data for a target.

**[0047]**Data exchange between a peripheral subsystem and a memory subsystem and general system transactions from memory to memory are handled by the System SDMA 1710.1. The DMA channels support interconnect qualifiers collectively designated MreqInfo, such as MreqSecure, MreqPrivilege, MreqSystem in order to regulate access to different protected memory spaces. The system configures and generates these different access qualifiers in a security robust way and delivers them to hardware firewalls 1712.1, 1712.2, etc. via lines 1738 as well as to firewalls 1722.1, 1722.2, etc. associated with some or all of the targets. The hardware firewalls protect the targets according to different access rights of initiators. The DMA channels 1715.1, .2, etc. are configurable through the L4 Interconnect 1734 by the MPU subsystem 1705. Firewall configuration on a DMA interface 1715.i restricts different DMA channels according to the configuration previously written to configuration Internal Register fields. This Firewall configuration implements hardware security architecture rules in place to allow and restrict usage of the DMA channel qualifiers used in attempted accesses to various targets. When an attempt to configure access for DMA channels in a disallowed way is detected, in-band errors are sent back to the initiator that made the accesses and out-band errors are generated to a Control Module 1765 and converted into an MPU Interrupt for security attack detection and neutralization.

**[0048]**Data exchanges within a DSP subsystem 1710.2 are handled by the DSP DMA 1718.2. Data exchange to store camera 1490 image capture is handled using a Camera DMA 1718.3 in camera subsystem CAM 1710.3. The CAM subsystem 1710.3 suitably handles one or two camera 1490 inputs of either serial or parallel data transfer types, and provides image capture hardware image pipeline and preview. Data exchange to refresh a display 1060 is handled in a display subsystem 1710.4 using a DISP DMA 1718.4. This subsystem 1710.4, for instance, includes a dual output three layer display processor for 1xGraphics and 2xVideo, temporal dithering (turning pixels on and off to produce grays or intermediate colors) and SDTV to QCIF video format and translation between other video format pairs. The Display block 1710.4 feeds a user-viewable display, such as a DLP® display from Texas Instruments Incorporated or an LCD panel or other display, using either a serial or parallel interface. Also television output TV and Amp provide CVBS or S-Video output and other television output types for display.

**[0049]**In FIG. 2, a hardware security architecture including SSM 1760 propagates qualifiers such as an MreqSystem qualifier for virtual machines on the interconnect 1721 and 1734. The MPU 1422 issues bus transactions and sets some qualifiers on Interconnect 1721. SSM 1760 also provides one or more qualifiers. The bus transactions propagate through the L4 Interconnect 1734 and then reach a DMA Access Properties Firewall 1712.1. Transactions are coupled to a DMA engine 1718.i in each subsystem 1710.i which supplies a subsystem-specific interrupt to the Interrupt Handler 1780. Interrupt Handler 1780 is also fed one or more interrupts from Secure State Machine SSM 1760 that performs security protection functions. Interrupt Handler 1780 outputs interrupts for MPU 1422. In FIG. 2, firewall protection by firewalls 1722.i is provided for various system blocks 1720.i, such as GPMC (General Purpose Memory Controller) to Flash memory 1720.1, ROM 1720.2, on-chip RAM 1720.3, Video Codec 1720.4, WCDMA/HSDPA 1720.6, device-to-device SAD2D 1720.7 coupled to manual input 1050 such as keypad, Modem(s) 1100, and to a mixed signal (digital and analog) circuit coupled to microphone (MIC) 1055. DSP 1720.8 and DSP DMA 1728.8 also support the system via interconnect 1721. A System Memory Interface SMS with SMS Firewall 1755 is coupled to SDRC 1752.1 (External Memory Interface EMIF with SDRAM Refresh Controller) and to system SDRAM 1750 (1024).

**[0050]**In FIG. 2, interconnect 1734 is also coupled to Control Module 1765 and cryptographic accelerators block 1740 and a continually-powered Wakeup block WKUP 1770. Wakeup block 1770 has a Power, Reset and Clock Manager PCRM for power management and wakeup and a RTC (real time clock) for maintaining time and date. PRCM is coupled via L4 interconnect 1734 to Power IC circuitry in a power chip 1200 powered by a battery pack 1280. Chip 1200 supplies controllable supply voltages VDD1, VDD2, etc. for the rest of the system 1700. PRCM 1770 is coupled to L4 Interconnect 1734 and coupled to Control Module 1765. PRCM 1770 is coupled to a DMA Firewall 1712.i to receive a Security Violation signal, if a security violation occurs, and to respond with a Cold or Warm Reset output. Also PRCM 1770 is coupled to the SSM 1760.

**[0051]**In FIG. 2, some embodiments have symmetric multiprocessing (SMP) core(s) such as RISC processor cores in the MPU subsystem. A hardware (HW) supported secure hypervisor runs a SMP core. Linux SMP HLOS (high-level operating system) is symmetric across all cores and is chosen as the master HLOS in some embodiments.

**[0052]**In FIG. 2, digital circuitry in modem(s) 1100 supports and provides wireless interfaces for any one or more of GSM, GPRS, EDGE, UMTS, and OFDMA/MIMO embodiments. Digital circuitry provides codec for CDMA (Code Division Multiple Access), CDMA2000, and/or WCDMA (wideband CDMA or UMTS) wireless suitably with HSDPA/HSUPA (High Speed Downlink Packet Access, High Speed Uplink Packet Access) (or 1xEV-DV, 1xEV-DO or 3xEV-DV) data feature via an analog baseband core and RF GSM/CDMA core. An audio/voice block supports audio and speech/voice functions and interfacing. Speech/voice codec(s) and user voice-recognition/voice control are suitably provided in memory space in the audio/voice block for processing by processor(s) 1422, 1424. Modem(s) 1100 are coupled for use by personal and/or vehicular navigation applications to accelerometer 1140 and/or electronic compass (e-compass) 1150 and/or location-determining circuitry 1190 for GPS (Global Positioning System). Environmental sensor(s) 1160 are likewise coupled to the system. IC 1100 is also coupled to a USIM (UMTS Subscriber Identity Module).

**[0053]**In FIG. 2, an audio block has audio I/O (input/output) circuits to a speaker, a microphone, and headphones (not shown). The audio block is also coupled to an audible piezoelectric transducer in prompt calibration transducer 1180, which also has an LED (light emitting diode) that controllably emits flashing calibration initiation prompts and calibration confirmation prompts for accelerometer calibration.

**[0054]**In FIG. 3, the improved system of FIG. 2 is further detailed. Personal and/or vehicular navigation is supported by accelerometer 1140 and/or electronic compass (e-compass) 1150, environmental sensor 1160, gyro 1170, prompt transducers 1180, and/or GPS unit 1190. GPS unit 1190 has an antenna 1195 for reception of satellite positioning signals and coupled to a GPS RF receiver provided as an analog or mixed-signal integrated circuit that in turn supplies signals to a digital GPS baseband decoder 2160 integrated circuit. GPS baseband decoder 2160 is called a satellite positioning engine or GPS engine GE 2160 herein. GPS (Global Positioning System) is a satellite positioning system for supplying satellite signals to GE 2160. The acronym GE herein is used to designate a baseband decoder circuit such as a satellite positioning computing engine herein whether of GPS type or any other satellite positioning scheme.

**[0055]**GE 2160 is coupled to the rest of system 1700 of FIGS. 2 and 3 by lines TIMESTAMP 2170 for timekeeping signals, GPS_IO 2175 for position data, and GPS_CTRL 2190 for controls. The rest of system 1700 is called a Communication Engine or Cellular Engine CE for this purpose and has a processor in hardware, or in hardware combined with software/firmware. In FIG. 3, Cellular Engine CE acts as a processing engine for time information derived from the cellular communications network. CE also processes some information from GE 2160, or not, depending on embodiment. CE need not be limited to cellular or wireless communication networks.

**[0056]**In FIG. 3, a printed wiring board has signal connection line TIMESTAMP 2170 and GSP_IO 2175 that couple strobe pulses and time-related information between the GE and CE. GE is coupled as a peripheral by a UART 2180 (universal asynchronous receiver/transmitter, i.e., a parallel/serial interface such as I2C, XPA, etc.) to interconnect 1734 of FIG. 2. Accordingly, a data bus 2185 in interconnect 1734 provides controls and data as parallel bits to the UART 2180 and these bits are supplied on particular lines in a set of lines 2190 to control the GE. For example, these lines convey control inputs to GE 2160 including a GSP_SLEEP input, a soft enable/reset GPS_EN_RESET, and a power up enable GPS_PWR_EN. Further lines to GE 2160 include interface lines for bi-directional serial communication.

**[0057]**In FIG. 3, a first clock 2162, such as a temperature compensated crystal oscillator TCX0, has a frequency illustratively between 10 and 100 MHz or higher, that during reception is continually (or selectively) locked to or synchronized with clocks present in base stations. Between receptions the first clock 2162 keeps time when GPS 1190 is asleep, and clock 2162 itself is switched off or is left to run depending on the operating mode. A second clock 2164 has a lower frequency, e.g., below 1 MHz. such as at 32 KHz. The second clock 2164 is on and operative between receptions when the first clock 2162 is turned off for power saving. Processing circuitry CE is connected to the modem(s) 1100 and to the first clock 2162 and second clock 2164 and to GE 2160.

**[0058]**In FIGS. 4-6B, an accelerometer calibration solution estimates Bias errors and Axes gain of MEMS three-axes accelerometers 1140 mounted on a smart phone 2010 or other portable device. Such solution recognizes the practical aspects of calibrating accelerometers 1140 by users and provides a set of embodiments for users that are easier to use and more convenient compared to a relatively demanding and less-convenient six-posture approach.

**[0059]**One demanding approach in estimating bias errors and axes gain involves orienting the 3 axes accelerometer 1140 of FIG. 1 in six fixed postures: the first one where the x-axis is exactly parallel to the gravity vector g followed by the second one where x-axis is exactly anti-parallel to gravity vector g. The third and fourth postures are with respect to y-axis parallel and anti parallel to gravity vector g and the last two postures are related to z-axis being parallel and anti-parallel to gravity vector g. Measurements need to be done first on a precisely horizontal platform followed by measurement done with precise pitch and roll of the platform. The accuracy of the method is limited by the angular precision of the setup. The bias errors μ and axes gain S are computed from the averaged accelerometer reading of all three axes. While the six-posture method is computationally simple, an accurate measurement by this method requires an accurate and well-calibrated setup in a controlled environment. Any inaccuracy can result in errors in estimating bias errors and gain errors. Such inaccuracy in turn can lead to convergence delays in applications requiring precise estimates (e.g., Inertial Navigation and Pedestrian Navigation). Moreover, such inaccuracy can result in heading errors (such as direction relative to North) in platforms that use electronic compass 1150 and/or gyroscope 1170 technology that relies on an accelerometer 1140 for tilt compensation. This demanding six-posture method is not user friendly because it is not practical for cell phone users if they want to calibrate the accelerometer 1140 on the fly. It also calls for costly setup arrangements even for cell phone manufacturers.

**[0060]**Embodiments of method and system herein remove the necessity of accurately orienting the accelerometer 1140. Instead, accelerometer 1140 readings at rest in different, imprecise or unspecified, freely-establishable orientations are conveniently taken. Precise or specific postures need not be prescribed nor relied upon while taking these readings. An ordinary or regular user can easily tilt the cell phone 2010, PDA 2096, or other portable device in different orientations 2535A, 2535B, 2535C and perform the calibration. Since the exact postures are not of concern, there is no requirement on the accuracy of the postures.

**[0061]**Various embodiments work on the datasets signaled by accelerometer 1140 at different imprecise, unspecified, non-specific or unknown orientations and nevertheless can estimate best-fit values for various accelerometer parameters, such as the axes gain and bias errors, etc. In other words, various embodiments of structure and process benefit from different orientations 2535A, B, C that are freely-establishable and user-determinable. No test fixture, calibration jig, nor otherwise-additional precision test instrumentation is required. Various types of accelerometer 1140 sensors, such as capacitive, piezoelectric, optical, MEMS (micro-electromechanical structure), and/or gyroscopic and others can be employed.

**[0062]**In FIG. 4, operations in this more-convenient approach commence in response to a step 2510 wherein the user clicks an icon, or recalibration item on a menu display of the portable device, or otherwise prompts a fetch of recalibration software as improved herein. The method is useful and handy for end-user, who may do a quick calibration of the accelerometer 1140 before deploying a particular application, e.g., Inertial Navigation assisted Pedestrian Navigation. Also, a parallel step 2520 responds to any internal prompt from the system software requesting recalibration software operation. Any of a suite of navigation applications 2524 can request accelerometer 1140 recalibration on processor 2522, or the operating system software or driver can call for recalibration when a navigation application is about to be launched. If substantial time has passed since last recalibration, as measured by Date/Time RTC 2526, or the accelerometer 1140 has never been calibrated as indicated by calibration parameters merely set to their original initialization values (TABLE 1 later herein below), then an internal flag is set for processor 2522 to generate an internal prompt. A substantial change in the environment, such as a temperature change, detected by environmental sensor(s) 1160 can also trigger a recalibration request.

**[0063]**A succeeding step 2530 cues the user such as by display messages and/or audible instructions calling for the user to position the accelerometer 1140 in different orientations or directions 2535A, B, C to accumulate data for calibration purposes. Various position assist prompts are suitably given to the user to clarify and facilitate the measurement process. A succession 2535 of cues and measurements occurs, as suggested by orientation-changing arrows 2535A, 2535B, and 2535C in FIG. 1. In this way, accelerometer 1140 measurements are taken with the accelerometer 1140 in different directions or orientations. The user changes the orientation in various directions using various orientation changes and combinations of the arrows 2535A, 2535B, and 2535C. The orientation changes and arrows are applicable to any of the portable devices like PDA/PEU 2096, cell phones 2010 and 2010', vehicle device 2095, etc. The user can change the orientation readily, and manually holds the device stationary in each new orientation. If desired, the user also can rest the portable device in various orientations on a desk or table leaning against any convenient object.

**[0064]**The portable device is programmed to cue the user with a beep and/or flash when each measurement is to be taken. Then after the orientation is stable and the measurement is acquired, a beep-beep and/or double-flash from prompt transducers 1180 is issued. If the orientation is not changed within a modest time interval, then a single cueing beep is again issued as a reminder. Any of numerous other audible sounds and optical cues and/or other cues can be issued in various embodiments, and human factors engineering can be applied to establish convenient, understandable cues/prompts.

**[0065]**In FIG. 4, step 2540 ascertains that the accelerometer 1140 has been maintained stationary in a given orientation for a sufficient interval of time to substantially average out measurement error and permit calculation of offsets, biases or parametric errors in the accelerometer 1140 sensors themselves. In a vehicle 2095 moving at constant velocity, stationarity is also satisfied if the accelerometer 1140 is held stationary relative to the vehicle 2095 by the user inside the vehicle. In moving vehicles, note that micro jerks can make the measurements significantly more noisy. Hence, some embodiments perform these measurements when the vehicle is not moving as in FIGS. 4 and/or 5, and screening as in FIG. 5 operates to reject measurements made in the presence of substantial noise. Some other embodiments perform the measurements either when the platform is stationary or in a vehicle moving at constant velocity and accommodate increased noise due to micro jerks by providing extended or adaptive averaging time intervals and/or other measurement noise-rejection processes and structures and measurement screening, such as in FIGS. 4 and 5 or otherwise effective for the purpose. Either way, the acceleration vector comprised of the outputs of the accelerometer sensors represents the one constant downward acceleration due to gravity g in connection with all the accelerometer measurements in every one of the orientations.

**[0066]**A further step 2550 performs a pre-calibration calculation of the parameters of the accelerometer 1140, such as bias errors μ and axes gains S for each of the three accelerometer sensors X, Y, Z that best fit with the measurements. A step 2560 performs position sensing calculations that blend the accelerometer 1140 information (INS) and GPS position information as in FIG. 9. Then a decision step 2570 determines whether the accuracy of calibration is insufficient as indicated by any substantial unexpected inaccuracy, trend, or drift in position measurement. At first, decision step 2570 determines that the accuracy is sufficient, goes to RETURN 2575, and proceeds to perform navigation applications 2524 upon user command or otherwise when launched. However, with passage of time, or with substantial and prolonged temperature changes, or some other factor, decision step 2570 can determine that recalibration is called for, whereupon operations proceed to a step 2580 to prompt the user to decide for recalibration and go to step 2520 or 2510.

**[0067]**FIG. 5 details step 2540 of FIG. 4. In FIG. 5, a step 2610 delivers a latest measurement vector for acceleration from accelerometer 1140. The measurement is screened or checked for credibility by steps 2620 and 2630. Step 2620 tests whether the resultant vectorial sum of the components of the latest measurement vector represents acceleration close to one-g, i.e., the acceleration of gravity 1 g. If not close to 1 g, operations discard the measurement and go back from step 2620 to 2610.

**[0068]**For example, if the user were still accelerating or decelerating the portable platform 2010 holding the accelerometer sensors in the process of changing the orientation of the platform, then the latest measurement vector that can depart significantly from the 1 g acceleration of gravity. Also, if the platform were accidentally dropped, the accelerometer sensors would be in free fall and would produce a measurement vector that would depart significantly from the 1 g acceleration of gravity. In use at run-time, measurements by properly-calibrated accelerometer sensors that depart from 1 g significantly would acceptably and desirably contribute to velocity-sensing and position-sensing. In this example of a specifically distinct calibration process at step 2620, however, the platform is oriented and held stationary in such a way that the acceleration is close to one-g.

**[0069]**Of course, sensors in need of calibration will supply measurement data that seemingly departs from 1 g acceleration of gravity, but moderately (e.g., within a small decision range on the order of plus/minus one percent +/-0.01 g). This decision range can be established, for instance, in relation to accelerometer vendor specified bias error (offset) range and gain error range. A programmed decision range used by step 2620 does accept a measurement that departs moderately from 1 g acceleration of gravity. In such case, operations proceed to a step 2630. (It may be better to perform these measurements with an assurance of stationarity from the user. Else, the data may be corrupted by small accelerations that falls in the decision range.)

**[0070]**In FIG. 5, step 2620 and step 2610 are alternated in a measurement loop transparent to user so that a series of acceleration vector measurements over an about-one-second interval are made and pass step 2620. When step 2630 is reached, the series of acceleration vector measurements from step 2610 that pass step 2620 for a given single orientation of the accelerometer 1140 are available for analysis collectively. Step 2630 computes the statistical variance (average squared-departure from their mean) of the series of acceleration vector measurements. This or any other suitable approach is applied to determine that each one of the accelerometer 1140 X, Y, Z sensor outputs f

^{m}(k)=[f

_{x}

^{m}(k) f

_{y}

^{m}(k) f

_{z}

^{m}(k)]

^{T}is essentially stable or unvarying. If the statistical variance is greater than a predetermined threshold (e.g., 0.01 or less), then operations discard the series of measurements, and go back to step 2610 to repeat the procedure for that platform orientation. An associated message to the user is suitably also provided to encourage physical stationarity. If the statistical variance is less than the predetermined threshold value at step 2630, then operations proceed. In some embodiments, the user is informed that the measurement is successful and cued for another orientation whereupon operations again go back to step 2530 of FIG. 4. The measurement acquisition process is repeated for another orientation until measurements corresponding to a predetermined number of different orientations have been acquired, whereupon a further part 2640 of the calibration procedure is executed as described herein. In some other embodiments, the mean of the series of acceleration vector measurements from step 2610 is passed directly to calibration procedure 2640 as described elsewhere herein.

**[0071]**The embodiments are user friendly. An ordinary user can orient the cell phone in six or more orientations and perform the calibration of bias errors and axes gains. Accelerometer bias error and sensitivity specifications are subject to inaccuracies of orientation in accelerometer vendor test setups when using the demanding six-posture method described earlier hereinabove. Here, the calibration embodiments do not depend on exact posture or accuracy of orientations and can be used not only by accelerometer manufacturers and portable device manufacturers to tighten their specs on parameters such as bias errors and sensitivity, but also by ordinary users.

**[0072]**Smart phones 2010 and 2010', such as in third-generation (3G) phone category can include Inertial Navigation as a beneficial navigation feature using MEMS (micro-electromechanical structure) 3-axis accelerometer 1140, gyros and e-compass 1150. MEMS accelerometers are low cost, low power devices that are quite useful in inertial navigation providing information on acceleration along its axes as well as performing as tilt sensors. Inertial navigation for vehicular navigation is however susceptible to accelerometer bias errors and gain errors. The velocity (speed) and the distance traversed by a vehicle 2095 are obtained by integrating the accelerometer 1140 output once and twice respectively. Accelerometer bias error can produce over time a linear error in velocity, and a quadratic error in distance due to time-integration (e.g., see equation (42.1) described later herein below).

**[0073]**In vehicle navigation, it is important to correct the bias errors μ and gain errors S of an accelerometer 1140 periodically to prevent a rapid build up in velocity and distance. For instance, a Kalman Filter can be provided to receive GPS (Global Positioning System) 1190 and accelerometer 1140 (Inertial) measurements and then calibrate the inertial output with respect to good GPS measurements. Reasonable estimates of the bias errors and gain errors of a given accelerometer 1140 help to define the initial states and facilitate quick convergence of the calibration filter. A 3-axis accelerometer 1140 exposed to acceleration (f

^{a}) {=[f

_{xf}

_{y}f

_{z}]

^{T}} registers acceleration outputs (f

_{m}) in all three axes given by:

**f**

^{m}=S*[f

^{a}

_{xf}

^{a}

_{y}f

^{a}

_{z}]

^{T}+μ+w (1)

**[0074]**where, S is the gain (sensitivity) matrix, μ is the bias error vector referenced to the gravitational acceleration and w is a noise vector representing the accelerometers noise on all three axes X, Y, Z.

**[0075]**In this example and in all formulations beyond this point, the acceleration values are referenced to the acceleration due to gravity in that location, where in the acceleration due to gravity is defined a value of unity. The actual accelerations in S.I. unit would be obtained by multiplying the corresponding acceleration vector with the actual gravity of that location (e.g. obtained from WGS 84 model).

**[0076]**Notice that if the measurement process is arranged to average out the noise w, then

**f**

^{a}T=S

^{1}*(f

^{m}-μ) (1A)

**[0077]**The three diagonal elements Sx, Sy, Sz of the gain matrix S are the gain coefficients for individual axes X, Y, Z while the six off-diagonal terms Sxy, Syx, Szx, Sxz, Syz, Szy represent cross-axes gain from each orthogonal axis. The cross-axes terms arise from small alignment errors of the individual sensor axes in the three axis accelerometer 1140. Typically the cross axis effects are less than 2% for state of art MEMS accelerometers and do not affect the inertial measurements significantly for purposes of some applications. MEMS accelerometer vendors can specify error bounds for bias error and axes gain errors.

**[0078]**Suppose the demanding six-posture method were used to estimate the coefficients of Gain matrix S and bias error μ. A precise test set up measures acceleration output vectors at 6 different orientations, the first one with the x-axis towards gravity axis or vector g followed by the second one with x-axis against gravity axis or vector g; the third and fourth one corresponding to y axis towards and against the gravity axis or vector g and the fifth and sixth one corresponding to z-axis towards and against the gravity axis or vector g. The measurements are averaged over a long enough time to reduce the effect of accelerometer 1140 noise.

**[0079]**The corresponding equations for averaged measured vector (fm) in the six-posture method are given by:

**f**1m=S*[1 0 0]

^{T}+μ (2)

**f**2m=S*[-1 0 0]

^{T}+μ (3)

**f**3m=S*[0 1 0]

^{T}+μ (4)

**f**4m=S*[0 -1 0]

^{T}+μ (5)

**f**5m=S*[0 0 1]

^{T}+μ (6)

**f**6m=S*[0 0 -1]

^{T}+μ (7)

**[0080]**The bias error parameter vector μ and gain parameter matrix S are estimated in the six posture method as follows. Local acceleration due to gravity is normalized to unity here, and plus/minus unity in equations (2)-(7) represents the orientation of a given one of the three accelerometer sensors parallel or anti-parallel to the downward gravitational acceleration. The zeros in equations (2)-(7) represent the negligible acceleration measured in each of the six postures by the other two accelerometer sensors, which are assumed to have perfectly orthogonal orientations relative to the given sensor. Because of the six precise orientations reflected by the measured acceleration vectors [1 0 0]

^{T}, [-1 0 0]

^{T}, . . . [0 0 -1]

^{T}of the accelerometer 1140 on the test stand, adding all those measured acceleration vectors cancels out contributions from matrix S and delivers the bias error vector μ by equation (8):

**μ = k = 1 6 f km / 6 ( 8 ) ##EQU00001##**

**[0081]**Moreover, because of the six precise orientations, pair wise subtraction for each of the three pairs of measured acceleration vectors cancels the bias error vector μ and delivers three column vectors comprised in estimated parameter matrix S, all according to equation (9):

**S**=[(f

_{1}m-f

_{2}m)/2(f

_{3}m-f

_{4}m)/2(f

_{5}m-f

_{6}m)/2] (9)

**[0082]**The demanding six-posture method has some practical difficulties in implementation. Small errors in orientation of each accelerometer sensor on the precision test stand relative to the gravitational acceleration vector g (i.e., straight down) cause erroneous estimation of bias error vector μ and axes gain matrix S. For an accelerometer 1140 in a cell phone 2010 that may need to get calibrated by a phone user, it would be difficult to implement the six-orientation based scheme that demands high accuracy of the orientation.

**[0083]**By contrast, an approach to solving the problems more conveniently is described herein and has various embodiments. At any point of time the true acceleration measurements of all three axes X, Y, Z at condition of rest produce a resultant vector of a unit of gravitational acceleration g. Normalizing the true acceleration vector f

^{a}for gravitational acceleration g to be unity, the true accelerations f

^{a}of the 3-axis [f

_{x}

^{a}f

_{y}

^{a}f

_{z}

^{a}]

^{T}satisfies the equation:

**f**

^{af}

^{a}T=[f

_{x}

^{af}

_{y}

^{af}

_{z}

^{a}][f

_{x}

^{af}.s- ub.y

^{af}

_{z}

^{a}]

^{T}=g

^{2}=1 (10)

**[0084]**Using equations (1A) and (10), equation (11) represents the constancy of the gravitational acceleration regardless of the posture of the accelerometer 1140:

(f

^{m}-μ)

^{T}(S

^{-1})

^{T}(S

^{-1})(f

^{m}-μ)=g

^{2}(11)

**[0085]**The three accelerometer 1140 X, Y, Z sensor outputs f

^{m}(k)=[f

_{x}

^{m}(k) f

_{y}

^{m}(k) f

_{z}

^{m}(k)]

^{T}represent a kth measurement and constitute the measured accelerometer vector averaged over long enough time to reduce the statistical variance of accelerometer noise w to an acceptably small level. The target value of gravitational acceleration g is unity (1), for example, in an iterative process embodiment described herein.

**[0086]**Notice that there are as many as nine (9) unknowns in the axes gain matrix S and three (3) unknowns in the bias error vector μ. Solving for these twelve (12) unknown quantities in some embodiments is performed in some embodiments by taking measurements (e.g., m>=12) at different postures and solving equation (11) in a recursive least squares sense, such as by using a microprocessor in system 1700 of FIG. 2 performing linear minimum mean square estimation, gradient descent process, and/or other applicable data analysis process. More measurements can be taken to improve the accuracy of measurements of the 12 unknowns. Embodiments for use with more than six unknowns are beneficial especially when the accelerometer sensors are subject to relatively-relaxed specifications for mutual perpendicularity, or where the desired calibration is to be very precise and the perpendicularity specification for accelerometer sensors is less than the precision desired.

**[0087]**In some embodiments, for simplicity of analysis, the cross axes terms in matrix S are ignored. When the cross axes terms are negligible, the above assumption (ignoring the cross-axes terms) does not affect acceleration measurements significantly. In accordance with the definition, the matrix S is defined as a diagonal matrix with the axes gain terms:

**S**= [ S xx 0 0 0 S yy 0 0 0 S zz ] ( 12 ) ##EQU00002##

**[0088]**In these embodiments, three (3) unknowns in the axes gain matrix S and three (3) unknowns in the bias error vector μ make a total of six (6) unknowns. Solving for these six unknown quantities in some of these embodiments is performed in some embodiments by taking measurements (e.g., m>=6) at different postures and solving equation (11) in a recursive least squares sense, such as by using a microprocessor in system 1700 performing linear minimum mean square estimation (LMMSE), iterative error feedback, and/or a gradient descent process, and/or other applicable data analysis process. More measurements can be taken (m>6) to improve the accuracy of measurement of the six unknowns.

**[0089]**Define the diagonal matrix Y=S

^{-1}

**Y**= [ Y xx 0 0 0 Y yy 0 0 0 Y zz ] ( 13 ) ##EQU00003##

**where**

**Yxx**=1/Sxx

**Yyy**=1/Syy

**Yzz**=1/Szz (14)

**[0090]**A number "m" of vector acceleration measurements f

^{m}(k) indexed k of are taken at different freely-established postures and a measured value of the acceleration of gravity g(k) is computed using equation (15). The orientation of each of the postures does not need to be known. Equation (11) is expressed as a square root of sum of squares for the kth measurement, and is given by equation (15).

**g**(k)= (Y

_{xx}

^{2}(f

_{x}

^{m}(k)=μ

_{x})

^{2}+Y

_{y}y

^{2}(f.- sub.y

^{m}(k)=μ

_{y})

^{2}+Y

_{z}z

^{2}(f

_{z}

^{m}(k)=μ

_{z})

^{2}) (15)

**[0091]**The measured acceleration of gravity g (k) for any given measurement will likely be different from the known value unity (1.00) while the six unknown parameters are being optimized by the procedure described next.

**[0092]**Define a parameter vector p holding the six unknowns (can be initialization values or currently-unrefined values) in this process embodiment:

**p**=[Y

_{xx}Y

_{y}yY

_{z}zμ

_{x}μ

_{y}μ

_{z}]

^{T}(16)

**[0093]**Here, parameter vector p does not need to be determined by equations (8) and (9) based on demandingly-precise test orientations. Instead, linearizing equation (15) by chain rule calculus differentiation, and expressing equation (15) directly in terms of changes Δ of measured quantities for an iterative process embodiment based on the gradient ∇g(k) with respect to the unknown parameters p, gives:

Δg(k)=ΔYxx(Yxx(f

_{x}

^{m}(k)-μ

_{x})

^{2}/g(k))+.DELTA- .Yyy(Yyy(f

_{y}

^{m}(k)-μ

_{y})

^{2}/g(k))+ΔYzz(Yzz(f

_{z}.s- up.m(k)-μ

_{z})

^{2}/g(k))-Δμ

_{z}(Yxx

^{2}(f

_{x}

^{m}(- k)-μ

_{x})/g(k))-Δμ

_{y}(Yyy

^{2}(f

_{y}

^{m}(k)-μ.sub- .y)/g(k))-Δμ

_{z}(Yzz

^{2}(f

_{z}

^{m}(k)-μ

_{z})/g(k)) (17)

**[0094]**An equivalent linearized form for an iterative process embodiment that substitutes equation (1A) to intermediately compute components of true acceleration f

^{a}for use in equation (17) is expressed as equation (17A):

Δg(k)=ΔYxxf

_{z}

^{a}(k)

^{2}/(Yxxg(k))+ΔYyyf

_{y}.s- up.a(k)

^{2}/(Yyyg(k))+ΔYzzf

_{a}

^{a}(k)

^{2}/(Yzzg(k))-Δ- μ

_{z}Yxxf

_{x}

^{a}(k)/g(k)-μ

_{y}Yyyf

_{y}

^{a}(k)/g(k)-.DEL- TA.μ

_{z}Yzzf

_{z}

^{a}(k)/g(k) (17A)

**[0095]**Rewriting either equation (17) or (17A) in matrix form provides a respective version of:

Δg=[∇

^{T}g]Δp=HΔp (18)

**[0096]**The matrix ∇

^{T}g=H signifies a matrix having m rows, each row equal to the transpose of column values of gradient of gravity with respect to the parameters p for a respective kth one of the m measurements f

^{m}(k). Additionally writing with a 6×6 matrix product H

^{TH}provides

**H**

^{T}Δg=H

^{TH}ΔP (18A)

**where**,

Δp=[ΔYxxΔYyyΔYzzΔμ

_{x}Δμ

_{y}- Δμ

_{z}]

^{T}

Δg=[Δg(1) . . . Δg(k) . . . Δg(m)]

^{T}

**[0097]**In (m×1) column vector Δg, each entry is given by equation (19):

Δg(k)=1-g(k) (19)

**[0098]**and H is the relation matrix (m×6) related to the gradient of gravity and defined by equation (17). Solving equation (18A) yields

Δp=(H

^{TH})

^{-1}H

^{T}Δg (20)

**[0099]**In a first example, note that each k

^{th}row of an (m×6) relation matrix H is based on the sensor outputs f

_{x}

^{m}(k) f

_{y}

^{m}(k) f

_{z}

^{m}(k) of the k

^{th}measurement and equation (17) and has six numerical values that are numerically generated by an electronic processor programmed with these six expressions that use information from equations (15) and (16):

**∇ T g ( k , j ) = H ( k , j ) = [ ( Y xx ( f x m ( k ) - μ x ) 2 / g ( k ) ) , ( Y yy ( f y m ( k ) - μ y ) 2 / g ( k ) ) , ( Y zz ( f z m ( k ) - μ z ) 2 / g ( k ) ) , - ( Y xx 2 ( f x m ( k ) - μ x ) / g ( k ) ) , - ( Y yy 2 ( f y m ( k ) - μ y ) / g ( k ) ) , ( Y zz 2 ( f z m ( k ) - μ z ) / g ( k ) ) ] ( 21 ) ##EQU00004##**

**[0100]**In a second example, note that each k

^{th}row of (m×6) relation matrix H is based instead on equation (1A) applied to compute components of true acceleration f

^{a}from the sensor outputs f

_{x}

^{m}(k) f

_{y}

^{m}(k) f

_{z}

^{m}(k) of the k

^{th}measurement. Each k

^{th}row of relation matrix H is based on equation (17A) and gets the same six numerical values as in the first example, but which are numerically generated by an electronic processor alternatively programmed with these alternative six expressions that use information from equations (1A), (15) and (16):

[f

_{z}

^{a}(k)

^{2}(Yxxg(k)),f

_{y}

^{a}(k)

^{2}/Yyyg(k),f

_{z}.su- p.a(k)

^{2}/(Yaag(k)-Yxxf

_{z}

^{a}(k),-Yyyf

_{y}

^{a}(k)/g(k),Yzzf.s- ub.z

^{a}(k)/g(k)] (21A)

**[0101]**The iterative process is programmed and stored, e.g., in flash memory 1025 (1720.1) for execution on a floating-point or fixed point processor in system 1700 of FIG. 2. It should be apparent to the reader that any of various iterative processes and sets of processor instructions to accomplish each of them are suitably provided and applied by the skilled worker in practicing various embodiments according to the teachings herein.

**[0102]**The various parameters initialization for equation (16) is shown in TABLE 1. The final estimates of bias errors μ

_{x}, μ

_{y}, μ

_{z}and axes gain reciprocals Yxx, Yyy, Yzz are obtained through multiple iterations. The steps for each iteration are as follows and are further described in connection with FIGS. 6A and 6B (or in FIG. 6C more general form for this and various other embodiments):

**TABLE**-US-00001 TABLE 1 PARAMETER INITIALIZATION Initial Parameters (p) Value μ

_{x}μ

_{y}μ

_{z}0, 0, 0 Yxx Yyy Yzz 1, 1, 1

**[0103]**Estimation Process I

1. Initialize parameters p according to TABLE 1.2. Keep the three axes accelerometer 1140 at any arbitrary posture, keep it stationary and measure the average acceleration on all three axes: [f

_{x}

^{m}f

_{y}

^{m}f

_{z}

^{m}]

^{T}. Repeat the process "m" number of times with different postures 2535A, B, C every time to get "m" sets of measurement vectors.3. Compute the measured value of g(k) using the current parameter values and equation (15) for each measurement k; k=1 to m4. Compute Δg(k)=1-g(k); k=1 to m (Difference between target value and measured value of gravity)5. Compute the gradient-related matrix H using equation (21) where the kth row of H is computed from the kth measurement set and the current parameter values.6. Compute Δp using equation (20).7. Update the parameter values; p=p+Δp.

8. Compute new g and Δg for new p.

**[0104]**9. If ((Δg

^{T}Δg)<Specified Threshold) Stop, else loopback to Step 5.

**[0105]**Note that the Specified Threshold for step (9) may also be expressed as the product (mε) of the number of measurements m times a small specified amount epsilon ε defining a numerical bound within which the optimizing iterations are to be regarded as having sufficiently approached zero when the estimation process has converged.

**[0106]**In FIG. 6A, parameter estimation process 2800 operations commence with BEGIN 2810 and then a step 2820 initializes the parameter p values so that the unknown bias errors μx, μy, μz are each initialized to zero, and the unknown axes gains Yxx, Yyy, Yzz are initialized to unity as in TABLE 1. If the accelerometer 1140 unit has been calibrated before, then subsequently using earlier-computed accelerometer parameter values, such as accelerometer parameter values that pertained under similar environmental conditions monitored by environmental sensor 1160, can reduce the number of iterations to convergence in FIGS. 6B and 6C and thereby save battery energy and reduce system latency.

**[0107]**Also, step 2820 establishes a configured number m of measurements and initializes measurement index k to one (1) to represent that a first measurement will be taken. A succeeding step 2830 prompts the user via control signals to prompt transducers 1180 to reorient the platform (e.g., cell phone handset 2010 with an accelerometer 1140) in any one or more of directions 2535A, B, C and put the platform in a new stationary arbitrary posture. Accelerometer 1140 has sensors for each of three substantially mutually perpendicular axes. An input step 2850 measures the average acceleration vector components f

_{x}

^{m}(k), f

_{y}

^{m}(k), and f

_{z}

^{m}(k) from accelerometer 1140 at the currently established stationary arbitrary posture for measurement k as discussed in connection with FIG. 5. A calibration confirmation control signal to transducers 1180 such as a double-flash and double-beep indicates the user that the measurement is successful.

**[0108]**In some embodiments a decision step 2855 screens that latest measurement k2 to determine whether it is an essential duplicate of a previous measurement k1, such as by checking whether the sum of squared differences between the 3-element measurement vectors |(f

^{m}(k2)-f

^{m}(k1))|

^{2}is less than a predetermined small value. (Duplication might occur either by user inaction or inadvertently by some re-orientations that, in effect, merely precess the accelerometer 1140 around the vertical.) If six or fewer measurements have been taken so far, (Yes at step 2855) then operations branch to a step 2858 to drop the latest measurement and prompt the user for more diverse positioning, whereupon operations go back through a point (D) to step 2830. This helps reduce the chances that the rank of the gradient-related matrix product H

^{TH}will be less than the number of unknowns (e.g., 6), which can impede inversion of matrix product H

^{TH}in equation (20).

**[0109]**In due course, sufficiently-diverse measurements f

^{m}(k) are taken, and operations proceed from decision step 2855 to a step 2860. Step 2860 increments the measurement index k=k+1. Then decision step 2870 determines whether all of a number m>=6 of desired measurements have been taken. If not, operations loop back to step 2830 to prompt the user to put the platform in another new stationary arbitrary posture, and the loop 2830-2870 is repeated until all m measurements have been taken. When k>m, (Yes at step 2870), operations proceed through point A of FIG. 6A to FIG. 6B, or in some embodiments, to FIG. 6C instead.

**[0110]**In FIG. 6B, operations continue from point A to a step 2910 wherein the measurement index is again initialized to one (1). A succeeding step 2920 computes a gravity value g(k) using square root of sum of squares equation (15) with the six-parameter vector in Equation (16) initialized to p=[1 1 1 0 0 0]

^{T}or a current parameter vector p, if available. Equation (20) is then computed and further uses the acceleration vector components f

_{x}

^{m}(k) f

_{y}

^{m}(k), and f

_{z}

^{m}(k) for k=1.

**[0111]**Further in FIG. 6B, a processor step 2930 uses equation (19) and computes a difference 1-g(k) between known unity gravitational acceleration and the computed gravity value g(k) from step 2920. Then a processor step 2940 generates a gradient ∇

^{T}g(k,j), i.e. a kth set of six row values for the kth row of (m×6) relation matrix H according to the row formulas in expression (21) or in expression (21A) for instance. The gradient-related relation matrix H is implemented as a table in memory 1024 (1720.3 or 1750) that is populated by the process of FIG. 6B with numerical values. A numerical value is generated by the processor for the memory entry corresponding to each row k, column j of the relation matrix H. The processor populates row k using the current parameter vector p and the average acceleration vector components f

_{x}

^{m}(k), f

_{y}

^{m}(k), and f

_{z}

^{m}(k) and the computed gravity value g(k), all for measurement k. For instance, the memory entry corresponding to row k, column one is computed by the processor programmed according to the formula H(k, 1)=(Yxx (f

_{x}

^{m}(k)-μ)

_{x})

^{2}/g(k)), and so forth over to row k, column 6, which uses further computer instructions that when executed do an electronic process that represents and implements the formula H(k, 6)=-(Yzz

^{2}(f

_{z}

^{m}(k)-μ

_{z})/g(k)).

**[0112]**At completion of step 2940 in FIG. 6B, matrix row k is populated, and the measurement index is incremented so k=k+1 at a step 2945. Then a decision step 2950 determines whether the entire table in memory corresponding to gradient-related matrix H is populated by testing whether index k exceeds the total number of measurements m. If not, operations loop back from step 2950 to step 2920. This inner loop 2920-2950 is executed until k>m, whereupon operations proceed to a step 2960. Step 2960 performs an outer loop kernel that collectively processes all the m measurements and updates the six-dimensional parameters estimate p using earlier-described equation (20) and adding to yield:

**p**=p+Δp=p+(H

^{TH})

^{-1}H

^{T}Δg (22)

**[0113]**Associated with step 2960, a test 2965 is provided (such as determining whether the determinant of matrix product H

^{TH}is less than a predetermined small values for the purpose of invertibility testing) to determine whether matrix product H

^{TH}is invertible, i.e., whether its rank is at least equal to the number of unknowns (e.g., 6). If the determinant is very small or zero at step 2965, operations branch to a step 2968 to prepare to take another measurement by setting k=m+1 and m=m+1 and cueing the user. After step 2968, operations go back to point (D) and step 2830 of FIG. 6A. Because of entry screening step 2855, step 2965 is likely to be passed (No at step 2965), and operations proceed to step 2970.

**[0114]**The outer loop has a decision step 2970 that computes a convergence metric and compares it with a threshold to determine whether the outer loop is converged. One example of such convergence test involves the sum of squares of computed gravity differences Δg:

Δg

^{T}Δg<mε (23)

**[0115]**Inequality (23) expresses the convergence criterion that the parameters p should be such that the sum of squares of computed gravity differences relative to unity over all the m measurements should be small (i.e., less than some small configuration value established for the purpose of convergence testing) so that all or almost all the measurements do a good job of measuring the gravitational acceleration components. An alternate method of convergence for all methods is to use (Δp

^{T}Δp<ε

_{p}), i.e. less than a specified convergence value epsilon.

**[0116]**If decision step 2970 detects that the outer loop is not converged (No), then operations loop back to step 2910 and perform another iteration based on the updated parameters p. When the outer loop is converged (Yes) at step 2970, operations proceed to a step 2980 that outputs recalibrated accelerometer parameters p whence RETURN 2995 is reached and the recalibrated accelerometer parameters p are stored in a memory record along with associated environmental sensor 1160 measurements and are used in navigation applications thereafter.

**[0117]**An experiment was carried out with 12 bit accelerometer KXR94 from Kionix Inc. The accelerometer bias errors and axes gain were initially estimated by obtaining the averaged outputs of the accelerometer in six different precise orientations or postures as discussed in connection with equations (8) and (9). The individual readings (for each orientation) and the computed estimates of parameters using this demanding six-posture method are shown in TABLE 2.

**[0118]**Next, according to the more user-convenient process embodiment I, the accelerometer was placed on 14 different and arbitrary postures and the averaged output on each posture at rest was obtained. The individual readings (for each orientation) and the computed estimates of parameters p are shown in TABLE 3 for the more convenient approach of embodiment I taught herein. The convenient approach of embodiment I is user friendly and does not depend on any specific orientation during calibration of accelerometers. A total of six readings at any different orientations is sufficient to obtain a solution for the axes gain and bias errors, however more observations help to refine the estimates. A set of observations drawn from various orientations (spanning 4π steradians of a sphere) is likely to provide better accuracy of estimates.

**TABLE**-US-00002 TABLE 2 ESTIMATION OF BIAS ERRORS AND AXES GAIN (DEMANDING SIX-POSTURE METHOD) Accelerometer Measurements Orientation X-axis Y-axis Z-axis x-axis towards gravity 1.172684 0.049973 -0.07548 x-axis against gravity -1.24361 0.073605 -0.09897 y-axis towards gravity -0.01779 1.266058 -0.08268 y-axis against gravity -0.03391 -1.14064 -0.12097 z-axis towards gravity -0.02251 0.052657 0.879216 z-axis against gravity -0.02764 0.074148 -1.07293 Results of Demanding Six-Posture Method Estimated Bias errors -0.0288 0.062634 -0.0953 Estimated Axes gain 1.208149 1.203347 0.976074

**TABLE**-US-00003 TABLE 3 ESTIMATION OF BIAS ERRORS AND AXES GAIN (PROCESS I) Accelerometer Measurements Orientation X-axis Y-axis Z-axis Horizontal -0.02251 0.052657 0.879216 Upside Down -0.02764 0.074148 -1.07293 30° Pitch 0.551517 0.053191 0.755749 60° Pitch 0.99879 0.0517 0.406065 90° Pitch 1.172684 0.049973 -0.07548 -30° Pitch -0.64078 0.065662 0.742544 -60° Pitch -1.08329 0.07364 0.384561 -90° Pitch -1.24361 0.073605 -0.09897 30° Roll -0.02992 0.643543 0.75876 60° Roll -0.02621 1.099725 0.407088 90° Roll -0.01779 1.266058 -0.08268 -30° Roll -0.03625 -0.55319 0.737029 -60° Roll -0.03995 -0.98712 0.373648 -90° Roll -0.03391 -1.14064 -0.12097 Results of Estimation Process I Estimated Bias errors -0.0343 0.0655 -0.0977 Estimated Axes gain 1.207438 1.204094 0.975515

**[0119]**The estimates of bias errors and axes gain obtained from the demanding six-posture approach of TABLE 2 and the process embodiment I in TABLE 3 were applied to the various measurements at different orientations. The resultant value of gravity vector was computed after applying the bias and scale corrections to the various observations on all three axes. The result is tabulated in TABLE 4 and shows the percentage errors as the magnitude of the difference between unity gravitational acceleration and computed gravitational acceleration based on the measurements.

**TABLE**-US-00004 TABLE 4 MEASUREMENT ERROR MAGNITUDE (%) BASED ON BIAS ERROR AND AXES GAIN ESTIMATES % error of measured value % error of of Gravity - Demanding measured value of Orientation Six-Posture Method Gravity - Process I Horizontal 0.155% 0.154% Upside Down 0.164% 0.025% 30° Pitch 0.450% 0.045% 60° Pitch 0.634% 0.057% 90° Pitch 0.525% 0.003% -30° Pitch 0.330% 0.291% -60° Pitch 0.179% 0.039% -90° Pitch 0.557% 0.158% 30° Roll 0.067% 0.064% 60° Roll 0.384% 0.278% 90° Roll 0.019% 0.272% -30° Roll 0.547% 0.190% -60° Roll 0.404% 0.114% -90° Roll 0.029% 0.198% Average (% error) 0.317% 0.135%

**[0120]**The results in TABLE 4 show a lower average error magnitude for Process I, with an upper bound of less than 0.3%. The error is higher for the demanding six-posture approach of TABLE 2 since it is difficult to accurately orient the accelerometers in the required six predetermined postures. Not only does Process I accurately measure the magnitude of gravity, but also it accurately measures the X, Y, Z vector components of the gravitational acceleration, as indicated by the close correspondence of the respective values determined for Estimated Bias errors in TABLES 3 and 2 and the close correspondence of the values determined for Estimated Axes gain in TABLES 3 and 2. The work presents a simple procedure to the user to measure bias and axes gain by process I and TABLE 3. It does not put any restriction on orientation and would benefit even ordinary cell phone users to calibrate accelerometers 1140 on the fly for portable device and vehicle navigation. The knowledge of bias errors and axes gain can serve as good initial estimates for a subsequent Kalman filter states for calibrating INS with respect to GPS as in FIG. 9 described later herein below.

**[0121]**A separate use of Kalman filtering is taught next herein for an alternative process embodiment 1K wherein the accelerometer 1140 calibration itself is achieved for process I above using Kalman filtering instead. The Kalman embodiment for Method IK goes as follows:

**[0122]**Step 1K-1. Parameters to be estimated: p=[Yxx, Yyy, Yzz, μ

_{x}, μ

_{y}, μ

_{z}]. Use a starting a priori estimate of the parameters: p

^{-}=[1 1 1 0 0 0], where the values represent the starting values of the parameters defined in vectorp.

**[0123]**Step 1K-2. Establish an initial uncertainty covariance matrix P

^{-}that describes the initial covariance of the uncertainties in parameters. P

^{-}(i,j)=E ((q

_{i}-p

^{-}

_{i})(q

_{j}-p

^{-}j)) where "E( )" signifies expectation and where {q

_{i}, q

_{j}} are the unknown actual values of parameters p

^{-}

_{i}, p

^{-}

_{j}. For example, set the a priori estimate of the covariance matrix according to a specification of the accelerometer 1140 bias error range and gain error range. Covariance matrix P

^{-}is square and symmetric in general, and has dimensions (6×6) in an example with six parameters as here.

**[0124]**The Kalman filter process for the above estimation problem is divided into a Time Update and a Measurement Model:

**[0125]**Step 1K-3. In the Time Update the parameters p are propagated from one time instant t to a next time instant t+1, i.e. p

^{t}+1=p

^{t}. In this example, iterations are used as a proxy for time.

**[0126]**Step 1K-4.1. The Measurement Model first determines the value of gravity function g based on a priori estimates of p(=p

^{-}) and references it to unity (normalized value of gravity) e.g., as in Equation (15). Actual gravity magnitude unity is equal to the sum of gravity function plus measurement noise as expressed by: 1=g(f

_{x}

^{k}, f

_{y}

^{k}, f

_{z}

^{k}, p

^{-})+w. Gravity g and noise w are bolded as column vectors indexed on the measurements k.

**[0127]**Step 1K-4.2. The values entered in measurement noise w from accelerometers 1140 are assumed to arise from a zero mean white Gaussian process. Establish a (m×m) matrix W as the covariance matrix for (m×1) measurement noise w.

**W**(i,j)=E(w

_{i}*w

_{j})

**It may be noted that for white Gaussian process**,

**W**(i,j)=σ

_{i}

^{2}

**W**(i,j)=0; i≠j

Δg(k)=1-g(f

_{x}

^{k}, f

_{y}

^{k}f

_{z}

^{k}, p

^{-}) is defined as the residue of the measurements k.

**[0128]**Step 1K-5. Compute values for a matrix H where H is the Jacobian (a gradient-based matrix) of the function g with respect to the parameters p, i.e., H (k, j)=δg(k)δp (j) is the Jacobian or gradient of the k

_{th}measurement with respect to the j

^{th}parameter. Matrix H is (m×6) and same as equation (21) hereinabove, for example.

**[0129]**Step 1K-6. Compute the Kalman Gain as follows:

**K**=P

^{-}H

^{T}(HP

^{-}H

^{T}+W)

^{-1}

(6×m)=(6×6) (6×m)×[(m×6)(6×6)(6×m)+(m×m)] is the dimensional relation.

**[0130]**The Kalman Gain K represents a suitable weighting factor to the measurement update based on the current state uncertainties and measurement uncertainties.

**[0131]**Step 1K-7.1. Update the parameters according to the equation:

**p**=p

^{-}+KΔg

**i**.e., (6×1)=(6×1)+(6×m)(m×1).

**[0132]**Step 1K-7.2. Update the estimates for the parameters p

^{-}for the next iteration using p

^{-}

_{k+1}=p

_{k}.

**[0133]**Step 1K-8.1. Update a matrix capital-P (P matrix) with the measurement as follows:

**P**=(I-KH)P

^{-}.

**i**.e., (6×6)=((6×6)-(6×m)(m×6)) (6×6).

**[0134]**Step 1K-8.2. Update the estimates for the parameter covariance matrix P

^{-}for the next iteration using P

^{-}

_{k+1}=P

_{k}.

**[0135]**Step 1K-9.1. Generate the sum of squared residues (Δg

^{T}Δg).

**[0136]**This sum is a scalar (1×m)(m×1)=(1×1).

**[0137]**Step 1K-9.2. Determine whether the sum of squared residues is less than a threshold value ε pre-established for purposes of convergence testing. If not less, loop back to Step 1K-4.1. The loop is continued until the estimation process converges, as indicated when the sum of squared residues (Δg

^{T}Δg) is less than the pre-established threshold ε. Then process goes to Step 1K-10.

**[0138]**Step 1K-10. Output the estimates for the parameters p for use in a navigation application. If a navigation application utilizes any other estimates generated by the Kalman filter process, output those other estimates as well. In some embodiments, measurements are time-windowed or grouped according to similar temperature, or both, according to a measurement grouping process. In such cases, the procedure is executed again when appropriate to do so given the type of measurement grouping process as new measurement data comes in over time.

**[0139]**Another, second, optimization process embodiment (II) for calibrating accelerometers 1140 on-the-fly takes a number "m" measurements indexed k of the acceleration of gravity-square g

^{2}(k) at different postures. FIGS. 6A and 6C depict process embodiment II, and the computational procedures are varied in process embodiment II in some ways relative to process embodiment I detailed earlier hereinabove. The orientation of each of the postures does not need to be known. In general, the embodiment II is computationally more efficient, as it avoids functions like square-root and some division operations and does converge. However, embodiment II may result in inferior convergence of final parameter set compared to embodiment I.

**[0140]**Equation (11) is expressed as a sum of squares for the kth measurement without square root, and is given by equation (24).

**g**

^{2}(k)=Yxx

^{2}(f

_{x}

^{m}(k)-μ

_{x})

^{2}+Yyy

^{2}(f

_{y}.- sup.m(k)-μ

_{y})

^{2}+Yzz

^{2}(f

_{z}

^{m}(k)-μ

_{z})

^{2}(24)

**[0141]**Until the calibration is completed, the measured square of the acceleration of gravity g

^{2}(k) for any given measurement k will likely be somewhat different from the known value unity (1.00) while the six unknown parameters are being optimized by the procedure described next.

**[0142]**Define the parameter vector p holding the six unknowns (initialization values or current unrefined values) in this process embodiment:

**p**=[YxxYyyYzzμ

_{x}μ

_{y}μ

_{z}]

^{T}(16)

**[0143]**Here, parameter vector p does not need to be determined by equations (8) and (9) based on demandingly-precise test orientations. Instead, equation (24) is linearized by chain rule calculus differentiation to become equation (25). Equation (25) is expressed directly in terms of measured quantities multiplied by their differences Δp for an iterative process embodiment free of division operations by g(k).

Δg

^{2}(k)=2[ΔYxxYxx(f

_{x}

^{m}(k)-μ

_{x})

^{2}+.DELT- A.YyyYyy(f

_{y}

^{m}(k)-μ

_{y})

^{2}+ΔYzzYzz(f

_{z}

^{m}(k)- -μ

_{z})

^{2}-Δμ

_{x}Yxx

^{2}(f

_{z}

^{m}(k)-μ

_{x})- -Δμ

_{y}Yyy

^{2}(f

_{y}

^{m}(k)-μ

_{y})-Δμ

_{z}- Yzz

^{2}(f

_{z}

^{m}(k)-μ

_{z})] (25)

**[0144]**Notice that Δg

^{2}(k) signifies some amount of change in the measured value of gravity-squared expressed as a linearized product of the difference vector expressing some amount of change in the six unknowns of parameter vector p and multiplied times the six partial derivatives (gradient in equation (25)) of gravity-squared equation (24) as coefficients. Notice that gravity squared g

^{2}(k) is treated as an entity per se and not as though some gravity value itself were known as a pre-existing value to multiply by itself to form such square. Moreover, at this point the difference value Δg

^{2}(k) of the entity gravity-squared is not determined in value, although its gradient-based linear relation is now established relative to also-undetermined changes in the six unknowns of parameter vector p.

**[0145]**An equivalent linearized form for an iterative process embodiment that uses equation (1A) to intermediately compute components of true accelerations f

^{a}for use in equation (17) is expressed as equation (17A):

Δg

^{2}(k)=2[ΔYxxf

_{x}

^{a}(k)

^{2}/Yxx+ΔYyyf

_{y}-

^{a}(k)

^{2}/Yyy+ΔYzzf

_{z}

^{a}(k)

^{2}/Yzz-Δμ

_{x}- Y

_{xx}f

_{x}

^{a}(k)-Δμ

_{y}Yyyf

_{y}

^{a}(k)-Δμ.- sub.zYzzf

_{z}

^{a}(k)] (25A)

**[0146]**Rewriting the linear relationship of either equation (25) or (25A) in matrix form, with the symbolism Δg

^{2}understood as an (m×1) vector of elements Δg

^{2}(k), provides equation (26):

Δg

^{2}=2H

_{2}Δp (26)

**[0147]**Matrix H

_{2}is the gradient-based relation matrix (m×6) defined by equation (25) or (25A). The six partial derivatives in equation (25) of gravity-squared equation (24) for any given measurement k are respectively equal to twice the corresponding values in the corresponding row k of matrix H

_{2}.

**[0148]**Pre-multiplying both sides of equation (26) with a matrix transpose, i.e., (6×m) matrix H

_{2}

^{T}, delivers equation (26A), which has a 6×6 invertible square matrix product H

_{2}

^{TH}

_{2}on the right side of the equation (26A):

**H**

_{2}

^{T}Δg

^{2}=2H

_{2}

^{TH}

_{2}Δp (26A)

**where**,

Δp=[ΔYxxΔYyyΔYzzΔμ

_{x}Δμ

_{y}- Δμ

_{z}]

^{T}

Δg

^{2}=[Δg

^{2}(1) . . . Δg

^{2}(k) . . . Δg

^{2}(m)]

^{T}

**[0149]**Solving equation (26A) by computationally relatively-convenient (6×6) matrix inversion yields equation (27):

Δp=0.5(H

_{2}

^{TH}

_{2})

^{-1}H

_{2}

^{T}Δg

^{2}(27)

**[0150]**The matrix inverse (H

_{2}

^{TH}

_{2})

^{-1}will generally not exist unless the number m of measurements equals or exceeds the number of unknowns (e.g., 6) in the parameter change vector Δp. In general, the matrix rank R of the matrix product H

_{2}

^{TH}

_{2}desirably equals or exceeds the number of unknowns in the parameter change vector Δp so that the determinant of the matrix product H

_{2}

^{TH}

_{2}is non-zero and the matrix product H

_{2}

^{TH}

_{2}is invertible in process II.

**[0151]**Still remaining undetermined at this point are both linearly related vectors--the (m×1) column vector Δg

^{2}for the differenced entity gravity-squared and the vector Δp representing changes in the six unknowns of parameter vector p. Their inverted linear relation is now established according to equation (27). To determine Δg

^{2}, it is here made to be a negative feedback quantity established as a function of each squared gravity measurement in the iterative process relative to its target value of unity (square of unity is unity). The difference of the entity gravity-squared relative to target value unity (1.00) of gravitational acceleration is g

^{2}(k)-1. A positive iteration constant c is applied, and negative feedback is signified by a leading minus-sign (-), as in equation (28):

Δg

^{2}=-c(g

^{2}(k))=c(1-g

^{2}(k))

**[0152]**Equation (28) is substituted into equation (27) to yield equation (29):

Δp=0.5c(H

_{2}

^{TH}

_{2})

^{-1}H

_{2}

^{T}[1-g

^{2}(k)] (29)

**[0153]**Equation (29) determines Δp, in terms of iteration constant c, the inverted linear relation 0.5(H

_{2}

^{TH}

_{2})

^{-1}H

_{2}

^{T}, and an (m×1) column vector [1-g

^{2}(k)]. Column vector [1-g

^{2}(k)] represented algebraically has m elements wherein each kth element is generated by a processor in system 1700 subtracting the kth measurement of gravity-squared g

^{2}(k) from unity (1). Equation (29) supports each negative-feedback-driven iteration in an iterative estimation process for updating unknown parameter vector p. If there are fewer measurements m than the number of unknowns (e.g., 6) and more measurements cannot be available or will not be available, then equation (29) can be replaced with equation (39A) described later hereinbelow.

**[0154]**In concept, the iteration constant c approximately represents a proportion of the distance vector from a given point in multi-dimensional mathematical space (e.g. 6-space) to the target point in that space. The iteration constant c suitably is predetermined to have some value in a range 0<c<2. Choosing a value of iteration constant c that is greater than zero and less than or equal to one generally defines motion in the multidimensional space progressively in the direction of the target without overshooting the target. Choosing a value of iteration constant c that is more than one (1.0) and less than two (2.0) generally defines motion in the multidimensional space that overshoots the target but can ultimately converge on the target by successive hunting that backtracks and overshoots decreasingly. Choosing a value of iteration constant c in the narrower range 0.8<c<1.2 is likely to produce convergence of the estimation process in fewer iterations than choosing a value outside that narrower range. A nominal value for iteration constant c is one (1.0) for rapid convergence, although some development trial and error in choosing a value for iteration constant c may show that some reduction in the number of iterations (and consequent computer time and energy) can be obtained by departing from c=1.0 somewhat. In the electronic processing, one suitably combines the product 0.5 c into one pre-stored constant value c'=0.5c for processing, and the corresponding ranges are wide range 0<c'<1, narrower range 0.4<c<0.6, and a nominal value c'=0.5 in process embodiment II. By contrast, in process embodiment I earlier hereinabove the factor 0.5 of process embodiment II is not present and an iteration factor c is suitably provided in equation (20) in process embodiment I in some versions.

**[0155]**Description now returns to give some more detail about the content of (m×6) relation matrix H

_{2}. In a first example, note that each kth row of an (m×6) relation matrix H

_{2}is based on the sensor outputs f

_{x}

^{m}(k) f

_{y}

^{m}(k) f

_{z}

^{m}(k) of the kth measurement and equation (25). Each kth row of matrix H

_{2}has six numerical values that are numerically generated by an electronic processor programmed with these six expressions that use information from equations (25) and (16):

[Yxx(f

_{x}

^{m}(k)-μ

_{x})

^{2},Yyy(f

_{y}

^{m}(k)-μ

_{y}).s- up.2,Yzz(f

_{z}

^{m}(k)-μ

_{z})

^{2},-Yxx

^{2}(f

_{x}

^{m}(k)-.m- u.

_{x}),-Yyy

^{2}(f

_{y}

^{m}(k)-μ

_{y})-Yzz

^{2}(f

_{z}

^{m}(- k)-μ

_{z})] (30)

**[0156]**In a second example, note that each kth row of (m×6) relation matrix H

_{2}is based instead on equation (1A) applied to compute components of true acceleration f

^{a}from the sensor outputs f

_{x}

^{m}(k) f

_{y}

^{m}(k) f

_{z}

^{m}(k) of the kth measurement. Each kth row of relation matrix H

_{2}is based on equation (25A) and gets the same six numerical values as in the first example, but which are numerically generated by an electronic processor alternatively programmed with these alternative six expressions that use information from equations (25A) and (16):

[f

_{x}

^{a}(k)

^{2}/Yxx,f

_{y}

^{a}(k)

^{2}/Yyy,f

_{x}

^{a}(k).su- p.2/Yzz,-Yxxf

_{x}

^{a}(k),-Yyyf

_{y}

^{a}(k),-Yzzf

_{z}

^{a}(k)] (30A)

**[0157]**An iterative estimation process embodiment such as one including equations (24)-(29) is programmed for execution on a floating-point or fixed point processor such as in system 1700. Different embodiments are suitably considered by the skilled worker in regard to expected number of iterations involved for convergence of the estimation process, number of clock cycles per iteration, acceptably small processor roundoff errors, processor power and energy dissipation, operability on less expensive fixed point processors with shorter register length, etc. Various iterative processes and sets of processor instructions to accomplish each of them are suitably provided and applied by the skilled worker in practicing various embodiments according to the teachings herein.

**[0158]**For gravity-squared process embodiment II, the various parameters initialization is shown in TABLE 1, same as in process embodiment I. The final estimates of bias errors μx, μy, μz and axes gain reciprocals Yxx, Yyy, Yzz are obtained through multiple iterations. The steps for each iteration are as follows and are further described in connection with FIGS. 6A and 6C:

**[0159]**Estimation Process II

1. Initialize parameters p according to TABLE 1.2. Keep the three axes accelerometer 1140 at any arbitrary posture, keep it stationary and measure the average acceleration on all three axes: [f

_{x}

^{m}f

_{y}

^{m}f

_{z}

^{m}]

^{T}. Repeat the process "m" number of times with different postures every time to get "m" sets of measurement vectors.3. Compute the measured value of g

^{2}(k) using the current parameter values and equation (24) for each measurement k; k=1 to m4. Compute 1-g

^{2}(k); k=1 to m

**[0160]**(Difference Between Target Value and Measured Value)

5. Compute the matrix H

_{2}using equation (30) where the kth row of H

_{2}is computed from the kth measurement set and the current parameter values (equation (16)).6. Compute Δp using equation (29).7. Update the parameter values; p=p+Δp.8. Compute g

^{2}(k) using current parameter values.9. Compute and test a convergence criterion, such as

**CC**1 = k = 1 m ( 1 - g 2 ( k ) ) 2 < m 2 ##EQU00005##

**or use CC**2=Δp

^{T}Δp<ε

_{3}instead as described herein below. If convergence criterion CC is less than Specified Threshold then stop, else loopback to Step 4.

**[0161]**Determining that convergence criterion

**CC**1 = Δ g 2 T Δ g 2 = k = 1 m ( 1 - g 2 ( k ) ) 2 ##EQU00006##

**less than Specified Threshold**(CC1<m ε

_{2}) is a reasonable formula since all the measurements g

^{2}(k) are similar in concept to one another. Note that the Specified Threshold CC1 for step (8) is expressed for process embodiment II as the product (mε

_{2}) of the number of measurements m times a small specified amount epsilon ε

_{2}defining a numerical bound within which the optimizing iterations are to be regarded as having sufficiently approached zero when the estimation process has converged.

**[0162]**An alternative convergence criterion for step (8) is given by CC2=Δp

^{T}Δp<ε

_{3}as Specified Threshold. In other words when the updates to the parameter vector become computationally insignificant, then the iterations are regarded as having converged in an embodiment version that uses convergence criterion CC2. The several elements of parameter vector p differ in their concept as gain parameters and bias parameters, so a small Specified Threshold amount ε

_{3}is specified and used.

**[0163]**The description of FIG. 6A hereinabove applies similarly to process embodiment II. In FIG. 6C, operations continue from point A of FIGS. 6A and 6C to a step 3110 wherein the measurement index k is initialized to one (1). A succeeding step 3120 computes a first function of gravitational acceleration such as g(k) itself of Process I equation (15), or gravity-squared value g

^{2}(k) of Process II using sum of squares equation (24), or some other function. The six-component parameter vector in Equation (16), or a twelve-component parameter vector, or some other parameter vector, is used. For example, the six-component parameter vector in equation (16) is initialized, e.g., to p=[1 1 1 0 0 0]

^{T}or a set of parameter values resulting from recent re-calibration. The function of gravitational acceleration is computed based on the current values in the parameter vector and the average acceleration measurement vector components f

_{x}

^{m}(k), f

_{y}

^{m}(k), and f

_{z}

^{m}(k) for k=1 from the accelerometer sensors X, Y, Z.

**[0164]**Further in FIG. 6C, a processor step 3130 computes a second function of the gravitational acceleration related to an error feedback based on the second function. An example of such a second function is a difference 1-g

^{2}(k) between known unity (1.00) squared-gravitational acceleration and the computed gravity-squared value g

^{2}(k) from step 3120. Then a processor step 3140 generates a set of values related to the gradient of the first function. One example of such a set of values is a kth set of six row values for the kth row of (m×6) relation matrix H

_{2}according to the row formulas in expression (30) or in expression (30A). In words, relation matrix H

_{2}is a table in memory that is populated by the process embodiment II with numerical values. A numerical value is generated by the processor for the memory entry corresponding to each row k, column j of the relation matrix H

_{2}. The processor populates row k using the current parameter vector p and the average acceleration vector components f

_{x}

^{m}(k) f

_{y}

^{m}(k) and f

_{z}

^{m}(k), all for measurement k. For instance, the memory entry corresponding to row k, column one is computed by the processor programmed according to the formula H(k, 1)=(Yxx (f

_{x}

^{m}(k)-μ

_{x})

^{2}), and so forth over to row k, column 6, which follows the formula H(k, 6)=-(Yzz

^{2}(f

_{z}

^{m}(k)-μ

_{z})). At this point in FIG. 6C, matrix H

_{2}row k is populated. Steps 3120, 3130, 3140 are repeated for as many new measurements as are available.

**[0165]**A succeeding step 3150 updates the parameters p based on the error feedback and the gradient-related values. This operation takes various forms in process embodiments I, II, III and IV described herein.

**[0166]**In process embodiment II, for instance, step 3150 updates the six-dimensional parameters estimate p based on equation (29):

**p**=p+Δp=p+0.5c(H

_{2}

^{TH}

_{2})

^{-1}H

_{2}

^{T}[1-g

^{2}(k)- ] (31)

**[0167]**If the matrix product H

_{2}

^{TH}

_{2}is not invertible due to insufficient rank R<6, operations go to point (D) in FIG. 6A to cue the user and take another measurement. Operations likely go from step 3150 to step 3160.

**[0168]**The outer loop has a decision step 3160 that computes a convergence metric, such as CC1 or CC2 hereinabove, and compares it with a threshold to determine whether the outer loop is converged. For instance, convergence test CC1 involves the sum of squares of computed differences for gravity-squared:

**CC**1 = k = 1 m ( 1 - g 2 ( k ) ) 2 < m 2 ( 32 ) ##EQU00007##

**[0169]**Inequality (32) expresses the convergence criterion that the parameters p should be such that the sum of squares of differences of computed gravity-squared relative to unity over all the m measurements should be small so that all or almost all the measurements do a good job of measuring the gravitational acceleration components. The convergence test expressed in another way determines a mean of the squares of the departures of g

^{2}(k) from unity according to inequality (32A):

**CC**1 A = k = 1 m ( 1 - g 2 ( k ) ) 2 / m < 2 ( 32 A ) ##EQU00008##

**If decision step**3160 detects that the outer loop is not converged (No), as indicated by the convergence test not being met, then operations loop back to step 3120 and perform another iteration based on the latest updated parameters p. When the outer loop is converged (Yes) at step 3160, operations proceed to a step 3170 that outputs recalibrated accelerometer 1140 parameters p and uses them in a navigation application in system operations whence RETURN 3180 is reached. It should be emphasized that the run-time navigation application is executed in general in the presence of varying accelerations that depart from the acceleration of gravity itself, which is desirable and satisfactory. The accelerometer 1140 desirably measures the acceleration as the acceleration actually varies over time for purposes of supporting the run-time navigation application. The measurements of acceleration for the navigation application are rendered more accurate because of the previously-performed recalibration of the accelerometer parameters in the presence of gravity acceleration itself. In general, the embodiment II is computationally more efficient, as it avoids functions like square-root etc. However, the convergence from embodiment II is expected to be inferior from embodiment I.

**[0170]**Description next turns to a third optimization process embodiment (III) for calibrating accelerometers on-the-fly, which applies measurement matrices for a gradient and a matrix of second partial derivatives to form a parameter change vector Δp for updating parameter estimate p.

**[0171]**An optimization function based on the gravity equation has a minimum in 6-dimensional space due to the mathematical form of the optimization function and the gravity equation. FIGS. 6A/6C depict process embodiment III at the level of the flow illustration, and the computational procedures are varied in process embodiment III in some ways in a first process form III-A relative to process embodiment II and in a second process form III-B relative to process embodiment I detailed hereinabove. The orientation of each of the postures does not need to be known.

**[0172]**Equation (24) is repeated for clarity here.

**g**

^{2}(k)=Yxx

^{2}(f

_{z}

^{m}(k)-μ

_{x})

^{2}+Yyy

^{2}(f

_{y}.- sup.m(k)-μ

_{y})

^{2}+Yzz

^{2}(f

_{z}

^{m}(k)-μ

_{z})

^{2}(24)

**[0173]**The measured square of the acceleration of gravity g

^{2}(k) for any given measurement k is computed for FIG. 6C step 3120 and will likely be different from the known value unity (1.00) while the six unknown parameters are being optimized by the procedure described next. Accordingly process embodiment III establishes an optimization function

**= k = 1 m F ( k ) , where F ( k ) = ( g 2 ( k ) - 1 ) 2 ( 33 ) ##EQU00009##**

**[0174]**that has its minimum when the parameters are such that applying equation (24) to the measurement set produces gravity-squared values very near or at the desired value unity, i.e., when g

^{2}(k)˜=1. The optimization function summand F(k) is a function of the parameter vector p holding the six unknowns in this process embodiment III, and equation (16) is also repeated for clarity:

**p**=[YxxYyyYzzμ

_{x}μ

_{y}μ

_{z}]

^{T}(16)

**[0175]**Here again, parameter vector p does not need to be determined by equations (8) and (9) based on demandingly-precise test orientations. Instead, in process embodiment III, a gradient descent or Newton-Raphson process is included. Conceptually, note that the matrix H

^{T}multiplication equation (18A) for process I and H

_{2}

^{T}equation (26A) for process II each represent a summation relationship between the numerous m measurements data and one parameter vector update estimate Δp. In process embodiment III, the approach posits that this one parameter vector update estimate Δp should be such as to make the gradient vanish. That is, for the measurements collectively, the summation of the gradients ∇F(k) should be canceled out by the matrix product of the summation of the matrices M(k) of second partial derivatives with respect to the parameters of the optimization summand function F(k), matrix multiplied by this one parameter vector update estimate Δp:

**∇ + ∇ ∇ Δ p = 0 , or ( 34.1 ) k = 1 m ∇ F ( k ) + k = 1 m ( M ( k ) Δ p ) = 0 ( 34.2 ) ##EQU00010##**

**[0176]**Because Δp does not depend on measurement index k, equation (34.2) is also expressed as follows:

**k**= 1 m ∇ F ( k ) + ( k = 1 m M ( k ) ) Δ p = 0 ( 34.3 ) ##EQU00011##

**[0177]**Next, solve for Δp:

**Δ p = - ( k = 1 m M ( k ) ) - 1 k = 1 m ∇ F ( k ) ( 34.4 ) ##EQU00012##**

**[0178]**For the electronic computations, the process III-A operates using equation (39) later below, evolved from equation (34.4) for the iteration(s). Execute process III-A in the same iterative manner as process II earlier herein above. The gradient ∇F(k) for process III-A is a column vector of first partial derivatives of optimization function F(k) and is given for the kth measurement by partial differentiating equation (33) to obtain equation (35). A convenient approach to set up the equation (35) partial-differentiates by the chain rule--derivative of F(k) in equation (33) with respect to g

^{2}itself (not g) multiplied times gradient of g

^{2}itself using g

^{2}equation (24) with respect to the parameters p:

∇F(k)=-4H

_{2}

^{T}(k)(1-g

^{2}(k)) (35)

**[0179]**Notice that the factor (1-g

^{2}(k)) is a scalar in equation (35) and arises in differentiating squared difference represented by optimization function F(k). Scalar factor (1-g

^{2}(k)) relates to error feedback step 3130. Column vector H

_{2}T(k) arises from the calculus chain rule that further proceeds to calculus-differentiate g

^{2}(k) of equations (35) and (24). The factor "4" (2×2) arises because the chain rule encounters and differentiates two squares in succession. Column vector H

_{2}T(k) is the transpose of the kth row of the relation matrix H

_{2}already given in expression (30) and repeated here for clarity:

[Yxx(f

_{x}

^{m}(k)-μ

_{x})

^{2},Yyy(f

_{y}

^{m}(k)-μ

_{y}).s- up.2,Yzz(f

_{z}

^{m}(k)-μ

_{z})

^{2},-Yxx

^{2}(f

_{x}

^{m}(k)-.m- u.

_{x}),-Yyy

^{2}(f

_{y}

^{m}(k)-μ

_{y}),-Yzz

^{2}(f

_{z}

^{m}- (k)-μ

_{z})] (30)

**[0180]**The matrix M(k) of second partial derivatives of the optimization function F(k) is derived by partial differentiation of equation (35) gradient ∇F(k) of the optimization function. To obtain matrix M(k) of second partial derivatives, it is convenient to write down by inspection of equations (24) and (21):

∇g

^{2}(k)/2=H

_{2}

^{T}(k)=gH

^{T}(k)=g(k)∇g(k) (36)

**[0181]**The matrix M(k) of second partial derivatives of F(k) that results is given by equation (37):

**M**(k)=8∇g

^{2}(k)/2∇g

^{2}(k)/2

^{T}-4[∇

^{2}g

^{2}(k)/2](1-g

^{2}(k)) (37)

**[0182]**In the first term of equation (37), a matrix ∇g

^{2}(k)/2∇g

^{2}(k)/2

^{T}is formed by pre-multiplying the row expressed by (30), by its own transpose. The double-del symbolism in the second term of equation (37) represents the following matrix in equation (38):

**[ ∇ 2 g 2 ( k ) / 2 ] = [ ∇ H 2 T ( k ) ] = [ ( f x m ( k ) - μ x ) 2 , 0 , 0 , - 2 Y xx ( f x m ( k ) - μ x ) , 0 , 0 ] [ 0 , ( f y m ( k ) - μ y ) 2 , 0 , 0 , - 2 Y yy ( f x m ( k ) - μ x ) , 0 ] [ 0 , 0 , ( f z m ( k ) - μ z ) 2 , 0 , 0 , - 2 Y zz ( f z m ( k ) - μ z ) ] [ - 2 Y xx ( f x m ( k ) - μ x ) , 0 , 0 , Y xx 2 , 0 , 0 ] [ 0 , - 2 Y yy ( f y m ( k ) - μ y ) , 0 , 0 , Y yy 2 , 0 ] [ 0 , 0 , - 2 Y zz ( f z m ( k ) - μ z ) , 0 , 0 , Y zz 2 ] ( 38 ) ##EQU00013##**

**[0183]**Now combine equations (34.4), (35), (36), (37) and insert an iteration constant c (e.g., 1.0 or in any range discussed earlier hereinabove) to yield equation (39):

**Δ p = 0.5 c ( H 2 T H 2 - 0.5 k = 1 m ( [ ∇ H 2 T ( k ) ] ( 1 - g 2 ( k ) ) ) ) - 1 H 2 T Δ g 2 ( 39 ) ##EQU00014##**

**[0184]**Equation (39) can be compared with process embodiment II equation (27). Notice that the matrix H

_{2}

^{TH}

_{2}of equation (27) to be inverted is adjusted in equation (39) by the adjustment term based on summation over measurements of the moderately-sparse matrix of equation (38) times Δg

^{2}(k):

**- 0.5 k = 1 m ( [ ∇ H 2 T ( k ) ] ( 1 - g 2 ( k ) ) ) . ##EQU00015##**

**[0185]**This adjustment term adds proportionately few computations and may reduce the number of iterations needed to converge the loop tested by step 3160.

**[0186]**The various parameters initialization is shown in TABLE 1 for initial calibration. When calibration is being updated, initialization values instead are suitably the most recent values for the calibrated parameters. The final estimates of bias errors μ

_{x}, μ

_{y}, μ

_{t}and axes gain reciprocals Yxx, Yyy, Yzz are obtained through multiple iterations, if needed, for each measurement and then averaging the parameter estimates. Using most recent calibrated parameters as a starting point, and/or using the adjustment term can reduce or eliminate multiple iterations.

**[0187]**Description now turns to a process embodiment III-B that is related to process embodiment I. Equation (36) hereinabove relates the gradient of that function of gravity g that is gravity itself in process embodiment I to the gradient of the function g

^{2}, i.e., of gravity-squared. A process III-B variant of process embodiment I starts with another optimization function

**1 = k = 1 m F 1 ( k ) , where F 1 ( k ) = ( g ( k ) - 1 ) 2 ( 33 - I ) ##EQU00016##**

**[0188]**and then is structured in a manner analogous to embodiment III-A equations herein above, except with "I" suffixes to the equations, as follows. Apply gradient descent or Newton-Raphson. Write the gradient-descent equation (34.4-I) and the gradient of F1(k) and a double-del matrix M1(k), i.e. ∇∇F1(k) of second partial derivatives, paralleling the development from equations (34.4) through (39):

**∇ 1 + ∇ ∇ 1 Δ p = 0 , or Δ p = - ( k = 1 m M 1 ( k ) ) - 1 k = 1 m ∇ F 1 ( k ) ( 34.4 - I ) ∇ F 1 ( k ) = 2 ( g ( k ) - 1 ) ∇ g ( k ) = 2 H 2 T ( k ) ( g ( k ) - 1 ) / g ( k ) ∇ ∇ F 1 ( k ) = 2 { H 2 T ( k ) [ ∇ ( 1 - 1 / g ( k ) ) ] - ( [ ∇ H 2 T ( k ) ] / g ( k ) ) ( 1 - g ( k ) ) } ( 35 - I ) = 2 { H T ( k ) H ( k ) ( 1 / g ( k ) ) - ( [ ∇ H 2 T ( k ) ] / g ( k ) ) ( 1 - g ( k ) ) } ( 37 - I ) ##EQU00017##**

**[0189]**Note in obtaining equation (37-I) that

**H**2 T ( k ) [ ∇ ( 1 - 1 / g ( k ) ) ] = H 2 T ( k ) [ ∇ g ( k ) T ] / g 2 ( k ) = H 2 T ( k ) / g ( k ) ) [ ∇ g ( k ) T ] ( 1 / g ( k ) ) = H T ( k ) H ( k ) ( 1 / g ( k ) ) . ##EQU00018##

**[0190]**Equation (39-I) for Process Embodiment III-B can be compared with process embodiment 1 equation (20).

**Δ p = c ( k = 1 m ( H T ( k ) H ( k ) ( 1 / g ( k ) ) - ( [ ∇ H 2 T ( k ) ] / g ( k ) ) ( 1 - g ( k ) ) ) ) - 1 H T Δ g ( 39 - I ) ##EQU00019##**

**[0191]**Execute process III-B by analogy with the steps of Estimation Process I earlier enumerated earlier hereinabove. (Note that the expression (1/g(k)) is dimensionless since the "1" is in gravity acceleration units, same units as gravity measurement g(k).) The dimensional analysis (physical units analysis) of equations (39) and (39-I) is given by: (param)=[(grav/param)

^{2}(grav/grav)-((grav

^{2}/param

^{2})/grav)(gr- av)]

^{-1}(grav/param)(grav). The expression "grav" represents gravitational acceleration in m/sec

^{2}and "param" represents the units of any given one of the parameters.

**[0192]**The iteration constant c is experimentally adjusted for fastest convergence, preferably convergence on the first or second iteration. Inspection of the different equation forms (20), (29), (39), and (39-I) suggests that the fastest-convergence value for iteration constant c may vary somewhat from process embodiment to embodiment. Indeed, because the iteration(s) occur in a multi-dimensional mathematical space, there are equally-multiple constants c

_{ii}that can be configured and used to support each process embodiment taught herein. The iterations may somewhat hunt or spiral toward the minimum of optimization function (or 1) where the gradient vanishes in the multi-dimensional mathematical space. Furthermore, iteration constant c is in some embodiments replaced with a diagonal matrix c having as many possibly-different independently-configured constant elements c

_{ii}down its main diagonal as there unknowns (e.g., 6) in parameter update vector Δp. Each of the diagonal elements c

_{ii}is chosen with a value approximately unity (1), or in a likely range 0.8<c

_{ii}<1.2 or substantially in the range 0<c

_{ii}<2. This use of such constant elements c

_{ii}recognizes that experimentation may show that iterations can be reduced in number on average by adjusting these constant elements c

_{ii}independently.

**[0193]**In FIG. 7A, another recalibration process embodiment 3300 acquires one or more new measurements at a time for input to any estimation process embodiment(s) described elsewhere herein and utilized in FIG. 7B. Recalibration process 3300 commences with BEGIN 3305 and determines whether an entry criterion is met at a step 3310. An example of entry criterion uses any one some or all of the following criteria: 1) time gating based on RTC 2526 over enough hours or days justify the calibration check, 2) user call for a navigation application, 3) environmental sensor 1160 input indicating a substantial temperature change, accelerometer voltage regulator voltage change, and/or other environmental change justifying recalibration, 4) or other suitable test. If the entry criterion is not met at step 3310, then operations go to RETURN 3395, otherwise operations proceed to a step 3320 that puts a set of pertinent already-determined parameters at the disposal of the procedure. For example, such parameters p in some embodiments are a set of parameters p obtained in a wholesale recalibration process that has gathered m measurements at some recent time and are associated with similar environmental sensor 1160 readings, e.g., same temperature and voltage. In some other embodiments, such parameters p are based on measurements one-by-one, hour-by-hour, or day-by-day, or otherwise occasional measurements.

**[0194]**Notice that FIG. 7A in some modes or embodiments does not need to cue the user, such as when a stable, diverse position is detected and elapsed time supported by RTC 2526 enables a new measurement occasionally to keep the calibration updated. An example of a new-measurement test first uses the currently available parameters p to convert the new accelerometer 1140 measurement vector f

^{m}(k)=[f

_{x}

^{m}(k) f

_{y}

^{m}(k) f

_{z}

^{m}(k)]

^{T}to an actual acceleration vector f

^{a}(k)=[f

_{z}

^{a}(k) f

_{z}(k)]. Then the measurement diversity test checks whether the inner product of f

^{a}(k)=[f

_{x}

^{a}(k) f

_{y}

^{a}(k) f

_{z}(k)] with each actual acceleration vector f

^{a}(k') for measurements k' in the applicable measurement set is, e.g., less than a predetermined value such as 0.8 for all but at most e.g. one (1) of the measurements k'. (If there is one earlier measurement k' for which the test fails, then earlier measurement can be culled in FIG. 7B.) This keeps the angles between the measurement-related actual acceleration vectors diverse (e.g., angles greater than arcos (0.8) up to 180 degrees. In some other modes, user cueing is provided to facilitate rapid acquisition of measurements. In this way, a further seamless, automatically self-calibrating accelerometer support for navigation applications is provided.

**[0195]**A succeeding input step 3330 automatically monitors sensors X, Y, Z from the 3-axes accelerometer 1140 to determine when a new set of stable measurements is available, whereupon the new set of measurements f

^{m}(k)=[f

_{x}

^{m}(k) f

_{y}

^{m}(k) f

_{z}

^{m}(k)]

^{T}is recorded along with the concurrent environmental variables. Then a further preliminary gating process has steps 3340 and 3350 to respectively compute a function and test of measured gravitational acceleration such as (1-g

^{2}(k))

^{2}<ε

_{4}, or a range check |(1-g

^{2}(k))|<1+ε

_{6}, or a range check on (1-g(k)), or otherwise. In the step 3350, if the test passes, then the new measurement does not add significant new information for purposes of obtaining the already-determined parameters p, and so operations go to RETURN 3395. In the step 3350, if the test fails, then operations proceed through point (B) of FIG. 7A and on to FIG. 7B.

**[0196]**In FIG. 7B, operations proceed through point (B) to a step 3510 that keeps a revolving set of measurements and/or already-determined parameters p. The latest measurement is recorded and included in this set. At least one earlier measurement is deselected or culled from the revolving set such as by applying any one or a combination of the following de-selection criteria: 1) least-recent (oldest) measurement or set of parameters, 2) outlier in a subset of oldest measurements or oldest parameters, 3) least-diverse measurement relative to the new measurement. In this way, the embodiment provides a running window of observations in one or more sets, respectively having similar environmental variables pertinent to the measurements within a given set, for re-calibration purposes. The de-selection process is made flexible enough to allow the re-calibration to trend away from earlier calibrations when such trend exists and should be recognized.

**[0197]**Operations execute a step 3520 to produce newly determined parameters p', such as by combining the latest parameters with the now-culled revolving set of already-determined parameters from step 3510. Any estimation process as described elsewhere herein is suitably executed based on the now-culled revolving set from step 3510 to produce newly determined parameters p'. The newly determined parameters p' become the starting point for later re-calibration iterations in place of the initial values in TABLE 1 when the process embodiment of FIGS. 7A and 7B is called at some later time. In this way, unnecessary iterations are obviated, and processing time and power dissipation are reduced.

**[0198]**A further step 3530 generates and tests a metric comparing the updated parameters p' to the recently-determined parameters p of step 3320. For example, the metric and test suitably involves a distance metric such as

(p'-p)

^{T}(p'-p)<ε

_{7}(40)

**[0199]**In the step 3530, if the test passes, then the new measurement does not change the already-determined parameters p much, and so operations go to RETURN 3535. In the step 3530, if the test fails, then operations proceed to a further decision step 3540 to determine whether the parameter change metric (p'-p)

^{T}(p'-p)>d indicates that the new measured parameters have one or more elements that are such substantial outliers that the measurement f

^{m}(k) is not credible, as indicated by the metric exceeding a predetermined scalar distance d. If so, operations restore the culled measurement set to its original state and pass through a point C to step 3330 of FIG. 7A to take a new measurement. If credible (No at step 3540 of FIG. 7B), then operations reach RETURN 3535. After RETURN 3535, operations may execute a navigation application 3170 based on newly determined parameters p from recalibration.

**[0200]**It should be evident from the description of FIGS. 7A and 7B and other Figures as well that numerous variations and alternative processes for practicing different embodiments can be readily devised by the skilled worker based on the teachings herein.

**[0201]**Description turns to a fourth optimization process embodiment (IV) for calibrating accelerometers on-the-fly including cross-axes sensitivities and also takes a number "m" measurements indexed k of the squared acceleration of gravity g

^{2}(k) at different postures. FIGS. 6A/6C depict process embodiment IV at the level of the flow illustration, although the computational procedures are varied in process embodiment IV in some ways relative to process embodiments I or IK, detailed hereinabove to take account of the cross axes sensitivities. The orientation of each of the postures does not need to be known.

**[0202]**A sensitivity matrix designated S1 is written out in full with cross-axes gain terms:

**S**1 = [ S xx S xy S xz S yx S yy S yz S zx S zy S zz ] ( 41 ) ##EQU00020##

**[0203]**Next the sensitivity matrix S1 is divided into the matrix product of the diagonal matrix S of equation (12) and a matrix of ratios of cross axes terms to their main diagonal sensitivity values in equation (12):

**S**1 = [ 1 S xy / S xx S xz / S xx S yx / S yy 1 S yz / S yy S zx / S zz S zy / Szz 1 ] [ S xx 0 0 0 S yy 0 0 0 S zz ] ( 41 ) ##EQU00021##

**[0204]**Inspection of the above matrix of ratios in light of the physical symmetry of an accelerometer indicates that matrix of ratios is symmetric. The cross axes ratios can each be interpreted to first-order as (small) direction cosine cos(90°-δ

_{i}) of an almost-90-degree angle. The direction cosine substantially equals its respective small departure angle δ

_{i}from perfect perpendicularity measured in radian measure from each sensor toward another sensor with respect to which a given main sensitivity value pertains. Symmetry exists because the physical angle between two given sensors does not depend which sensor is thought of first. Accordingly, three departure angles are defined as follows.

**[0205]**Departure angle δ

_{1}is the angle by which the Y sensor departs from being perpendicular to the X sensor.

δ

_{1}Sxy/Sxx=Syx/Syy (42.1)

**[0206]**Departure angle δ

_{2}is the angle by which the Z sensor departs from being perpendicular to the Y sensor.

δ

_{2}=Syz/Syy=Szy/Szz (42.2)

**[0207]**Departure angle δ

_{3}is the angle by which the Z sensor departs from being perpendicular to the X sensor.

δ

_{3}=Sxz/Sxx=Szx/Szz (42.3)

**[0208]**Next, the inverse of the sensitivity matrix is obtained in terms of diagonal matrix Y of equation (13) and the matrix of those ratios found in equations (41) and (42.1), (42.2), (42.3), which is now designated bold-delta δ:

**Y**1=S1

^{-1}=(δS)

^{-1}=Yδ

^{-1}(43)

**[0209]**With the cross-axes departure angles assumed small, the inverse of the matrix of ratios simply has a minus sign on the departure angles:

**Y**1 = [ Y xx 0 0 0 Y yy 0 0 0 Y zz ] [ 1 - δ 1 - δ 3 - δ 1 1 - δ 2 - δ 3 - δ 2 1 ] ( 44 ) ##EQU00022##

**[0210]**Gravity equation (11) is revised using equation (43) to take account of the cross axis angles as follows.

(f

^{m}-μ)

^{T}(Yδ

^{-1})

^{T}(Yδ

^{-1})(f

^{m}-μ)- =g

^{2}(45)

**[0211]**Equation (45) in algebraic form (compare to equation (15)) is written:

**g**( k ) = { Y xx 2 [ ( f x m ( k ) - μ x ) - δ 1 ( f y m ( k ) - μ y ) - δ 3 ( f z m ( k ) - μ z ) ] 2 + Y yy 2 [ - δ 1 ( f x m ( k ) - μ x ) + ( f y m ( k ) - μ y ) - δ 2 ( f z m ( k ) - μ z ) ] 2 + Y zz 2 [ - δ 3 ( f x m ( k ) - μ x ) - δ 2 ( f y m ( k ) - μ y ) + ( f z m ( k ) - μ z ) ] 2 } ( 45 A ) ##EQU00023##

**[0212]**Equation (45) in effect uses a sum of squares of the different corrected sensor outputs to generate a gravity-squared value for each measurement and equation (45) for gravity takes the square root. For some embodiments, this constitutes a sufficient approximation. Some other embodiments recognize that because the sensors are not perpendicular to one another, the sum of squares of even the true acceleration components measured by each of the sensors departs somewhat from the acceleration being experienced by the platform. Accordingly, equation (45A) can be adjusted in any suitable manner, such as by applying factors (1-δ

_{1}

^{2}) and (1-δ

_{2}

^{2}-δ

_{3}

^{2}) for squares of (small) direction cosines, and written:

**g**( k ) = { Yxx 2 [ ( f x m ( k ) - μ x ) - δ 1 ( f y m ( k ) - μ y ) - δ 3 ( f z m ( k ) - μ z ) ] 2 + ( 1 - δ 1 2 ) Yyy 2 [ - δ 1 ( f x m ( k ) - μ x ) + ( f y m ( k ) - μ y ) - δ 2 ( f z m ( k ) - μ z ) ] 2 + ( 1 - δ 2 2 - δ 3 2 ) Yzz 2 [ - δ 3 ( f x m ( k ) - μ x ) - δ 2 ( f y m ( k ) - μ y ) + ( f z m ( k ) - μ z ) ] 2 } ( 45 B ) ##EQU00024##

**[0213]**Process embodiment IV also establishes an optimization function, such as:

**1 = k = 1 m F 1 ( k ) , where F 1 ( k ) = ( g ( k ) - 1 ) 2 ( 33 - I ) ##EQU00025##**

**[0214]**The optimization summand function F1(k) this time is a function of a conveniently low-dimensional parameter vector p1 holding the three departure angles as three unknowns in an angle-only process embodiment designated IV-A, and equation (16) is revised to a 3-vector:

**p**1=[δ

_{1}δ

_{2}δ

_{3}]

^{T}(46-A)

**[0215]**A more involved approach to process embodiment IV instead defines parameter vector p2 nine parameters including the axes gains, biases, and three departure angles as unknowns in a process embodiment designated IV-B, and equation (16) is instead revised to a 9-vector

**p**2=[YxxYyyYzzμ

_{x}μ

_{y}μ

_{z}δ

_{1}δ

_{2}.delt- a.

_{3}]

^{T}(46-B)

**[0216]**Here again, parameter determination does not call for demandingly-precise test orientations. Instead, in process embodiment IV, (either IV-A or IV-B) an iterative process according to embodiments I or IK is applied. For instance, a gradient descent process is applied using iterations wherein the change of parameters equal to minus the inverse of the matrix M1 of second partial derivatives of the optimization function F1(k) multiplied by the gradient of the optimization function F1(k), as stated by equation (47):

**Δ p 1 = - ( k = 1 m M 1 ( k ) ) - 1 k = 1 m ∇ F 1 ( k ) ( 47 ) ##EQU00026##**

**[0217]**The gradient here is again a column vector of first partial derivatives of optimization function F1(k) now using gravity g(k) of equation (45B), the partial derivatives with respect to the parameters of equation (46A) or (46B) depending on embodiment. The gradient is given for the kth measurement by partial differentiating optimization function F1 of equation (33-I) with respect to the parameters of either equation (46A) or (46B) to obtain equation (48) in terms of a gradient-related row H

_{3}(k) of fully-written-out algebraic expressions involving the three departure angles δ

_{i}:

∇F1(k)=-2H

_{3}

^{T}(k)(1-g(k))/g(k) (48)

**[0218]**Column vector H

_{3}

^{T}(k) is the transpose of the kth row of a relation matrix H

_{3}and H

_{3}

^{T}(k)/g(k) is substituted for H in process I. Matrix M1 of second partial derivatives of the optimization function F1(k) is derived by partial differentiation of fully-written-out gradient ∇F1(k) equation (48) with respect to the parameters of either equation (46A) or (46B) for the optimization function if applying process III-B.

**[0219]**Estimation Process IV-A

0. Execute an estimation process such as I or IK to obtain good estimates of bias errors μ

_{x}, μ

_{y}, μ

_{z}and axes gain reciprocals Yxx, Yyy, Yzz.1. Initialize three departure angles δ

_{i}parameters p1=[0 0 0] or according to most recent calibrated departure angle parameters δ

_{i}if available.2. Use the Step 0 data for measured average acceleration on all three axes:

[f

_{x}

^{mf}

_{y}

^{mf}

_{z}

^{m}]

^{T}.

3. Execute an estimation process such as I or IK to obtain good estimates of departure angles δ

_{1}δ

_{2}δ

_{3}.4. Generate the gain matrix Y1 including cross axes gains according to equation (44).

**[0220]**Process IV-A generates a set of updated accelerometer calibration parameters by desirably executing sub processes (e.g., step 0 and steps 1-3) to generate different subsets in succession of the accelerometer parameters.

**Estimation Process IV**-B

**[0221]**1. Initialize the nine parameters p2=[1, 1, 1, 0, 0, 0, 0, 0, 0] or according to most recent calibrated parameters if available.2. Use the data for measured average acceleration on all three axes:

[f

_{x}

^{mf}

_{y}

^{mf}

_{z}

^{m}]

^{T}

3. Execute an estimation process such as I or IK to obtain good estimates of bias errors μ

_{x}, μ

_{y}, μ

_{z}and axes gain reciprocals Yxx, Yyy, Yzz and departure angles δ

_{1}δ

_{2}δ

_{3}.4. Generate the gain matrix Y1 including cross axes gains according to equation (44).

**[0222]**Process IV-B generates a set of updated accelerometer parameters together, and iterations allow interactions between the parameters to be more fully accounted for in getting good values for them.

**[0223]**Description now turns to a multi-mode recalibration embodiment of FIG. 8.

**[0224]**In FIG. 8, a call from either user or internal software occurs at a step 3605 and calls the system to launch a navigation application. Then a step 3610 updates a data record regarding any recalibration criterion based on date/time RTC 2526 and environmental sensor 1160. Next, a decision step 3620 evaluates a recalibration criterion for determining whether to invoke a recalibration mode that involves m measurements taken by user cueing and collective processing for them, or not. The recalibration criterion may be programmed in any appropriate manner. For example, if RTC elapsed time alone is the reason for recalibration, then a less aggressive single-measurement calibration update to a running window of measurements under similar environmental variables (No at step 3620) is illustratively applied with or without user cueing. On the other hand, if a substantial temperature increase or decrease has occurred or a significant accelerometer voltage regulator voltage change has occurred or the accelerometer 1140 has never been calibrated, then (Yes at step 3620) a more-aggressive recalibration is performed. The more-aggressive recalibration mode takes multiple new measurements and uses prompt transducer 1180 to cue multiple different user-established orientations. If Yes at step 3620, operations go to a mode using process 2800 of FIG. 6A and proceed through point A to perform recalibration with numerous new measurements. If No at step 3620, operations instead go to a second, different mode such as one using process 3300 of FIG. 7A and then go to point B thereof to perform recalibration with fewer new measurements, or even a single new measurement, which is combined with previous measurements that have similar environmental variables. For example, m measurements are suitably used that are or have been taken when the device has been at about the same temperature and about the same voltage regulator supply voltage for the accelerometer. The m measurements are utilized to estimate the accelerometer parameters as taught herein. Either way, thereafter operations proceed to launch the navigation application 3170 supported by the updated calibration of the accelerometer parameters.

**[0225]**FIG. 9 shows an embodiment of structure and process for using accelerometer gain parameter estimates Yxx, Yyy, Yzz and bias parameter estimates μ

_{x}, μ

_{y}, μ

_{z}included in parameters p in a position engine. In FIG. 8, a step 3710 provides estimation of accelerometer gain and bias by calibration or recalibration according to any of the process embodiments described hereinabove.

**[0226]**In FIG. 9, a position engine 3720 is provided to receive GPS (Global Positioning System) and Inertial measurements (comprised of accelerometers and/or, gyros and/or, e-compass) and then blend the inertial output with GPS measurements obtained by a GPS engine 1190 in any of FIGS. 1-3. Conveniently calibrated MEMS accelerometers 1140 herein provide a seamless navigation experience to end users even when GPS visibility is absent or poor, such as when the environment is severely affected by multi-path propagation. Such recalibration thereby delivers a very attractive value-add to GPS-enabled portable devices such as those of FIG. 1 and others described herein. Estimation of accelerometer parameters improves runtime acceleration measurement accuracy and dead reckoning of position in the absence of GPS, as well as usefully blending with GPS when GPS has moderate or poor quality. Blending involves a Kalman filter implementation, or other suitable implementation, that uses both GPS as well as dead reckoning DR information to give a blended output. The recalibration processes, circuits, devices, and systems taught herein can be accurate, reliable, and easy for end-users to use. Computed true acceleration Y*(f

^{m}-μ) for the INS is based on the 3-axis accelerometer actual sensor outputs f

_{x}

^{m}(k), f

_{y}

^{m}(k), f

_{z}

^{m}(k), which have bias errors and gain errors.

**[0227]**Calibration step 3710 beneficially supplies accurate gain parameter estimates Yxx, Yyy, Yzz and bias parameter estimates μ

_{x}, μ

_{y}, μ

_{z}by any of the improved processes described hereinabove. Applying the correct bias and gain parameters to generate a computed true acceleration Y*(f

^{m}-μ) delivers a good approximation to the actual true acceleration f

^{a}=[f

_{x}

^{a}f

_{y}

^{a}f

_{z}

^{a}]

^{T}that the accelerometer 1140 is actually experiencing in the navigation application. It is important to correct the bias and gain errors in actual accelerometer sensor outputs f

_{x}

^{m}(k), f

_{y}

^{m}(k) f

_{z}

^{m}(k), to prevent a rapid buildup of velocity measurement error and distance measurement error in the navigation application. Such rapid buildup can occur because velocity is the time-integral of acceleration and because distance is the time-integral of velocity.

**[0228]**Accurate parameter estimates of the bias errors and gain errors of a given accelerometer 1140 help to define the state initialization for a position engine 3720 that combines GPS position input and 3-axis accelerometer (INS) actual sensor outputs f

_{x}

^{m}(k), f

_{y}

^{m}(k), f

_{z}

^{m}(k). A concept of Dead Reckoning is motivated by a process for combining information that adds a most-recent blended position x

_{blend}and velocity v

_{blend}to twice-integrated corrected acceleration according to equation (49.1). It is particularly useful in scenarios where GPS visibility is limited.

**x blend**( t ) = x blend ( t gps ) + ( t - t gps ) v blend ( t gps ) + ∫ tgps t ∫ tgps t [ g - Y * ( f m - μ ) ] t t ( 49.1 ) ##EQU00027##

**[0229]**In equation (49.1), the double-integral performs definite integration twice of the computed actual acceleration with respect to time t, starting with the time t

_{gps}of a most-recent blended vector position measurement x

_{gps}and most-recent vector velocity measurement v

_{gps}. The measured accelerometer sensor inputs f

^{m}are corrected by a processor in FIG. 1 or 2 applying gain parameter estimates Yxx, Yyy, Yzz and bias parameter estimates μ

_{x}, μ

_{y}, μ

_{z}from step 3710 as shown in equations (49.1) and (49.2). The accelerometer measures the gravity vector g with the platform at rest, so the difference between gravity vector g (essentially unity 1.00) and the compensated measurement Y*(f

^{m}-μ) is expressed in the integrand.

**[0230]**A most recent velocity input v

_{gps}is added to integrated corrected acceleration according to equation (49.2) to obtain blended velocity v

_{blend}(t):

**v blend**( t ) = v blend ( t gps ) + ∫ tgps t Y * ( f m - μ ) t t ( 49.2 ) ##EQU00028##

**[0231]**For greater position accuracy, and to remove the effects of statistical error in various measurements, multiple GPS vector position measurement x

_{gps}over occasional times and/or multiple computed actual acceleration measurements over independently-occasional time in some embodiments are instead combined using a Kalman filter for position engine 3720. Kalman filter processing of time sequence data need not be tediously described here. The point for the purposes of the present description is that a well-defined state initialization with gain parameter estimates Yxx, Yyy, Yzz and bias parameter estimates μ

_{x}, μ

_{y}, μ

_{z}from step 3710 facilitates quick convergence or settling of a Kalman filter for position engine 3720 such as in Inertial Navigation INS applications. In this way, position engine 3720 usefully supplies a blended position output for display or further analysis and use by the navigation application 3170 (2524).

**[0232]**FIG. 10 shows an embodiment of structure and process for using accelerometer gain and bias estimates from any of FIGS. 4-8 in Tilt Compensation for an e-compass 1150 and/or gyro 1170 or other device that benefits from tilt compensation. In FIG. 10, as in FIG. 9, calibration step 3710 beneficially supplies accurate gain parameter estimates Yxx, Yyy, Yzz and bias parameter estimates μ

_{x}, μ

_{y}, μ

_{z}by any of the improved calibration processes described hereinabove. In FIG. 10, accelerometer 1140 supplies a post-calibration set of raw run-time acceleration measurements f

^{m}=[f

_{x}

^{m}(k), f

_{y}

^{m}(k), f

_{z}

^{m}(k)]

^{T}to measure acceleration when it may or may not be the same as gravity alone. Accelerometer bias correction is applied by a summer 3910 effectively subtracting step 3710 bias estimates μ[μ

_{x}, μ

_{y}, μ

_{z}]

^{T}from the respective raw acceleration measurements f

^{m}. Computed true acceleration Y*(f

^{m}-μ) is generated by a multiplier 3920 to multiply the resulting vector output (f

^{m}-μ) of summer 3910 by the respective parameter estimates Yxx, Yyy, Yzz. Applying the correct bias and gain parameters to generate a computed true acceleration Y*(f

^{m}-μ) delivers a useful measurement of the actual true accelerations f

^{a}=[f

_{z}

^{a}f

_{y}

^{a}f

_{z}

^{a}]

^{T}that the accelerometer 1140 is actually experiencing in the navigation application.

**[0233]**In FIG. 10, correcting the bias and gain errors in actual accelerometer 1140 sensor outputs f

_{x}

^{m}(k), f

_{y}

^{m}(k), f

_{z}

^{m}(k), beneficially improves the results from tilt-compensation process 3930, which means that e-compass 1150 direction measurements more accurately support navigation applications 3170 (2524) and provide a better user experience. The output of multiplier 3920 is a set of compensated measurements that are delivered to a Tilt Compensation process 3930, such as for tilt-compensating e-compass 1150 and/or gyro 1170 of FIGS. 1-3. Some information on tilt compensation process 3930 is disclosed in US patent application titled "Processes for More Accurately Calibrating E-Compass for Tilt Error, Circuits, and Systems" Ser. No. ______ (TI-65997) filed on even date herewith, and said U.S. patent application is incorporated herein by reference in its entirety.

**[0234]**In FIG. 11, various system embodiments as described herein are manufactured in a process 4300. Step 4340 provides a particular design and printed wiring board (PWB) of the system 1700 unit having one or more integrated circuits, such as for a modem, a processor coupled to a modem, a controlled power management circuitry, one or more peripherals coupled to the processor, and a user interface coupled to the processor. In steps 4342 and 4345 a storage, such as SDRAM and Flash memory for coupling to on-chip memory, is coupled to the system and has configuration software and initialization parameters according to any of FIGS. 4-10 for an accelerometer 1140, as well as navigation applications and other system software.

**[0235]**Step 4350 tests operations of the accelerometer 1140 and other circuits by confirming rapid and accurate accelerometer parameter estimation and measurement corrections, and operations of the integrated circuit(s) and system in actual application. SoC (system on chip) performance and power consumption with processes from any of FIGS. 4-10 and various alternative estimation processes I, IK, II, III, IV or otherwise, can be compared at the development phase and the most desirable estimation processes selected for a given system. Various embodiments taught herein are respectively attractive for different types of systems at low, medium and high-end performance/marketing points.

**[0236]**In step 4350, verification and test operations are applied pertaining to real-time and non-real-time operations in navigation applications such as location-based applications, position sensing, velocity sensing, directional heading applications, etc. Other test operations involve power management, various real-time scenarios, system stability and performance, satisfactory operation of mobile video display for continuity of content, phone, e-mails/data service, web browsing, voice over packet, content player for continuity of content, camera/imaging, audio/video synchronization, and other such operation that is apparent to the human user and can be evaluated by system use. Also, various security attack scenarios are applied.

**[0237]**Step 4360 adjusts supporting parameters of the accelerometer 1140 circuitry, the accelerometer calibration software, and the system for faster calibration and navigation application execution, lower power/energy dissipation, and maintained or enhanced QoS (quality of service). Supporting parameters include enable/disable register bits, parameter registers bit lengths, iteration constants c or c

_{ii}, convergence metric epsilons, measured-gravity screening range, data outlier distance d, FIG. 4 RTC gating elapsed-time intervals for enabling calibration, environmental sensor thresholds and ranges for initiating a call for calibration, accelerometer data averaging time interval in FIG. 5, and any other supporting parameters involved in processes described hereinabove. If further increased efficiency or accuracy is called for in a step 4355, then step 4360 adjusts or reconfigures parameter(s) and safety margins and loops back to reload parameter(s) at step 4345 and do further testing. When satisfactory at step 4355, operations proceed to step 4370, where adjusted parameter(s) are loaded into the Flash memory or otherwise by system manufacturer or a supplier, and components are assembled on PWB in volume manufacturing to produce resulting system units and END 4375 is reached.

**[0238]**Various embodiments are used with one or more processors that perform electronic processes on signals representing the accelerometer data and generate processor signals representing recalibrated parameters and corrected acceleration vectors. Processors perform signal processing according to instructions and by actual electronic processes that represent or correspond to the various matrix operations disclosed herein. Memory circuits hold physical representations of instructions and parameters. In various embodiments, the accelerometer 1140 is a physically compact device including 1) a set of tri-axes MEMS accelerometer sensors, 2) the accelerometer sensors combined with a nonvolatile memory holding calibration software and/or parameters as described herein, 3) the accelerometer sensors combined with a microprocessor for the accelerometer 1140 as well as nonvolatile memory holding the calibration software and/or parameters, 4) e-compass 1150 and/or, Gyro 1170 combined with any of the other embodiments and further having tilt compensation software and parameters, 5) position sensing (e.g., GPS) unit combined with then any other embodiments and further having GPS software and parameters, and/or 5) a high-performance applications processor SoC integrated circuit for supporting plural applications, and having either integrated therein or coupled thereto any of the other embodiments and/or holding any of the software and/or parameters, or 6) other suitable assembly.

**[0239]**In FIG. 12, manufacturing process operations for making integrated circuit chips are illustrated, such as for subsequent use in system integration of FIG. 11. A step 4510 prepares RTL (register transfer language) design code representing the hardware of any part or all of FIGS. 2 and 3, and prepares software code according to any of FIGS. 4-10 and/or as described herein to run on the hardware as well. From the RTL is prepared a netlist of the actual gates in the integrated circuit, followed by place and route to establish the physical layout of the integrated circuit. A step 4520 delivers the layout on an physical medium such as a pattern generation tape and prepares reticles for ultraviolet lithography or other wafer fab process. Wafer fabrication is then performed using the reticles in a step 4530. Serial-scan testing of scan able registers and other testing is performed using emulation EMU of FIG. 2 on the manufactured integrated circuits in a step 4540. If the integrated circuits do not pass testing operations may go back to step 4510 or any applicable intermediate step so that the manufactured integrated circuits do pass testing. Operations proceed on to assembly/test step 4550 wherein an integrated circuit plastic packaging or ceramic or other packaging may be applied.

**[0240]**Because of the electronic operations representing matrix operations described earlier hereinabove, a processor with one or more fast multiply-accumulate units provides desirably high performance in some embodiments. Each processor can have a pipeline for high performance and selected from the group consisting of 1) reduced instruction set computing (RISC), 2) digital signal processing (DSP), 3) complex instruction set computing (CISC), 4) superscalar, 5) skewed pipelines, 6) in-order, 7) out-of-order, 8) very long instruction word (VLIW), 9) single instruction multiple data (SIMD), 10) multiple instruction multiple data (MIMD), 11) multiple-core using any one or more of the foregoing, and 12) microcontroller pipelines, control peripherals, and other micro-control blocks using any one or more of the foregoing.

**[0241]**Such integrated circuits with processors are depicted in various example forms in FIGS. 12A, 12B, and 12C with reference to enumerations of structures in FIG. 1.

**[0242]**In FIG. 12A, a processor 1030 is flanked on both sides by memory 1034/1036/1032 and has an accelerometer 1140 and an environmental sensor 1160 next to processor 1030. Gyro circuitry 1170 can also be provided. The memory in FIGS. 12A, 12B, 12C includes a memory for holding physical representations of instructions defining processes of any one, some, or all of various embodiments herein.

**[0243]**In FIG. 12B, a GPS baseband decoder 2160 of FIG. 3 is associated row-wise with centrally located processor 1030. Accelerometer 1140 and environmental sensor 1160 together with at least part of a gyro and/or, an electronic compass 1150 are laid out on the opposite side of processor 1030 from GPS decoder 2160. Memory 1034/1036/1032 occupies substantially the balance of the layout.

**[0244]**FIG. 12C, GPS baseband decoder 2160 is surrounded on three sides by memory 1034/1036/1032. Decoder 2160 is situated opposite on the chip from processor 1030. A SoC system bus 1721 at metal level L3, and 1734 at metal level L4, joins decoder 2160 and processor 1030 with length-wise access by the bus line to memory. Accelerometer 1140 and an environmental sensor 1160 occupy a corner of the chip next to processor 1030. Electronic compass circuitry 1150 occupies an opposite corner of the chip next to processor 1030. Gyro circuitry is also provided.

**[0245]**ASPECTS (See Notes paragraph at end of this Aspects section.)

**[0246]**1A. The electronic circuit claimed in claim 1 further comprising at least part of an electronic compass situated and coupled to said electronic processor on a same single chip.

**[0247]**1B. The electronic circuit claimed in claim 1 further comprising at least part of a gyro situated and coupled to said electronic processor on a same single chip.

**[0248]**7A. The information storage medium claimed in claim 7 further comprising a second set of instructions to generate at least one distinct accelerometer calibration parameter.

**[0249]**7B. The information storage medium claimed in claim 7 wherein the instructions include instructions to analyze the accelerometer data for acceptability.

**[0250]**7C. The information storage medium claimed in claim 7 wherein the instructions include instructions to generate prompting transducer control signals.

**[0251]**7D. The information storage medium claimed in claim 7 wherein the medium includes an integrated circuit with a nonvolatile memory.

**[0252]**10A. The process claimed in claim 10 further comprising separately generating at least one additional signal representing a distinct accelerometer calibration parameter.

**[0253]**10B. The process claimed in claim 10 further comprising processing of signals representing the multi-axes accelerometer data for acceptability beforehand.

**[0254]**10C. The process claimed in claim 10 further comprising producing prompting transducer control signals.

**[0255]**10D. The process claimed in claim 10 further comprising electronically blending the signals representing multi-axes accelerometer data, the signals representing accelerometer calibration parameters, and additional signals representing satellite positioning decoder data.

**[0256]**10E. The process claimed in claim 10 further comprising electronically executing a navigation application using the signals representing accelerometer calibration parameters and run-time signals representing accelerometer data.

**[0257]**16A. The system claimed in claim 16 wherein said accelerometer sensors are mounted on and least three different axes.

**[0258]**16B. The system claimed in claim 16 wherein said electronic processor is also operable to cause said transducer to emit a distinct second user-perceptible prompt signifying that the accelerometer signals representing accelerometer data resulting from at least one of the freely-establishable orientations are satisfactory.

**[0259]**16C. The system claimed in claim 16 further comprising a manual input coupled to said electronic processor for user-initiation of accelerometer calibration.

**[0260]**16D. The system claimed in claim 16 further comprising a nonvolatile storage coupled to said electronic processor and holding a software application responsive to the signals representing the calibration parameters.

**[0261]**Notes: Aspects are paragraphs which might be offered as claims in patent prosecution. The above dependently-written Aspects have leading digits and internal dependency designations to indicate the claims or aspects to which they pertain. Aspects having no internal dependency designations have leading digits and alphanumerics to indicate the position in the ordering of claims at which they might be situated if offered as claims in prosecution.

**[0262]**Processing circuitry comprehends digital, analog and mixed signal (digital/analog) integrated circuits, ASIC circuits, PALs, PLAs, decoders, memories, and programmable and nonprogrammable processors, microcontrollers and other circuitry. Internal and external couplings and connections can be ohmic, capacitive, inductive, photonic, and direct or indirect via intervening circuits or otherwise as desirable. Numerical values in the description are illustrative. "Physical representations" herein includes electrical voltages or currents, electrically-, magnetically- or optically-detectable physical alterations, and otherwise detectable physical or electrical alterations or programming. Process diagrams herein are representative of flow diagrams for operations of any embodiments whether of hardware, software, or firmware, and processes of manufacture thereof. Flow diagrams and block diagrams are each interpretable as representing structure and/or process. While this invention has been described with reference to illustrative embodiments, this description is not to be construed in a limiting sense. Various modifications and combinations of the illustrative embodiments, as well as other embodiments of the invention may be made. The terms "including", "includes", "having", "has", "with", or variants thereof are used in the detailed description and/or the claims to denote non-exhaustive inclusion in a manner similar to the term "comprising". The appended claims and their equivalents cover any such embodiments, modifications, and embodiments as fall within the scope of the invention.

User Contributions:

Comment about this patent or add new information about this topic: