Hopefully someone here could help. I need to debug, but I don't know much about perl.
I bought a cheap USB thermometer:
http://www.amazon.com/dp/B002VA813U?tag=grepular02-20
And found directions for use (for Linux) here:
https://grepular.com/Using_Linux_to_Monitor_Room_Temperature_Remotely_and_Ch...
On a CentOS 6 machine, I have connected the USB device (it shows here as "Microdia":
[root@farm2 scripts]# lsusb Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub Bus 001 Device 002: ID 8087:0020 Intel Corp. Integrated Rate Matching Hub Bus 002 Device 002: ID 8087:0020 Intel Corp. Integrated Rate Matching Hub Bus 001 Device 003: ID 0424:2514 Standard Microsystems Corp. USB 2.0 Hub Bus 001 Device 006: ID 0c45:7401 Microdia
With CPAN, I installed the Perl module Device::USB::PCSensor::HidTEMPer, as directed. That seemed to be successful.
Now my perl script (as copied from grepular.com, see above) gives no error messages about missing modules. But I should get a temperature reading as output. Instead, I get no output at all.
When I add to the script this: print $pcsensor; I get this as output: Device::USB::PCSensor::HidTEMPer=HASH(0x14d8900) But this: $pcsensor->list_devices(); gives no output.
How could I debug this?
- Jussi
Do you find a temper-poll script in /usr/local/bin/ ? (I found that mentioned at https://github.com/padelt/temper-python )
This isn't really CentOS-specific. If you peruse further down the page you linked, one of the commenters describes the exact symptoms you're seeing, but they were running Ubuntu 12.04 LTS.
On 23.3.2014 16.29, Darr247 wrote:
Do you find a temper-poll script in/usr/local/bin/ ? (I found that mentioned athttps://github.com/padelt/temper-python )
No. That seems to be a different approach in using the thermometer. The one I tried was made with perl, temper-poll is python.
I tried the python scripts too, but stumbled on problems there, too. The basic problem may be that the thermometer behavior has changed in the new models, and the third party scripts have stopped working.
This isn't really CentOS-specific. If you peruse further down the page you linked, one of the commenters describes the exact symptoms you're seeing, but they were running Ubuntu 12.04 LTS.
Yes, I found the description of symptoms, but no solution was mentioned.
- Jussi