Skip to content

Cannot get temperature of a tempfile on widget but with cat I can #498

Open
@gcarlos64

Description

@gcarlos64

Hi, I'm trying to use the temperature widget but get only "N/A" temperature. My widget config is:

   timeout = 5,
   tempfile = "/sys/class/hwmon/hwmon1/temp1_input",
   settings = function()
       widget:set_markup("<span foreground='#F0544C'> CPU_TEMP:</span> " .. coretemp_now .. "°C ");
   end

When I cat this tempfile I get the correct temperature of my CPU (I got this tempfile over lm-sensor "debug").
My widget works when the tempfile is on /sys/devices/virtual/thermal/thermal_zone* path, but don't have any temp file of my cpu and gpu over here.

Awesome and lua versions:

awesome v4.3 (Too long)
 • Compiled against Lua 5.3.5 (running with Lua 5.3)
 • D-Bus support: ✔
 • execinfo support: ✔
 • xcb-randr version: 1.6> gdfsg
 • LGI version: 0.9.2
$ lua -v
Lua 5.4.2  Copyright (C) 1994-2020 Lua.org, PUC-Rio> gdfsg

So, I don't know if it's a bug or if I did something wrong, so sorry if it's not pertinent.
Since now, thanks for the help!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions