nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni

nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni

MPP System Control Module User Guide /V1.0 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni

Document version:V1.0 Release Date:2017.4.13

nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni Copyright © Zhuhai Allwinner Co., Ltd. 2018. All rights reserved. No part or all of the contents of this document may be copied or reproduced without the written permission of the company, and may not be used.What form of communication. nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni

Trademark statement

、Allwinner and other Allwinner trademarks are trademarks of Zhuhai

Co., Ltd.All other trademarks or registered trademarks mentioned in this document are the property of their respective owners.

Note The products, services or features you purchase are subject to the terms and conditions of the company and all or part of the products, services or features described in this document may not be covered by your purchase or use. Unless otherwise agreed by the contract, Allwinner Company makes no representations or warranties, nulllindeni expressnulllindenior implied, regarnulllindeniding the contentsnulllindeniof this document.nulllindeni nulllindeni nulllindeni nulllindeni The contents of this document may be updated from time to time due to product version upgrades or other reasons. Unless otherwise agreed, this document is provided as a guide only, and all statements, information, and recommendations in this document are not warranties of any kind, express or implied.

nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni

nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MPP System Control Module User Guide About this document About this document Overview nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni

Product Version Product name Product version

Intended audience nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni This document is primarily intended for the following engineers: Electronic product development staff

Modify History Version No Modify Date Modify Contents V1.0 2019-07-15 First released

nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni

版权所有 侵权必究 Copyright © by Allwinner. All rights reserved i nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MPP System Control Module User Guide Content Content 1. System Control...... 1 nulllindeni nulllindeni1.1. Overview...nulllindeni...... nulllindeni...... nulllindeni...... nulllindeni...... nulllindeni...... 1 nulllindeni 1.2. Function Description...... 1 1.2.1. Status...... 1 1.2.2. System Binding...... 1 1.2.3. Data Transfer Mode of Component Port...... 2 1.2.4. Media Memory Allocation...... 5 1.3. API Reference...... 5 1.3.1. AW_MPI_SYS_Init...... 5 1.3.2. AW_MPI_SYS_Exit...... 6 1.3.3. AW_MPI_SYS_SetConf...... 6 1.3.4. AW_MPI_SYS_GetConf...... 7 1.3.5. AW_MPI_SYS_Bind...... 8 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni 1.3.6. AW_MPI_SYS_UnBind...... 8 1.3.7. AW_MPI_SYS_GetBindbyDest...... 9 1.3.8. AW_MPI_SYS_GetVersion...... 9 1.3.9. AW_MPI_SYS_GetCurPts...... 10 1.3.10. AW_MPI_SYS_InitPtsBase...... 10 1.3.11. AW_MPI_SYS_SyncPts...... 11 1.3.12. AW_MPI_SYS_MmzAlloc_Cached...... 11 1.3.13. AW_MPI_SYS_MmzFree...... 12 1.3.14. AW_MPI_SYS_MmzFlushCache...... 13 1.3.15. AW_MPI_SYS_Mmap...... 13 1.3.16. AW_MPI_SYS_Munmap...... 14 nulllindeni nulllindeni1.3.17. AWnulllindeni_MPI_SYS_SetRnulllindenieg...... nulllindeni...... nulllindeni...... nulllindeni...... 14 nulllindeni 1.3.18. AW_MPI_SYS_GetReg...... 15 1.3.19. AW_MPI_SYS_SetProfile...... 16 1.3.20. AW_MPI_SYS_GetVirMemInfo...... 16 1.3.21. AW_MPI_SYS_HANDLE_ZERO...... 17 1.3.22. AW_MPI_SYS_HANDLE_SET...... 17 1.3.23. AW_MPI_SYS_HANDLE_ISSET...... 18 1.3.24. AW_MPI_SYS_HANDLE_Select...... 19 1.4. Data Type...... 19

版权所有 侵权必究 Copyright © by Allwinner. All rights reserved ii nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MPP System Control Module User Guide Content 1.5. Error Code...... 19 2. Shorthand...... 21 3. Declaration...... 32 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni

nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni

nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni

版权所有 侵权必究 Copyright © by Allwinner. All rights reserved iii nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MPP System Control Module User Guide 1 System Control 1. System Control nulllindeni 1.1. Onulllindeniverview nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni

The MPP system control module completes the resetting and basic initialization of each hardware component according to the characteristics of the chip, and it is responsible for completing the initialization, de-initialization, and management status of various service modules of the MPP system and providing version information of the current MPP system, etc. Before the application starts the MPP service, the MPP system initialization must be completed. Similarly, after the application exits the MPP service, it also needs to complete the de-initialize of the MPP system and release the resources. 1.2. Function Description

(1) Initialize the environment of the MPP component, and complete the initial configuration of hardware devices such as audio input and output, video input and output. nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni (2) Provide an interface to bind components. (3) Provide an interface for media memory allocation, release, and query. 1.2.1. Status

This component has no internal threads, so there is no state transition. 1.2.2. System Binding

MPP provides a system binding interface (AW_MPI_SYS_Bind), which is to establish a relationship between data reciver and data source by binding data receiver to data source (only allow the data receiver binding to the data source). Once bound, the data generated by the data source is automatically sent to the recipient. The binding relationship is mutual, that is if the receiver finish processing the data and the Buffer that transmits the data comes from the data source, the Buffer needs to be returned to the data source. A nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni component can be bound to multiple components, and the binding relationship is accurate to the component port. The binding relationships supported by MPP are shown in Table 1-1. Data resource Data receiver VI VO VENC ISE ISE VO

版权所有 侵权必究 Copyright © by Allwinner. All rights reserved 1 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MPP System Control Module User Guide 1 System Control VENC VENC MUX AI AO nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni AENC AENC MUX DEMUX VDEC ADEC VDEC VO ADEC AO AO AI CLOCK AO VO DEMUX Table 1-1 The binding relationships supported by MPP nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni

The following smart algorithm components do not support binding: libaiMOD (moving target detection), libVLPR (license plate recognition), Libeveface (face detection). 1.2.3. Data Transfer Mode of Component Port

