Add pcsensor post
This commit is contained in:
parent
d1c7bc623e
commit
52950dc1bf
3 changed files with 60 additions and 27 deletions
2
Gemfile
2
Gemfile
|
@ -3,6 +3,6 @@ source 'https://rubygems.org'
|
|||
gem 'jekyll', '~> 2.5.3'
|
||||
|
||||
group :extensions do
|
||||
gem 'jekyll-assets', '~> 0.13.0'
|
||||
gem 'jekyll-assets', '~> 0.14.0'
|
||||
gem 'yui-compressor', '~> 0.12.0'
|
||||
end
|
||||
|
|
54
Gemfile.lock
54
Gemfile.lock
|
@ -1,22 +1,22 @@
|
|||
GEM
|
||||
remote: https://rubygems.org/
|
||||
specs:
|
||||
addressable (2.3.7)
|
||||
addressable (2.3.8)
|
||||
blankslate (2.1.2.4)
|
||||
celluloid (0.16.0)
|
||||
timers (~> 4.0.0)
|
||||
classifier-reborn (2.0.3)
|
||||
fast-stemmer (~> 1.0)
|
||||
coffee-script (2.3.0)
|
||||
coffee-script (2.4.1)
|
||||
coffee-script-source
|
||||
execjs
|
||||
coffee-script-source (1.8.0)
|
||||
coffee-script-source (1.9.1.1)
|
||||
colorator (0.1)
|
||||
execjs (2.2.2)
|
||||
execjs (2.5.2)
|
||||
fast-stemmer (1.0.2)
|
||||
fastimage (1.6.6)
|
||||
fastimage (1.7.0)
|
||||
addressable (~> 2.3, >= 2.3.5)
|
||||
ffi (1.9.6)
|
||||
ffi (1.9.10)
|
||||
hike (1.2.3)
|
||||
hitimes (1.2.2)
|
||||
jekyll (2.5.3)
|
||||
|
@ -34,49 +34,51 @@ GEM
|
|||
redcarpet (~> 3.1)
|
||||
safe_yaml (~> 1.0)
|
||||
toml (~> 0.1.0)
|
||||
jekyll-assets (0.13.0)
|
||||
jekyll-assets (0.14.0)
|
||||
fastimage (~> 1.6)
|
||||
jekyll (~> 2.0)
|
||||
mini_magick (~> 4.1)
|
||||
sass (~> 3.2)
|
||||
sprockets (~> 2.10)
|
||||
sprockets-helpers
|
||||
sprockets-sass
|
||||
jekyll-coffeescript (1.0.1)
|
||||
coffee-script (~> 2.2)
|
||||
jekyll-gist (1.1.0)
|
||||
jekyll-gist (1.2.1)
|
||||
jekyll-paginate (1.1.0)
|
||||
jekyll-sass-converter (1.3.0)
|
||||
sass (~> 3.2)
|
||||
jekyll-watch (1.2.0)
|
||||
jekyll-watch (1.2.1)
|
||||
listen (~> 2.7)
|
||||
kramdown (1.5.0)
|
||||
liquid (2.6.1)
|
||||
listen (2.8.4)
|
||||
celluloid (>= 0.15.2)
|
||||
kramdown (1.8.0)
|
||||
liquid (2.6.2)
|
||||
listen (2.10.1)
|
||||
celluloid (~> 0.16.0)
|
||||
rb-fsevent (>= 0.9.3)
|
||||
rb-inotify (>= 0.9)
|
||||
mercenary (0.3.5)
|
||||
multi_json (1.10.1)
|
||||
mini_magick (4.2.7)
|
||||
multi_json (1.11.2)
|
||||
parslet (1.5.0)
|
||||
blankslate (~> 2.0)
|
||||
posix-spawn (0.3.9)
|
||||
pygments.rb (0.6.0)
|
||||
posix-spawn (0.3.11)
|
||||
pygments.rb (0.6.3)
|
||||
posix-spawn (~> 0.3.6)
|
||||
yajl-ruby (~> 1.1.0)
|
||||
rack (1.6.0)
|
||||
rb-fsevent (0.9.4)
|
||||
yajl-ruby (~> 1.2.0)
|
||||
rack (1.6.4)
|
||||
rb-fsevent (0.9.5)
|
||||
rb-inotify (0.9.5)
|
||||
ffi (>= 0.5.0)
|
||||
redcarpet (3.2.2)
|
||||
redcarpet (3.3.2)
|
||||
safe_yaml (1.0.4)
|
||||
sass (3.4.9)
|
||||
sprockets (2.12.3)
|
||||
sass (3.4.16)
|
||||
sprockets (2.12.4)
|
||||
hike (~> 1.2)
|
||||
multi_json (~> 1.0)
|
||||
rack (~> 1.0)
|
||||
tilt (~> 1.1, != 1.3.0)
|
||||
sprockets-helpers (1.1.0)
|
||||
sprockets (~> 2.0)
|
||||
sprockets-helpers (1.2.1)
|
||||
sprockets (>= 2.2)
|
||||
sprockets-sass (1.3.1)
|
||||
sprockets (~> 2.0)
|
||||
tilt (~> 1.1)
|
||||
|
@ -85,7 +87,7 @@ GEM
|
|||
hitimes
|
||||
toml (0.1.2)
|
||||
parslet (~> 1.5.0)
|
||||
yajl-ruby (1.1.0)
|
||||
yajl-ruby (1.2.1)
|
||||
yui-compressor (0.12.0)
|
||||
|
||||
PLATFORMS
|
||||
|
@ -93,5 +95,5 @@ PLATFORMS
|
|||
|
||||
DEPENDENCIES
|
||||
jekyll (~> 2.5.3)
|
||||
jekyll-assets (~> 0.13.0)
|
||||
jekyll-assets (~> 0.14.0)
|
||||
yui-compressor (~> 0.12.0)
|
||||
|
|
31
_posts/2015-07-12-porting-pcsensor-to-freebsd.md
Normal file
31
_posts/2015-07-12-porting-pcsensor-to-freebsd.md
Normal file
|
@ -0,0 +1,31 @@
|
|||
---
|
||||
layout: post
|
||||
title: Porting pcsensor to FreeBSD
|
||||
description: "Introducing my port of the pcsensor utility to FreBSD."
|
||||
date: 2015-07-12 18:46:00 CEST
|
||||
category: posts
|
||||
tags: [pcsensor, freebsd, english]
|
||||
comments: true
|
||||
---
|
||||
|
||||
Last week, it got rather hot where I live and so I got interested in measuring the temperature of the room where I keep my NAS and various other devices. I started looking for cheap USB thermometers and quickly found [this one](http://www.amazon.de/gp/product/B009RETJIO). It has some decent reviews and costs only around 16€, which seemed perfect to simply play around with.
|
||||
|
||||
The device only comes bundled with Windows software, but there is an open source utility called `pcsensor` which allows you use it via the command line on Linux. I don't have any Linux devices in the room that I wanted to measure. Since the source code was pretty straightforward and only minimal changes were required to port the utility to FreeBSD, I did just that! You can find the ported source code on [GitHub](https://github.com/nifoc/pcsensor-freebsd).
|
||||
|
||||
{% highlight text %}
|
||||
$ pcsensor -h
|
||||
pcsensor version 1.0.3
|
||||
Aviable options:
|
||||
-h help
|
||||
-v verbose
|
||||
-l[n] loop every 'n' seconds, default value is 5s
|
||||
-c output only in Celsius
|
||||
-f output only in Fahrenheit
|
||||
-a[n] increase or decrease temperature in 'n' degrees for device calibration
|
||||
-m output for mrtg integration
|
||||
-d output with Bus and Device number
|
||||
-D display device list
|
||||
-D[n] specific device number
|
||||
{% endhighlight %}
|
||||
|
||||
If you want to read the temperature from the device, you might have to prefix the call to `pcsensor` with `sudo`.
|
Loading…
Reference in a new issue