Commit Graph

1176 Commits

Author SHA1 Message Date
Martin Ling
23d69bf90c New method to test RTC oscillator. 2025-11-27 04:41:09 +00:00
Michael Ossmann
cde5d754d3 Remove 32 kHz oscillator self-test
Reliable oscillator start-up requires several hundred milliseconds which
is longer than we are willing to wait at every boot. We could add an
on-demand test in the future instead of an automatic self-test.
2025-11-25 20:31:44 -05:00
Michael Ossmann
95e7e2a009 Fix readsel for RFFC5072 device ID read 2025-11-25 20:13:01 -05:00
Michael Ossmann
4832619823 Use MAX2831 RSSI mux and ADC for selftest
Co-authored-by: Martin Ling <martin-git@earth.li>
2025-11-25 20:12:27 -05:00
Michael Ossmann
29be31bf71 Add hackrf_debug option to read ADC
Co-authored-by: Martin Ling <martin-git@earth.li>
2025-11-25 20:08:20 -05:00
Michael Ossmann
785c068f91 Change Praline USB product string to "HackRF Pro" 2025-11-24 21:33:21 -05:00
Michael Ossmann
409acbc3c9 Add support for HackRF Pro (code name: Praline)
Co-authored-by: mndza <diego.hdmp@gmail.com>
Co-authored-by: Martin Ling <martin-git@earth.li>
Co-authored-by: Antoine van Gelder <antoine@greatscottgadgets.com>
2025-11-24 20:53:41 -05:00
Martin Ling
2d2b6231fb Bump CMake minimum version to 3.10. 2025-09-19 01:12:24 +01:00
Martin Ling
5c39452040 Bump CMake minimum version to 3.5.0.
This is the minimum now accepted by latest CMake releases.
2025-09-16 19:00:49 +01:00
mndza
cae8060d0d firmware: disable rffc5071 dithering, tune to nearest 625000 Hz step 2025-08-21 10:04:45 +02:00
mndza
5520f8467c firmware: round to nearest frequency when tuning 2025-08-19 11:40:09 +02:00
mndza
2e6bb0ab68 firmware: rffc5071 synth configuration accepts Hz instead of MHz 2025-08-19 11:40:09 +02:00
mndza
ac0552a5b9 firmware: optimize and rename rffc5071 synth config function 2025-08-19 11:40:08 +02:00
mndza
d3ee417807 firmware: fix max283x fractional long division 2025-08-19 11:17:04 +02:00
mndza
32870ad486 firmware: no division when calculating n_lo in RFFC5071 synth 2025-08-19 11:17:04 +02:00
Mike Walters
3b5cd8f889 Fix DFU CRC errors
Previously we were calculating the dfu-suffix CRC and then modifying the
image, invalidating the check.

