149 Commits

Author SHA1 Message Date
Tobias Schneider
e612dfd8bf fix(usb): Use new USB PID: 0xCC15 2015-08-11 11:19:58 +02:00
Stefan `Sec` Zehl
62799d4158 HACK: wait until si5351 is powered up 2015-07-28 02:51:52 +02:00
Dominic Spill
510dde7485 Update rad1o firmware and libhackrf to use rad1o PID 2015-07-21 21:22:34 +02:00
Tobias Schneider
d7ecde3dc1 hack(hackrf_usb): Disable reading the serial number via IAP 2015-06-13 21:56:18 +02:00
Tobias Schneider
fb219b6f86 fix(usb_descriptor): Let the rad1o be a hack-rf on the usb for now 2015-06-09 14:08:57 +02:00
Tobias Schneider
c79c53c52f chore(name): We are now rad1o 2015-06-07 23:33:24 +02:00
Tobias Schneider
b4b768c76f feat(max2871.c): Set the default values after reset 2015-06-07 13:58:46 +02:00
Tobias Schneider
c05929fe25 fix(common, hackf_usb): Make it compile for rad10 2015-06-06 18:49:09 +02:00
Heikki Hannikainen
35b9e0bea0 Create a #define/constant for the usb_descriptor_string_serial_number length.
Clean up a compilation warning, libusb headers do not like the 'const'.
2015-02-24 01:13:06 +02:00
Heikki Hannikainen
9e92adda79 Refactor obtaining LPC serial number and chip ID into separate API and header/source files. Remove from main().
Create a usb_set_descriptor_by_serial_number(), called before USB stack is started.
2015-02-24 01:12:49 +02:00
Jared Boone
9dbe967bf2 Serial number firmware and host-side changes. Very hacky at this point.
Among the TODOs:
* Refactor obtaining LPC serial number and chip ID into separate API and header/source files. Remove from main().
* Create a usb_set_serial_number_descriptor() or similar function to be called before USB stack is started.
* Ensure USB serial number descriptor is valid even if code forgets to initialize the serial number before the USB stack is started. May be as simple as providing default initializer for usb_descriptor_string_serial_number[].
* Create a #define/constant for the usb_descriptor_string_serial_number length.
* Identify what's causing intermittent crashes in hackrf_transfer when no serial number is specified. I'm probably misusing getopt.
* Permit serial number without leading zeros so you don't have to type as much.
* Add support for serial number argument in other hackrf_* tools.
* Provide libhackrf support for enumerating multiple HackRFs, so that hackrf_info can list all devices. May require an additional libhackrf function, outside of hackrf_open().

...and anything else that makes this less of a hack.
2015-02-23 19:23:31 +02:00
Jared Boone
9bf640895f Quiet warning about unused args in cpld_buffer_refilled(). 2014-11-10 11:11:49 -08:00
Jared Boone
9e95d235b4 Create separate CMake toolchain file. Add references to toolchain file in each firmware CMakeLists.txt. I suspect this can be simpler still, just not sure how, yet... 2014-08-11 16:43:58 -07:00
Jared Boone
2a7ed069c7 Firmware build system is now CMake, and seems much more sane on the whole. 2014-08-11 16:37:14 -07:00
Michael Ossmann
44df9d1f82 si5351c_activate_best_clock_source() when starting RX or TX 2014-07-01 15:21:36 -06:00
Michael Ossmann
f9c90f0d35 commented si5351c_activate_best_clock_source() trying to solve intermittent USB failures 2014-07-01 15:21:31 -06:00
Michael Ossmann
ca04d7c04b activated CLKOUT (always on) and CLKIN (automatically used when detected) 2014-03-14 21:28:13 -06:00
Michael Ossmann
d4a5c2290b replaced set_freq_if() with set_freq_explicit() and implemented explicit tuning option in hackrf_transfer 2014-03-13 16:06:51 -06:00
Michael Ossmann
7c3f6340ed HackRF One antenna port power control in firmware, libhackrf, and hackrf_transfer 2014-03-12 17:21:49 -06:00
Michael Ossmann
dce15fa9f6 firmware support for HackRF One USB ID 2014-03-12 16:21:20 -06:00
Jared Boone
847289bf31 Fix attempt #2 for proper tuning frequency calculation. 2014-02-19 13:17:47 -08:00
Jared Boone
b1eccd4e79 Add integer promotion to tuning frequency calculation. 2014-02-19 13:08:02 -08:00
Jared Boone
a51eb9dd60 Remove usb_bulk_buffer declaration, it was causing duplicate buffers to exist in RAM. Allow ldscript to determine symbol's address by making buffer "extern" only. 2014-02-14 10:48:38 -08:00
Jared Boone
ba2cc32ac6 Combine ram_usb[01] into a single region.
Assign usb_bulk_buffer symbol to ram_usb origin, instead of hard-coding a pointer in C.
Change declaration of usb_bulk_buffer from a pointer to an array.
2014-01-11 17:07:49 -08:00
Jared Boone
63292419c8 Moved M0 memory region to larger first AHB region (32K), moved USB bulk buffers to smaller AHB RAM area. 2014-01-02 15:10:09 -08:00
Jared Boone
7920490f1e Change USB bulk endpoint for baseband data to have only one queue item. Since there are only two baseband buffers, and one is transferring with the codec and the other with USB, enqueueing more than one buffer at a time would result in transferring an incomplete buffer. 2013-12-31 20:34:01 -08:00
Jared Boone
fc5ec03353 Adjust tuning API to use a single 64-bit integer for frequency in Hz, since the Cortex-M4F has good support for uint64_t. 2013-12-31 20:12:47 -08:00
Jared Boone
b285b91e4c Merge remote-tracking branch 'mossmann/master' into jboone_refactor_20130906
Conflicts:
	firmware/common/hackrf_core.h
	firmware/common/rffc5071.c
