View Single Post
Old 08-28-2010, 11:39 AM   #66
Mackx
Guru
Mackx is a splendid one to beholdMackx is a splendid one to beholdMackx is a splendid one to beholdMackx is a splendid one to beholdMackx is a splendid one to beholdMackx is a splendid one to beholdMackx is a splendid one to beholdMackx is a splendid one to beholdMackx is a splendid one to beholdMackx is a splendid one to beholdMackx is a splendid one to behold
 
Posts: 998
Karma: 19985
Join Date: Dec 2008
Location: Netherlands
Device: iRex DR1000S
Quote:
Originally Posted by CoolDragon View Post
Hi Mackx,

Where is the code/script related to this analysis?
The behaviour is in: \4.0\iRex\sysd\src\system.c.
103: #define IDLE_TIMEOUT_SEC 5

296: g_idle_time_source = g_timeout_add_seconds(IDLE_TIMEOUT_SEC, on_idle_timeout, NULL);

2324: static gboolean on_idle_timeout(gpointer data)
2361: do_idle();

2653: // call idle script and wait for it to return
2654: gchar *command = g_strdup_printf("idle.sh %d", min_before_standby);
2655: sys_spawn_sync(command);

idle.sh can be found here: \4.0\iRex\sysd\data\idle.sh
Which contains:
10: hwclock -s -u

I assume that this command stops the cpu clock, stalling all processing. It will presumally also trigger a special DRAM refresh mode to preserve the ram-content. Since the cpu stopped, power consumption is very low. An external processor (I assume there is a separate display processor that controls the eInk-screen, pre-processes the wacom layer events and checks the keys.) can get the main cpu out of the low-power mode by triggering an external interrupt on the main cpu.

Note that this is all based on interpreting the code/scripts and some knowledge on consumer electronics hardware.

Hope this helps.
Mackx is offline   Reply With Quote