Page 1
IMU383 Series User’s Manual IMU383 SERIES USER MANUAL Document Part Number: 7430-1398-01 Doc# 7430-1398-01 Page i Downloaded From Oneyac.com...
Page 2
IMU383 Series User’s Manual ACEINNA, Inc. email: info@aceinna.com, website: www.aceinna.com Page ii Doc# 7430-1398-01 Downloaded From Oneyac.com...
Page 3
IMU383 Series User’s Manual Revision History Date Document Firmware Description Author(s) Revision Applicability Aug 22, Rev. A v1.1.x Draft release of IMU383 Joseph Motyka 2019 manual Dec. 9, Rev. B v1.1.3 Updates to manual to Joseph Motyka 2019 describe fault detection and settings Dec.
IMU383 Series User’s Manual Table of Contents Introduction ..........................1 Manual Overview ......................1 Overview of the IMU383 Series Inertial Measurement Unit ..........2 Interface ............................ 3 Electrical Interface ......................3 2.1.1 Connector and Mating Connector ................3 2.1.2 Power Input and Power Input Ground ................ 4 2.1.3...
Page 5
IMU383 Series User’s Manual 4.8.6 Hardware and Software Version ................25 4.8.7 Sensor Control registers ................... 25 4.8.8 Fault detection Control registers ................26 Suggested Operation ......................26 4.9.1 Startup Timing ......................26 4.9.2 SPI Timing ....................... 27 Signal Synchronization ....................28 Bootloader ........................
Page 6
IMU383 Series User’s Manual IMU383 Advanced UART Port Commands ................40 Configuration Fields ......................40 Continuous Packet Type Field..................41 Digital Filter Settings ...................... 41 Orientation Field ......................41 Fault-Detection Fault-Causation Fields ................42 Fault-Detection Enable/Disable..................43 Commands to Program Configuration ................43 7.7.1...
Page 7
IMU383 Series User’s Manual 10.3.2 Identification and Protection ..................57 10.3.3 Sealing the Container ....................58 10.3.4 Marking ........................58 Appendix A: Installation and Operation of NAV-VIEW .............. 59 NAV-VIEW Computer Requirements ..................59 Install NAV-VIEW ......................... 59 Setting up NAV-VIEW ......................59 Data Recording ...........................
Page 8
IMU383 Series User’s Manual About this Manual The following symbols are used to provide additional information. NOTE Note provides additional information about the topic. EXAMPLE This symbol indicates an example that will help the reader understand the terminology.
Introduction Manual Overview This manual describes ACEINNA’s IMU383 IMU Inertial Measurement Unit. The IMU383 will be referred to as “the unit” frequently in this document. For users wishing to get started quickly, please refer to the two-page quick start guide included with each evaluation kit shipment.
It is designed for OEM applications. At the core of the IMU383 Series is a trio of rugged 6-DOF (Degrees of Freedom) MEMS inertial sensor clusters. Each 6-DOF MEMS inertial sensor cluster includes three axes of MEMS angular rate sensing and three axes of MEMS linear acceleration sensing.
IMU383ZA Series User’s Manual ________________________________________________________________________ Interface Electrical Interface 2.1.1 Connector and Mating Connector The unit main connector is a SAMTEC FTM-110-02-F-DV-P defined in Figure 1. The SAMTEC CLM-110-02 mating connector is compatible with the IMU383unit main connector. Figure 1 IMU383 Interface Connector Table 2 Interface Connector Pin Definition IMU383 Pin Description (IMU383) Inertial-Sensor Sampling Indicator (sampling...
IMU383 Series User’s Manual ________________________________________________________________________ External Reset (NRST) Reserved – factory use only Power VIN (3-5 VDC) Power VIN (3-5 VDC) Power VIN (3-5 VDC) Power GND Power GND Power GND Reserved – factory use only Reserved Reserved – factory use only Reserved Reserved –...
IMU383ZA Series User’s Manual ________________________________________________________________________ 2.1.3.1 SPI Com Synchronization Input Pin 2 can be used as a sync pulse to force synchronization of sensor data collection to a 1 kHz rising-edge signal for output over the SPI port. See Section 4.10 for a more complete description. 2.1.4 Reserved –...
This section of the manual covers detailed theory of operation for the IMU383 Figure 3 shows the IMU383 Series hardware block diagram. At the core of the IMU383 Series is a rugged 6-DOF (Degrees of Freedom) MEMS inertial sensor cluster. The 6-DOF MEMS inertial sensor cluster includes three axes of MEMS angular rate sensing and three axes of MEMS linear acceleration sensing.
Page 15
IMU383ZA Series User’s Manual ________________________________________________________________________ more powerful features in the IMU383 Series architecture as it allows the IMU383 Series to work in a wide range of commercial applications by settings different modes of operation for the IMU383 Series. User Outputs...
The axes form an orthogonal SAE right-handed coordinate system. Acceleration is positive when it is oriented towards the positive side of the coordinate axis. For example, with a IMU383 Series product sitting on a level table, it will measure zero g along the x- and y-axes and -1 g along the z-axis.
IMU383ZA Series User’s Manual ________________________________________________________________________ filtering, and custom axes configuration. The units can be configured using NAV-VIEW, as described in Appendix A, or directly with serial commands as described in Sections 5-8. IMU383 Theory of Operation The unit provides inertial rate and acceleration data in 6-DOF (six degrees of freedom). The unit signal processing chain consists of the 6-DOF sensor cluster, programmable low-pass filters, and a signal processing component for sensor error compensation.
Page 18
IMU383 Series User’s Manual ________________________________________________________________________ When a fault is detected, the system BIT (Section 8.5) will indicate that a fault related to the sensor fault detection has occurred. This field will not indicate which sensor was removed from the triad; Fields 0x42 and 0x43 must be read to determine which of the three sensors was removed from the combination.
Generally, there is no reason to change the low-pass filter settings on the unit or other IMU383 Series Inertial Systems. However, when an IMU383 Series product is installed in an environment with a lot of vibration, it can be helpful to reduce the vibration-based signal energy and noise prior to further processing on the signal.
Page 20
The over-range only applies to the rotational rate sensors. Because instantaneous acceleration levels due to vibration can exceed the accelerometer sensor range in many applications, none of the IMU383 Series products trigger over-range on accelerometer readings.
IMU383ZA Series User’s Manual ________________________________________________________________________ IMU383 SPI Port Interface Definition The IMU383 provides a SPI interface for data communications. This section of the user’s manual defines the unit register map, register control capabilities, and the data register reading and writing methodologies. The unit operates as a slave device.
IMU383 Series User’s Manual ________________________________________________________________________ Name Read/Write Address Default Function Sensors status, chip3 0x1F Status of sensors on chip 3 Reserved 0x20 to 0x33 DATA_READY 0x34 0x04 See Table 14 0x01 OUTPUT_DATA_RATE 0x37 See Table 15 (200Hz) LOW_PASS_FILTER 0x38 0x06 (5Hz)
IMU383ZA Series User’s Manual ________________________________________________________________________ In polled-mode, the IMU383 transfers information from any register back to the master in two (or more) SPI cycles . In Burst-Mode, the IMU383 transfers predefined blocks of data in one contiguous group of nine to twenty SPI cycles. 4.2.1 IMU383 SPI Port Polled-Mode Read In polled-mode, data transfer begins when the SPI master sets the chip-select line (nSS) low and...
Page 24
IMU383 Series User’s Manual ________________________________________________________________________ words in length, depending on the packet selected. Table 6 lists the data-packets available for the unit. The data packets are described in more detail, including data-ordering and conversion factor information, in Section 6.4. Burst-reads and polled-reads should be initiated when data-ready signal indicates that new data is available.
Page 25
IMU383ZA Series User’s Manual ________________________________________________________________________ 0x3E00 0x0000 0x0000 0x0000 MOSI BOARD_ STATUS X_RATE MISO TEMP Figure 7 Multiple Register Read via Burst-Mode Burst-Read of Extended Data-Packet The extended data-packet comprises data from multiple predefined registers. Table 8 lists the data contained in an extended data packet.
IMU383 Series User’s Manual ________________________________________________________________________ Extended Burst-mode begins when the master requests a read of burst-mode extended data-packet by sending the 16-bit word 0x3F00. Ten additional 16-bit SPI cycles complete the read (one for each word in the extended data-packet). Figure 8 illustrates the burst-mode sequence. Note: if the incorrect number of SPI cycles follow the burst-mode command, the SPI transfer will either complete early or remain in burst-mode;...
IMU383ZA Series User’s Manual ________________________________________________________________________ System Registers In addition to the output data registers, there are other read-only registers that provide IMU383 system information to the SPI master. Table 10 provides a description of each along with their read-addresses. Table 10 IMU383 System Registers Name Read Address Function...
IMU383 Series User’s Manual ________________________________________________________________________ Sensors status registers For the IMU383, triple sensor redundancy (along each axis) has been introduced. Each axes of every sensor is individually calibrated. The output signal generated for each sensor type is a composite of the three unique sensors. For example, output value for acceleration on axis X in normal conditions is combination of all three individual X-axis accelerometer readings.
IMU383ZA Series User’s Manual ________________________________________________________________________ Figure 9 illustrates the sensor self-test command sent over SPI. 0xB404 MOSI MISO Figure 9 Single Register Write to Initiate Self-Test Note: as described in the Register Reads (Section 4.2), a register read returns two bytes, in this case a read from register 0x34 returns data from registers 0x34 and 0x35.
IMU383 Series User’s Manual ________________________________________________________________________ Figure 10 IMU383 Bartlett Filter Response 4.8.4 Axis Orientation Settings The unit gives users the ability to set the axes orientation by selecting which axis aligns with the base axes as well as the sign. The only constraint is the axes must conform to a right-hand definition.
IMU383ZA Series User’s Manual ________________________________________________________________________ Table 19 Saving Configuration to EEPROM Data Written to Register Function 0x76 0x00 Permanently saves orientation, dynamic range, data ready signal configuration, SPI packet rate, LPF type 0x01 Permanently saves fault detection settings 0x74 Permanently saves orientation 0x38 Permanently saves dynamic range 0x35...
IMU383 Series User’s Manual ________________________________________________________________________ All bits in registers 0x1A to 0x1C are HIGH by default. 4.8.8 Fault detection Control registers Inside the IMU383 fault detection, up to five different fault detection algorithms may be enabled at the same time. The registers in Table 22 control the configuration of fault detection mechanism.
IMU383ZA Series User’s Manual ________________________________________________________________________ · After releasing the reset line, the unit requires 300 msec (t ) before the system is System Delay ready for use · Data should be read from the unit after the data-ready line is set active (low) (see Section 4.8.1) Power-on nRST pulled low...
IMU383 Series User’s Manual ________________________________________________________________________ DELAY Figure 12 Delay Time SU,NSS h,NSS V,MISO MISO bit 14 bit 13 bit 1 SU,MOSI h,MOSI MOSI bit 14 bit 13 bit 1 Figure 13 SPI Timing Diagram Signal Synchronization The IMU383 is capable of synchronizing its output with a 1 kHz external clock signal, in the form of a square wave, applied to Pin 2.
IMU383ZA Series User’s Manual ________________________________________________________________________ Method 1- Using the Sensor Sampling Indicator (Pin 1) When the user requires finer knowledge of the instant that data is sampled, the IMU383 provides the ability to determine when the sensor read is performed. A falling edge of the signal provided on pin 1 indicates when the inertial sensors are sampled.
CRC itself. Input packets with incorrect CRC’s will be ignored. · Each complete communication packet must be transmitted to the IMU383 Series inertial system within a 4 second period. Number Formats Number Format Conventions include: ·...
(U1)> payload> The Ping Command does not require a CRC, so a IMU383 Series unit can be pinged from a terminal emulator. To Ping a IMU383 Series unit, type the ASCII sequence ‘UUPK’. If properly connected, the IMU383 Series unit will respond with ‘PK’. All other communications with the IMU383 Series unit require the 2-byte CRC.
Input messages are sent from the user system to the IMU383 Series inertial system and will result in an associated Reply Message or NAK message. Note that reply messages typically have the same <2-byte packet type (U2)>...
Page 41
IMU383ZA Series User’s Manual ________________________________________________________________________ Table 26 Message Table ASCII Mnemonic <2-byte <payload byte- Description Type packet type length (U1)> (U2)> Link Test 0x504B Ping Command and Input/Reply Response Message 0x4348 Echo Command and Input/Reply Response Message Interactive Commands 0x4750 Get Packet Request Input Message 0x1515...
Second to last byte of echo data echoData… Last byte of echo data Interactive Commands Interactive commands are used to interactively request data from the IMU383 Series, and to calibrate or reset the IMU383 Series. Doc# 7430-1398-01 Page 34 Downloaded From...
IMU383ZA Series User’s Manual ________________________________________________________________________ 6.2.1 Get Packet Request Get Packet (‘GP’ = 0x4750) Preamble Packet Type Length Payload Termination 0x5555 0x4750 0x02 <GP payload> <CRC (U2)> This command allows the user to poll for both measurement packets and special purpose output packets including ‘T0’, ‘VR’, and ‘ID’.
IMU383 Series User’s Manual ________________________________________________________________________ ID Payload Contents Byte Offset Name Format Scaling Units Description serialNumber Unit serial number modelString Unit Version String 0x00 Zero Delimiter 6.3.2 Version Data Packet Version Data (‘VR’ = 0x5652) Preamble Packet Type Length Payload...
IMU383ZA Series User’s Manual ________________________________________________________________________ Communication Serial A BIT comSerialABIT Field comSerialBBIT Communication Serial B BIT Field softwareBIT Software BIT Field softwareAlgorithmBIT Software Algorithm BIT Field softwareDataBIT Software Data BIT Field hardwareStatus Hardware Status Field comStatus Communication Status Field softwareStatus Software Status Field sensorStatus Sensor Status Field...
IMU383 Series User’s Manual ________________________________________________________________________ zRate 7*pi/2^16 rad/s Z angular rate [1260°/2^16] [°/sec] Reserved Reserved Reserved xRateTemp 200/2^16 deg. C X rate temperature yRateTemp 200/2^16 deg. C Y rate temperature zRateTemp 200/2^16 deg. C Z rate temperature boardTemp 200/2^16 deg. C...
Page 47
IMU383ZA Series User’s Manual ________________________________________________________________________ yRateTemp 200/2^16 deg. C Y rate temperature zRateTemp 200/2^16 deg. C Z rate temperature boardTemp 200/2^16 deg. C CPU board temperature timer 15.259022 Free running fast counter 1s= 65535, captured at sampling BITstatus Master BIT and Status Doc# 7430-1398-01 Page 39 Downloaded From...
________________________________________________________________________ 7 IMU383 Advanced UART Port Commands The advanced commands allow users to programmatically change the IMU383 Series settings. This section of the manual documents all of the settings and options contained under the Unit Configuration tab within NAV-VIEW. Using these advanced commands, a user’s system can change or modify the settings without the need for NAV-VIEW.
IMU383ZA Series User’s Manual ________________________________________________________________________ Table 31 Fault-Detection Fault-Causation Flags Field Value Corresponding Fault No fault Accelerometer Consistency Fault Rate-Sensor Consistency Fault When a fault occurs, the master BIT (Section 8.2) will be set to indicate a Hardware Status error (the sensor status BIT is also set but the sensor-status field does not indicate an error –...
IMU383 Series User’s Manual ________________________________________________________________________ numFields*4 -1 field…Data The last field ID’s data to write Write Fields Response Write Fields (‘WF’ = 0x5746) Preamble Packet Type Length Payload Termination 0x5555 0x5746 1+numFields*2 <WF payload> <CRC (U2)> The unit will send this packet in response to a write fields command if the command has completed without errors.
IMU383ZA Series User’s Manual ________________________________________________________________________ Set Fields Response Set Fields (‘SF’ = 0x5346) Preamble Packet Type Length Payload Termination 0x5555 0x5346 1+numFields*2 <SF payload> <CRC (U2)> The unit will send this packet in response to a set fields command if the command has completed without errors.
IMU383 Series User’s Manual ________________________________________________________________________ Preamble Packet Type Length Payload Termination 0x5555 0x5246 1+numFields*4 <RF payload> <CRC (U2)> The unit will send this packet in response to a read fields request if the command has completed without errors. RF Payload Contents...
Page 55
IMU383ZA Series User’s Manual ________________________________________________________________________ The unit will send this packet in response to a get fields request if the command has completed without errors. GF Payload Contents Byte Offset Name Format Scaling Units Description numFields The number of fields retrieved field0 The first field ID retrieved field0Data...
IMU383 Series User’s Manual ________________________________________________________________________ 8 IMU383 Advanced UART Port BIT Built In Test (BIT) and Status Fields Internal health and status are monitored and communicated in both hardware and software. The ultimate indication of a fatal problem is a hardware BIT signal on the user connector which is mirrored in the software BIT field as the masterFail flag.
________________________________________________________________________ Master BIT and Status (BITstatus) Field The BITstatus field is the global indication of health and status of the IMU383 Series product (See Table 32). The LSB contains BIT information and the MSB contains status information. There are four intermediate signals that are used to determine when masterFail and the hardware BIT signal are asserted.
IMU383 Series User’s Manual ________________________________________________________________________ reserved 8:15 softwareDataBIT Field The softwareDataBIT field contains flags that indicate low level software data errors (See Table 34). The dataError flag in the softwareBIT field is the bit-wise OR of this softwareDataBIT field. Table 34 IMU383 Software Data BIT Field...
IMU383ZA Series User’s Manual ________________________________________________________________________ 9 IMU383 BOOTLOADER A bootloader function is available to upgrade the IMU383 firmware. The firmware can be updated over either the UART or SPI interface, as described in the following sections. Updating firmware over UART Interface A user can initiate the bootloader at any time by sending ‘JI’...
IMU383 Series User’s Manual ________________________________________________________________________ WA Payload Contents Byte Offset Name Format Scaling Units Description startingAddress U4 bytes The FLASH word offset to begin writing data byteLength bytes The word length of the data to write dataByte0 FLASH data dataByte1 FLASH data …...
IMU383ZA Series User’s Manual ________________________________________________________________________ 9.2.2 Boot Mode Status Register (0x78) The Boot Status register contains information about current unit status in Boot Mode. Table 38 Boot Mode Status Register Bits Description System Busy 0: Ready, 1: Busy System Mode 0: Normal Mode, 1: Boot Mode Last Operation Status 0: Pass, 1: Fail (sticky, will stay 1 until reset) CRC Check Status: 0: Pass, 1: Fail Application image compatibility: 0 –...
IMU383 Series User’s Manual ________________________________________________________________________ NOTE: Data Ready signal will be HIGH when device is BUSY and LOW when device available for new transaction over SPI interface. 9.2.3 Boot Command Register (0x7A) The Boot Command register dedicated to receive Boot Mode related commands. The commands provided in Table 39.
IMU383ZA Series User’s Manual ________________________________________________________________________ NOTE: Data Ready signal will be HIGH when device is BUSY and LOW when device available for new transaction over SPI interface. NOTE: Each command message includes 16-bit CRC which covers first 16 bit command word and 32-bit data word.
IMU383 Series User’s Manual ________________________________________________________________________ 9.2.5 Boot Loading Sequence 1. Reset unit using nRST pin or power cycle. 2. Wait about 1 second. 3. Read BOOT_STATUS register and check for boot mode compatibility (register should have pattern 0x06AB in NORMAL mode or 0x46AB in BOOT mode). If register has pattern 0x46AB that means unit already in boot mode.
10.3.2 Identification and Protection If the equipment is to be shipped to ACEINNA for service or repair, please attach a tag TO THE EQUIPMENT, as well as the shipping container(s), identifying the owner. Also indicate the service or repair required, the problems encountered and other information considered valuable to the service facility such as the list of information provided to request the RMA number.
In all correspondence, please refer to the equipment by the model number, the serial number, and the RMA number. Warranty The ACEINNA product warranty is one year from date of shipment. Doc# 7430-1398-01 Page 58 Downloaded From Oneyac.com...
Setting up NAV-VIEW With the IMU383 Series product powered up and connected to your PC serial port, open the NAV-VIEW software application. 1. NAV-VIEW should automatically detect the IMU383 Series product and display the serial number and firmware version if it is connected.
4. Under the “View” menu you have several choices of data presentation. Graph display is the default setting and will provide a real time graph of all the IMU383 Series data. The remaining choices will be discussed in the following pages.
IMU383ZA Series User’s Manual ________________________________________________________________________ Data Playback In addition to data recording, NAV-VIEW allows the user to replay saved data that has been stored in a log file. 1. To playback data, select “Playback Mode” from the “Data Source” drop down menu at the top.
IMU383 Series User’s Manual ________________________________________________________________________ Figure 16 Raw Data Console Packet Statistics View Packet statistics can be obtained from the “View” menu by selecting the “Packet Statistics” option (See Figure 17). This view simply provides the user with a short list of vital statistics (including Packet Rate, CRC Failures, and overall Elapsed Time) that are calculated over a one second window.
IMU383ZA Series User’s Manual ________________________________________________________________________ Unit Configuration The Unit Configuration window (See Figure 18) gives the user the ability to view and alter the system settings. This window is accessed through the “Unit Configuration” menu item under the configuration menu. Under the “General” tab, users have the ability to verify the current configuration by selecting the “Get All Values”...
IMU383 Series User’s Manual ________________________________________________________________________ Figure 18 Unit Configuration Advanced Configuration Users who wish to access some of the more advanced features of NAV-VIEW and the IMU383 Series products can do so by selecting the “Advanced” tab at the top of the “Unit Configuration”...
IMU383ZA Series User’s Manual ________________________________________________________________________ Figure 19 Advanced Settings Bit Configuration The third and final tab of the unit configuration window is “Bit Configuration” (See Figure 20). This tab allows the users to alter the logic of individual status flags that affect the masterStatus flag in the master BIT status field (available in most output packets).
IMU383 Series User’s Manual ________________________________________________________________________ Figure 20 BIT Configuration Read Unit Configuration NAV-VIEW allows users to view the current settings and calibration data for a given IMU383 Series unit by accessing the “Read Configuration” selection from the “Configuration” drop down menu (See Figure 21).
Page 75
IMU383ZA Series User’s Manual ________________________________________________________________________ Figure 21 Read Configuration Appendix A: Firmware Upgrade Step 1, select Firmware upgrade from configuration menu. Step 2, On pop-up window, select a new version binary file by clicking SELECT button, then click Upgrade button. Doc# 7430-1398-01 Page 67 Downloaded From...
Page 76
IMU383 Series User’s Manual ________________________________________________________________________ Doc# 7430-1398-01 Page 68 Downloaded From Oneyac.com...
Page 77
IMU383ZA Series User’s Manual ________________________________________________________________________ Step 3, wait for the process ongoing until a successful or failure message pops up. Doc# 7430-1398-01 Page 69 Downloaded From Oneyac.com...
This appendix includes sample code written in ANSI C for parsing packets from data sent by the IMU383 Series Inertial Systems. This code can be used by a user application reading data directly from the IMU383 Series product, or perhaps from a log file. Check at https://github.com/Aceinna for other reference code.
/* buffer size */ #define MAXQUEUE 500 * circular queue typedef struct queue_tag int count; int front; int rear; char entry[MAXQUEUE]; } QUEUE_TYPE; * ACEINNA packet typedef struct xbow_packet unsigned short packet_type; char length; unsigned short crc; char data[256]; } XBOW_PACKET;...
Page 80
IMU383 Series User’s Manual ________________________________________________________________________ return 0; /* empty buffer */ /* find header */ for(numToPop=0; numToPop+1<Size(queue_ptr) ;numToPop+=1) if(0x5555==peekWord(queue_ptr, numToPop)) break; Pop(queue_ptr, numToPop); if(Size(queue_ptr) <= 0) /* header was not found */ return 0; /* make sure we can read through minimum length packet */ if(Size(queue_ptr)<7)
Page 81
IMU383ZA Series User’s Manual ________________________________________________________________________ /* fill out result of parsing in structure */ result->packet_type = peekWord(queue_ptr, 2); result->length = peekByte(queue_ptr, 4); result->crc = packetCRC; for(counter=0; counter < result->length; counter++) result->data[counter] = peekByte(queue_ptr, 5+counter); Pop(queue_ptr, dataLength+7); return 1; /******************************************************************************* * FUNCTION: calcCRC calculates a 2-byte CRC on serial data using CRC-CCITT 16-bit standard maintained by the ITU (International Telecommunications Union).
Page 82
IMU383 Series User’s Manual ________________________________________________________________________ * FUNCTION: Initialize - initialize the queue * ARGUMENTS: queue_ptr is pointer to the queue *******************************************************************************/ void Initialize(QUEUE_TYPE *queue_ptr) queue_ptr->count = 0; queue_ptr->front = 0; queue_ptr->rear = -1; /******************************************************************************* * FUNCTION: AddQueue - add item in front of queue...
Page 83
IMU383ZA Series User’s Manual ________________________________________________________________________ if(queue_ptr->count <= 0) retval = 0; /* queue is empty */ else queue_ptr -> count--; *item = queue_ptr->entry[queue_ptr->front]; queue_ptr->front = (queue_ptr->front+1) % MAXQUEUE; retval=1; return retval; /******************************************************************************* * FUNCTION: peekByte returns 1 byte from buffer without popping * ARGUMENTS: queue_ptr is pointer to the queue to return byte from index is offset into buffer to which byte to return * RETURNS:...
Page 84
IMU383 Series User’s Manual ________________________________________________________________________ firstIndex = (queue_ptr->front + index) % MAXQUEUE; secondIndex = (queue_ptr->front + index + 1) % MAXQUEUE; word = (queue_ptr->entry[firstIndex] << 8) & 0xFF00; word |= (0x00FF & queue_ptr->entry[secondIndex]); return word; /******************************************************************************* * FUNCTION: Pop - discard item(s) from queue...
Page 85
IMU383ZA Series User’s Manual ________________________________________________________________________ *******************************************************************************/ int Empty(QUEUE_TYPE *queue_ptr) return queue_ptr->count <= 0; /******************************************************************************* * FUNCTION: Full * ARGUMENTS: queue_ptr is pointer to the queue * RETURNS: return 1 if full, 0 if not full *******************************************************************************/ int Full(QUEUE_TYPE *queue_ptr) return queue_ptr->count >= MAXQUEUE; Doc# 7430-1398-01 Page 77 Downloaded From...
Need help?
Do you have a question about the IMU383 Series and is the answer not in the manual?
Questions and answers