Difference between revisions of "GreatFET One"
(start GreatFET device page) |
(reference driver source code) |
||
(5 intermediate revisions by the same user not shown) | |||
Line 2: | Line 2: | ||
| image = [[File:Greatfet_mugshot.png|180px]] | | image = [[File:Greatfet_mugshot.png|180px]] | ||
| name = GreatFET One | | name = GreatFET One | ||
| status = | | status = supported | ||
| source_code_dir = | | source_code_dir = greatfet | ||
| channels = 8 | | channels = 8/4/2/1 | ||
| samplerate = 204MHz max | | samplerate = 40.8/68/102/204MHz max | ||
| voltages = 3.3V | | voltages = 3.3V | ||
| compression = No (packing) | | compression = No (packing) | ||
Line 11: | Line 11: | ||
}} | }} | ||
The '''GreatFET One''' is a USB connected 8 channel logic analyser with | The '''GreatFET One''' is a USB connected versatile tool for USB analysis and other hardware research | ||
and also provides a mode of being an 8 channel logic analyser with a 40.8MHz samplerate and no local sample memory. | |||
Higher samplerates are available when the number of enabled channels gets reduced (up to 204MHz for 1 channel). | |||
Data acquisition employs the SGPIO machinery of the NXP LPC4330 microcontroller. | Data acquisition employs the SGPIO machinery of the NXP LPC4330 microcontroller. | ||
The GreatFET's firmware is also available for other boards which use the same MCU. | The GreatFET's firmware is also available for other boards which use the same MCU. | ||
The device firmware is known for its efficient use of USB communication, streaming capabilities to the host are similar to HackRF One. | The device firmware is known for its efficient use of USB communication, | ||
streaming capabilities to the host are similar to HackRF One. | |||
Transfer rates are a little shy of 42MB/s. | Transfer rates are a little shy of 42MB/s. | ||
The '''greatfet''' sigrok driver supports the operation of these devices in logic analyzer mode. | The '''greatfet''' sigrok driver supports the operation of these devices in logic analyzer mode. | ||
The GreatFET device is exclusively used in continuous mode where sample data gets streamed to the host while the acquisition is executing. | The GreatFET device is exclusively used in continuous mode where sample data | ||
gets streamed to the host while the acquisition is executing. | |||
With 8 channels enabled, sample rates up to 40.8 MHz are supported. | With 8 channels enabled, sample rates up to 40.8 MHz are supported. | ||
When fewer channels are enabled then these can get sampled at higher rates. | |||
The device firmware always captures channel counts that are a power of two. | The device firmware always captures channel counts that are a power of two. | ||
In other words when three channels are enabled, then data is captured for four channels. | In other words when three channels are enabled, then data is captured for four channels. | ||
This is important to keep in mind, as the product of samplerate and channel count must not exceed the USB2.0 bandwidth. | This is important to keep in mind, as the product of samplerate and channel count must not exceed the USB2.0 bandwidth. | ||
The limit is near 336Mbps (depends on the host computer's capabilities). | The limit is near 336Mbps (depends on the host computer's capabilities). | ||
Sample data is "densely packed" but not compressed during USB transmission. | |||
Device firmware can optionally "shift pins" such that sampling e.g. channels 8 through 15 | |||
will only transmit one byte per sample from the device to the host, | |||
omitting the lower byte in the transfer which would carry no user perceivable data, | |||
thus working as efficiently and allowing as high a samplerate as sampling channel 0 through 7 would. | |||
Pin shift counts other than 8 are not usefully applicable. | |||
The sigrok driver supports this feature by responding to the set of | |||
enabled and disabled channels according to users' specs. | |||
Getting more than 8 channels at the same time is currently not supported by | |||
the device's firmware due to the MCU's hardware constraints, and | |||
was prepared but is untested in the sigrok driver. | |||
"Seemingly odd" samplerates are the result of an unusual (rather: unexpected to users) base clock and integer dividers. | "Seemingly odd" samplerates are the result of an unusual (rather: unexpected to users) base clock and integer dividers. | ||
Line 33: | Line 50: | ||
!channels count | !channels count | ||
!max samplerate | !max samplerate | ||
!comment | |||
|- | |||
| style="text-align:center" | 16-9 | |||
| style="text-align:right" | 20.4MHz | |||
| currently unsupported | |||
|- | |- | ||
| style="text-align:center" | 8-5 | | style="text-align:center" | 8-5 | ||
| style="text-align:right" | 40.8 MHz | | style="text-align:right" | 40.8 MHz | ||
| — | |||
|- | |- | ||
| style="text-align:center" | 4-3 | | style="text-align:center" | 4-3 | ||
| style="text-align:right" | 68 MHz | | style="text-align:right" | 68 MHz | ||
| — | |||
|- | |- | ||
| style="text-align:center" | 2 | | style="text-align:center" | 2 | ||
| style="text-align:right" | 102 MHz | | style="text-align:right" | 102 MHz | ||
| — | |||
|- | |- | ||
| style="text-align:center" | 1 | | style="text-align:center" | 1 | ||
| style="text-align:right" | 204 MHz | | style="text-align:right" | 204 MHz | ||
| — | |||
|} | |} | ||
Using more than 8 channels requires coordination of multiple pin banks (and their SGPIO activity) within the device firmware, | Using more than 8 channels requires coordination of multiple pin banks (and their SGPIO activity) within the device firmware, | ||
is said to be under construction, and currently is not supported by sigrok. | is said to be under construction, and currently is not supported by sigrok | ||
(parts were prepared but are untested, it's assumed that more byte shuffling is involved which is yet to get determined and implemented). | |||
If you are aware of requirements for this feature, and a working combination of the involved components, | If you are aware of requirements for this feature, and a working combination of the involved components, | ||
please report them so that the sigrok device driver could get adjusted to support up to 16 channels. | please report them so that the sigrok device driver could get adjusted to support up to 16 channels. | ||
Line 60: | Line 88: | ||
See [[GreatFET One/Info]] for more details (USB identification). | See [[GreatFET One/Info]] for more details (USB identification). | ||
== | == Hardware == | ||
The GreatFET One is also code named '''Azalea''', and is based on the '''NXP LPC4330''' microcontroller. | |||
See the [https://github.com/greatfet-hardware/azalea hardware git repo] for design documents. | |||
It's all open hardware (BSD 3-clause). | |||
"Shields", "HATs", "capes", etc are referred to as '''neighbours''' in the GreatFET ecosystem. | |||
* [https://github.com/greatfet-hardware/foxglove Foxglove] is a level shifting neighbour. | |||
* Rhododendron sniffs USB (two wires, high samplerates) | |||
== Photos == | |||
<gallery> | |||
File:Greatfet_top.png|<small>top</small> | |||
File:Greatfet_bottom.png|<small>bottom</small> | |||
File:Greatfet_4chan.png|<small>capturing USB and UART</small> | |||
</gallery> | |||
== Example use == | |||
This section discusses '''sigrok software use''' with the device, after its operation was verified with vendor software. | |||
See the [[#Firmware|Firmware section]] of this page for getting the firmware and checking device operation. | |||
Make sure a compatible firmware version is loaded and that you have permissions to access the USB device. | Make sure a compatible firmware version is loaded and that you have permissions to access the USB device. | ||
Scan for the device(s), see their USB connection details and serial number(s). | Scan for the device(s), see their USB connection details and serial number(s). | ||
Line 165: | Line 169: | ||
</small> | </small> | ||
== | == Firmware == | ||
This section discusses '''Getting the firmware, using the vendor software''' to verify the device's operation. | |||
It is recommended to (re-)check these details when sigrok software has issues using the device. | |||
It is recommended to use at least v2021.2.1 firmware. | |||
This version was used for the initial development of sigrok support and is known to work well. | |||
The simplest method of checking the device's operation and upgrading its firmware is to use the '''greatfet''' host software. | |||
Which is available as a Python package, and makes the gf(1) utility available. | |||
This also happens to verify permissions to access the USB device. | |||
<small> | |||
$ '''pip install greatfet''' | |||
$ '''gf''' (see available subcommands) | |||
$ '''gf info''' | |||
$ '''gf firmware --help''' | |||
$ '''gf firmware --autoflash''' | |||
$ '''gf info''' | |||
</small> | |||
The greatfet host software ships with firmware images that correspond to the host's software version. | |||
Which ensures proper operation of the device under the host's software control. | |||
The "auto flash" feature writes that matching firmware to the device. | |||
Other options are available to write arbitrary images and thus firmware versions, | |||
as well as backup a device's firmware. | |||
The GreatFET | The greatfet host software demonstrates the GreatFET device's several modes of operation (as serial or parallel bridge, JTAG adapter, et al), | ||
allows versatile use of the device in interactive ways as well as scripted. | |||
It's | It also covers operation as a logic analyzer, which can either | ||
store raw data in files on disk, or optionally can record captures in sigrok's native format. | |||
<small> | |||
$ '''gf logic --help | |||
$ '''gf logic -p capture.sr -f 34M''' (executes until CTRL-C terminates) | |||
$ '''sigrok-cli -i capture.sr --show''' | |||
$ '''pulseview capture.sr &''' | |||
</small> | |||
See the [https://greatfet.readthedocs.io/en/latest/ read the docs] pages for details on using the software. | |||
Especially the [https://greatfet.readthedocs.io/en/latest/using_greatfet_apis.html#logic-analyzer Logic Analyzer] mode of operation and its pinout. | |||
Also [https://greatfet.readthedocs.io/en/latest/greatfet_logic.html greatfet_logic] for identical information on the first 8 channels. | |||
The software resides [https://github.com/greatscottgadgets/greatfet in a github repo]. | |||
This covers the device firmware as well as the host software. | |||
== Resources == | == Resources == | ||
Line 191: | Line 225: | ||
[[Category:Device]] | [[Category:Device]] | ||
[[Category:Logic analyzer]] | [[Category:Logic analyzer]] | ||
[[Category: | [[Category:Supported]] |
Latest revision as of 16:26, 1 December 2023
Status | supported |
---|---|
Source code | greatfet |
Channels | 8/4/2/1 |
Samplerate | 40.8/68/102/204MHz max |
Min/max voltage | 3.3V |
Compression | No (packing) |
Website | greatscottgadgets.com |
The GreatFET One is a USB connected versatile tool for USB analysis and other hardware research and also provides a mode of being an 8 channel logic analyser with a 40.8MHz samplerate and no local sample memory. Higher samplerates are available when the number of enabled channels gets reduced (up to 204MHz for 1 channel). Data acquisition employs the SGPIO machinery of the NXP LPC4330 microcontroller. The GreatFET's firmware is also available for other boards which use the same MCU. The device firmware is known for its efficient use of USB communication, streaming capabilities to the host are similar to HackRF One. Transfer rates are a little shy of 42MB/s. The greatfet sigrok driver supports the operation of these devices in logic analyzer mode.
The GreatFET device is exclusively used in continuous mode where sample data gets streamed to the host while the acquisition is executing. With 8 channels enabled, sample rates up to 40.8 MHz are supported. When fewer channels are enabled then these can get sampled at higher rates. The device firmware always captures channel counts that are a power of two. In other words when three channels are enabled, then data is captured for four channels. This is important to keep in mind, as the product of samplerate and channel count must not exceed the USB2.0 bandwidth. The limit is near 336Mbps (depends on the host computer's capabilities). Sample data is "densely packed" but not compressed during USB transmission.
Device firmware can optionally "shift pins" such that sampling e.g. channels 8 through 15 will only transmit one byte per sample from the device to the host, omitting the lower byte in the transfer which would carry no user perceivable data, thus working as efficiently and allowing as high a samplerate as sampling channel 0 through 7 would. Pin shift counts other than 8 are not usefully applicable. The sigrok driver supports this feature by responding to the set of enabled and disabled channels according to users' specs.
Getting more than 8 channels at the same time is currently not supported by the device's firmware due to the MCU's hardware constraints, and was prepared but is untested in the sigrok driver.
"Seemingly odd" samplerates are the result of an unusual (rather: unexpected to users) base clock and integer dividers. Users can specify arbitrary desired samplerates, the device firmware will determine the minimum samplerate which satisfies this user request.
channels count | max samplerate | comment |
---|---|---|
16-9 | 20.4MHz | currently unsupported |
8-5 | 40.8 MHz | — |
4-3 | 68 MHz | — |
2 | 102 MHz | — |
1 | 204 MHz | — |
Using more than 8 channels requires coordination of multiple pin banks (and their SGPIO activity) within the device firmware, is said to be under construction, and currently is not supported by sigrok (parts were prepared but are untested, it's assumed that more byte shuffling is involved which is yet to get determined and implemented). If you are aware of requirements for this feature, and a working combination of the involved components, please report them so that the sigrok device driver could get adjusted to support up to 16 channels. It is understood that the use of 9..16 channels will result in a maximum samplerate of 20.4MHz to allow for continuous streaming to the host.
See GreatFET One/Info for more details (USB identification).
Hardware
The GreatFET One is also code named Azalea, and is based on the NXP LPC4330 microcontroller. See the hardware git repo for design documents. It's all open hardware (BSD 3-clause).
"Shields", "HATs", "capes", etc are referred to as neighbours in the GreatFET ecosystem.
- Foxglove is a level shifting neighbour.
- Rhododendron sniffs USB (two wires, high samplerates)
Photos
Example use
This section discusses sigrok software use with the device, after its operation was verified with vendor software. See the Firmware section of this page for getting the firmware and checking device operation.
Make sure a compatible firmware version is loaded and that you have permissions to access the USB device.
Scan for the device(s), see their USB connection details and serial number(s).
$ sigrok-cli -d greatfet --scan greatfet:conn=3.85 - Great Scott Gadgets GreatFET v2021.2.1 [S/N: 000057cc67e630223f57] with 8 channels: SGPIO0 SGPIO1 SGPIO2 SGPIO3 SGPIO4 SGPIO5 SGPIO6 SGPIO7
See the device's parameters and its current configuration. Optionally specify connection details or serial numbers to disambiguate.
$ sigrok-cli -d greatfet:conn=3.85 --show (or) $ sigrok-cli -d greatfet:conn=sn=30223f57 --show Driver functions: Logic analyzer Scan options: conn probe_names greatfet:conn=3.85 - Great Scott Gadgets GreatFET v2021.2.1 [S/N: 000057cc67e630223f57] with 8 channels: SGPIO0 SGPIO1 SGPIO2 SGPIO3 SGPIO4 SGPIO5 SGPIO6 SGPIO7 Channel groups: Logic: channels SGPIO0 SGPIO1 SGPIO2 SGPIO3 SGPIO4 SGPIO5 SGPIO6 SGPIO7 Supported configuration options across all channel groups: continuous: on (current), off conn: 3.85 (current) samplerate - supported samplerates: 1 MHz 2 MHz 4 MHz 8.5 MHz 10.2 MHz 12 MHz 17 MHz 20.4 MHz 25.5 MHz 34 MHz (current) 40.8 MHz 51 MHz 68 MHz 102 MHz 204 MHz limit_samples: 0 (current) limit_time: 0 (current)
Capture some data, use the device interactively.
$ sigrok-cli -d greatfet --config samplerate=40M --time 1000 -o capture.sr $ sigrok-cli -i capture.sr --show
$ pulseview -d greatfet &
Firmware
This section discusses Getting the firmware, using the vendor software to verify the device's operation. It is recommended to (re-)check these details when sigrok software has issues using the device.
It is recommended to use at least v2021.2.1 firmware. This version was used for the initial development of sigrok support and is known to work well.
The simplest method of checking the device's operation and upgrading its firmware is to use the greatfet host software. Which is available as a Python package, and makes the gf(1) utility available. This also happens to verify permissions to access the USB device.
$ pip install greatfet $ gf (see available subcommands) $ gf info $ gf firmware --help $ gf firmware --autoflash $ gf info
The greatfet host software ships with firmware images that correspond to the host's software version. Which ensures proper operation of the device under the host's software control. The "auto flash" feature writes that matching firmware to the device. Other options are available to write arbitrary images and thus firmware versions, as well as backup a device's firmware.
The greatfet host software demonstrates the GreatFET device's several modes of operation (as serial or parallel bridge, JTAG adapter, et al), allows versatile use of the device in interactive ways as well as scripted. It also covers operation as a logic analyzer, which can either store raw data in files on disk, or optionally can record captures in sigrok's native format.
$ gf logic --help $ gf logic -p capture.sr -f 34M (executes until CTRL-C terminates) $ sigrok-cli -i capture.sr --show $ pulseview capture.sr &
See the read the docs pages for details on using the software. Especially the Logic Analyzer mode of operation and its pinout. Also greatfet_logic for identical information on the first 8 channels.
The software resides in a github repo. This covers the device firmware as well as the host software.
Resources
- Great Scott Gadgets GreatFET product page
- hardware git repo and firmware and host software repo
- read the docs pages, with logic analyzer pinout and logic analyzer pinout, with a pinout sticker