The MPP component has two ports (inport/outport). The inport port is used to receive data. After the internal thread of the component processes and generates new data, the data would be added to the data link table, waiting for the user to actively take data from the out port port(Unbind mode) or automatically sent to the next component through the out port(Bind mode). Data transfer mode of component port includes bind mode (binding mode, also refer to tunnel mode) nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni and unbind mode (unbound mode, also refer to non-tunnel mode). Automatically passing data to the next component is called tunnel mode, and the way the user manually manages and passes data is called non-tunnel mode. The tunnel mode and non-tunnel mode transfer data as shown in the following 1-1 and 1-2 diagrams.

版权所有 侵权必究 Copyright © by Allwinner. All rights reserved 2 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MPP System Control Module User Guide 1 System Control

nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni

Figure 1-1 MPP Component tunnel Mode The figure above shows how the data pass under the tunnel mode between components. The application only needs a few simple commands to create, start, stop, destroy, etc. After the process of component creation, binding, startup, etc. is completed, the internal threads of each component run, and the data is continuously generated and managed in the internal output data manager. The data is then generated nulllindeni and autonulllindenimatically passednulllindenito the next componulllindeninent (Comp_A[onulllindeniutPort] -> Comp_nulllindeniB[inPort], Compnulllindeni_B[outPort] nulllindeni -> Comp_C[inPort]), and the internal thread of next component uses the data sent from the input port to produce data and add to its internal output data manager for management, then return the used data from the input port to the previous component (Comp_A[outPort] <- Comp_B[inPort], Comp_B[outPort] <- Comp_C[ inPort]), so that the previous component releases the buffer space occupied by the data. For example, when the ai component is bound to the aenc component, it means that the outport of ai and the inport of aenc are docked. When there is pcm data in the ai channel, the data is automatically sent to the ainc inport port through ai channel’s outport port. The internal thread of the aenc component encodes, generates compressed audio data, manages it, sends it to the mux component or waits for the user to fetch data, depending on the data transfer mode of the aenc component output port. Notice: For component with two ports, the input port and output port data transfer modes are independent of each other. For example, a component ‘s input transfer mode is bind mode and that won’t nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni affect the transfer mode of the output mode.

版权所有 侵权必究 Copyright © by Allwinner. All rights reserved 3 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MPP System Control Module User Guide 1 System Control

nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni

Figure 1-2 MPP components non-tunnel Mode The figure above shows how the data transfer between components in non-tunnel mode works. After the application creates and starts the component, it needs to send data to the input port of the component through the interface such as SendFrame()/SendStream(), and then call the interface such as GetStream()/GetFrame() to fetch the generated data (divided into blocking mode and timeout wait mode). nulllindeni After thnulllindenie internal thread nulllindeniof the componennulllindenit uses the data onulllindenif the input port tnulllindenio generate data, nulllindeniand add the nulllindeni generated data to the output data queue for management, then the caller on data-feteching functions can exit (blocking mode), and the application obtains the generated data for processing and after that it need to actively tell the component application that the data has been used, and the component application can release the buffer space it occupies. Notice: When using the non-tunnel mode, if the application doesn’t send data to the input port of the component timely, it will not cause serious consequences of “starvation”, however, if the data is not taken in time and the frame not returned in time, it will lead to “death” phenomenon, because the internal thread continuously produce new data, and the output buffer queue is gradually full until the burst occurs. Unless the application does not send data to the component input port, the data will not be produced and the output buffer will not burst. Binding and unbinding support for each component’s input port and output port are shown in Table nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni 1-2 below. Component type Input Output VI —— tunnel、non-tunnel ISE tunnel、non-tunnel tunnel、non-tunnel AI —— tunnel、non-tunnel VENC tunnel、non-tunnel tunnel、non-tunnel AENC tunnel、non-tunnel tunnel、non-tunnel VDEC tunnel、non-tunnel tunnel、non-tunnel

版权所有 侵权必究 Copyright © by Allwinner. All rights reserved 4 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MPP System Control Module User Guide 1 System Control ADEC tunnel、non-tunnel tunnel、non-tunnel VO tunnel、non-tunnel —— AO tunnel、non-tunnel tunnel、non-tunnel nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MUX tunnel —— DEMUX —— tunnel、non-tunnel Table 1-2 Bind relationship supported by MPP Normally, for the source type component, the device connected to the input port is used to obtain raw-data, the output port is used to send the collected data, and the output port supports two modes: tunnel and non-tunnel; for sink type component, its input import supports the tunnel and non-tunnel modes, and the output port directly connects to the render type device for data presentation, such as sound playback and image display; for filter type component, its dual ports support tunnel and non-tunnel modes. 1.2.4. Media Memory Allocation

Use ION method to allocate physically continuous memory for multimedia processing. The system nulllindeni control mnulllindeniodule encapsulanulllindenites the ION interfnulllindeniace. nulllindeni nulllindeni nulllindeni nulllindeni

1.3. API Reference

The system control implements functions such as MPP (Media Process Platform) system initialization, system binding unbinding, and acquisition of MPP version number. 1.3.1. AW_MPI_SYS_Init

【description】 Initialize the MPP system, including audio input and output, audio codec, video input and output, ISP processing, video codec, video overlay area, video detection analysis, etc. 【grammar】 ERRORTYPE AW_MPI_SYS_Init(); nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni 【parameter】 parameter name description Input/Output 无

【Return Value】 Return Value description 0 success Not 0 Failed, refer to error code. 【notice】  Before initialieze the MPP system, you need to call AW_MPI_SYS_SetConf first, otherwise the 版权所有 侵权必究 Copyright © by Allwinner. All rights reserved 5 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MPP System Control Module User Guide 1 System Control initialization will fail.  If it is initialized multiple times, it will still return success, but the system will not have any effect on the running status of MPP. nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni 【Example】 None. 1.3.2. AW_MPI_SYS_Exit

