# Software exemple.

**URL:** <https://forum.sierrawireless.com/t/software-exemple/4102>\
**Category:** Documentation feedback\
**Created:** [January 14, 2010, 9:16am UTC](https://forum.sierrawireless.com/t/software-exemple/4102 "2010-01-14T09:16:56Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![ANNAT](https://avatars.discourse-cdn.com/v4/letter/a/898d66/32.png) [@ANNAT](https://forum.sierrawireless.com/u/ANNAT)\
**Post date:** [January 14, 2010, 9:16am UTC](https://forum.sierrawireless.com/t/software-exemple/4102/1 "2010-01-14T09:16:56Z")

</div>

Have anybody an exemple of battery charger in openAT software?

---

<div class="post-metadata">

**Author:** ![awneil](https://avatars.discourse-cdn.com/v4/letter/a/49beb7/32.png) [@awneil](https://forum.sierrawireless.com/u/awneil)\
**Post date:** [January 14, 2010, 9:26am UTC](https://forum.sierrawireless.com/t/software-exemple/4102/2 "2010-01-14T09:26:58Z")

</div>

Look at the Application Notes…

---

<div class="post-metadata">

**Author:** ![ANNAT](https://avatars.discourse-cdn.com/v4/letter/a/898d66/32.png) [@ANNAT](https://forum.sierrawireless.com/u/ANNAT)\
**Post date:** [January 14, 2010, 10:01am UTC](https://forum.sierrawireless.com/t/software-exemple/4102/3 "2010-01-14T10:01:13Z")

</div>

Yes, I look there but I couldn’t find anything. I’m trying to undestand, how can I program battery managment by using open AT libraryies, but I have some erros.

Anna.

---

<div class="post-metadata">

**Author:** ![awneil](https://avatars.discourse-cdn.com/v4/letter/a/49beb7/32.png) [@awneil](https://forum.sierrawireless.com/u/awneil)\
**Post date:** [January 14, 2010, 10:13am UTC](https://forum.sierrawireless.com/t/software-exemple/4102/4 "2010-01-14T10:13:37Z")

</div>

> [@ANNAT](#):
>
> I’m trying to undestand, how can I program battery managment by using open AT libraryies, but I have some erros.

Yes, I know - but you haven’t answered my question yet: [viewtopic.php?f=36&t=4470&p=17997#p17998](http://www.wavecom.com/modules/movie/scenes/forums/viewtopic.php?f=36&t=4470&p=17997#p17998)

There’s no point going off on a tangent before you know what the actual problem is!

---

<div class="post-metadata">

**Author:** ![awneil](https://avatars.discourse-cdn.com/v4/letter/a/49beb7/32.png) [@awneil](https://forum.sierrawireless.com/u/awneil)\
**Post date:** [January 14, 2010, 11:01am UTC](https://forum.sierrawireless.com/t/software-exemple/4102/5 "2010-01-14T11:01:14Z")

</div>

> [@ANNAT](#):
>
> I’m trying to undestand, how can I program battery managment by using open AT libraryies

There is no spedific API for battery charging; so you just have to use AT Commands. 😠  
See: [viewtopic.php?f=3&t=3595](http://www.wavecom.com/modules/movie/scenes/forums/viewtopic.php?f=3&t=3595)

> [@](#):
>
> but I have some erros.

If you have +CME ERRORS, then those are responses to the AT Commands; they have nothing specifically to do with Open-AT or ADL - you would get exactly the same response if you entered the same command manually at the same point;

If you have error results in the API return codes, then the code tells you what the error is - and it probably has nothing to do with the spedific AT command.

---

<div class="post-metadata">

**Author:** ![awneil](https://avatars.discourse-cdn.com/v4/letter/a/49beb7/32.png) [@awneil](https://forum.sierrawireless.com/u/awneil)\
**Post date:** [January 15, 2010, 10:35am UTC](https://forum.sierrawireless.com/t/software-exemple/4102/6 "2010-01-15T10:35:15Z")

</div>

> [@ANNAT](#):
>
> Yes, I look there [Application Notes] but I couldn’t find anything. I’m trying to undestand, how can I program battery managment by using open AT libraryies, but I have some erros.

> [@awneil](#):
>
> There is no spedific API for battery charging; so you just have to use AT Commands. 😠

The AT Commands User Guidelines document has a whole chapter describing the charging process - including an example of using the AT Commands, and interpreting the Responses.

Reference: WM\_ASW\_OAT\_UGD\_015  
Revision: 001  
Date: 4 Jan 2005

The document is listed right at the bottom of the Application Notes page as “AT implementation of GPRS, PLMN, AEC, Battery & USSD”.

---

<div class="post-metadata">

**Author:** ![davidc](https://avatars.discourse-cdn.com/v4/letter/d/a183cd/32.png) [@davidc](https://forum.sierrawireless.com/u/davidc)\
**Post date:** [January 15, 2010, 10:28pm UTC](https://forum.sierrawireless.com/t/software-exemple/4102/7 "2010-01-15T22:28:44Z")

</div>

Hiya,

Just to make it obvious: There is NO API for battery management - you have to write your own state machine routine to manage battery states, and use the AT commands referred to by awneil to control the battery charger sub-system.

Once you do that, it all works reasonably well…

ciao, Dave

---

<div class="post-metadata">

**Author:** ![awneil](https://avatars.discourse-cdn.com/v4/letter/a/49beb7/32.png) [@awneil](https://forum.sierrawireless.com/u/awneil)\
**Post date:** [January 15, 2010, 10:41pm UTC](https://forum.sierrawireless.com/t/software-exemple/4102/8 "2010-01-15T22:41:47Z")

</div>

Alternatively, just use an external battery charger…
