History log of /freebsd-9.3-release/usr.sbin/apmd/apmdlex.l
Revision Date Author Comments
(<<< Hide modified files)
(Show modified files >>>)
# 267654 19-Jun-2014 gjb

Copy stable/9 to releng/9.3 as part of the 9.3-RELEASE cycle.

Approved by: re (implicit)
Sponsored by: The FreeBSD Foundation

# 252181 24-Jun-2013 marius

A set of MFCs allowing stable/9 to be built again on head after r250881:

r250227:
Improve compatibility with recent flex from flex.sourceforge.net.

r250914:
Improve compatibility with old flex and fix build with GCC.

r250926 (partial):
Work around build breakages with GCC 4.2.


# 225736 22-Sep-2011 kensmith

Copy head to stable/9 as part of 9.0-RELEASE release cycle.

Approved by: re (implicit)


# 215676 22-Nov-2010 brucec

Don't generate input() since it's not used.


# 208075 14-May-2010 uqs

Sync apmd(8) with DragonflyBSD, bringing WARNS to 3

Reviewed by: ed (partial, long time ago)


# 76611 15-May-2001 nsayer

Add battery state monitoring to apmd.

The new syntax available in the config file is:

apm_battery [0-9]+(%|[Mm) (dis|)charging { ... }

The stuff in the braces is the same as the existing case. nn% checks for
a certain percentage of life remaining and nnM checks for a cerain
number of minutes remaining. Specifying "discharge" means that you're
interested in knowing when the battery reaches a certain level while AC
power is off, "charging" the opposite.

The man page needs to be updated.

The code can be fooled. If you SIGHUP the daemon and the battery level
matches a rule it will be performed once per SIGHUP. If the battery
level matches a rule and you repeatedly apply and take away AC power,
the rule will be run once per occurance. This, however, is a feature.
:-) The code also only runs when select() times out, so getting APM
events more often than the timeout interval will result in the rules not
being run. These are things that remain to be overcome.


# 50479 27-Aug-1999 peter

$Id$ -> $FreeBSD$


# 48731 10-Jul-1999 iwasaki

This commit was generated by cvs2svn to compensate for changes in r48730,
which included commits to RCS files with non-trunk default branches.


# 48730 10-Jul-1999 iwasaki

The apmd package provides a means of handling various APM events from
userland code. Using apmd.conf, the apmd(8) configuration file, you
can select the APM events to be handled from userland and specify the
commands for a given event, allowing APM behaviour to be configured
flexibly.

Have Fun!

Submitted by: iwasaki, KOIE Hidetaka <hide@koie.org>
Reviewed by: -hackers, -mobile and bsd-nomads ML folks.
Contributed by: Warner Losh <imp@FreeBSD.org>,
Hiroshi Yamashita <bluemoon@msj.biglobe.ne.jp>,
Yoshihiko SARUMARU <mistral@imasy.or.jp>,
Norihiro Kumagai <kuma@nk.rim.or.jp>,
NAKAGAWA Yoshihisa <nakagawa@jp.FreeBSD.org>, and
Nick Hilliard <nick@foobar.org>.