【description】 De-initialize the MPP system, including audio input and output, audio codec, video input and output, video encoding, video overlay area, video detection and analysis channels, etc. 【grammar】 ERRORTYPE AW_MPI_SYS_Exit(); 【parameter】 parameter name description Input/Output 无 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni 【Return Value】 Return Value description 0 success Not 0 Failed, refer to error code. 【notice】  When de-initializing, if there is a user process blocking on the MPI, the initialization will fail. If all the calls that blocking on the MPI are returned, then de-initialization can be successful.  De-initializing repeatedly won’t return failure.  De-initializing the system does not destroy the codec channel of the audio, the destruction of these channels requires the user initiatively perform. If the process that created these channels exits, the channels would be destroyed. nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni 【Example】 None. 1.3.3. AW_MPI_SYS_SetConf

【description】 Configure system control parameters. 【grammar】 ERRORTYPE AW_MPI_SYS_SetConf(const MPP_SYS_CONF_S* pstSysConf); 【parameter】

版权所有 侵权必究 Copyright © by Allwinner. All rights reserved 6 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MPP System Control Module User Guide 1 System Control parameter name description Input/Output pstSysConf System control parameter input pointer. nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni Static attribute (property that can only be set when the system is not initialized or the device/channel is not enabled). 【Return Value】 Return Value description 0 success Not 0 Failed, refer to error code. 【notice】  This function can be called to configure the MPP system only when the entire system of the MPP is in an uninitialized state. Otherwise, the configuration fails. nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni 【Example】 None. 1.3.4. AW_MPI_SYS_GetConf

【description】 Get system control parameters. 【grammar】 ERRORTYPE AW_MPI_SYS_GetConf(MPP_SYS_CONF_S* pstSysConf); 【parameter】 parameter name description Input/Output pstSysConf System control parameter pointer. output Static attribute. nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni 【Return Value】 Return Value description 0 success Not 0 Failed, refer to error code. 【notice】  AW_MPI_SYS_SetConf must be called successfully before the configuration can be obtained. 【Example】 None.

版权所有 侵权必究 Copyright © by Allwinner. All rights reserved 7 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MPP System Control Module User Guide 1 System Control 1.3.5. AW_MPI_SYS_Bind

【description】 nulllindeni Binnulllindenid the data sourcenulllindenichannel port withnulllindenithe data receivernulllindenichannel port. nulllindeni nulllindeni nulllindeni 【grammar】 ERRORTYPE AW_MPI_SYS_Bind(MPP_CHN_S* pstSrcChn, MPP_CHN_S* pstDestChn); 【parameter】 parameter name description Input/Output pstSrcChn Source channel pointer input pstDestChn Destination channel pointer input 【Return Value】 Return Value description 0 success Not 0 Failed, refer to error code. nulllindeni 【nnulllindeniotice】 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni  Only the components that have binding relationship can be bound successfully bound, this interface will tell the binding relationship of components. After the user invokes the interface, the return value needs to be checked. 【Example】 None. 1.3.6. AW_MPI_SYS_UnBind

【description】 Unbind interface for data resource with data receiver. 【grammar】 ERRORTYPE AW_MPI_SYS_UnBind(MPP_CHN_S* pstSrcChn, MPP_CHN_S* pstDestChn); nulllindeni 【pnulllindeniarameter】 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni parameter name description Input/Output pstSrcChn Source channel pointer. input pstDestChn Destination channel pointer. input 【Return Value】 Return Value description 0 success Not 0 Failed, refer to error code. 【notice】

版权所有 侵权必究 Copyright © by Allwinner. All rights reserved 8 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MPP System Control Module User Guide 1 System Control  This interface is used to release the binding relationship between components. However, application does not need to call the interface when exiting, and its internal implementation is null. 【Example】 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni None. 1.3.7. AW_MPI_SYS_GetBindbyDest

【description】 Get info about the source channel bound on this channel. 【grammar】 ERRORTYPE AW_MPI_SYS_GetBindbyDest(MPP_CHN_S* pstDestChn, MPP_CHN_S* pstSrcChn); 【parameter】 parameter name description Input/Output pstDestChn Source channel pointer input 【 】 nulllindeni Rnulllindenieturn Value nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni Return Value description 0 success Not 0 Failed, refer to error code. 【notice】  If the channel is bound to more than 2 source channels (for example, the Muxer module receives the encoded data of the audio and video encoding channels at the same time), only the source channel information bound first is returned. 【Example】 None. 1.3.8. AW_MPI_SYS_GetVersion nulllindeni 【dnulllindeniescription】 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni Get the version no of the MPP. 【grammar】 ERRORTYPE AW_MPI_SYS_GetVersion(MPP_VERSION_S* pstVersion); 【parameter】 parameter name description Input/Output pstVersion Version number description input pointer. Dynamic attribute (refers to an

版权所有 侵权必究 Copyright © by Allwinner. All rights reserved 9 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MPP System Control Module User Guide 1 System Control attribute that can be set at any time). 【Return Value】 Return Value description nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni 0 success Not 0 Failed, refer to error code. 【notice】 None. 【Example】 None. 1.3.9. AW_MPI_SYS_GetCurPts

【description】 Get the current timestamp of the MPP. 【grammar】 nulllindeni ERnulllindeniRORTYPE AW_MnulllindeniPI_SYS_GetCunulllindenirPts(uint64_t* pu6nulllindeni4CurPts); nulllindeni nulllindeni nulllindeni 【parameter】 parameter name description Input/Output pu64CurPts Current timestamp pointer output 【Return Value】 Return Value description 0 success Not 0 Failed, refer to error code. 【notice】 None. 【Example】 None. nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni 1.3.10. AW_MPI_SYS_InitPtsBase

【description】 Initialize the timestamp reference for MPP. 【grammar】 ERRORTYPE AW_MPI_SYS_InitPtsBase(uint64_t u64PtsBase); 【parameter】 parameter name description Input/Output u64PtsBase Timestamp reference. Unit: input

