porting guide from open at 3.10 to 4 - hmangas.com · 3.5.1 adl_irqsubscribe (new).....14 3.5.2...

56
Date: 22-May-2007 Revision: 001 PORTING GUIDE Open AT v3.10 to Open AT v4.1x Reference: WM_DEV_OAT_UGD_047

Upload: hoangduong

Post on 09-Apr-2019

213 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

PORTING GUIDE

Open AT® v3.10 to Open AT® v4.1x

7

Reference: WM_DEV_OAT_UGD_04

Date

1

Revision: 00

: 22-May-2007

Page 2: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

Document Information

Level Date History of the evolution Writer

001 May 22, 2007 Creation Wavecom Consultant

NOTE

This section is for Wavecom�s reference only, and must be deleted before printing this training courseware. Ensure that printing begins from the next page.

© 2007 Wavecom. All rights reserved.

WAVECOM S.A.

3, Esplanade du Foncet

92442 Issy-les-Moulineaux Cedex

FRANCE

Tel: +33 1 46 29 08 00

Fax: +33 1 46 29 08 08

Email: [email protected]

Information in this manual is subject to change without notice and does not represent a commitment on the part of the vendor. The Open AT® IDE described in this manual is furnished under a license agreement and may be used or copied only in accordance with the terms of agreement. No part of this manual may be reproduced or transmitted in any form or by any means, electronic or mechanical, including photocopying and recording, for any purpose without the express written permission of Wavecom.

Open AT® IDE is a registered trademark of Wavecom.

Other product and company names mentioned in this manual may be trademarks or registered trademarks of their respective owners.

This document has been commissioned by Wavecom for Open AT® IDE version 4.00.

©Confidential

Page:2/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

Page 3: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:3/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

Contents 1 INTRODUCTION ..................................................................................... 7

1.1 Related Documents .................................................................................. 7 1.2 Abbreviations .......................................................................................... 8 1.3 Glossary ................................................................................................. 9

2 INTRODUCTION TO OPEN AT® V4.1X.................................................... 10 3 NEW ADL SERVICES ............................................................................. 11

3.1 Introduction ...........................................................................................11 3.2 Open SIM Access ....................................................................................11

3.2.1 adl_osaSubscribe (New) ...................................................................11 3.2.2 adl_osaHandler_f callback type (New) ................................................11 3.2.3 adl_osaSendResponse (New).............................................................11 3.2.4 adl_osaUnsubscribe (New) ................................................................11

3.3 Message Service .....................................................................................12 3.3.1 adl_msgSubscribe (New) ..................................................................12 3.3.2 adl_msgHandler_f callback type (New) ...............................................12 3.3.3 adl_msgSend (New).........................................................................12 3.3.4 adl_msgUnsubscribe (New) ...............................................................12

3.4 Semaphore ADL Service ...........................................................................13 3.4.1 adl_semSubscribe (New) ..................................................................13 3.4.2 adl_semProduce (New).....................................................................13 3.4.3 adl_semConsume (New) ...................................................................13 3.4.4 adl_semConsumeDelay (New) ...........................................................13 3.4.5 adl_semUnsubscribe (New) ...............................................................13

3.5 IRQ Service............................................................................................14 3.5.1 adl_irqSubscribe (New) ....................................................................14 3.5.2 adl_irqHandler_f callback type (New) .................................................14 3.5.3 adl_irqUnsubscribe (New) .................................................................14

Page 4: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:4/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

3.6 SCTU Service..........................................................................................15 3.6.1 adl_sctuSubscribe (New) ..................................................................15 3.6.2 adl_sctuSetChannelConfig (New) .......................................................15 3.6.3 adl_sctuStart (New) .........................................................................15 3.6.4 adl_sctuRead (New).........................................................................15 3.6.5 adl_sctuStop (New) .........................................................................15 3.6.6 adl_sctuUnsubscribe (New) ...............................................................15

3.7 ADL External Interruption Service..............................................................17 3.7.1 adl_extintSubscribe (New) ................................................................17 3.7.2 adl_extintConfig (New).....................................................................17 3.7.3 adl_extintRead (New).......................................................................17 3.7.4 adl_extintUnsubscribe (New).............................................................17

3.8 Execution Context Service ........................................................................18 3.8.1 adl_ctxGetID (New) .........................................................................18 3.8.2 adl_ctxGetTaskID (New)...................................................................18 3.8.3 adl_ctxGetDiagnostic (New) ..............................................................18 3.8.4 adl_ctxSuspend (New) .....................................................................18 3.8.5 adl_ctxResume (New) ......................................................................18

3.9 ADL VariSpeed Service.............................................................................19 3.9.1 adl_vsSubscribe (New) .....................................................................19 3.9.2 adl_vsSetClockMode (New) ...............................................................19 3.9.3 adl_vsUnsubscribe (New)..................................................................19

3.10 ADL DAC Service.....................................................................................20 3.10.1 adl_dacSubscribe (New) ...................................................................20 3.10.2 adl_dacWrite (New) .........................................................................20 3.10.3 adl_dacUnsubscribe (New) ................................................................20

4 APIS IMPORTED FROM OPEN AT® LIBRARY.......................................... 21 5 MODIFIED ADL SERVICES .................................................................... 22

5.1 Mandatory Application Code......................................................................22 5.2 New Error Code ......................................................................................22 5.3 AT Commands APIs .................................................................................22

Page 5: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:5/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

5.3.1 Unsolicited Responses ......................................................................22 5.3.2 Responses ......................................................................................24 5.3.3 Incoming AT Commands...................................................................25 5.3.4 Run AT Commands ..........................................................................25

5.4 Memory Service APIs ...............................................................................26 5.4.1 The adl_memGetInfo function (New) ..................................................26 5.4.2 The adl_memGet function (Unchanged) ..............................................26 5.4.3 The adl_memRelease function (Unchanged) ........................................26 5.4.4 The adl_memGetType function (Removed) ..........................................26

5.5 GPIO APIs ..............................................................................................27 5.5.1 GPIO Types ....................................................................................27

5.6 Bus Service APIs .....................................................................................35 5.6.1 BUS Types......................................................................................35 5.6.2 The adl_busSubscribe () function (Changed) .......................................38 5.6.3 The adl_busUnsubscribe () function (Changed) ....................................39 5.6.4 The adl_busRead () function (Changed) ..............................................39 5.6.5 The adl_busWrite () function (Changed)..............................................41 5.6.6 The adl_busDirectRead () function (New) ............................................41 5.6.7 The adl_busDirectWrite () function (New)............................................41