2013-11-20 18:43:40 -08:00
Jared Boone
986e4dec93 Massive rework of Makefile_inc.mk, to support building of heterogeneous (M4+M0) binaries, and easy switching between RAM and SPIFI-bootable builds. Constructive criticism welcome -- I'm sure there's better ways to do this. 2013-11-20 15:28:28 -08:00
Michael Ossmann
5b14636c2c initial firmware support for HackRF One 2013-11-19 10:01:26 -07:00
Jared Boone
89eafaa79a Remove sample-pair reordering in SGPIO interrupt -- CPLD fixes address this. 2013-11-16 13:32:41 -08:00
Jared Boone
2ed5c9d057 Consolidate hackrf_usb and hackrf_usb_rom_to_ram projects -- with generation of SPIFI binary by default. 2013-09-20 20:16:49 -07:00
Jared Boone
61a8d0f1d6 Move set_transceiver stuff back hackrf_usb.c, since it seems to fit better there. 2013-09-20 14:24:05 -07:00
Jared Boone
7b50dfa12c Factor out USB API for transceiver control into separate files.
Pull out streaming control functions into common/streaming.[ch].
Remove excess #includes in hackrf_usb.c.
2013-09-20 12:54:56 -07:00
Jared Boone
db432842da Sync related Makefiles with changes to hackrf_usb/Makefile. 2013-09-20 12:09:47 -07:00
Jared Boone
9120e0b7ba Extracted USB API for board information into separate files. 2013-09-19 22:45:38 -07:00
Jared Boone
aab36292db Moved USB API for manipulating RF chip registers into separate files. 2013-09-19 22:37:36 -07:00
Jared Boone
cde5e1af8a Extracted USB API for SPI flash erase/write/read into separate files. 2013-09-19 22:29:49 -07:00
Jared Boone
f7a42e0747 Move USB API for CPLD management into separate files. 2013-09-19 19:52:14 -07:00
Jared Boone
82ce660932 Broke some application-specific USB code into separate files within hackrf_usb/. Hoping I can use them as necessary in other projects, or push them into a library eventually. 2013-09-19 19:51:32 -07:00
Jared Boone
5b7b98be6c Clean up SGPIO vector assignment code. 2013-09-17 22:37:40 -07:00
Jared Boone
c06facdd25 Push SGPIO configuration into RF path API. 2013-09-17 22:32:10 -07:00
Jared Boone
2e2275ed51 Pull out leaky tri-state transceiver_mode value from sgpio_configure(), replace with SGPIO_DIRECTION_* #defines. 2013-09-17 22:29:41 -07:00
Jared Boone
aebea16b0f Remove USB endpoint fiddling from baseband_streaming_disable().
Create baseband_streaming_enable() to do SGPIO IRQ and stream enable.
2013-09-17 22:23:18 -07:00
Jared Boone
1ec9f560b4 Move more RF path stuff (initialization and MAX5864 state management) into rf_path.c.
Changed initial RF path mode to lowest power (OFF).
Remove initial MAX2837 IF setting -- it's a waste of effort when the first (and necessary) tuning operation will reset it anyway (perhaps to a different value).
2013-09-17 17:25:00 -07:00
Jared Boone
53415a620d Allow set_transceiver_mode(OFF) to fall through the rest of the function, now that sgpio_configure() is expecting OFF as a value. 2013-09-17 15:33:07 -07:00
Jared Boone
0e8e3c8d53 Push MAX2837 state management into rf_path_set_direction(). 2013-09-17 15:27:16 -07:00
Jared Boone
e02d2f0325 Remove dependencies on application-specific USB descriptors. 2013-09-17 15:13:12 -07:00
Jared Boone
fe2a700f8f Move files that have no application-specific bits (e.g. USB stack, tuning, and RF path APIs) to ../common/. 2013-09-17 15:10:46 -07:00
Jared Boone
78121f5a3e Merge branch 'refs/heads/bgamari_usb_merge' into jboone_refactor_20130906
Conflicts:
	firmware/hackrf_usb/hackrf_usb.c
2013-09-17 13:10:30 -07:00