版权所有 侵权必究 Copyright © by Allwinner. All rights reserved 10 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MPP System Control Module User Guide 1 System Control microseconds. 【Return Value】 Return Value description nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni 0 success Not 0 Failed, refer to error code. 【notice】  Initializing the timestamp reference will force the timestamp of the current system to be u64PtsBase, without any constraint with the original timestamp of the system. Therefore, it is recommended to call this interface when the media service is not started (for example, the system just started). If the media service has already started, it is recommended to call AW_MPI_SYS_SyncPts for timestamp fine-tuning. 【Example】 None. 1.3.11. AW_MPI_SYS_SyncPts nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni 【description】 Synchronize the timestamp of the MPP. 【grammar】 ERRORTYPE AW_MPI_SYS_SyncPts(uint64_t u64PtsBase); 【parameter】 parameter name description Input/Output u64PtsBase Timestamp reference. input 【Return Value】 Return Value description 0 success Not 0 Failed, refer to error code. nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni 【notice】  Fine-tune the current system timestamp (microseconds). After the fine-tuning, there won’t be timestamp rollback. When synchronizing between multiple slices, since the clock source error of the board may be large, it is recommended to perform a timestamp fine adjustment per second. 【Example】 None. 1.3.12. AW_MPI_SYS_MmzAlloc_Cached

【description】

版权所有 侵权必究 Copyright © by Allwinner. All rights reserved 11 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MPP System Control Module User Guide 1 System Control Allocate MMZ memory in user mode. Allocates physical contiguous memory from ION internally. 【grammar】 ERRORTYPE AW_MPI_SYS_MmzAlloc_Cached(unsigned int* pu32PhyAddr, void** ppVirtAddr, nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni unsigned int u32Len); 【parameter】 parameter name description Input/Output pu32PhyAddr Physical address pointer output ppVirtAddr Pointer to the virtual address output pointer u32Len Memory block size input 【Return Value】 Return Value description 0 success Not 0 Failed, refer to error code. nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni 【notice】 None. 【Example】 None. 1.3.13. AW_MPI_SYS_MmzFree

【description】 Release MMZ memory in user mode. 【grammar】 ERRORTYPE AW_MPI_SYS_MmzFree(unsigned int u32PhyAddr, void* pVirtAddr); 【parameter】 parameter name description Input/Output nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni u32PhyAddr Physical address input pVirtAddr Virtual address pointer input 【Return Value】 Return Value description 0 success Not 0 Failed, refer to error code. 【notice】 None. 【Example】 版权所有 侵权必究 Copyright © by Allwinner. All rights reserved 12 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MPP System Control Module User Guide 1 System Control None. 1.3.14. AW_MPI_SYS_MmzFlushCache nulllindeni 【dnulllindeniescription】 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni Refresh the contents of the cache to memory and invalidate the contents of the cache. 【grammar】 ERRORTYPE AW_MPI_SYS_MmzFlushCache(unsigned int u32PhyAddr, void* pVitAddr, unsigned int u32Size); 【parameter】 parameter name description Input/Output u32PhyAddr The starting physical address input of the data to be manipulated. pVitAddr The starting Virtual address input pointer of the data to be nulllindeni nulllindeni nulllindeni mannulllindeniipulated. nulllindeni nulllindeni nulllindeni nulllindeni u32Size The size of the data to be input manipulated. 【Return Value】 Return Value description 0 success Not 0 Failed, refer to error code. 【notice】 None. 【Example】 None.

nulllindeni 1.3.15nulllindeni. AW_MPI_SnulllindeniYS_Mmap nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni 【description】 system mapping interface. 【grammar】 void* AW_MPI_SYS_Mmap(unsigned int u32PhyAddr, unsigned int u32Size); 【parameter】 parameter name description Input/Output u32PhyAddr The starting address of the input memory unit to be mapped.

版权所有 侵权必究 Copyright © by Allwinner. All rights reserved 13 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MPP System Control Module User Guide 1 System Control u32Size The number of bytes to be input mapped. 【Return Value】 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni Return Value description 0 success Not 0 Failed, refer to error code. 【notice】 None. 【Example】 None. 1.3.16. AW_MPI_SYS_Munmap

【description】 unmapping interface. nulllindeni 【gnulllindenirammar】 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni ERRORTYPE AW_MPI_SYS_Munmap(void* pVirAddr, unsigned int u32Size); 【parameter】 parameter name description Input/Output pVirAddr The address returned after input mmap. u32Size The length of bytes of the input mapped area. 【Return Value】 Return Value description 0 success Not 0 Failed, refer to error code. nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni 【notice】 None. 【Example】 None. 1.3.17. AW_MPI_SYS_SetReg

【description】 Set the value of the register. 【grammar】

版权所有 侵权必究 Copyright © by Allwinner. All rights reserved 14 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MPP System Control Module User Guide 1 System Control ERRORTYPE AW_MPI_SYS_SetReg(unsigned int u32Addr, unsigned int u32Value); 【parameter】 parameter name description Input/Output nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni u32Addr The address to be written. input u32Value The value to be written. input 【Return Value】 Return Value description 0 success Not 0 Failed, refer to error code. 【notice】 None. 【Example】 None. 1.3.18. AW_MPI_SYS_GetReg nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni 【description】 Get the value of the register. 【grammar】 ERRORTYPE AW_MPI_SYS_GetReg(unsigned int u32Addr, unsigned int* pu32Value); 【parameter】 parameter name description Input/Output u32Addr Physical address input pu32Value The value in this memory output address. 【Return Value】 Return Value description nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni 0 success Not 0 Failed, refer to error code. 【notice】  Must be set before decoding is started, and the setting during decoding is invalid. If not set, the decoding channel uses the default value. 【Example】 None.

版权所有 侵权必究 Copyright © by Allwinner. All rights reserved 15 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MPP System Control Module User Guide 1 System Control 1.3.19. AW_MPI_SYS_SetProfile

【description】 nulllindeni Setnulllindeniprofile of the nulllindenipower consumptinulllindenion. This interfacnulllindenie is mainly usenulllindenid to implement nulllindenilow power nulllindeni resolution for the media power domain by controlling the operating frequency of each media domain chip module through input parameters in order to controlling power consumption. 【grammar】 ERRORTYPE AW_MPI_SYS_SetProfile(PROFILE_TYPE_E enProfile); 【parameter】 parameter name description Input/Output enProfile parameter of power input consumption profile type 【Return Value】 Return Value description nulllindeni 0 nulllindeni nulllindeni nulllindeni nulllindenisuccess nulllindeni nulllindeni nulllindeni Not 0 Failed, refer to error code. 【notice】 None. 【Example】 None. 1.3.20. AW_MPI_SYS_GetVirMemInfo

【description】 Obtain corresponding memory information based on the virtual address, including the physical address and the cached attribute. 【grammar】 nulllindeni ERnulllindeniRORTYPE AW_nulllindeniMPI_SYS_GetVnulllindeniirMemInfo(const nulllindenivoid* pVitAddrnulllindeni, SYS_VIRMEMnulllindeni_INFO_S* nulllindeni pstMemInfo); 【parameter】 parameter name description Input/Output enProfile parameter of power input consumption profile type 【Return Value】 Return Value description 0 success

版权所有 侵权必究 Copyright © by Allwinner. All rights reserved 16 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MPP System Control Module User Guide 1 System Control Not 0 Failed, refer to error code. 【notice】 None. nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni 【Example】 None.

1.3.21. AW_MPI_SYS_HANDLE_ZERO

【description】 Empty the audio and video encoding channel handle set. 【grammar】 ERRORTYPE AW_MPI_SYS_HANDLE_ZERO(handle_set *pHandleSet); 【parameter】 parameter name description Input/Output nulllindeni pHnulllindeniandleSet nulllindeni nulllindeniThe encoding cnulllindenihannel handle nulllindeniinput nulllindeni nulllindeni set pointer. 【Return Value】 Return Value description 0 success 【notice】  If the user uses the select method to obtain the data of each code channel, before starting a new round of select method, the interface must be called first to clear the waiting handle set, and use the HANDLE_SET interfaceto add the handle of the code channel to the handle set. 【Example】 None.

nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni 1.3.22. AW_MPI_SYS_HANDLE_SET

【description】 use the HANDLE_SET interfaceto add the handle of the code channel to the waiting handle set. 【grammar】 ERRORTYPE AW_MPI_SYS_HANDLE_SET(int handle, handle_set *pHandleSet); 【parameter】 parameter name description Input/Output handle The encoding channel handle input

版权所有 侵权必究 Copyright © by Allwinner. All rights reserved 17 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MPP System Control Module User Guide 1 System Control number to be added pHandleSet Coded channel handle set input pointer nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni 【Return Value】 Return Value description 0 success 【notice】 None. 【Example】 None.

1.3.23. AW_MPI_SYS_HANDLE_ISSET

【description】 nulllindeni Denulllindenitermines if the encnulllindenioding handle numnulllindeniber is in the givenulllindenin handle set. nulllindeni nulllindeni nulllindeni 【grammar】 ERRORTYPE AW_MPI_SYS_HANDLE_ISSET(int handle, handle_set *pHandleSet); 【parameter】 parameter name description Input/Output handle 编码句柄号 input pHandleSet Coded channel handle set input pointer 【Return Value】 Return Value description 1 success 0 Failed, the data is not ready. nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni 【notice】  After the HANDLE_select function returns, user this interface to check if certain encoding channel is ready or not for the next processing operation. For example, multiple aenc channels are running at the same time and HANDLE_select returns, call this interface to determine whether an aenc channel data is ready. If the return is 1, the coded stream data can be taken from the channel. 【Example】 None.

版权所有 侵权必究 Copyright © by Allwinner. All rights reserved 18 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MPP System Control Module User Guide 1 System Control 1.3.24. AW_MPI_SYS_HANDLE_Select

【description】 nulllindeni monulllindeninitor the set of ennulllindenicoding channel hanulllindenindles. nulllindeni nulllindeni nulllindeni nulllindeni 【grammar】 ERRORTYPE AW_MPI_SYS_HANDLE_Select(handle_set *pHandleSet, int nMilliSecs); 【parameter】 parameter name description Input/Output pHandleSet Coded channel handle set input pointer nMilliSecs Timeout waiting time to be set input 【Return Value】 Return Value description -1 abnormal nulllindeni 0 nulllindeni nulllindeni nulllindeni nulllindenitimeout for thenulllindeniwaiting, the ennulllindenicoding channel onulllindenif the handle set description is not ready. >0 Some encoding channels are ready. 【notice】  The parameter nMilliSecs sets different data make the interface in the following three states: nMilliSecs<0: Put HANDLE_Select in a blocking state until one of the channels is ready. nMilliSecs=0: Put in non-blocking state, return immediately, return a positive value if a channel is ready, otherwise return 0. nMilliSecs>0: It is blocked during nMilliSecs time. If the data of one channel is readable within the ms unit time represented by nMilliSecs, it will return positive value immediately, otherwise it will return 0. 【Example】 None. nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni

1.4. Data Type 1.5. Error Code

Error code Macro definition description 0xA0028006 ERR_SYS_NULL_PTR Null pointer error 0xA0028010 ERR_SYS_NOTREADY System control properties are

版权所有 侵权必究 Copyright © by Allwinner. All rights reserved 19 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MPP System Control Module User Guide 1 System Control not configured 0xA0028009 ERR_SYS_NOT_PERM Operation not allowed 0xA002800C ERR_SYS_NOMEM Failed to allocate memory, nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni such as insufficient system memory 0xA0028003 ERR_SYS_ILLEGAL_PARA Invalid parameter setting M 0xA0028012 ERR_SYS_BUSY System is busy 0xA0028008 ERR_SYS_NOT_SUPPORT An operation or type that is not supported.

nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni

nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni

版权所有 侵权必究 Copyright © by Allwinner. All rights reserved 20 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MPP System Control Module User Guide 2 Shorthand 2. Shorthand nulllindeni CBnulllindeniR:(Constant BitnulllindeniRate)固定比特nulllindeni率 nulllindeni nulllindeni nulllindeni nulllindeni CCI: Camera Control Interface CSF: chrominance spatial-domain filtering, 色度空域滤波 CTF: chrominance time domain filtering, 色度时域滤波 DHD,DSD:显示设备高清和显示设备标清 DPB: Decoded Picture Buffer HDR:高动态范围图像(High-Dynamic Range,简称 HDR) IDR:(Instantaneous Decoding Refresh)--即时解码刷新 ie: Picture texture enhancement,图像纹理增强 I2C: Inter-Integrated Circuit ISP:Image Signal Processor IVS:智能视频监控(Intelligent Video Surveillance) nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni JVT: 联合视频组(JVT,Joint Video Team) LDA:Linux Dvb Api(LDA) LDC:Lens distortion correction,镜头畸变校正 MIPI: Mobile Industry Processor Interface(移动行业处理器接口) MIPI CSI2: MIPI Camera Serial Interface 2 MPP:Media Process Platform PIP:(Picture In Picture)画面叠加 POC: 在编解码中,视频的播放顺序序号叫做 POC(picture order count) PPS: Picture Parameter Set QP: quantizer parameter ROI:(Region Of Interest)编码,感兴趣区域编码 ROP: raster operation nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni SPS: Sequence Parameter Sets TDE: Two Dimensional Engine,海思的硬件模块,利用硬件为 OSD(On Screen Display)和 GUI (Graphics )提供快速的图形绘制功能 TDM: time-division-multiplexing,分时复用 VB:Video Buffer VBR:(Variable Bit Rate)可变比特率 VBV:Video Buffering Verifier,视频缓存检验器 VCM: Voice Coil Motor(音圈马达) VFE: Video Front End 版权所有 侵权必究 Copyright © by Allwinner. All rights reserved 21 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MPP System Control Module User Guide 2 Shorthand VGS: 是视频图形子系统,全称为 Video Graphics Sub-System 支持对一幅 input 图像进行处理, 如进行缩放、格式转换、解压、打 Cover/OSD 等处理 海思命名 VHD,VSD:视频层高清和视频层标清 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni VI:Video Input VLPR: 车牌识别技术(Vehicle License Plate Recognition), VOU(Video Output Unit)海思视频 output 模块 VPSS:Video Process Sub-System V4L2:Video for linux 2 WDR:Wide Dynamic Range(宽动态范围) YSF: luminance spatial-domain filtering, 亮度空域滤波, 亮度经常用 Y 表示 YTF: luminance time domain filtering, 亮度时域滤波 h264 spec 定义的简写如下: CABAC: Context-based Adaptive Binary Arithmetic Coding CABAC 基于上下文的自适应二 进制算术编码 nulllindeni CAnulllindeniVLC: Context-banulllindenised Adaptive Varinulllindeniable Length Codinnulllindenig CAVLC 基nulllindeni于上下文的自适nulllindeni应变长 nulllindeni 编码

CBR: Constant Bit Rate CBR 恒定比特率 CPB: Coded Picture Buffer CPB 编码图像缓存区 DPB: Decoded Picture Buffer DPB 解码图像缓存区 DUT: Decoder under test DUT 被测解码器 FIFO: First-In, First-Out FIFO 先进先出 HRD: Hypothetical Reference Decoder HRD 假想参考解码器 HSS: Hypothetical Stream Scheduler HSS 假想码流调度器 IDR: Instantaneous Decoding Refresh IDR 即时解码刷新 LSB: Least Significant Bit LSB 最低有效位 MB: Macroblock MB 宏块 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MBAFF: Macroblock-Adaptive Frame-Field Coding MBAFF 宏块自适应帧-场编 码

MSB: Most Significant Bit MSB 最高有效位 NAL: Network Abstraction Layer NAL 网络抽象层 RBSP: Raw Byte Sequence Payload RBSP 原始字节序列载荷 SEI: Supplemental Enhancement Information SEI 补充的增强信息 SODB: String Of Data Bits SODB 数据比特串 UUID: Universal Unique Identifier UUID 通用唯一性标识符 VBR: Variable Bit Rate VBR 可变比特率 版权所有 侵权必究 Copyright © by Allwinner. All rights reserved 22 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MPP System Control Module User Guide 2 Shorthand VCL: Video Coding Layer VCL 视频编码层 VLC: Variable Length Coding VLC 变长编码 VUI: Video Usability Information,视频可用性信息 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni

h265 spec 定义的简写如下: JCT-VC: Joint Collaborative Team on Video Coding HEVC: High Efficiency Video Coding SAO: Sample adaptive offset,自适应样点补偿 B Bi-predictive BLA Broken Link Access CABAC Context-based Adaptive Binary Arithmetic Coding CB Coding Block CBR Constant Bit Rate CRA Clean Random Access nulllindeni CPnulllindeniBCoded Picture Bnulllindeniuffer nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni CTBCoding Tree Block CTU Coding Tree Unit CU Coding Unit CVSCoded Video Sequence DPBDecoded Picture Buffer DUT Decoder Under Test EG Exponential-Golomb FIFO First-In, First-Out FIR Finite Impulse Response FL Fixed-Length GDR Gradual Decoding Refresh nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni HRD Hypothetical Reference Decoder HSS Hypothetical Stream Scheduler I Intra IDR Instantaneous Decoding Refresh IRAP Intra Random Access Point LPS Least Probable Symbol LSB Least Significant Bit MPS Most Probable Symbol MSB Most Significant Bit 版权所有 侵权必究 Copyright © by Allwinner. All rights reserved 23 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MPP System Control Module User Guide 2 Shorthand NAL Network Abstraction Layer P Predictive PB Prediction Block nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni PPS Picture Parameter Set PU Prediction Unit RADL Random Access Decodable Leading (Picture) RASL Random Access Skipped Leading (Picture) RBSP Raw Byte Sequence Payload RPS Reference Picture Set SEI Supplemental Enhancement Information SODB String Of Data Bits SPS Sequence Parameter Set STSA Step-wise Temporal Sub-layer Access TB Transform Block nulllindeni TRnulllindeniTruncated Rice nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni TSATemporal Sub-layer Access TU Transform Unit UUID Universal Unique Identifier VBR Variable Bit Rate VCL Video Coding Layer VPS Video Parameter Set VUI Video Usability Information

