Patrick Mahoney wrote: > > Hello pple, > > My setup: MPC850 on a RPXlite_dw board. > > My problem: > > I am trying toggle between power saving modes and evaluate the current > drops with an ampermeter. > > I succeeded in switching to several power modes, but each time i > switch, my serial connection dies, even if i switch to the 'normal > low mode', which is supposed to keep all functionnalities present. > > I am looking to use the PIT to automatically bring back the chip to > normal full power mode. > > I tried the following: > > init_timer(&timer); > timer.expires=1000; > timer.function=timer_handler; > add_timer(&timer); > > without success. The kernel oops'es everytime. Ive been browsing the > kernel sources, but have yet to see where the PIT was > initialized/used. > > Would anyone have successfully used the several power modes of the > mpc850 (or equivalent) through linux 2.4? If so, is there any code > snippet available? > I have played with some of the power saving modes on our custom 850 board and have had no problems. I have toyed with the Doze High and Doze Low modes in the idle loop. Attached is a hacked up idle loop for kernel 2.4.19 that works for me. Do you have the SCCR[PRQEN] bit set? Is there any particular reason you want to wake up the processor with the PIT instead of just letting any old interrupt wake it up? > Also, do you have any idea as to why the serial connection dies? Is it > a uart syncing -type problem? I'm not sure but could the SCCR[CRQEN] bit not being set and a normal low clock speed set to low to allow the CPM to work properly cause this? > > Best regards, > > Pat Mahoney > You should be able to drop my idle.c in place of the old one. To disable my hack just comment out the #define MPC8XX_POWERSAVE . My comments shouldn't be to hard to understand. Also I have the SCCR[PRQEN] and the SCCR[CRQEN] bits set. Please let me know how this works. Conn -- ***************************************************************** If you live at home long enough, your parents will move out. (Warning they may try to sell their house out from under you.) ***************************************************************** Conn Clark Engineering Stooge clark@esteem.com Electronic Systems Technology Inc. www.esteem.com