Skip to content

Add support for reading transceiver temperature#1792

Open
martinling wants to merge 7 commits into
greatscottgadgets:mainfrom
martinling:max283x-temp
Open

Add support for reading transceiver temperature#1792
martinling wants to merge 7 commits into
greatscottgadgets:mainfrom
martinling:max283x-temp

Conversation

@martinling

@martinling martinling commented Jul 1, 2026

Copy link
Copy Markdown
Member

All the MAX283x chips include a built-in temperature sensor, but we've never had support for reading it out in the standard firmware.

This PR adds:

  • Support for reading temperature on MAX2837, MAX2839 and MAX2831.
    • Switches the RSSI MUX to output the analog temperature, and samples with the LPC43xx ADC, giving ~0.3 degrees per LSB.
  • A new hackrf_read_temperature function to libhackrf.
  • Transceiver temperature to hackrf_info:
$ hackrf_info 
hackrf_info version: git-6d545835
libhackrf version: git-6d545835 (0.10.0)
Found HackRF
Index: 0
Serial number: 0000000000000000977c64de390d7813
Board ID Number: 5 (HackRF Pro)
Firmware Version: git-8dbb3475 (API:1.13)
Part ID Number: 0xa0000a30 0x00664f62
Hardware Revision: r1.2
Hardware appears to have been manufactured by Great Scott Gadgets.
Hardware supported by installed firmware:
    HackRF One
    HackRF Pro
Transceiver temperature: 24°C
There is 1 other device on the same USB bus.
You may have problems at high sample rates.

@martinling

Copy link
Copy Markdown
Member Author

@miek I've revised this to use the same reading method on all boards - connect the analog temperature output to the LPC43xx ADC and read it that way. That gets us better resolution than was possible with the built in 5-bit ADC on the MAX2837 and MAX2839.

I'm getting responsive and generally similar readings on HackRF One r4 & r9, HackRF Pro, and rad1o, but the absolute numbers feel a bit high, so I think we still need to do some calibration.

@martinling martinling added this to the harmony milestone Jul 14, 2026
@martinling
martinling marked this pull request as ready for review July 25, 2026 20:49
@martinling

Copy link
Copy Markdown
Member Author

I've calibrated this as best as I can with a temperature probe and a hot plate. Refinements welcome :)

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants