1
0
mirror of https://github.com/gryf/wmtemp.git synced 2026-05-11 00:43:04 +02:00

12 Commits

Author SHA1 Message Date
gryf fc28caa211 New branch for nouveau driver 2013-10-21 22:20:36 +02:00
gryf fb2374178c README update 2013-10-06 16:23:23 +02:00
gryf d029966151 Added option for reading GPU temperature from sysfs 2013-10-06 16:19:28 +02:00
gryf 85bd74b4f5 Updated README 2013-03-23 12:33:57 +01:00
gryf e707cf4d33 fixed typo 2012-05-30 11:28:46 +02:00
gryf c8ac94080c Added tag 0.1 for changeset 7e2b77c0fa7f 2012-05-30 11:23:30 +02:00
gryf 53e3358e73 Added tag 0.4 for changeset 4d9dcd7e2dca 2012-05-30 11:23:22 +02:00
gryf 4e3058820d removed hgtags 2012-05-30 11:22:48 +02:00
gryf ac503a1ee5 Using NVCtrlLib library instead of nvidia-settings program. Refactoring and
code cleanup. Changed version to 0.4.0
2012-05-30 11:21:27 +02:00
gryf 4e92b6f5ca Added tag help for changeset 1ebdda9bbf87 2012-05-30 11:18:59 +02:00
gryf 0c442e8e90 Reverted code to nvidia-settings approach since nvclock stopped working with
nvidia drivers 295.40. To conserve resources there is delay in running
nvidia-settings utility in contrast to CPU temp readings.
2012-05-30 11:04:50 +02:00
gryf 28d2a7fd2e Attempt to use nvclock code for reading GPU temperature, since running
nvidia-settings couple of times for a second is highly inefficient.
2012-05-30 11:01:21 +02:00
5 changed files with 70 additions and 72 deletions
+2 -2
View File
@@ -1,4 +1,4 @@
This is dead simple Windo Wmaker app for monitoring CPU and GPU temperature. This is dead simple Window Wmaker app for monitoring CPU and GPU temperature.
Hardcoded Core2 and Nvidia GPU support. Based on WMTempMon dockapp. Hardcoded Core2 and Nvidia GPU support. Based on WMTempMon dockapp.
author: roman.dobosz@gmail.com Depends on lmsensors and optionally on nvidia-settings packages.
+1 -1
View File
@@ -366,7 +366,7 @@ void setMaskXY(int x, int y) {
/*******************************************************************************\ /*******************************************************************************\
|* openXwindow *| |* openXwindow *|
\*******************************************************************************/ \*******************************************************************************/
void openXwindow(int argc, char *argv[], char *pixmap_bytes[], char *pixmask_bits, int pixmask_width, int pixmask_height) { void openXwindow(int argc, char *argv[], char *pixmap_bytes[], const char *pixmask_bits, int pixmask_width, int pixmask_height) {
unsigned int borderwidth = 1; unsigned int borderwidth = 1;
XClassHint classHint; XClassHint classHint;
+1 -1
View File
@@ -45,7 +45,7 @@ Display *display;
void AddMouseRegion(int index, int left, int top, int right, int bottom); void AddMouseRegion(int index, int left, int top, int right, int bottom);
int CheckMouseRegion(int x, int y); int CheckMouseRegion(int x, int y);
void openXwindow(int argc, char *argv[], char **, char *, int, int); void openXwindow(int argc, char *argv[], char **, const char *, int, int);
void RedrawWindow(void); void RedrawWindow(void);
void RedrawWindowXY(int x, int y); void RedrawWindowXY(int x, int y);
+6 -8
View File
@@ -2,11 +2,10 @@
* wmtempnv: a sensor monitor for WindowMaker. this little app is mainly based * wmtempnv: a sensor monitor for WindowMaker. this little app is mainly based
* on wmsensormon and other simple dockapps. * on wmsensormon and other simple dockapps.
* *
* version = 0.1 * version = 0.4
* date: Fri Oct 31 20:41:14 CET 2008 @861 /Internet Time/ *
* author: Roman 'gryf' Dobosz * requirements: configured lm_sensors, sensor program and nouveau
* requirements: configured lm_sensors and sensor program, nvidia-settings, cut, *
* grep.
* licence: gpl * licence: gpl
*/ */
@@ -46,7 +45,7 @@ int main(int argc, char **argv){
offset1 = get_offset(temp1, 1); offset1 = get_offset(temp1, 1);
temp2 = get_temp(1); temp2 = get_temp(1);
offset2 = get_offset(temp2, 1); offset2 = get_offset(temp2, 1);
temp3 = get_temp(2); temp3 = get_temp(2) / 1000;
offset3 = get_offset(temp3, 0); offset3 = get_offset(temp3, 0);
counter = 200; counter = 200;
} }
@@ -91,7 +90,6 @@ int get_offset(int temp, int cpu){
} }
} }
void display_values(int temp, int offset, int offset2){ void display_values(int temp, int offset, int offset2){
char text[5], num1, num2, num3, num4; char text[5], num1, num2, num3, num4;
@@ -115,7 +113,7 @@ int get_temp(int core_number){
int core=0; int core=0;
char cmd[] = " "; char cmd[] = " ";
if(core_number==2){ if(core_number==2){
sprintf(cmd, "echo `nvidia-settings -q 'GPUCoreTemp'|grep Attribute|cut -d ':' -f 3|cut -d '.' -f 1`"); sprintf(cmd, "echo `cat /sys/devices/pci0000:00/0000:00:01.0/0000:01:00.0/hwmon/hwmon0/temp1_input`");
}else{ }else{
sprintf(cmd, "echo `sensors |grep 'Core %d'|cut -d ':' -f 2|cut -d '.' -f 1`", core_number); sprintf(cmd, "echo `sensors |grep 'Core %d'|cut -d ':' -f 2|cut -d '.' -f 1`", core_number);
} }
+1 -1
View File
@@ -1,6 +1,6 @@
#define wmtempnv_mask_width 64 #define wmtempnv_mask_width 64
#define wmtempnv_mask_height 64 #define wmtempnv_mask_height 64
static unsigned char wmtempnv_mask_bits[] = { static const char wmtempnv_mask_bits[] = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,