This re-orders the operations to apply the boot image header first and
then run dfu-suffix.
2025-05-22 10:04:40 +01:00
gullradriel
9bdf731fc0 added memory clobber to prevent memory reordering 2024-12-18 17:01:18 +01:00
gullradriel
039ab0de46 define replacement for enable and disable irq for m0 2024-12-17 22:00:47 +01:00
Michael Ossmann
cfdfe8a1aa Merge pull request #1517 from martinling/locking-api
Add a shim header to support locking without ldrex/strex
2024-12-17 12:14:03 -05:00
Martin Ling
f3e7d10d07 Add comment about constraints on locking primitives. 2024-12-16 21:19:12 +00:00
Martin Ling
a272e97fda Include nvic.h via the dispatch headers. 2024-12-16 21:14:16 +00:00
gullradriel
46f43c3a9e fix compilation warnings (#1516)
Co-authored-by: gullradriel <gullradriel@no-mail.com>
2024-12-16 19:28:16 +00:00
Martin Ling
b9945de490 Add a shim header to support locking without ldrex/strex.
Required to allow the USB queue code to be built for the M0.
2024-12-16 19:15:08 +00:00
Michael Ossmann
db884152dc Merge pull request #1513 from martinling/sgpio-doc-fix
Update SGPIO code documentation
2024-12-05 11:31:16 -05:00
Michael Ossmann
75431531f2 Merge pull request #1510 from martinling/sgpio-deadline-check
SGPIO deadline check
2024-12-05 11:30:06 -05:00
Martin Ling
8b5a10c26c Update SGPIO code documentation. 2024-12-04 16:10:07 +00:00
bernd-herzog
3175c47372 added AGM CPLD to portapack detect routine 2024-12-01 10:29:25 +01:00
Martin Ling
03551cb1fd Detect whether the M0 missed its deadline.
Counter-intuitively, this actually saves us two cycles because we unroll
the first iteration of the loop that spins on the interrupt flag, saving
a branch in the case that the flag is clear the first time.
2024-11-26 19:34:29 +00:00
Martin Ling
d21f01f7b4 In conditional branch table, list one destination per line, in order. 2024-11-26 19:04:42 +00:00
Michael Ossmann
413409760a Set version to 2024.02.1+ 2024-02-23 13:09:46 -05:00
Michael Ossmann
109d7c025c Set version to 2024.02.1 2024-02-22 14:11:01 -05:00
Michael Ossmann
24ac1edf5a Support detection of HackRF One r10 2024-02-21 23:48:54 -05:00
Michael Ossmann
93d9f9b45c Use 10-bit ADC value for pin strap detection
Previously we thought we were configuring the ADC for 8-bit values, but
we did so incorrectly. We were throwing away the top two bits of a
10-bit value. This never caused a problem because the only fixed
voltages we used were at the extreme minimum or maximum of the ADC
range.
2024-02-21 23:29:27 -05:00
Martin Ling
72a0a01190 Revert "Reduce firmware USB transfer size from 16KB to 8KB."
This reverts commit fefa4f0e45.
2024-02-08 01:07:11 +00:00
Jonathan Suite
dab548bf29 Firmware updates to allow fine-grained control of biast from command line (#1314)
* Initial commit of hackrf_biast

* Cleaned up hackrf_biast

* Cleaned up usage info

* Include getopt.h for non-GNU systems

* Add support for overriding HackRF's default antenna power behavior in firmware.  Add support for specifying antenna power behavior in libhackrf.

* Moved bias tee config routines into user_config.c, cleaned up operation of hackrf_biast

* hackrf_biast now calls usage() and exits when invoked with no arguments

* Fixed minor documentation error in usage()

* minor syntax cleanup

* Add some documentation to the host API call

* Add proper declaration magic in hackrf.h to hackrf_set_user_bias_t_opts() to appease Visual Studio

* Documentation changes suggested by @martinling

* Moved bias t setting above switch statement, removed line that explicit turned bias t off when entering OFF mode

* Change hackrf_set_user_bias_t_opts() to use a friendly struct() instead of a bitmask.  User friendliness fixes to hackrf_biast options.  More clang-format appeasement.

* Removed support for integer mode args from hackrf_biast

* clang-format error fixes

* Tweaked position of comment for clang-format v14

* Reformat files with clang-format v14 instead of 16

* Remove internal numeric modes for bias T settings

Co-authored-by: Martin Ling <martin-github@earth.li>

* Fix documentation error in hackrf_biast.c

---------

Co-authored-by: Martin Ling <martin-github@earth.li>
2023-09-13 11:15:30 -04:00
Jacob Graves
189b5bf693 wrap clkin init in r9 board check (#1307) 2023-04-19 13:32:32 -04:00
Michael Ossmann
00253b02e1 set version to 2023.01.1+ 2023-02-08 14:03:06 -05:00
Michael Ossmann
d9ebb089a5 set version to 2023.01.1 2023-02-01 00:22:29 -05:00
Michael Ossmann
3796bc94d8 h1r9: check firmware running on r9 for r9 support
Previously we checked for OG support instead of r9 support because we
didn't yet have a way to tag firmware binaries with support for multiple
platforms.
2023-01-08 08:27:28 -05:00
Michael Ossmann
c19f85ef24 h1r9: use single SSP configuration for MAX283x
During r9 hardware development it was thought that the MAX2839 would use
a different GPIO pin for chip select, but it ended up being the same pin
as is used for MAX2837 on other hardware revisions.

This takes the MAX283x abstraction a bit further and fixes a bug with
hackrf_debug -m.
2023-01-08 08:21:27 -05:00
Mike Walters
8051675c60 h1r9: add R9 to supported platforms 2023-01-06 14:40:55 +00:00
Michael Ossmann
ff4e1107f3 h1r9: fix clkout PLL source bug 2023-01-06 14:33:56 +00:00
Michael Ossmann
bdb6000bb4 h1r9: fix inverted spectrum on TX
Unify and clean up the firmware spectrum inversion handling for all
hardware platforms.
2023-01-06 14:33:56 +00:00
Michael Ossmann
50a2e9dd56 h1r9: update clock drive strength for spin C 2023-01-06 14:33:56 +00:00
Mike Walters
bfe882a2fa h1r9: add MAX283x abstraction layer 2023-01-06 14:33:53 +00:00
Michael Ossmann
24f2c1d073 h1r9: MAX2839: always use the low LNA band 2023-01-06 14:33:53 +00:00
Michael Ossmann
51bae663fc h1r9: update pin assignments for board spin B 2023-01-06 14:33:53 +00:00
Michael Ossmann
dc67fbd2ee h1r9: fix Opera Cake time mode compatibility
TIMER3 match register 3 was interfering with SCT, fixed by turning off
all ORing of timer outputs with SCT outputs.
2023-01-06 14:33:53 +00:00
Michael Ossmann
7b5d8da821 h1r9: swap RX Q inversion 2023-01-06 14:33:53 +00:00
Michael Ossmann
b15509c2d9 h1r9: MAX2839: emulate MAX2837 RX gain configuration 2023-01-06 14:33:53 +00:00