5.7 Error Management APIs ...........................................................................43 5.7.1 The adl_errSubscribe () function (Unchanged) .....................................43 5.7.2 The adl_errUnsubscribe () function (Unchanged) ..................................43 5.7.3 The adl_errHalt () function (Unchanged) .............................................43 5.7.4 The adl_errEraseAllBacktraces () function (Changed) ............................43 5.7.5 The adl_errStartBacktraceAnalysis () function (Unchanged) ...................44 5.7.6 The adl_errGetAnalysisState () function (Unchanged) ...........................44 5.7.7 The adl_errRetrieveNextBacktrace () function (Unchanged) ...................44

5.8 SIM Service APIs.....................................................................................45 5.8.1 The adl_simSubscribe () function (Changed)........................................45 5.8.2 The adl_simUnsubscribe () function (Changed) ....................................45 5.8.3 The adl_simGetState () function (Unchanged)......................................46

Page 6: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:6/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

5.9 Application and Data Storage Service APIs..................................................47 5.9.1 The adl_ adSubscribe function (Unchanged) ........................................47 5.9.2 The adl_ adWrite function (Changed)..................................................47 5.9.3 The adl_ adInfo (Changed) ...............................................................47 5.9.4 The adl_ adFinalise (Changed)...........................................................48 5.9.5 The adl_ adInstall (Changed) ............................................................49 5.9.6 The adl_ adDelete (Changed) ............................................................49 5.9.7 The adl_ adUnsubscribe (Changed) ....................................................49 5.9.8 The adl_ adGetState (Unchanged)......................................................50 5.9.9 The adl_ adRecompact (Changed)......................................................50 5.9.10 The adl_ adGetCellList (Unchanged) ...................................................50 5.9.11 The adl_ adFormat (Changed) ...........................................................51 5.9.12 The adl_ adEventSubscribe (New) ......................................................51 5.9.13 The adl_ adEvnetUnsubscribe (New)...................................................51

6 SDK TOOLS EVOLUTIONS ..................................................................... 52

6.1 SDK Setup .............................................................................................52 6.2 Sample HTML documentation....................................................................52 6.3 Open AT® Settings ..................................................................................53 6.4 Open AT® Project Wizard..........................................................................54 6.5 Eclipse IDE.............................................................................................55

Page 7: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

1 Introduction

1.1 Related Documents

[1] ADL User Guide for Open AT® v310 (WM_ASW_OAT_UGD_006)

[2] ADL User Guide for Open AT® OS v4.11 (WM_DEV_OAT_UGD_019)

Page 8: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:8/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

1.2 Abbreviations

Abbreviation/Acronym Description

A&D Application And Data Storage

ADL Application Development Interface

API Application Programming Interface

APN Access Point Name

CID Context identifier

CPU Central Processing Unit

DAC Digital Analog Converter

EXTINT External interruption

FCM Flow Control Manager

GGSN Gateway GPRS Support Node

GPIO General Purpose Input Output

GPRS General Packet Radio Service

IP Internet Protocol

IR Infrared

KB Kilobyte

OS Operating System

PDP Packet Data Protocol

PDU Protocol Data Unit

RAM Random-Access Memory

ROM Read-Only Memory

RTK Real-Time Kernel

SDK Software Development Kit

SMA Small Adapter

SMS Short Message Services

Page 9: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:9/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

1.3 Glossary

Term Description

Application Mandatory API Mandatory software interfaces to be used by the Embedded Application.

AT commands Set of standard Wireless CPU® commands.

AT function Software that processes the AT commands and AT subscriptions.

Embedded API layer Software developed by Wavecom, containing the Open AT® APIs (Application Mandatory API, AT Command Embedded API, OS API, Standard API, FCM API, IO API, and BUS API).

Embedded Application User application sources to be compiled and run on a Wavecom product.

Embedded Core software Software that includes the Embedded Application and the Wavecom library.

Embedded software User application binary: set of Embedded Application sources + Wavecom library.

External Application Application external to the Wavecom product that sends AT commands through the serial link.

Receive command pre-parsing Process for intercepting AT responses.

Send command pre−parsing Process for intercepting AT commands.

Standard API Standard set of �C� functions.

Target Open AT® compatible product supporting an Embedded Application.

Target Monitoring Tool Set of utilities used to monitor a Wavecom product.

Wavecom Core Software Set of GSM and open functions supplied to the User.

Wavecom library Library delivered by Wavecom to interface Embedded Application sources with Wavecom Core Software functions.

Page 10: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:10/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

2 Introduction to Open AT® v4.1x

Open AT® v4.1x has been introduced to make full use of the enhanced processing power and new peripherals available with the new Q268x family of Wireless CPU®s. New services have been introduced in Open AT® and existing services have been revamped with new APIs.

Please note that the new features of the Wireless CPU® need to be activated. Please contact your Wavecom distributor for more information regarding the same.

Page 11: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:11/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

3 New ADL Services

This chapter lists the new Services that have been introduced with Open AT® v4.1x.

3.1 Introduction

The following services have been added to the currently existing Open AT® services to use the advanced processing power of the new Q268x family Wireless CPU®s.

3.2 Open SIM Access

The Open SIM Access (OSA) service allows the Open AT® Application to interact with an external SIM card. This SIM can be connected through one of the Wireless CPU® interfaces (UART, SPI, I2C).

3.2.1 adl_osaSubscribe (New) Prototype:

s32 adl_osaSubscribe ( adl_osaHandler_f OsaHandler ); This function subscribes to the OSA service and registers the callback handler associated with the service.

3.2.2 adl_osaHandler_f callback type (New) Prototype:

typedef void (* adl_osaHandler_f) ( adl_osaEvent_e Event , adl_osaEventParam_u * Param );

The callback handler receives events related to the OSA service.

3.2.3 adl_osaSendResponse (New) Prototype:

s32 adl_osaSendResponse ( s32 OsaHandle, adl_osaStatus_e Status, u16 Length, u8 * Data );

This function posts OSA responses to the Open AT® Firmware.

3.2.4 adl_osaUnsubscribe (New)

Prototype:

s32 adl_osaUnsubscribe ( s32 OsaHandle ); This function unsubscribes from the OSA service.

Page 12: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:12/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

3.3 Message Service

This service is provided by ADL to post and handle messages between the different components of an Open AT® Application. The user can only post messages to the Open AT® Application task. Using this service it is possible to compare and filter the messages that are received to differentiate and handle different messages.

3.3.1 adl_msgSubscribe (New) Prototype:

s32 adl_msgSubscribe ( adl_msgFilter_t * Filter, adl_msgHandler_f MsgHandler);

This function subscribes to the Message Service. The Open AT® Application will now receive messages from different application components (Open AT® Application or interruption handlers) which matches the �Filter� and the associated callback handler will be called.

3.3.2 adl_msgHandler_f callback type (New)

Prototype:

typedef void (*adl_msgHandler_f) ( u32 MsgIdentifier, adl_ctxID_e Source, u32 Length, void * Data );

The callback function through which the messages posted to the Open AT® Application Task will be received.

3.3.3 adl_msgSend (New) Prototype:

s32 adl_msgSend ( adl_msgMailBox_e DestinationMbx, u32 MessageIdentifier, u32 Length, void * Data );

Function to post messages to the Open AT® Application task.

3.3.4 adl_msgUnsubscribe (New)

Prototype:

s32 adl_msgUnsubscribe ( s32 MsgHandle ); This function unsubscribes from the Message Service.

Page 13: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:13/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

3.4 Semaphore ADL Service

Semaphore service is used to synchronize between the Open AT® Application task and high level interruption handlers.

3.4.1 adl_semSubscribe (New) Prototype:

s32 adl_semSubscribe ( u16 SemCounter ); This function subscribes to the semaphore service with the amount of times the semaphore can be consumed.

3.4.2 adl_semProduce (New) Prototype:

s32 adl_semProduce ( s32 SemHandle ); This function increases the required semaphore count by 1

3.4.3 adl_semConsume (New)

Prototype:

s32 adl_semConsume ( s32 SemHandle ); This function consumes a semaphore resource

3.4.4 adl_semConsumeDelay (New)

Prototype:

s32 adl_semConsumeDelay ( s32 SemHandle, u32 TimeOut ); This function consumes a semaphore resource and specifies time-out to produce a semaphore before application resume automatically the suspended context.

3.4.5 adl_semUnsubscribe (New)

Prototype:

s32 adl_semUnsubscribe ( s32 SemHandle ); This function unsubscribes from the Semaphore service

Page 14: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:14/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

3.5 IRQ Service

This service is used to define interrupt callback handler. These handlers have to be used along with the External Interrupt service and SCTU service. Interrupt handler can be defined as High Level Interrupts and Low Level Interrupts. They can also be defined as Low Priority and High Priority Interrupts.

3.5.1 adl_irqSubscribe (New) Prototype:

s32 adl_irqSubscribe ( adl_irqHandler_f IrqHandler, adl_irqNotificationLevel_e NotificationLevel, adl_irqPriorityLevel_e PriorityLevel, u32 Options );

This function subscribes to the IRQ service. It registers the associated callback handler at the required level with a specified priority and options.

3.5.2 adl_irqHandler_f callback type (New) Prototype:

typedef bool (*adl_irqHandler_f) ( adl_irqID_e Source, adl_irqNotificationLevel_e NotificationLevel, adl_irqEventData_t * Data );

The callback handler receives the interrupts. The Source specifies where the interrupt was raised.

3.5.3 adl_irqUnsubscribe (New)

Prototype:

s32 adl_irqUnsubscribe ( s32 IrqHandle ); This function unsubscribes from the IRQ service.

Page 15: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:15/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

3.6 SCTU Service

The SCTU service allows access to the System Controller Timer Unit. This allows hardware timer configurations and interruptions.

3.6.1 adl_sctuSubscribe (New) Prototype:

s32 adl_sctuSubscribe ( adl_sctuID_e BlockID, s32 LowLevelIrqHandle, s32 HighLevelIrqHandle, adl_sctuSettings_t * Settings );

This function subscribes to the SCTU service. The required SCTU block is powered on when this function is called. The interrupt handles have to be defined using the IRQ service.

3.6.2 adl_sctuSetChannelConfig (New)

Prototype:

s32 adl_sctuSetChannelConfig ( s32 SctuHandle, adl_sctuChannel_e ChannelID, u16 CompareValue, bool InterruptionFlag );

This function is used to configure the subscribed SCTU block comparators

3.6.3 adl_sctuStart (New)

Prototype:

s32 adl_sctuStart ( s32 SctuHandle ); This function starts the SCTU block timer.

3.6.4 adl_sctuRead (New) Prototype:

s32 adl_sctuRead ( s32 SctuHandle, adl_sctuInfo_t * Info ); This function used to retrieve the SCTU interruption source mask.

3.6.5 adl_sctuStop (New)

Prototype:

s32 adl_sctuStop ( s32 SctuHandle ); This function stops the SCTU block timer

3.6.6 adl_sctuUnsubscribe (New)

Prototype:

Page 16: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:16/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

s32 adl_sctuUnsubscribe ( s32 SctuHandle ); This function unsubscribes from the SCTU service.

Page 17: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:17/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

3.7 ADL External Interruption Service

The External Interruption (Extint) service is used to handle the Wireless CPU®�s external interruption. This feature has to be enabled using the AT Command �AT+WFM�

3.7.1 adl_extintSubscribe (New) Prototype:

s32 adl_extintSubscribe ( adl_extintID_e ExtIntID, s32 LowLevelIrqHandle, s32 HighLevelIrqHandle, adl_extintSettings_t * Settings );

This function is used to subscribe to the external interrupt Service. The interrupt handles have to be defined using the IRQ service.

3.7.2 adl_extintConfig (New) Prototype:

s32 adl_extintConfig ( s32 ExtIntHandle, adl_extintSettings_t * Settings );

This function is used to configure the Interrupt pin settings

3.7.3 adl_extintRead (New)

Prototype:

s32 adl_extintRead ( s32 ExtIntHandle, adl_extintInfo_t * Info ); This function is used to retrieve the input status of the external interrupt pin

3.7.4 adl_extintUnsubscribe (New) Prototype:

s32 adl_extintUnsubscribe ( s32 ExtIntHandle ); This function is used to unsubscribe from the Extint service.

Page 18: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:18/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

3.8 Execution Context Service

The Open AT® Application can have several contexts (Application Task Context, Low Level & High Level Handler contexts). The Execution Context Service is used to monitor the various contexts.

3.8.1 adl_ctxGetID (New)

Prototype:

adl_ctxID_e adl_ctxGetID ( void ); This function is used to retrieve the currently execution context identifier.

3.8.2 adl_ctxGetTaskID (New) Prototype:

adl_ctxID_e adl_ctxGetTaskID ( void ); This function is used to retrieve the currently running task identifier.

3.8.3 adl_ctxGetDiagnostic (New)

Prototype:

u32 adl_ctxGetDiagnostic ( void ); This function is used to retrieve information about the current application context.

3.8.4 adl_ctxSuspend (New)

Prototype:

s32 adl_ctxSuspend ( adl_ctxID_e Task ); This function is used to suspend the specified Open AT® task.

3.8.5 adl_ctxResume (New) Prototype:

s32 adl_ctxResume ( adl_ctxID_e Task ); This function is used to resume the specified Open AT® task which had been previously suspended.

Page 19: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:19/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

3.9 ADL VariSpeed Service

This service is used to change the clock speed of the Wireless CPU® to temporarily boost the performance of Open AT® Application.

3.9.1 adl_vsSubscribe (New) Prototype:

s32 adl_vsSubscribe ( void ); This function is used to subscribe to the ADL VariSpeed service

3.9.2 adl_vsSetClockMode (New)

Prototype:

s32 adl_vsSetClockMode ( s32 VsHandle, adl_vsMode_e ClockMode );

This function is used to set the Wireless CPU® to the required clock speed.

3.9.3 adl_vsUnsubscribe (New) Prototype:

s32 adl_vsUnsubscribe ( s32 VsHandle ); This function is used to unsubscribe from the VariSpeed service.

Page 20: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:20/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

3.10 ADL DAC Service

The ADL DAC service allows the Open AT® Application to access the DAC feature of the Wireless CPU®.

3.10.1 adl_dacSubscribe (New) Prototype:

s32 adl_dacSubscribe( adl_dacChannel_e Channel, adl_dacParam_t * Parameters );

This function is used to unsubscribe to the ADL DAC service

3.10.2 adl_dacWrite (New)

Prototype:

s32 adl_dacWrite ( s32 Handle, u32 Value ); This function is used to set the output value of the DAC block

3.10.3 adl_dacUnsubscribe (New) Prototype:

s32 adl_dacUnsubscribe ( s32 Handle ); This function is used to unsubscribe from the DAC service.

Page 21: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:21/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

4 APIs Imported from Open AT® Library

The following APIs are added in Open AT® v4.1x from the standard mode.

• Standard API � defined in wm_stdio.h file

• List API � defined in wm_list.h file

• Sound APIs � defined in wm_snd.h file

Page 22: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:22/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

5 Modified ADL Services

5.1 Mandatory Application Code

The mandatory application code requested for Open AT® v4.1x is the following:

const u16 wm_apmCustomStackSize = 1024; If the application needs to handle interruptions, it must also define the required contexts call stack sizes.

The constant used for low level interruption handler execution context is defined as:

const u16 wm_apmIRQLowLevelStackSize = 1024; The constant used for high level interruption handler execution context is defined as:

const u16 wm_apmIRQHighLevelStackSize = 1024; Note: The above definitions are optional. If the application does not provide one or both the call stack sizes or initialize them to 0, the associated context will not be available at runtime.

5.2 New Error Code

Some ADL APIs will return error code �ADL_RET_ERR_SERVICE_LOCKED� when called from the low level interruption handler. The meaning of this error code is the APIs can not be used in the low level context. The call of such APIs is prohibited from the context.

5.3 AT Commands APIs

These API�s are used to manage the AT commands. This includes

• sending of AT command string

• reception of AT responses

• pre-parsing of AT commands and AT responses

• intermediate AT responses

• unsolicited responses

5.3.1 Unsolicited Responses

The APIs adl_atUnSoSubscribe () and adl_atUnSoUnSubscribe () are the same as defined in Open AT® v3.

Page 23: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:23/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

Note: The above APIs cannot be called from a low level interruption handler. On doing so an error �ADL_RET_ERR_SERVICE_LOCKED� will be returned as the functions cannot be used in this context.

Page 24: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:24/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

5.3.2 Responses

5.3.2.1 The adl_atSendResponse () function (Changed)

Prototype:

s32 adl_atSendResponse (u16 Type, ascii * String); The function sends any text to required port as a response, intermediate or unsolicited response depending on the type specified.

Old Prototype

// Send a response adl_atSendResponse (u16 Type, ascii * String);

New Prototype

// Send a response s32 adl_atSendResponse (u16 Type, ascii * String);

Note: The function returns OK on success and �ADL_RET_ERR_SERVICE_LOCKED� when called from a low level interruption handler.

5.3.2.2 The adl_atSendResponse () function (Changed)

Prototype:

s32 adl_atSendStdResponse (u16 Type, adl_strId_e RspID);

The function sends a standard response to required port as a response, intermediate or unsolicited response depending on the type specified.

Old Prototype

// Send standard response void adl_atSendStdResponse (u8 Type, adl_strId_e RspID);

New Prototype

//Send standard response s32 adl_atSendStdResponse (u16 Type, adl_strId_e RspID);

Page 25: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:25/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

Note: The function returns OK on success and �ADL_RET_ERR_SERVICE_LOCKED� when called from a low level interruption handler.

5.3.2.3 The adl_atSendStdResponseExt () function (Changed)

Prototype:

s32 adl_atSendStdResponseExt (u16 Type, adl_strId_e RspID, u32 arg);

The function sends a standard response with an argument to required port as a response, intermediate or unsolicited response depending on the type specified.

Old Prototype

// Send standard response with argument void adl_atSendStdResponseExt (u8 Type, adl_strId_e RspID, u32 arg);

New Prototype

//Send standard response with argument s32 adl_atSendStdResponseExt (u16 Type, adl_strId_e RspID, u32 arg);

Note: The function returns OK on success and �ADL_RET_ERR_SERVICE_LOCKED� when called from a low level interruption handler.

5.3.3 Incoming AT Commands The APIs adl_atCmdSubscribe () and adl_atCmdUnSubscribe () are the same as defined in Open AT® v3.

Note: The above APIs cannot be called from a low level interruption handler. On doing so an error �ADL_RET_ERR_SERVICE_LOCKED� will be returned as the functions cannot be used in this context.

5.3.4 Run AT Commands

The APIs adl_atCmdCreate () and adl_atCmdSendText () are the same as defined in Open AT® v3.

Note: The above APIs cannot be called from a low level interruption handler.

Page 26: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:26/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

5.4 Memory Service APIs

5.4.1 The adl_memGetInfo function (New)

Prototype :

s32 adl_memGetInfo (adl_memInfo_t * Info) ; Returns the Open AT® RAM area size i.e the Total RAM size, Stack size, Heap size and the Global variables area size.

Note: The field is set to 0 under Remote Task Environment.

5.4.2 The adl_memGet function (Unchanged) Prototype :

void * adl_memGet (u32 size); Allocates the memory of requested size into the application RAM meory.

5.4.3 The adl_memRelease function (Unchanged)

Prototype :

bool adl_memRelease (void * ptr); Releases the allocated memory buffer.

5.4.4 The adl_memGetType function (Removed)

Prototype :

