MagSafeポートの電圧を監視し、電圧が一定の変化をするとスクリプトを実行するMacBook用アプリ「SMC Voltmeter」がリリース。

記事内に広告が含まれています。
スポンサーリンク
スポンサーリンク
スポンサーリンク

 MagSafeアダプタの電圧を監視し、MagSafeからの電圧が一定の変化をするとスクリプトを実行するMacBook用アプリ「SMC Voltmeter」がリリースされています。詳細は以下から。


SMC-Voltmeter-Hero


 SMC Voltmeterはインドの開発者Peter(@peterburk)さんが開発したアプリで、MacBookに使用されているMagSafeポートにかかっている電圧を毎秒監視し、電圧に一定の変化があるとそれをトリガーにスクリプトを実行します。


SMC-Voltmeter-Feature

SMC Voltmeter is an app to watch the input voltage on your MagSafe port, log it, graph it, and trigger scripts based on the voltage changing.

[SMC Voltmeter – Peter Burkimsher]

 デフォルトでは電圧が変化するとFinderダイアログをだすコマンドが設定されていますが、BashやApple Scriptを使用してより複雑な事をさせることも可能だそうです。


SMC-Voltmeter-Command-Down

3. What kinds of scripts can I run?

Bash scripts are triggered by the voltage going up or down. If you want to write a more complex script, make it in another file and call that script instead.
Behind the scenes, this uses AppleScript and “do shell script”, which is easier to code than NSTask. Tweak the source code if you want to change that.
[SMC Voltmeter – Peter Burkimsher]

 SMC Voltmeterはソースコードも公開(URLが間違っていますがpngをzipにするとダウンロード可能です)されているので興味のある方は関連リンクからどうぞ。

関連リンク:
SMC Voltmeter – Peter Burkimsher

コメント

タイトルとURLをコピーしました