Stromverbrauch per terminal

N

NOcTua

Aktives Mitglied
Thread Starter
Dabei seit
17.12.2006
Beiträge
463
Reaktionspunkte
5
Hallo,

ich versuche zurzeit ein wenig Strom zu sparen. Dazu möchte ich gerne den Stromverbrauch im Terminal auslesen lassen.

Habe dazu auf dieser Seite einen netten Tipp gefunden.

Doch leider bekomme ich diese fehlermeldung
Code:
awk: syntax error at source line 12
 context is
	 >>> ",tolower($3),100? <<< ?ct[5]/ct[4])
awk: illegal statement at source line 13
Gibt es einen anderen weg es anzeigen zu lassen (am besten jede sehr schnell), oder vielleicht einen tipp den Fehler zu beheben?
 
Ersetz mal in dem Skript das ü (das da definitiv nix zu suchen hat) durch *, dann sollte es funktionieren

MattMacs
 
hmm ... jetzt bekomme ich keine Fehlermeldung, aber auch nicht anderes.
 
na das ist doch schon mal was :D

falls sich bis heute nachmittag kein anderer meldet, schau ich mal nach, sobald ich an mein MBP komme...

was gibt denn '/usr/sbin/ioreg -p IODeviceTree -n "battery" -w 0' aus ?

evtl. hat sich da ja was seit 2003 geaendert

MattMacs
 
Das gibt viel, wirklich sehr viel (für mich) unverständlichen Text aus.

ein ausschnitt:

Code:
  | |   +-o PRT6@6  <class IORegistryEntry, id 0x1000001cd, retain 4>
    | |   +-o PRT7@7  <class IORegistryEntry, id 0x1000001ce, retain 4>
    | +-o HDEF@8  <class IOPCIDevice, id 0x1000001cf, registered, matched, active, busy 0 (8394 ms), retain 10>
    | +-o GIGE@A  <class IOPCIDevice, id 0x1000001d0, registered, matched, active, busy 0 (536 ms), retain 11>
    | +-o SATA@B  <class IOPCIDevice, id 0x1000001d1, registered, matched, active, busy 0 (772 ms), retain 13>
    | | +-o PRT0@0  <class AppleMCP79AHCIPort, id 0x1000001d2, registered, matched, active, busy 0 (124 ms), retain 10>
    | | | +-o PMP@0  <class IOAHCIDevice, id 0x100000256, registered, matched, active, busy 0 (124 ms), retain 13>
    | | |   +-o @0:0  <class IOMedia, id 0x100000267, registered, matched, active, busy 0 (51 ms), retain 10>
    | | |   +-o @0:1  <class IOMedia, id 0x10000026d, registered, matched, active, busy 0 (7 ms), retain 8>
    | | |   +-o @0:2  <class IOMedia, id 0x10000026e, registered, matched, active, busy 0 (19 ms), retain 10>
    | | |   +-o @0:3  <class IOMedia, id 0x10000026f, registered, matched, active, busy 0 (10 ms), retain 9>
    | | +-o PRT1@1  <class AppleMCP79AHCIPort, id 0x1000001d3, registered, matched, active, busy 0 (209 ms), retain 10>
    | |   +-o PMP@0  <class IOAHCIDevice, id 0x100000258, registered, matched, active, busy 0 (209 ms), retain 7>
    | +-o RP01@C  <class IOPCIDevice, id 0x1000001d4, registered, matched, active, busy 0 (556 ms), retain 11>
    | | +-o GFX0@0  <class IOPCIDevice, id 0x1000001d5, registered, matched, active, busy 0 (482 ms), retain 17>
    | |   +-o NVDA,Display-A@0  <class IONDRVDevice, id 0x1000002fe, registered, matched, active, busy 0 (18 ms), retain 10>
    | |   +-o NVDA,Display-B@1  <class IONDRVDevice, id 0x1000002ff, registered, matched, active, busy 0 (7 ms), retain 9>
    | +-o IXVE@10  <class IOPCIDevice, id 0x1000001d6, registered, matched, active, busy 0 (595 ms), retain 11>
    | | +-o IGPU@0  <class IOPCIDevice, id 0x1000001d7, registered, matched, active, busy 0 (514 ms), retain 17>
    | |   +-o NVDA,Display-A@0  <class IONDRVDevice, id 0x1000002c6, registered, matched, active, busy 0 (287 ms), retain 10>
    | |   +-o NVDA,Display-B@1  <class IONDRVDevice, id 0x1000002c7, registered, matched, active, busy 0 (8 ms), retain 9>
    | +-o P4MI@3,3  <class IOPCIDevice, id 0x1000001d9, registered, matched, active, busy 0 (206 ms), retain 8>
    | +-o RP04@15  <class IOPCIDevice, id 0x1000001da, registered, matched, active, busy 0 (743 ms), retain 11>
    | | +-o ARPT@0  <class IOPCIDevice, id 0x1000001db, registered, matched, active, busy 0 (589 ms), retain 11>
    | +-o RP05@16  <class IOPCIDevice, id 0x1000001dc, registered, matched, active, busy 0 (566 ms), retain 11>
    | | +-o FRWR@0  <class IOPCIDevice, id 0x1000001dd, registered, matched, active, busy 0 (460 ms), retain 10>
    | +-o RP06@17  <class IOPCIDevice, id 0x1000001de, registered, matched, active, busy 0 (241 ms), retain 11>
    | | +-o EXCD@0  <class IORegistryEntry, id 0x1000001df, retain 4>
    | +-o pci-bridge@9  <class IOPCIDevice, id 0x1000001e7, registered, matched, active, busy 0 (247 ms), retain 10>
    +-o options  <class AppleEFINVRAM, id 0x100000200, registered, matched, active, busy 0 (1 ms), retain 829>
dons-macbook-pro:~ Don$
 
Also im Systemprofiler steht das auch
 
Zurück
Oben Unten