Shorthand definition of jpeg spec: A probability interval AC AC DCT coefficient nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni ACji AC coefficient predicted from DC values Ah successive approximation bit position, high Al successive approximation bit position, low Api ith 8-bit parameter in APPn segment APPn marker reserved for application segments B current byte in compressed data B2 next byte in compressed data when B = X’FF’ BE counter for buffered correction bits for Huffman coding in the successive approximation process 版权所有 侵权必究 Copyright © by Allwinner. All rights reserved 24 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MPP System Control Module User Guide 2 Shorthand BITS 16-byte list containing number of Huffman codes of each length BP pointer to compressed data BPST pointer to byte before start of entropy-coded segment nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni BR counter for buffered correction bits for Huffman coding in the successive approximation process Bx byte modified by a carry-over C value of bit stream in code register Ci component identifier for frame Cu horizontal frequency dependent scaling factor in DCT Cv vertical frequency dependent scaling factor in DCT CE conditional exchange C-low low order 16 bits of the arithmetic decoder code register Cmi ith 8-bit parameter in COM segment CNT bit counter in NEXTBYTE procedure nulllindeni COnulllindeniDE Huffman codnulllindenie value nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni CODESIZE(V) code size for symbol V COM comment marker Cs conditioning table value Csi component identifier for scan CT renormalization shift counter Cx high order 16 bits of arithmetic decoder code register CX conditional exchange data unit from horizontal position i, vertical position j djik dji for component k D decision decoded Da in DC coding, the DC difference coded for the previous block from the same component; nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni in lossless coding, the difference coded for the sample immediately to the left DAC define-arithmetic-coding-conditioning marker Db the difference coded for the sample immediately above DC DC DCT coefficient DCi DC coefficient for ith block in component DCk kth DC value used in prediction of AC coefficients DHP define hierarchical progression marker DHT define-Huffman-tables marker DIFF difference between quantized DC and prediction 版权所有 侵权必究 Copyright © by Allwinner. All rights reserved 25 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MPP System Control Module User Guide 2 Shorthand DNL define-number-of-lines marker DQT define-quantization-tables marker DRI define restart interval marker nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni E exponent in magnitude category upper bound EC event counter ECS: entropy-coded segment ECSi ith entropy-coded segment Eh horizontal expansion parameter in EXP segment EHUFCO Huffman code table for encoder EHUFSI encoder table of Huffman code sizes EOB end-of-block for sequential; end-of-band for progressive EOBn run length category for EOB runs EOBx position of EOB in previous successive approximation scan EOB0, EOB1, ..., EOB14 run length categories for EOB runs nulllindeni EOnulllindeniI end-of-image mnulllindeniarker nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni Ev vertical expansion parameter in EXP segment EXP expand reference components marker FREQ(V) frequency of occurrence of symbol V Hi horizontal sampling factor for ith component Hmax largest horizontal sampling factor HUFFCODE list of Huffman codes corresponding to lengths in HUFFSIZE HUFFSIZE list of code lengths HUFFVAL list of values assigned to each Huffman code i subscript index I integer variable Index(S) index to probability estimation state machine table for context index S nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni j subscript index J integer variable JPG marker reserved for JPEG extensions JPGn marker reserved for JPEG extensions k subscript index K integer variable Kmin index of 1st AC coefficient in band (1 for sequential DCT) Kx conditioning parameter for AC arithmetic coding model L DC and lossless coding conditioning lower bound parameter 版权所有 侵权必究 Copyright © by Allwinner. All rights reserved 26 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MPP System Control Module User Guide 2 Shorthand Li element in BITS list in DHT segment Li(t) element in BITS list in the DHT segment for Huffman table t La length of parameters in APPn segment nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni LASTK largest value of K Lc length of parameters in COM segment Ld length of parameters in DNL segment Le length of parameters in EXP segment Lf length of frame header parameters Lh length of parameters in DHT segment Lp length of parameters in DAC segment LPS less probable symbol (in arithmetic coding) Lq length of parameters in DQT segment Lr length of parameters in DRI segment Ls length of scan header parameters nulllindeni LSnulllindeniB least significantnulllindenibit nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni m modulo 8 counter for RSTm marker mt number of Vi,j parameters for Huffman table t M bit mask used in coding magnitude of V Mn nth statistics bin for coding magnitude bit pattern category MAXCODE table with maximum value of Huffman code for each code length MCU minimum coded unit MCUi ith MCU MCUR number of MCU required to make up one MCU-row MINCODE table with minimum value of Huffman code for each code length MPS more probable symbol (in arithmetic coding) MPS(S) more probable symbol for context-index S nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MSB most significant bit M2, M3, M4, ... , M15 designation of context-indices for coding of magnitude bits in the arithmetic coding models n integer variable N data unit counter for MCU coding N/A not applicable Nb number of data units in MCU Next_Index_LPS new value of Index(S) after a LPS renormalization 版权所有 侵权必究 Copyright © by Allwinner. All rights reserved 27 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MPP System Control Module User Guide 2 Shorthand Next_Index_MPS new value of Index(S) after a MPS renormalization Nf number of components in frame NL number of lines defined in DNL segment nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni Ns number of components in scan OTHERS(V) index to next symbol in chain P sample precision Pq quantizer precision parameter in DQT segment Pq(t) quantizer precision parameter in DQT segment for quantization table t PRED quantized DC coefficient from the most recently coded block of the component Pt point transform parameter Px calculated value of sample Qji quantizer value for coefficient ACji Qvu quantization value for DCT coefficient Svu Q00 quantizer value for DC coefficient nulllindeni QAnulllindeniCji quantized ACnulllindenicoefficient predicnulllindenited from DC valunulllindenies nulllindeni nulllindeni nulllindeni QDCk kth quantized DC value used in prediction of AC coefficients Qe LPS probability estimate Qe(S) LPS probability estimate for context index S Qk kth element of 64 quantization elements in DQT segment rvu reconstructed image sample R length of run of zero amplitude AC coefficients Rvu dequantized DCT coefficient Ra reconstructed sample value Rb reconstructed sample value Rc reconstructed sample value Rd rounding in prediction calculation nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni RES reserved markers Ri restart interval in DRI segment RRRR 4-bit value of run length of zero AC coefficients RS composite value used in Huffman coding of AC coefficients RSTm restart marker number m syx reconstructed value from IDCT S context index Svu DCT coefficient at horizontal frequency u, vertical frequency v SC context-index for coding of correction bit in successive approximation coding 版权所有 侵权必究 Copyright © by Allwinner. All rights reserved 28 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MPP System Control Module User Guide 2 Shorthand Se end of spectral selection band in zig-zag sequence SE context-index for coding of end-of-block or end-of-band SI Huffman code size nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni SIGN 1 if decoded sense of sign is negative and 0 if decoded sense of sign is positive SIZE length of a Huffman code SLL shift left logical operation SLL a b logical shift left of a by b bits SN context-index for coding of first magnitude category when V is negative SOF0 baseline DCT process frame marker SOF1 extended sequential DCT frame marker, Huffman coding SOF2 progressive DCT frame marker, Huffman coding SOF3 lossless process frame marker, Huffman coding SOF5 differential sequential DCT frame marker, Huffman coding SOF6 differential progressive DCT frame marker, Huffman coding nulllindeni SOnulllindeniF7 differential losnulllindenisless process framnulllindenie marker, Huffmnulllindenian coding nulllindeni nulllindeni nulllindeni SOF9 sequential DCT frame marker, arithmetic coding SOF10 progressive DCT frame marker, arithmetic coding SOF11 lossless process frame marker, arithmetic coding SOF13 differential sequential DCT frame marker, arithmetic coding SOF14 differential progressive DCT frame marker, arithmetic coding SOF15 differential lossless process frame marker, arithmetic coding SOI start-of-image marker SOS start-of-scan marker SP context-index for coding of first magnitude category when V is positive Sqvu quantized DCT coefficient SRL shift right logical operation nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni SRL a b logical shift right of a by b bits Ss start of spectral selection band in zig-zag sequence SS context-index for coding of sign decision SSSS 4-bit size category of DC difference or AC coefficient amplitude ST stack counter Switch_MPS parameter controlling inversion of sense of MPS Sz parameter used in coding magnitude of V S0 context-index for coding of V = 0 decision t summation index for parameter limits computation 版权所有 侵权必究 Copyright © by Allwinner. All rights reserved 29 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MPP System Control Module User Guide 2 Shorthand T temporary variable Taj AC entropy table destination selector for jth component in scan Tb arithmetic conditioning table destination identifier nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni Tc Huffman coding or arithmetic coding table class Tdj DC entropy table destination selector for jth component in scan TEM temporary marker Th Huffman table destination identifier in DHT segment Tq quantization table destination identifier in DQT segment Tqi quantization table destination selector for ith component in frame U DC and lossless coding conditioning upper bound parameter V symbol or value being either encoded or decoded Vi vertical sampling factor for ith component Vi,j jth value for length i in HUFFVAL Vmax largest vertical sampling factor nulllindeni Vt nulllindenitemporary variablnulllindenie nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni VALPTR list of indices for first value in HUFFVAL for each code length V1 symbol value V2 symbol value xi number of columns in ith component X number of samples per line in component with largest horizontal dimension Xi ith statistics bin for coding magnitude category decision X1, X2, X3, ... , X15 designation of context-indices for coding of magnitude categories in the arithmetic coding models XHUFCO extended Huffman code table XHUFSI table of sizes of extended Huffman codes nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni X’values’ values within the quotes are hexadecimal yi number of lines in ith component Y number of lines in component with largest vertical dimension ZRL value in HUFFVAL assigned to run of 16 zero coefficients ZZ(K) Kth element in zig-zag sequence of quantized DCT coefficients ZZ(0) quantized DC coefficient in zig-zag sequence order

