ADC Home > Reference Library > Technical Notes > Legacy Documents > Hardware & Drivers >

Legacy Documentclose button

Important: This document is part of the Legacy section of the ADC Reference Library. This information should not be used for new development.

Current information on this Reference Library topic can be found here:

PowerBook Miscellanea (Cold Serial in the Morning)


This Technical Note describes some nonintuitive ramifications of working with a battery-powered computer.

[Oct 01 1992]

It Feels Like I'm Floating

You may have problems connecting RS-232 from PowerBook to PowerBook or from PowerBook to other battery-powered device if your connection is not properly grounded. This will result in unacceptable noise in your signal or a complete failure in the two devices to interpret the transmitted voltage levels correctly. Serial communications using RS-232 voltage levels depend on reference to ground. Because the PowerBooks are freestanding battery-powered devices, they are properly grounded with respect to RS-232 only when the cable converting their RS-422 to RS-232 also connects to a proper signal ground and shield ground. (RS-422 uses balanced-pair signals and does not have this problem.) This is a common cause of your program getting stuck in the vSyncWait routine as the serial driver is waiting for character transmission to complete while the SCC waits for an appropriate DTR or CTS that can't be seen due to a lack of proper ground reference.

To remedy this problem, you will need to make sure the cable you are using connects the signal and shield grounds to both devices and that at some point these grounds are connected to an actual grounding source (grounding strap, ground plug, or similar "metal pipe into the planet"). Plugging in the wall power adapter will have no effect on this problem--it provides no grounding to the PowerBook.

Back to top

AT or Not AT?

PowerBook modem has been designed with a minor deviation from the Hayes modem command set standard. The Hayes command set deviation is documented on page 88 of the FaxModem user's guide. Many programs begin their modem initialization by issuing a modem break command. For these programs, you will need to change the "+++" string in your communication programs to "+++AT<Return>" (6 characters). Additional information about the entire supported AT command set is now available in the PowerBook Modem Guide on the Developer CD.

Back to top

You Light Up My Life (The Charging Process)

The Power Adapter port on the PowerBook has been engineered with a mechanical switch that detects the presence of the adapter. Software detects the insertion of the plug into the PowerBook Power Adapter port, and, during the attempt to charge the battery, the lightning bolt icon that appears in the Battery desk accessory toggles on to indicate that the charging apparatus is attempting to bulk charge the battery. In the status byte returned by BatteryStatus, bit 0 indicates the presence of the physical plug in the power connector. Bit 1 indicates if the charging circuit is set to bulk rate or trickle.

There is no way to determine if the attached charging apparatus is providing current, as the circuit can read only the voltage level of the entire system. Additionally, it might be possible to write a utility that, over time (seconds) and while also watching the power state of the various subsystems, could determine if the unit was gaining a charge. Although a difficult programming problem, this might make a great third-party product.

There are two phases to recharging the battery. The first is bulk recharge and the second is trickle charge. The bulk recharge will bring the battery to an 80 percent charge. It takes 2 hours to get to this 80 percent level when the unit is not being used. The full current level available from the power adapter is used in this phase of the recharge cycle. When the 80 percent level has been reached, the computer will start a trickle recharge. This is a reduced current that allows the battery to reach 100 percent charge without the danger of overcharging.

Back to top

When I Snap My Fingers, You Will Forget...

When the PowerBook enters sleep mode, all subsystems except the memory and the Power Manager are turned off. This means the SCC, being disconnected from power, will no longer be able to drive the DTR lines state despite the setting of csCode 16 to the serial driver to hold DTR.

In addition, when the power is dropped to the internal modem its current settings will be lost also. To work around this if you expect the modem to remember settings across sleeps, you should install a Sleep Queue task to read out the settings just before sleep and then restore settings on system wake-up.

Back to top

Snap, Crackle, Pop

To further power conservation and enhance battery life, the system software detects whether or not the sound chip is being used. If it hasn't been used for a while, power is disconnected from the sound circuitry in order to conserve power. During this process, a click may be heard from the speaker as the speaker coil deenergizes. You can defeat this sound by plugging a minijack into the Sound Output port, thus disconnecting the internal speaker. The electrical discharge and subsequent sound are unfortunately the other side of an engineering trade-off made to help maximize battery life.

Back to top

NiCad Myths and Nightmares

There really is a "charge memory" problem with Nickel-Cadmium batteries! The trouble is that to get that effect you need to get your battery into a geosynchronous orbit, in microgravity, and subject it to extremes of heat and cold while charging for precise times over a period of months. Also, the result of a true "charge memory" effect is a reduction in voltage by a few tenths of a volt, not a change in the amp-hour duration of battery charge. In satellites where this is a concern, a reconditioning cycle is run every year or so! This is not a reasonable concern even if your work routine is the same day to day. The problem is that, for fear of causing a memory problem in NiCad batteries, many people attempt to fully discharge then fully recharge their batteries. This tends to accelerate electrolyte loss and to create the possibility of reverse polarizing individual internal cells--resulting in the reduced battery capacity that these same people claim as evidence of the "memory" effect. You should therefore never attempt to run your battery down for the purpose of "reconditioning" it.

Another possible problem is charging or discharging the battery too fast. In the first case you can generate excessive heat and cause the loss of electrolyte and in the second (by shorting the terminals) you can cause the loss of electrolyte and generate excessive heat. The charger circuit in the PowerBooks as well as the stand-alone battery chargers from Apple are designed to bulk charge the battery as fast as possible without overheating, then to trickle charge up to their full charge.

In general use, you should plug into your wall adapter whenever it is available, whether using the lead-acid battery in the PowerBook 100 or the NiCads in the 140 and 170, and not worry about possible memory effects. If you are looking for a third-party battery charger, stay away from bulk chargers and those that "provide" discharge/recharge cycles.

Despite what the manual says, you should never intentionally discharge your battery other than in the course of normal use.


Inside Macintosh, Volume VI, Power Manager

Macintosh PowerBook Family Developer Notes

"Getting the Most Out of Nickel-Cadmium Batteries" by Ken Stuart, QST Magazine, February 1992

PowerBook Modem Guide available on the Developer CD

Back to top


Acrobat gif

Acrobat version of this Note (60K)


Back to top

Did this document help you?
Yes: Tell us what works for you.
It’s good, but: Report typos, inaccuracies, and so forth.
It wasn’t helpful: Tell us what would have helped.