adl_memType_e adl_memGetType (void); Returns the current module memory type.

Page 27: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:27/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

5.5 GPIO APIs

This service allows the application to handle GPIO related operations.

5.5.1 GPIO Types

5.5.1.1 The adl_ioConfig_t Structure (New)

Definition:

typedef struct { adl_ioLabel_u eLabel; //GPIO Label u32 Pad; adl_ioDirection_e eDirection;//GPIO direction adl_ioState_e eState; //GPIO state at subscription } adl_ioConfig_t;

The above structure is used by adl_ioSubscribe () API to set the GPIO parameters.

5.5.1.2 The adl_ioLabel_u Union (New)

Definition:

typedef union { adl_ioLabel_Q2686_e Q2686_Label; //Used for Q2686 Wireless CPU® adl_ioLabel_Q2687_e Q2687_Label; //Used for Q2687 Wireless CPU® } adl_ioLabel_u;

The union represents the different GPIO labels.

/* GPIO labels for Q2686 Wireless CPU® */ typedef enum { ADL_IO_Q2686_GPIO_1 = 3, ADL_IO_Q2686_GPIO_2, ADL_IO_Q2686_GPIO_3, ... ADL_IO_ Q2686_GPIO_43, ADL_IO_ Q2686_GPIO_44, ADL_IO_Q2686_PAD = 0x7FFFFFFF } adl_ioLabel_Q2686_e;

Page 28: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:28/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

/* GPIO labels for Q2687 Wireless CPU® */ typedef enum { ADL_IO_Q2687_GPIO_1 = 2, ADL_IO_Q2687_GPIO_2, ADL_IO_Q2687_GPIO_3, ... ADL_IO_ Q2687_GPIO_43, ADL_IO_ Q2687_GPIO_44, ADL_IO_Q2687_PAD = 0x7FFFFFFF } adl_ioLabel_Q2687_e;

5.5.1.3 The adl_ioDirection_e Type (New)

Definition:

typedef enum { ADL_IO_OUTPUT, //GPIO set as output ADL_IO_INPUT //GPIO set as input }adl_ioDirection_e;

This type represents the direction used for a GPIO.

5.5.1.4 The adl_ioState_e Type (New)

Definition:

typedef enum { ADL_IO_LOW, //Low state ADL_IO_HIGH //High state }adl_ioState_e;

This type represents the state of a GPIO.

Page 29: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:29/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

5.5.1.5 The adl_ioSetDirection_t Structure (New)

Definition:

typedef struct { adl_ioLabel_u eLabel; //GPIO Label adl_ioDirection_e eDirection; //New GPIO direction } adl_ioSetDirection_t;

The above structure is used by adl_ioSetDirection () API to set the GPIO to a new direction.

5.5.1.6 The adl_ioRead_t Structure (New)

Definition:

typedef struct { adl_ioLabel_u eLabel; //GPIO Label adl_ioState_e eState; //Set to GPIO read value } adl_ioRead_t;

The above structure is used by adl_ioRead () API to read one or several GPIO values.

5.5.1.7 The adl_ioWrite_t Structure (New)

Definition:

typedef struct { adl_ioLabel_u eLabel; //GPIO Label adl_ioState_e eState; //GPIO value set on output } adl_ioWrite_t;

The above structure is used by adl_ioWrite () API to write one or several GPIO values.

Page 30: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:30/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

5.5.1.8 The adl_ioFeature_e Type (New)

Definition:

typedef enum { ADL_IO_FEATURE_NONE, ADL_IO_FEATURE_BUS_SPI1_CLK, ADL_IO_FEATURE_BUS_SPI1_IO, ADL_IO_FEATURE_BUS_SPI1_I, ADL_IO_FEATURE_BUS_SPI1_CS, ADL_IO_FEATURE_BUS_SPI2_CLK, ADL_IO_FEATURE_BUS_SPI2_IO, ADL_IO_FEATURE_BUS_SPI2_I, ADL_IO_FEATURE_BUS_SPI2_CS, ADL_IO_FEATURE_BUS_I2C, ADL_IO_FEATURE_BUS_PARALLEL_ADDR1, ADL_IO_FEATURE_BUS_PARALLEL_ADDR2_CS2, ADL_IO_FEATURE_KBD, ADL_IO_FEATURE_SIMPRES, ADL_IO_FEATURE_UART1, ADL_IO_FEATURE_UART2, ADL_IO_FEATURE_INT0, ADL_IO_FEATURE_INT1, ADL_IO_FEATURE_BT_RST, ADL_IO_FEATURE_LAST } adl_ioFeature_e;

Enumerates the Wireless CPU® features multiplxed with one or several GPIOs.

5.5.1.9 The adl_ioEventSubscribe () function (New)

Prototype:

s32 adl_ioEventSubscribe (adl_ioHdlr_f GpioEventHandler); This function subscribes to the GPIO related events usinga callback handler.

5.5.1.10 The adl_ioEventUnsubscribe () function (New)

Prototype:

s32 adl_ioEventUnsubscribe (s32 GpioEventHandle); The function unsubscribes from GPIO events notification.

Page 31: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:31/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

5.5.1.11 The adl_ioSubscribe () function (Changed)

Prototype:

s32 adl_ioSubscribe (u32 GpioNb, adl_ioConfig_t * GpioConfig, u8 PollingTimerType, u32 PollingTime, s32 GpioEventHandle);

The function allows to subscribe to some GPIOs.

Old Prototype

// Subscribe to GPIO s8 sRet = adl_ioSubscribe (GpioMask, GpioDir, GpioDefValues, PollingTime, GpioHandler);

New Prototype

//Subscribe to GPIO s32 sRet = adl_ioSubscribe (GpioNb, GpioConfig, PollingTimerType, PollingTime, GpioEventHandle);

5.5.1.12 The adl_ioUnsubscribe () function (Unchanged)

Prototype:

s32 adl_ioUnsubscribe (s32 GpioHandle); The function unsubscribe from the previously allocated GPIO handle.

5.5.1.13 The adl_ioSetDirection () function (New)

Prototype:

s32 adl_ioSetDirection (s32 GpioHandle, u32 GpioNb, adl_ioSetDirection_t * GpioDir);

The function allows to change the direction of one or more previously allocated GPIOs.

Page 32: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:32/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

5.5.1.14 The adl_ioRead () function (Changed)

Prototype:

s32 adl_ioRead (s32 GpioHandle, u32 GpioNb, adl_ioRead_t * GpioRead);

The function allows several GPIOs to read from previously allocated handle.

Old Prototype

// Read from GPIO s32 sRet = adl_ioRead (Handle);

New Prototype

//Read from GPIO s32 sRet = adl_ioRead (GpioHandle, GpioNb, GpioRead);

5.5.1.15 The adl_ioReadSingle() function (New)

Prototype:

s32 adl_ioReadSingle (s32 GpioHandle, u32 Gpio);

The function allows one GPIO to read from previously allocated handle.

Page 33: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:33/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

5.5.1.16 The adl_ioWrite () function (Changed)

Prototype:

s32 adl_ioWrite (s32 GpioHandle, u32 GpioNb, adl_ioRead_t * GpioWrite);

The function writes on several GPIOs from previously allocated handle.

Old Prototype

// Write to GPIO S8 sRet = adl_ioWrite (Handle, GpioMask, GpioValues);

New Prototype

//Write to GPIO s32 sRet = adl_ioWrite (GpioHandle, GpioNb, GpioWrite);

5.5.1.17 The adl_ioWriteSingle() function (New)

Prototype:

s32 adl_ioWriteSingle (s32 GpioHandle, u32 Gpio, u32 State);

The function allows to write on one GPIO from previously allocated handle.

5.5.1.18 The adl_ioGetProductType () function (Unchanged)

Prototype:

adl_ioProductTypes_e adl_ioGetProductType (void); The function returns the type of Wireless CPU® used.

5.5.1.19 The adl_ioGetFeatureGPIOList () function (New)

Prototype:

s32 adl_ioGetFeatureGPIOList (adl_ioFeature_e Feature,

Page 34: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:34/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

u8 * GpioTab, u8 GpioNb);

The function retrieves the list of GPIO multiplexed with a specific feature and are not available when this feature is activated.

5.5.1.20 The adl_ioIsFeatureEnabled () function (New)

Prototype:

bool adl_ioIsFeatureEnabled (adl_ioFeature_e Feature); The function checks if the required feature is enabled or not.

Note: The above APIs cannot be called from a low level interruption handler.

Page 35: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:35/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

5.6 Bus Service APIs

This service allows to handle the SPI, I2C and Parallel bus operations.

5.6.1 BUS Types

5.6.1.1 The adl_busType_e Type (New)

Definition:

typedef enum { ADL_BUS_SPI1 = 1, //Constant to access SPI1 bus ADL_BUS_SPI2, //Constant to access SPI2 bus ADL_BUS_I2C = 4 //Constant to access I2C bus ADL_BUS_PARALLEL = 6 //Constant to access Parallel bus } adl_busType_e;

The above type defines the bus available for subscription on the Wireless CPU®.

5.6.1.2 The adl_busSPISettings_t Structure (New)

Definition:

typedef struct { u32 Clk_Speed; //SPI bus clock speed u32 Clk_Mode; //SPI clock mode u32 ChipSelect; //Sets the pin to handle Chip Select signal u32 ChipSelectPolarity; //Sets polarity of Chip Select signal u32 LsbFirst; //Sets priority of data transmission u32 GpioChipSelect; //Sets GPIO label to use as Chip Select u32 WriteHandling; // Chip Select signal behavior u32 DataLinesConf; // Sets SPI bus as Bidirectional or Unidirectional } adl_busSPISettings_t;

The structure defines the SPI bus settings for subscription.

Page 36: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:36/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

5.6.1.3 The adl_busI2CSettings_t Structure (New)

Definition:

typedef struct { u32 ChipAddress; //Sets remote chip address on I2C bus

u32 Clk_Speed; //Sets I2C bus speed }adl_busI2CSettings_t;

The structure defines the I2C bus settings for subscription.

5.6.1.4 The adl_busParallelCs_t Structure (New)

Definition:

typedef struct { u8 Type; //Chip Select signal type u8 Id; //Chip Select identifier used u8 pad[2] }adl_busParallelCs_t;

The structure defines the Parallel bus Chip Select.

5.6.1.5 The adl_busParallelTimingCfg_t Structure (New)

Definition:

typedef struct { u8 AccessTime; u8 SetupTime; u8 HoldTime; u8 TurnaroundTime; u8 OpToOpTurnaroundTime; u8 pad[3]; } adl_busParallelTimingCfg_t;

The structure defines the Parallel bus timings.

5.6.1.6 The adl_busParallelSettings_t Structure (New)

Definition:

typedef struct { union { struct {

Page 37: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:37/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

u8 Width; // Read/Write data buffer size u8 Mode; // Parallel bus mode u8 pad[2]; //Timing configuration for read adl_busParallelTimingCfg_t ReadCfg; //Timing configuration for write adl_busParallelTimingCfg_t WriteCfg; //Chip Select signal configuration adl_busParallelCs_t Cs; // Number of address pins used u8 NbAddNeeded; } In; struct { //Reserved for ADL usage volatile void * PrivateAddress; u32 MaskValidAddress; } Out; } u; } adl_busParallelSettings_t;

The above structure defines the Parallel bus settings for subscription.

5.6.1.7 The adl_busSettings_u Union (New)

Definition:

typedef union { adl_busSPISettings_t SPI; //for SPI bus adl_busI2CSettings_t I2C; //for I2C bus adl_busParallelsettings_t Parallel // for Parallel bus } adl_busSettings_u;

This type sets the bus configuration parameters at subscription time.

5.6.1.8 The adl_busAccess_t Structure (New)

Definition:

typedef struct { u32 Address; u32 Opcode; u8 OpcodeLength;

Page 38: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:38/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

u8 AddressLength; adl_busSize_e Size; } adl_busAccess_t;

Sets the bus access configuration parameters to be used for read/write process. This structure is used for SPI and I2C buses only.

5.6.1.9 The adl_busSize_e Type (New)

Definition:

typedef enum { ADL_BUS_SIZE_1_BIT = 1, ADL_BUS_SIZE_2_BITS, ADL_BUS_SIZE_3_BITS, ADL_BUS_SIZE_4_BITS, ADL_BUS_SIZE_5_BITS, ADL_BUS_SIZE_6_BITS, ADL_BUS_SIZE_7_BITS, ADL_BUS_SIZE_BYTE, ADL_BUS_SIZE_9_BITS, ADL_BUS_SIZE_10_BITS, ADL_BUS_SIZE_11_BITS, ADL_BUS_SIZE_12_BITS, ADL_BUS_SIZE_13_BITS, ADL_BUS_SIZE_14_BITS, ADL_BUS_SIZE_15_BITS, ADL_BUS_SIZE_HALF, ADL_BUS_SIZE_WORD = ADL_BUS_SIZE_HALF } adl_busSize_e;

Sets the bit size for read/write data buffer items.

5.6.2 The adl_busSubscribe () function (Changed) Prototype:

s32 adl_busSubscribe (adl_busType_e BusType, adl_busSettings_u * BusSettings);

This function subscribes to a specific bus.

Page 39: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:39/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

Old Prototype

// Subscribe to Bus s8 sRet = adl_busSubscribe (BusAddress, Param);

New Prototype

//Subscribe to Bus s32 sRet = adl_busSubscribe (BusType, BusSettings);

5.6.3 The adl_busUnsubscribe () function (Changed) Prototype:

s32 adl_busUnsubscribe (s32 Handle); The function unsubscribes from previously subscribed SPI or I2C bus. It cannot be used for Parallel bus.

Old Prototype

// Unsubscribe from Bus s8 sRet = adl_busUnsubscribe (Handle);

New Prototype

//Unsubscribe from Bus s32 sRet = adl_busUnsubscribe (Handle);

Note: The above APIs cannot be called from a low level interruption handler.

5.6.4 The adl_busRead () function (Changed) Prototype:

s32 adl_busRead (s32 Handle, adl_busAccess_t * pAccessMode, u32 DataLen, void * Data);

The function reads data from previously subscribed SPI or I2C bus. It cannot be used for Parallel bus.

Page 40: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:40/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

Old Prototype

// Read from Bus s8 sRet = adl_busRead (Handle, pAccessMode, DataLen, void * Data);

New Prototype

//Read from Bus s32 sRet = adl_busRead (Handle, pAccessMode, DataLen, Data);

Page 41: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:41/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

5.6.5 The adl_busWrite () function (Changed) Prototype:

s32 adl_busWrite (s32 Handle, adl_busAccess_t * pAccessMode, u32 DataLen, void * Data);

The function writes data on previously subscribed SPI or I2C bus. It cannot be used for Parallel bus.

Old Prototype

// Writes to Bus s8 sRet = adl_busWrite (Handle, pAccessMode, DataLen, Data);

New Prototype

//Writes to Bus s32 sRet = adl_busWrite (Handle, pAccessMode, DataLen, Data);

5.6.6 The adl_busDirectRead () function (New) Prototype:

s32 adl_busDirectRead (s32 Handle, u32 ChipAddress, u32 DataLen, void * Data);

The function reads data from previously subscribed Parallel bus. It cannot be used for SPI and I2C bus.

5.6.7 The adl_busDirectWrite () function (New)

Prototype:

s32 adl_busDirectWrite (s32 Handle, u32 ChipAddress, u32 DataLen, void * Data);

Page 42: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:42/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

The function writes data on previously subscribed Parallel bus. It cannot be used for SPI and I2C bus.

Page 43: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:43/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

5.7 Error Management APIs

5.7.1 The adl_errSubscribe () function (Unchanged)

Prototype:

s8 adl_errSubscribe (adl_errHdlr_f Handler ); The function subscribes to error service. The associated error handler is called when error generated by ADL or adl_errHalt () API occurs.

5.7.2 The adl_errUnsubscribe () function (Unchanged)

Prototype:

s8 adl_errUnsubscribe (adl_errHdlr_f Handler ); The function unsubscribes from error service.

5.7.3 The adl_errHalt () function (Unchanged) Prototype:

void adl_errHalt (u16 ErrorID, const ascii * ErrorString );

The function causes an error which is defined by the ID and the error string. The error handleris called if defined, else the Wireless CPU® will reset.

5.7.4 The adl_errEraseAllBacktraces () function (Changed) Prototype:

s32 adl_errEraseAllBacktraces (void ); The function allows to free and re-initialize the Wireless CPU® non-volatile memory where the backtraces are stored.

Old Prototype

adl_errEraseAllBacktraces ();

New Prototype

// Return value added s32 sRet = adl_errEraseAllBacktraces ();

Page 44: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:44/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

5.7.5 The adl_errStartBacktraceAnalysis () function (Unchanged) Prototype:

s8 adl_errStartBacktraceAnalysis (void );

The function retrieves the backtraces from the Wireless CPU®�s memory.

5.7.6 The adl_errGetAnalysisState () function (Unchanged) Prototype:

adl_errAnalysisState_e adl_errGetAnalysisState (void ); The function is used to get the current backtrace analysis process state.

5.7.7 The adl_errRetrieveNextBacktrace () function (Unchanged)

Prototype:

s32 adl_ errRetrieveNextBacktrace (u8 Handle, u8 * BacktraceBuffer, u16 Size );

The function allows the application to retrieve the next backtrace buffer stored in the Wireless CPU® memory.

Note: The above APIs cannot be called from a low level interruption handler.

Page 45: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:45/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

5.8 SIM Service APIs

This service enables the application to handle SIM and PIN code related events.

5.8.1 The adl_simSubscribe () function (Changed) Prototype:

s32 adl_simSubscribe (adl_simHdlr_f SimHandler, ascii * PinCode );

The function subscribes to SIM service using a callback handler to receive SIM and PIN code related events.

Old Prototype

//Subscribes to SIM service adl_simSubscribe (SimHandler, PinCode );

New Prototype

//Subscribes to SIM service s32 sRet = adl_simSubscribe (SimHandler, PinCode );

5.8.2 The adl_simUnsubscribe () function (Changed)

Prototype:

s32 adl_simUnsubscribe (adl_simHdlr_f Handler ); The function unsubscribes from SIM service.

Old Prototype

//Unsubscribes from SIM service adl_simUnsubscribe (Handler );

New Prototype

//Unsubscribes from SIM service s32 sRet = adl_simUnsubscribe (Handler );

Note: The above APIs cannot be called from a low level interruption handler.

Page 46: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:46/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

5.8.3 The adl_simGetState () function (Unchanged) Prototype:

adl_simState_e adl_simGetState (void ); The function gets the current SIM service state.

Page 47: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:47/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

5.9 Application and Data Storage Service APIs

This service provides APIs to used the Application & Data storage volume which may be used to store data or the �.dwl� files.

5.9.1 The adl_ adSubscribe function (Unchanged) Prototype:

s32 adl_adSubscribe( u32 CellID, u32 Size ); This function subscribes to an A&D cell of the specified Cell ID and size.

5.9.2 The adl_ adWrite function (Changed)

Prototype:

s32 adl_adWrite ( s32 CellHandle, u32 Size, void * Data ); This function writes data to the A&D cell.

Old Prototype

u32 CellHandle; //Writes to A&D memory s32 sRet = adl_adWrite (CellHandle, Size, Data );

New Prototype

s32 CellHandle; //Writes to A&D memory s32 sRet = adl_adWrite (CellHandle, Size, Data );

5.9.3 The adl_ adInfo (Changed) Prototype:

s32 adl_adInfo ( s32 CellHandle, adl_adInfo_t * Info ); This function gets current information regarding the specified A&D cell.

Page 48: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:48/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

Old Prototype

u32 CellHandle; //Gets current information of the A&D cell s32 sRet = adl_adInfo (CellHandle, Info );

New Prototype

s32 CellHandle; // Gets current information of the A&D cell s32 sRet = adl_adInfo (CellHandle, Info );

5.9.4 The adl_ adFinalise (Changed)

Prototype:

s32 adl_adFinalise ( s32 CellHandle ); This function finalizes the cell and makes it read only.

Old Prototype

u32 CellHandle; //Finalizes the A&D cell s32 sRet = adl_adFinalise (CellHandle );

New Prototype

s32 CellHandle; // Finalizes the A&D cell s32 sRet = adl_adFinalise (CellHandle );

Page 49: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:49/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

5.9.5 The adl_ adInstall (Changed) Prototype:

s32 adl_adInstall ( s32 CellHandle ); This function installs the Open AT® application stored in the specified A&D cell.

Old Prototype

u32 CellHandle; //Installs application in the A&D cell s32 sRet = adl_adInstall (CellHandle );

New Prototype

s32 CellHandle; // Installs application in the A&D cell s32 sRet = adl_adInstall (CellHandle );

5.9.6 The adl_ adDelete (Changed) Prototype:

s32 adl_adDelete ( s32 CellHandle ); This function deletes the specified A&D cell.

Old Prototype

u32 CellHandle; //Deletes the specified A&D cell s32 adl_adDelete (CellHandle );

New Prototype

s32 CellHandle; // Deletes the specified A&D cell s32 adl_adDelete (CellHandle );

5.9.7 The adl_ adUnsubscribe (Changed) Prototype:

s32 adl_adUnsubscribe ( s32 CellHandle );

Page 50: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:50/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

This function unsubscribes from the specified A&D cell.

Old Prototype

u32 CellHandle; //Unsubscribes from the specified A&D cell s32 adl_adUnsubscribe (CellHandle );

New Prototype

s32 CellHandle; // Unsubscribes from the specified A&D cell s32 adl_adUnsubscribe (CellHandle );

5.9.8 The adl_ adGetState (Unchanged) Prototype:

s32 adl_adGetState ( adl_adState_t * State ); Gets the A&D volume state.

5.9.9 The adl_ adRecompact (Changed)

Prototype:

s32 adl_adRecompact ( s32 EventHandle ); This function launches the recompaction process.

Old Prototype

// Recompacts the A&D memory s32 sRet = adl_adRecompact (Handler );

New Prototype

// Recompacts the A&D memory s32 sRet = adl_adRecompact (EventHandle );

5.9.10 The adl_ adGetCellList (Unchanged) Prototype:

s32 adl_adGetCellList ( wm_lst_t * CellList ); This function gets the A&D volume current cell list.

Page 51: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:51/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

5.9.11 The adl_ adFormat (Changed) Prototype:

s32 adl_adFormat ( s32 EventHandle ); This function formats the complete A&D volume.

Old Prototype

//Formats the A&D memory s32 sret = adl_adFormat ( void );

New Prototype

//Formats the A&D memory s32 sRet = adl_adFormat (EventHandle );

5.9.12 The adl_ adEventSubscribe (New)

Prototype:

s32 adl_adEventSubscribe ( adl_adEventHdlr_f Handler ); This function subscribes to A&D events service.

5.9.13 The adl_ adEvnetUnsubscribe (New) Prototype:

s32 adl_adEventUnsubscribe ( s32 EventHandle ); This function unsubscribes from A&D events service.

Note: The above APIs cannot be called from a low level interruption handler.

Page 52: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:52/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

6 SDK Tools evolutions

6.1 SDK Setup

The Open AT® setup is re-designed in Open AT® v4.1x:

• Already installed components are automatically detected ;

• No more additional setup script to call from the Cygwin command line ;

• No more manually environment variable update.

Please refer to the Getting Started guide to know how the Open AT® v4 setup runs.

6.2 Sample HTML documentation

To provide more information, and clearer implementation documentation about provided Open AT® samples, a new Sample HTML documentation set is available on Open AT® v4.1x SDK.

Page 53: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:53/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

6.3 Open AT® Settings

A new graphical application is designed to setup the Open AT® v4.1x related environment variables and options.

Figure 1: Open AT® settings window

Please refer to the Tools Manual to know more about the available options the Open AT® Settings application.

Page 54: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:54/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

6.4 Open AT® Project Wizard

The Open AT® SDK setup installs the �Open AT® Project Wizard� application which is used to create an Open AT® Project.

Figure 2: Project wizard window

The wmnew script still exists and additional plug-ins list is provided to link the desired plug-in library to the current project.

The compiler & memory settings are still present. The associates IDE to be used can also be set. The Eclipse IDE has been introduced in Open AT® v4.1x.

The currently supported IDE are:

• Microsoft Visual C++ 6.0 ;

• Eclipse

• Microsoft Visual C++ .NET 2002 ;

• Microsoft Visual C++ .NET 2003.

Page 55: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

Porting Guide From Open AT® v3.10 to Open AT® v4.1x

©Confidential

Page:55/55

This document is the sole and exclusive property of WAVECOM. Not to be distributed or divulged without prior written agreement. Ce document est la propriété exclusive de WAVECOM. Il ne peut être communiqué ou divulgué à des tiers sans son autorisation préalable.

6.5 Eclipse IDE

The Open AT® Project Wizard can be used to select the IDE to be used to run the Open AT® Application. Eclipse IDE will be launched as soon as the project is created.

Please refer to the Tools Manual for more information on how to execute application using Eclipse IDE.

Page 56: Porting Guide from Open AT 3.10 to 4 - hmangas.com · 3.5.1 adl_irqSubscribe (New).....14 3.5.2 adl_irqHandler_f callback type (New) .....14 3.5.3 adl ... IP Internet Protocol IR

WAVECOM S.A. - 3 esplanade du Foncet - 92442 Issy-les-Moulineaux Cedex - France - Tel: +33(0)1 46 29 08 00 - Fax: +33(0)1 46 29 08 08Wavecom, Inc. - 4810 Eastgate Mall - Second Floor - San Diego, CA 92121 - USA - Tel: +1 858 362 0101 - Fax: +1 858 558 5485WAVECOM Asia Pacific Ltd. - Unit 201-207, 2nd Floor, Bio-Informatics Centre – No.2 Science Park West Avenue - Hong Kong Science Park, Shatin

- New Territories, Hong Kong