IVE: intelligent video engine, IVS Engine

版权所有 侵权必究 Copyright © by Allwinner. All rights reserved 30 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MPP System Control Module User Guide 2 Shorthand MD: motion detection, 运动侦测 OD: occlusion detection, 遮挡检测 SAD: sum of absolute difference nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni OBJ: object(OBJ) region information,运动区域信息 VDA_ALG_REF: frame reference algorithm VDA_ALG_BG: background algorithm

VQE: voice quality enhancement, 声音质量增强 RES: resampling, 重采样 HPF: high-pass filtering, 高通滤波 AEC: audio echo cancellation, 回声抵消 ANR: environment noise suppression, 环境噪声抑制 Adaptive Noise Restrain 自适应噪声抑制 AGC: automatic gain control, 自动增益 nulllindeni EnulllindeniQ: equalizer, 均nulllindeni衡器 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni RNR: Hi-Fi noise suppression, 高保真噪声抑制 Gain: volume gain adjustment AIP: Audio Input Ports (AIPs) AOP: Audio Output Ports (AOPs) PD: power down,下电,也相当于 power off 吧 CSC: Color Space Conversion, 颜色空间转换 DIS:Digital Image Stabilization, 防抖属性 MMZ: media memory zone, 媒体内存区域,海思 HI_ID_ODT = 48, //Object detection trace HI_ID_VQA = 49, //Video quality analysis HI_ID_LPR = 50, // License Plate Recognition nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni 英文和 VLPR 车牌识别技术(Vehicle License Plate Recognition)比较相似

版权所有 侵权必究 Copyright © by Allwinner. All rights reserved 31 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni MPP System Control Module User Guide 3 Declaration 3. Declaration This document is the original work and copyrighted property of Allwinner Technology (“Allwinner”). nulllindeni Reprodunulllindeniction in whole nulllindenior in part musnulllindenit obtain the wrinulllindenitten approval ofnulllindeniAllwinner andnulllindenigive clear nulllindeni acknowledgement to the copyright owner.

The information furnished by Allwinner is believed to be accurate and reliable. Allwinner reserves the right to make changes in circuit design and/or specifications at any time without notice. Allwinner does not assume any responsibility and liability for its use. Nor for any infringements of patents or other rights of the third parties which may result from its use. No license is granted by implication or otherwise under any patent or patent rights of Allwinner. This datasheet neither states nor implies warranty of any kind, including fitness for any particular application.

nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni

nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni

版权所有 侵权必究 Copyright © by Allwinner. All rights reserved 32 nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni nulllindeni