sht21_temperature_show(9)
π sht21_temperature_show(9) β the Kernel API Manual, bestie edition π
okay so we're deep in the kernel API manual rn and this page is all about sht21_temperature_show β yes that's a mouthful, yes it slays β¨
π NAME π
sht21_temperature_show β literally just here to show the temperature measurement value in sysfs π₯΅π‘οΈ
β¨ SYNOPSIS β¨
ssize_t sht21_temperature_show (struct device *dev , struct
device_attribute *attr , char *buf );
that's the whole vibe right there, no notes π
π¦ ARGUMENTS π¦
devβ the device, bestie. that's it, that's the arg π«Άattrβ the device attribute πbufβ the sysfs buffer (PAGE_SIZE) where the measurement values get written to. so like, that's where the numbers go π
πΈ DESCRIPTION πΈ
the way this function gets called on read access to the temp1_input sysfs attribute β iconic behavior honestly π
it returns the number of bytes written into the buffer, and a negative errno on error π (so if you see a negative number, that's the universe telling you something went wrong, fr fr)
ngl there's no extra lore here β read = call, bytes out or negative errno out. periodt. π
π SEE ALSO π
- the kernel file
./drivers/hwmon/sht21.cποΈ struct sht21(9)sht21_temp_ticks_to_millicelsius(9)sht21_rh_ticks_to_per_cent_mille(9)sht21_update_measurements(9)sht21_humidity_show(9)eic_show(9)
go read those next, iykyk πβ¨ β they're the whole friend group and this function is just one member of it π
and that's a wrap on the sht21_temperature_show(9) lore drop!! this page lives over in ./drivers/hwmon, dated October 2026, and it's brought to you by the Kernel API Manual itself β mwah, sending you all the kernel love, stay hydrated, compile clean, and don't forget to check your errno πππ¦πΈπ
π₯πβπππ§π
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms