Subject: Re: brightness control on an ibook g4
To: Antoine Reilles <Antoine.Reilles@loria.fr>
From: Michael <macallan18@earthlink.net>
List: port-macppc
Date: 05/10/2005 07:39:16
--Signature_Tue__10_May_2005_07_39_16_-0400_k8SmKL9Ajo2qyOL.
Content-Type: text/plain; charset=US-ASCII
Content-Transfer-Encoding: quoted-printable

Hello,

> The most important is that the abtn key does not work, and that if i
> try to use the brightness keys, it simply looks like it does nothing.
> Typing 5 or 6 times the brightness down or up button simply power down
> the machine, and resets the time and date.
> It's stange, since it is reported to work on linux (and also openbsd,
> but they do use another technique for setting brightness, using
> OF_call_method_1, and not pmu and nvram.

Hmm, I didn't look at this stuff yet. ( but I've got the same hardware
so I'll probably do it when I have time )

> I looked into the linux code, and it seems they do not pass the same
> values as netbsd does for the PMU_SET_BRIGHTNESS command, but use an
> array of values:
>=20
> static int backlight_to_bright[] __pmacdata =3D {
>   0x7f, 0x46, 0x42, 0x3e, 0x3a, 0x36, 0x32, 0x2e,
>   0x2a, 0x26, 0x22, 0x1e, 0x1a, 0x16, 0x12, 0x0e
> };
> can this be the cause of the netbsd problems with abtn ?

Maybe.

> Another problem is that the CPU speed is not well recognized. macosx
> says it is a 800MHz processor, but dmesg on netbsd says 614MHz, and
> the machine is a bit slow.

The detected speed is almost certainly correct - OF simply doesn't start
the CPU at full speed and NetBSD doesn't know (yet) how to change that.

> For my personal use, it's fine like that, it it can help the machine
> to keep cold, and give more autonomy, but is it possible to change for
> the highest speed ?

CPU sleep mode doesn't work yet on this kind of G4, at least it didn't
last time I checked ( about 2 months ago ) so keeping it like this is
probably a good idea, at least until we can get it to cool down properly
when idle.

I have a patch lying around to add a userland interface for the sensor /
fan controller which helps a lot to keep it cool ( by allowing you to
change temperature when the fan kicks in ) but it's not committed yet.=20

have fun
Michael

--Signature_Tue__10_May_2005_07_39_16_-0400_k8SmKL9Ajo2qyOL.
Content-Type: application/pgp-signature

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (NetBSD)

iQEVAwUBQoCdZcpnzkX8Yg2nAQKLiggAjRd/r0Jsrwok5kDsLlgK46lha1QFdTYz
vLBg/uttgzxn+F219J6AItDa6mSK5temhVJWZmc074yQ9CV+JUKjp5HOjIDiTcBe
KigZRMLQUkIiNHCIuHVF+WEyIl8zvHvio7tPLTrHj9g1wAaQPUKEGMRvwkff6g8R
RFTdkhEwk+y522Dt96qJZANYh/wGvJI8elh4lt5LG8bblbxxXAMZbswtDN2xdsff
V9LKiBW1dbfTk6SgLe7Sz9dTcMlFzh0S5sYgPEyAYaoS0vwK677nHS2+t1K6GVcV
rUd9DDzMKfGZ31keDxPHAHpiWLEswXZW9ywMpILHgbGNL5j2cmvVHg==
=hEc2
-----END PGP SIGNATURE-----

--Signature_Tue__10_May_2005_07_39_16_-0400_k8SmKL9Ajo2qyOL.--