STRUCT W1_THERM_FAMILY_DATA(9)
π struct w1_therm_family_data(9) β device data, but make it make sense
okay bestie, welcome to the Kernel API Manual β¨ today's main character is struct w1_therm_family_data, which is literally just a little bundle of device data for the w1_therm world. it's giving β¨scratchpad-coreβ¨ and honestly? we're obsessed π«Ά
πΈ NAME πΈ
struct w1_therm_family_data β device data π (yes that's it, that's the whole vibe)
β¨ SYNOPSIS β¨
here's the actual shape of it, no cap, copy it exactly:
struct w1_therm_family_data {
uint8_t rom[9];
atomic_t refcnt;
int external_powered;
int resolution;
int convert_triggered;
int conv_time_override;
unsigned int features;
struct w1_therm_family_converter *specific_functions;
};
π Members π
okay so every field gets its own little moment π
romβ the ROM device id π (that's the 64bit Lasered ROM code plus 1 CRC byte, so nine whole bytes of identity, slay)refcntβ the ref count π’ literally what it saysexternal_poweredβ power situation check β‘1= device powered externally,0= device parasite powered,-x= error or undefined (π so if you see a negative, bestie, something is not okay)resolutionβ the current device resolution ποΈconvert_triggeredβ conversion state of the device π₯conv_time_overrideβ user selected conversion time, orCONV_TIME_DEFAULTβ±οΈfeaturesβ bit mask π β enable temperature validity check, poll for completionspecific_functionsβ pointer to struct of device specific function ππ«Ά
π¦ SEE ALSO π¦
the whole friend group, fr fr π β starting with the kernel file ./drivers/w1/slaves/w1_therm.c:
struct w1_therm_family_converter(9)struct therm_info(9)reset_select_slave(9)convert_t(9)read_scratchpad(9)write_scratchpad(9)copy_scratchpad(9)recall_eeprom(9)read_powermode(9)trigger_bulk_read(9)w1_therm_add_slave(9)w1_therm_remove_slave(9)w1_DS18B20_convert_temp(9)w1_DS18S20_convert_temp(9)w1_DS1825_convert_temp(9)device_family(9)bus_mutex_lock(9)check_family_data(9)bulk_read_support(9)conversion_time(9)temperature_from_RAM(9)int_to_short(9)w1_poll_completion(9)
ngl this whole page has zero drama and 100% struct energy β but that's kind of iconic in its own way ππ
okay that's the whole page, bye bestie πβ¨ this cutie lives in ./drivers/w1/slaves and the manual is dated October 2026, signed off as struct w1_therm_family_data(9) β periodt ππ
π¦ 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