Commit graph

1470 commits

Author SHA1 Message Date
Antoine van Gelder
2b7ba8d7ab
radio: rename RADIO_BANK_ACTIVE to RADIO_BANK_REQUESTED 2026-07-16 12:31:31 +02:00
Martin Ling
8bfbd716da Add RADIO_CLOCK_CORRECTION register, bump USB API to 1.13. 2026-06-30 14:20:31 +01:00
Martin Ling
dda161cb1f Add multiply & divide implementations for 128-bit unsigned integers. 2026-06-30 12:00:52 +01:00
Martin Ling
74c3b730fa Add 1.63 fixed point type. 2026-06-30 08:44:40 +01:00
Martin Ling
95a30a9840
Merge pull request #1781 from martinling/portapack-detection
Simplify PortaPack detection and init API
2026-06-17 19:07:53 +01:00
Martin Ling
57fc841ddb
Merge pull request #1783 from martinling/i2c-khz
Make I2C startup & clock speed consistent
2026-06-17 10:26:55 +01:00
Michael Ossmann
be669ce370
Merge pull request #1776 from mndza/cic-default-factor
gateware: CIC defaults to the minimum resampling factor
2026-06-16 10:02:49 -04:00
Martin Ling
d6913807a6 Specify I2C clock in kHz, and adjust for CPU clock changes. 2026-06-15 11:58:33 +01:00
Martin Ling
3afd5d2acd Move i2c_bus_start calls out of clock_gen_init and clock_gen_shutdown. 2026-06-15 11:56:10 +01:00
Martin Ling
092d034d80 Simplify PortaPack detection and init API.
Some checks failed
Check code style / clang-format-2 (push) Failing after 12s
Check code style / clang-format-3 (push) Failing after 10s
Check includes / includes-check (HACKRF_ONE, latest) (push) Failing after 7s
Check includes / includes-check (JAWBREAKER, 3.12.0) (push) Failing after 7s
Check includes / includes-check (JAWBREAKER, latest) (push) Failing after 6s
Check includes / includes-check (HACKRF_ONE, 3.12.0) (push) Failing after 5s
Check includes / includes-check (PRALINE, 3.12.0) (push) Failing after 7s
Check includes / includes-check (PRALINE, latest) (push) Failing after 7s
Check includes / includes-check (RAD1O, 3.12.0) (push) Failing after 8s
Check includes / includes-check (RAD1O, latest) (push) Failing after 6s
Check includes / includes-check (UNIVERSAL, 3.12.0) (push) Failing after 7s
Check includes / includes-check (UNIVERSAL, latest) (push) Failing after 4s
Build / host (3.10.0, map[os:macos shell:bash]) (push) Has been cancelled
Build / host (3.16.0, map[os:macos shell:bash]) (push) Has been cancelled
Build / host (3.21.0, -DPKG_CONFIG_EXECUTABLE=C:/vcpkg/installed/x64-windows/tools/pkgconf/pkgconf.exe -DCMAKE_TOOLCHAIN_FILE=C:/vcpkg/scripts/buildsystems/vcpkg.cmake --install-prefix=$env:GITHUB_WORKSPACE/install, map[os:windows shell:pwsh]) (push) Has been cancelled
Build / host (3.21.0, map[os:macos shell:bash]) (push) Has been cancelled
Build / host (4.0.0, -DPKG_CONFIG_EXECUTABLE=C:/vcpkg/installed/x64-windows/tools/pkgconf/pkgconf.exe -DCMAKE_TOOLCHAIN_FILE=C:/vcpkg/scripts/buildsystems/vcpkg.cmake --install-prefix=$env:GITHUB_WORKSPACE/install, map[os:windows shell:pwsh]) (push) Has been cancelled
Build / host (4.0.0, map[os:macos shell:bash]) (push) Has been cancelled
Build / firmware (UNIVERSAL, 3.12.0, macos) (push) Has been cancelled
Build / firmware (UNIVERSAL, latest, macos) (push) Has been cancelled
Build / host (latest, --install-prefix=/usr/local, map[os:windows shell:msys2]) (push) Has been cancelled
Build / host (latest, -DPKG_CONFIG_EXECUTABLE=C:/vcpkg/installed/x64-windows/tools/pkgconf/pkgconf.exe -DCMAKE_TOOLCHAIN_FILE=C:/vcpkg/scripts/buildsystems/vcpkg.cmake --install-prefix=$env:GITHUB_WORKSPACE/install, map[os:windows shell:pwsh]) (push) Has been cancelled
Build / host (latest, map[os:macos shell:bash]) (push) Has been cancelled
Build / firmware (HACKRF_ONE, latest, windows) (push) Has been cancelled
Build / firmware (JAWBREAKER, latest, windows) (push) Has been cancelled
Build / firmware (PRALINE, 3.12.0, macos) (push) Has been cancelled
Build / firmware (PRALINE, latest, macos) (push) Has been cancelled
Build / firmware (PRALINE, latest, windows) (push) Has been cancelled
Build / firmware (RAD1O, latest, windows) (push) Has been cancelled
Build / firmware (UNIVERSAL, latest, windows) (push) Has been cancelled
2026-06-12 17:09:49 +01:00
Martin Ling
42b7f7703d Fix management of CLKOUT/MCU_CLK synth sharing on H1R9. 2026-06-12 16:00:48 +01:00
Martin Ling
9153f3d55e Use PLL B for MCU_CLKIN on Praline.
Some checks failed
Check includes / includes-check (HACKRF_ONE, 3.12.0) (push) Failing after 6s
Check code style / clang-format-2 (push) Failing after 11s
Check code style / clang-format-3 (push) Failing after 9s
Check includes / includes-check (JAWBREAKER, 3.12.0) (push) Failing after 2s
Check includes / includes-check (HACKRF_ONE, latest) (push) Failing after 4s
Check includes / includes-check (JAWBREAKER, latest) (push) Failing after 3s
Check includes / includes-check (PRALINE, 3.12.0) (push) Failing after 3s
Check includes / includes-check (PRALINE, latest) (push) Failing after 3s
Check includes / includes-check (RAD1O, 3.12.0) (push) Failing after 3s
Check includes / includes-check (RAD1O, latest) (push) Failing after 2s
Check includes / includes-check (UNIVERSAL, 3.12.0) (push) Failing after 4s
Check includes / includes-check (UNIVERSAL, latest) (push) Failing after 3s
Build / host (3.10.0, map[os:macos shell:bash]) (push) Has been cancelled
Build / host (3.16.0, map[os:macos shell:bash]) (push) Has been cancelled
Build / host (latest, -DPKG_CONFIG_EXECUTABLE=C:/vcpkg/installed/x64-windows/tools/pkgconf/pkgconf.exe -DCMAKE_TOOLCHAIN_FILE=C:/vcpkg/scripts/buildsystems/vcpkg.cmake --install-prefix=$env:GITHUB_WORKSPACE/install, map[os:windows shell:pwsh]) (push) Has been cancelled
Build / host (latest, map[os:macos shell:bash]) (push) Has been cancelled
Build / host (3.21.0, -DPKG_CONFIG_EXECUTABLE=C:/vcpkg/installed/x64-windows/tools/pkgconf/pkgconf.exe -DCMAKE_TOOLCHAIN_FILE=C:/vcpkg/scripts/buildsystems/vcpkg.cmake --install-prefix=$env:GITHUB_WORKSPACE/install, map[os:windows shell:pwsh]) (push) Has been cancelled
Build / host (3.21.0, map[os:macos shell:bash]) (push) Has been cancelled
Build / host (4.0.0, -DPKG_CONFIG_EXECUTABLE=C:/vcpkg/installed/x64-windows/tools/pkgconf/pkgconf.exe -DCMAKE_TOOLCHAIN_FILE=C:/vcpkg/scripts/buildsystems/vcpkg.cmake --install-prefix=$env:GITHUB_WORKSPACE/install, map[os:windows shell:pwsh]) (push) Has been cancelled
Build / host (4.0.0, map[os:macos shell:bash]) (push) Has been cancelled
Build / host (latest, --install-prefix=/usr/local, map[os:windows shell:msys2]) (push) Has been cancelled
Build / firmware (HACKRF_ONE, latest, windows) (push) Has been cancelled
Build / firmware (JAWBREAKER, latest, windows) (push) Has been cancelled
Build / firmware (PRALINE, 3.12.0, macos) (push) Has been cancelled
Build / firmware (PRALINE, latest, macos) (push) Has been cancelled
Build / firmware (PRALINE, latest, windows) (push) Has been cancelled
Build / firmware (RAD1O, latest, windows) (push) Has been cancelled
Build / firmware (UNIVERSAL, 3.12.0, macos) (push) Has been cancelled
Build / firmware (UNIVERSAL, latest, macos) (push) Has been cancelled
Build / firmware (UNIVERSAL, latest, windows) (push) Has been cancelled
2026-06-11 20:23:35 +01:00
Michael Ossmann
bd2440277d
Merge pull request #1751 from martinling/si5351c-next
Further work on Si5351 driver
2026-06-09 11:27:04 -04:00
Martin Ling
404429de2a
Merge pull request #1753 from martinling/reduce-pins-setup
Reduce dependencies of `pins.c`
2026-06-09 13:57:34 +01:00
Martin Ling
fd470d078d
Merge pull request #1766 from martinling/delay-cleanup
Clean up delay functions
2026-06-09 13:04:48 +01:00
Martin Ling
977a9d24a6 Move ice40-related bits out of pins_setup. 2026-06-08 17:02:59 +01:00
Martin Ling
0585339269 Move cpld_jtag-related bits out of pins_setup. 2026-06-08 17:02:59 +01:00
Martin Ling
d534e1d019 Move mixer-related bits out of pins_setup. 2026-06-08 17:02:59 +01:00
Martin Ling
e3ffbf68f0 Move rf_path-related bits out of pins_setup. 2026-06-08 17:02:59 +01:00
Martin Ling
b533e1c5dc Move sgpio-related bits out of pins_setup. 2026-06-08 17:02:59 +01:00
Martin Ling
9c0a211f13 Move w25q80bv-related bits out of pins_setup. 2026-06-08 17:02:55 +01:00
Martin Ling
a7925bd74e Remove some superfluous spi_bus_setup calls. 2026-06-08 17:02:21 +01:00
Martin Ling
9d6e43a1cb Move max5864-related bits out of pins_setup. 2026-06-08 16:52:16 +01:00
Martin Ling
c77c962b71 Move max283x-related bits out of pins_setup. 2026-06-08 16:52:16 +01:00
Martin Ling
a716b642ec si5351c: Move other globals into driver struct. 2026-06-08 16:31:28 +01:00
Martin Ling
ff052af352 si5351c: Move the clk array into the driver struct. 2026-06-08 16:31:28 +01:00
Martin Ling
595ea6c072 Make switching SPI bus modes automatic. 2026-06-04 17:29:03 +01:00
mndza
e32695e24f
gateware: CIC defaults to the minimum resampling factor 2026-06-03 10:12:36 +02:00
Martin Ling
b86b139305 Express all delays as delay_us() or delay_ms(). 2026-06-02 16:55:17 +01:00
Martin Ling
eb2e6a1c05 Move SSP0 and SSP1 bus instances to spi_ssp.{c,h}. 2026-05-28 16:37:18 +01:00
Michael Ossmann
74d0437e6b
Merge pull request #1761 from martinling/remove-sample-rate-callback
Remove sample rate callback, move radio instance to `radio.c`.
2026-05-28 11:06:47 -04:00
mndza
7cce66a7fa
Fix reads with hackrf_spiflash when size is a multiple of 64 bytes. 2026-05-22 08:18:17 +02:00
Martin Ling
62229fdf73 Remove sample rate callback, move radio instance to radio.c. 2026-05-21 18:40:44 +01:00
Martin Ling
c2262ccda1 si5351c: Add control of MCU_CLKIN output. 2026-05-21 15:34:47 +01:00
Martin Ling
835e7b618a Move LPC43xx I2C instances and configs to ipc_lpc.{c,h}. 2026-05-19 17:57:07 +01:00
Martin Ling
9423133c4b si5351c: Make clk array persistent, setup in init, include OE flags. 2026-05-19 16:57:15 +01:00
Martin Ling
4c69adb9da si5351c: API: change argument of si5351c_clkout_enable to bool. 2026-05-19 16:40:44 +01:00
Martin Ling
50ce90908f si5351c: Wait for SYS_INIT flag to clear during startup. 2026-05-19 16:40:44 +01:00
Michael Ossmann
49bce311e2
Merge pull request #1755 from martinling/font-edit
Add script to extract font data to an image file for editing.
2026-05-18 14:39:04 -04:00
Martin Ling
dc255468b1 Fix up IWYU issues in cpld_jtag.{c,h}. 2026-05-18 17:31:57 +01:00
Michael Ossmann
76dd5916a7
Merge pull request #1752 from martinling/move-cpld-load
Move `cpld_jtag_sram_load` into `cpld_jtag.c`
2026-05-18 11:52:49 -04:00
Michael Ossmann
2d1f53d730
Merge pull request #1750 from greatscottgadgets/old-iwyu
Fix compatibility with older IWYU
2026-05-18 11:42:36 -04:00
Martin Ling
478a520d65 Add script to extract font data to an image file for editing. 2026-05-18 14:42:16 +01:00
Martin Ling
016910567b si5351c: internal: reimplement using register helpers. 2026-05-14 22:25:55 +01:00
Martin Ling
a1cdbaddbf si5351c: internal: Add register definitions and helpers. 2026-05-14 22:25:39 +01:00
Martin Ling
098b9dd9f2 si5351c: API: distinguish between PLL IDs and PLL masks.
We're going to want a type that just identifies one PLL, and is
consistent with how the PLLs are numbered in register settings.

The current si5351c_pll_t is a bitmask which allows referring to
both PLLs. Let's make that a different type, and name things more
clearly when using it.
2026-05-14 22:25:35 +01:00
Martin Ling
d00dae3835 si5351c: API: change terminology to refer to XTAL/CLKIN as "inputs".
There are multiple similar but different things called a "source"
or "clock source", or that are set in a register called "SRC", in the
context of the Si5351 and its usage in HackRF.

One place we can be unambiguous is that there are only two inputs to
the Si5351C itself: XTAL and CLKIN. Let's have a type for that alone,
and name it as such when we use it.

There should be no functional changes in this commit.
2026-05-14 22:24:04 +01:00
Martin Ling
b460014811 Move cpld_jtag_sram_load() into cpld_jtag.c. 2026-05-13 21:52:51 +01:00
Michael Ossmann
db44436fda Remove redundant includes 2026-05-07 19:30:30 -04:00
Michael Ossmann
6ff7f8ed63 Fix IWYU --keep syntax for compatibility with 0.22 2026-05-07 18:56:53 -04:00