Device...Sensor(3pm)

πŸ“¦
version 0.04 Β· 4 versions
, in debian trixie, ubuntu resolute, ubuntu stonking

πŸ’– Device::USB::PCSensor::HidTEMPer::Sensor πŸ’–

okay bestie, so this page is Device::USB::PCSensor::HidTEMPer::Sensor(3pm) from the User Contributed Perl Documentation section, and it's literally the blueprint for every HidTEMPer sensor out there. sit down, grab a strawberry, let's go πŸ“


🌸 NAME 🌸

Device::USB::PCSensor::HidTEMPer::Sensor β€” the generic sensor class. like, the mother of all sensors, the template, the moment. πŸ’…


⭐ VERSION ⭐

Version 0.0301 β€” yes it's giving vintage, and no we're not apologizing. πŸ‘‘


✨ SYNOPSIS ✨

None. That's it. Nothing to see here, moving on. πŸ™ˆ


πŸ¦‹ DESCRIPTION πŸ¦‹

so this module holds a generic class that every single HidTEMPer sensor should inherit from. why? because it keeps all the implemented methods consistent across the board, and it makes it possible to use the exact same code to talk to every supported device. no cap. one codebase, all the sensors, that's the dream. ✨

🌈 CONSTANTS 🌈

  • MAX_TEMPERATURE β€” the highest temperature (in Celsius) this sensor can even detect. it's giving ceiling. 🧚
  • MIN_TEMPERATURE β€” the lowest temperature (in Celsius) this sensor can detect. the floor, fr fr. 🧚

πŸ’œ METHODS πŸ’œ

  • new( $device ) β€” the generic initializing method that creates a sensor object. the glow-up moment where your sensor is born. πŸŽ€

Input parameter

$device = a pre-initialized Device::USB::PCSensor::HidTEMPer::Device that the sensor is connected to. this device is what handles all the communication for you. think of it as the sensor's manager. 😌

  • fahrenheit() β€” reads the current temperature and hands you back the value in fahrenheit degrees. πŸ‡ΊπŸ‡Έβœ¨
  • max() β€” returns the highest temperature (Celsius) the sensor can detect.
  • min() β€” returns the lowest temperature (Celsius) the sensor can detect.
  • celsius() β€” an empty method that should be implemented in each sensor, returning the current degrees in celsius. like, it's a placeholder bestie, it's waiting for its main character moment. 😭

🫢 DEPENDENCIES 🫢

this module internally includes and takes use of the following packages:

use Scalar::Util qw/ weaken /;

and also, this module uses the strict and warning pragmas. safety first, always. πŸ’…


πŸ’€ BUGS πŸ’€

please report any bugs or missing features using the CPAN RT tool. don't suffer in silence, tell on it. πŸ™


πŸ‘‘ FOR MORE INFORMATION πŸ‘‘

None. we said what we said. 🀷


🌸 AUTHOR 🌸

Magnus Sulland < msulland@cpan.org > β€” iconic behavior, thank you for your service. πŸ«‘πŸ’–


✨ ACKNOWLEDGEMENTS ✨

thanks to Elan RuusamÀe for fixing some compatibility issues with perl 5.8. a real one. 🫢


Copyright (c) 2010-2011 Magnus Sulland

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

periodt. πŸ’…


😭 POD ERRORS 😭

hey! so the above document had some coding errors, and they're explained below:

Around line 157:

Non-ASCII character seen before =encoding in 'RuusamΓ€e'. Assuming
UTF-8

not the document exposing itself like that, but okay, we move. πŸ’€


and that's the whole vibe, bestie. this was Device::USB::PCSensor::HidTEMPer::Sensor(3pm), brought to you by perl v5.40.0 on 2024-11-30. mwah, go forth and read your temperatures. πŸ’–πŸŒΈβœ¨
πŸ“¦ where this page comes from