{"id":30877,"date":"2024-07-29T13:48:34","date_gmt":"2024-07-29T20:48:34","guid":{"rendered":"https:\/\/digilent.com\/blog\/?p=30877"},"modified":"2025-04-29T10:54:50","modified_gmt":"2025-04-29T17:54:50","slug":"characterizing-a-pmod-ports-switching-frequency-advantages-of-a-high-bandwidth-oscilloscope","status":"publish","type":"post","link":"https:\/\/digilent.com\/blog\/characterizing-a-pmod-ports-switching-frequency-advantages-of-a-high-bandwidth-oscilloscope\/","title":{"rendered":"Characterizing a Pmod Port\u2019s Switching Frequency: Advantages of a High-Bandwidth Oscilloscope"},"content":{"rendered":"<p><span data-contrast=\"auto\">Digilent recently announced the release of two new members of the <a href=\"https:\/\/digilent.com\/shop\/adp-5000-series\/\">Analog Discovery Pro 5000 Series<\/a>, the ADP5470 and ADP5490, which are both four-channel mixed-signal oscilloscopes offering substantially higher bandwidths and sample rates than any comparable oscilloscope Digilent has previously released. In this article, we will take advantage of those bandwidths to perform some testing on an FPGA board.<\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:278}\">\u00a0<\/span><\/p>\n<p><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:278}\"> <a href=\"https:\/\/digilent.com\/blog\/characterizing-a-pmod-ports-switching-frequency-advantages-of-a-high-bandwidth-oscilloscope\/pxl_20240725_201357285\/\" rel=\"attachment wp-att-30878\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/digilent.com\/blog\/wp-content\/uploads\/2024\/07\/PXL_20240725_201357285-1024x768.jpg\" alt=\"\" width=\"735\" height=\"551\" class=\"alignnone wp-image-30878 size-large\" srcset=\"https:\/\/digilent.com\/blog\/wp-content\/uploads\/2024\/07\/PXL_20240725_201357285-1024x768.jpg 1024w, https:\/\/digilent.com\/blog\/wp-content\/uploads\/2024\/07\/PXL_20240725_201357285-600x450.jpg 600w, https:\/\/digilent.com\/blog\/wp-content\/uploads\/2024\/07\/PXL_20240725_201357285-1536x1152.jpg 1536w, https:\/\/digilent.com\/blog\/wp-content\/uploads\/2024\/07\/PXL_20240725_201357285-2048x1536.jpg 2048w\" sizes=\"auto, (max-width: 735px) 100vw, 735px\" \/><\/a><\/span><\/p>\n<p><span data-contrast=\"auto\">In the FPGA world, a frequently asked question is exactly how fast a pin can be toggled, as it directly informs the maximum speed at which data can be transferred onto or off of a board. This maximum speed depends on many factors, including the length of PCB traces between connector and FPGA pin, the presence (or lack thereof) of current-limiting protection resistors, and the inherent quality of a connector used. Pmod connectors are easier to use and to design peripherals for than other commonly used connectors, like SYZYGY or FMC, but signals run through them can only achieve limited speeds.<\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:278}\">\u00a0<\/span><\/p>\n<p><span data-contrast=\"auto\">So, I put together a project that toggles the Pmod I\/O pins on an Arty S7 at controllable frequency, by exposing Clocking Wizard register settings through a simple command interface connected to a serial port. In this way, the serial port can be controlled from a Python script to consistently configure the clock while also recording clock pulses using an ADP5490. This post is focused on the ADP5000 devices, so the details of the Arty S7 project are out of scope (pun intended) for this article, but a post we put out a couple of weeks ago covers it in more detail: <a href=\"https:\/\/digilent.com\/blog\/vcos-mmcms-plls-and-cmts-clocking-resources-on-fpga-boards\/\">VCOs, MMCMs, PLLs, and CMTs \u2013 Clocking Resources on FPGA Boards<\/a><\/span><span data-contrast=\"auto\">.<\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:278}\">\u00a0<\/span><\/p>\n<p><span data-contrast=\"auto\">For a digital signal to be properly transmitted from one device to another, the output signal must exceed VOH and fall below VOL. For 3.3V LVCMOS logic, as is commonly used on our FPGA boards, for example, to count as a rising edge, a signal must transition from below 0.4 V to above 2.4 V.<\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:278}\">\u00a0<\/span><\/p>\n<p><a href=\"http:\/\/https:\/\/docs.amd.com\/r\/en-US\/ds189-spartan-7-data-sheet\/DC-Input-and-Output-Levels\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/digilent.com\/blog\/wp-content\/uploads\/2024\/07\/ds189-table-8.png\" alt=\"\" width=\"856\" height=\"698\" class=\"alignnone wp-image-30890 size-full\" srcset=\"https:\/\/digilent.com\/blog\/wp-content\/uploads\/2024\/07\/ds189-table-8.png 856w, https:\/\/digilent.com\/blog\/wp-content\/uploads\/2024\/07\/ds189-table-8-600x489.png 600w\" sizes=\"auto, (max-width: 856px) 100vw, 856px\" \/><\/a><\/p>\n<p><span data-contrast=\"auto\">Table 8, SelectIO DC Input and Output Levels, from <a href=\"https:\/\/docs.amd.com\/r\/en-US\/ds189-spartan-7-data-sheet\/DC-Input-and-Output-Levels\">DS189, Spartan 7 AC\/DC Switching Characteristics<\/a><\/span><span data-contrast=\"auto\">, describes the logic thresholds for various logic standards. Note that these values are defined for DC signals, and whether or not they can be achieved <span class=\"ui-provider a b c d e f g h i j k l m n o p q r s t u v w x y z ab ac ae af ag ah ai aj ak\" dir=\"ltr\">when the pin is toggling quickly and<\/span>\u00a0the chip is placed on a PCB depends on the analog characteristics of the board \u2013 which we\u2019re about to test.<\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:278}\">\u00a0<\/span><\/p>\n<p><span data-contrast=\"auto\">By observing increasing frequencies of clock signal with the scope, we can see that the LVCMOS33 voltage levels are no longer met once the clock is run faster than [unknown frequency].<\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:278}\">\u00a0<\/span><\/p>\n<p><span data-contrast=\"auto\">WaveForms\u2019 cursors feature makes it easy to spot things like \u201cDoes this signal rise above this threshold?\u201d at a glance. In the screenshots you\u2019re about to see, we placed cursors, the red lines, at a couple of common threshold voltage levels, so that we could confirm whether our output signals met the spec.<\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:278}\">\u00a0<\/span><\/p>\n<p><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:278}\"> <a href=\"https:\/\/digilent.com\/blog\/characterizing-a-pmod-ports-switching-frequency-advantages-of-a-high-bandwidth-oscilloscope\/allchannels-jcpins-10mhzphase\/\" rel=\"attachment wp-att-30879\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/digilent.com\/blog\/wp-content\/uploads\/2024\/07\/AllChannels-JCPins-10MHzPhase.png\" alt=\"\" width=\"1920\" height=\"1040\" class=\"alignnone wp-image-30879 size-full\" srcset=\"https:\/\/digilent.com\/blog\/wp-content\/uploads\/2024\/07\/AllChannels-JCPins-10MHzPhase.png 1920w, https:\/\/digilent.com\/blog\/wp-content\/uploads\/2024\/07\/AllChannels-JCPins-10MHzPhase-600x325.png 600w, https:\/\/digilent.com\/blog\/wp-content\/uploads\/2024\/07\/AllChannels-JCPins-10MHzPhase-1024x555.png 1024w, https:\/\/digilent.com\/blog\/wp-content\/uploads\/2024\/07\/AllChannels-JCPins-10MHzPhase-1536x832.png 1536w\" sizes=\"auto, (max-width: 1920px) 100vw, 1920px\" \/><\/a><\/span><\/p>\n<p><i><span data-contrast=\"auto\">Output signals with varying phase shifts relative to each other, 10 MHz. Expected phase shifts are ~0 degrees between C1 and C2, 45 degrees between C1 and C3, and 90 degrees between C1 and C4. We can see that these are pretty close.<\/span><\/i><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:278}\">\u00a0<\/span><\/p>\n<p><i><span data-contrast=\"auto\">Note, the cursors we used in these tests don\u2019t match the thresholds outlined by AMD above<\/span><\/i><span data-contrast=\"auto\">.<\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:278}\">\u00a0<\/span><\/p>\n<p><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:278}\"> <a href=\"https:\/\/digilent.com\/blog\/characterizing-a-pmod-ports-switching-frequency-advantages-of-a-high-bandwidth-oscilloscope\/allchannels-jcpins-60mhzphase\/\" rel=\"attachment wp-att-30880\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/digilent.com\/blog\/wp-content\/uploads\/2024\/07\/AllChannels-JCPins-60MHzPhase.png\" alt=\"\" width=\"1920\" height=\"1040\" class=\"alignnone wp-image-30880 size-full\" srcset=\"https:\/\/digilent.com\/blog\/wp-content\/uploads\/2024\/07\/AllChannels-JCPins-60MHzPhase.png 1920w, https:\/\/digilent.com\/blog\/wp-content\/uploads\/2024\/07\/AllChannels-JCPins-60MHzPhase-600x325.png 600w, https:\/\/digilent.com\/blog\/wp-content\/uploads\/2024\/07\/AllChannels-JCPins-60MHzPhase-1024x555.png 1024w, https:\/\/digilent.com\/blog\/wp-content\/uploads\/2024\/07\/AllChannels-JCPins-60MHzPhase-1536x832.png 1536w\" sizes=\"auto, (max-width: 1920px) 100vw, 1920px\" \/><\/a><\/span><\/p>\n<p><i><span data-contrast=\"auto\">The same clocks at 60 MHz \u2013 slew rates begin to matter, though it can be seen that thresholds are still respected. Note that harmonics are still present, even if they have less impact on the shape of the square wave edges. You can see here that we\u2019re capturing multiple different harmonics of these waves, all the way up to the 7<\/span><\/i><i><span data-contrast=\"auto\">th<\/span><\/i><i><span data-contrast=\"auto\"> at 420 MHz.<\/span><\/i><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:278,&quot;469777462&quot;:[3950],&quot;469777927&quot;:[0],&quot;469777928&quot;:[1]}\">\u00a0<\/span><\/p>\n<p><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:278,&quot;469777462&quot;:[3950],&quot;469777927&quot;:[0],&quot;469777928&quot;:[1]}\"> <a href=\"https:\/\/digilent.com\/blog\/characterizing-a-pmod-ports-switching-frequency-advantages-of-a-high-bandwidth-oscilloscope\/clocking75mhz-seriesvsnot\/\" rel=\"attachment wp-att-30881\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/digilent.com\/blog\/wp-content\/uploads\/2024\/07\/Clocking75MHz-seriesVsNot.png\" alt=\"\" width=\"1920\" height=\"1040\" class=\"alignnone wp-image-30881 size-full\" srcset=\"https:\/\/digilent.com\/blog\/wp-content\/uploads\/2024\/07\/Clocking75MHz-seriesVsNot.png 1920w, https:\/\/digilent.com\/blog\/wp-content\/uploads\/2024\/07\/Clocking75MHz-seriesVsNot-600x325.png 600w, https:\/\/digilent.com\/blog\/wp-content\/uploads\/2024\/07\/Clocking75MHz-seriesVsNot-1024x555.png 1024w, https:\/\/digilent.com\/blog\/wp-content\/uploads\/2024\/07\/Clocking75MHz-seriesVsNot-1536x832.png 1536w\" sizes=\"auto, (max-width: 1920px) 100vw, 1920px\" \/><\/a><\/span><\/p>\n<p><i><span data-contrast=\"auto\">Things can get funky at high frequencies. Here we see a 75 MHz output, which, while it seems to be able to keep up and swing past the thresholds, also seems to have a much higher amplitude than expected. A smoothed-out overshoot?<\/span><\/i><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:278,&quot;469777462&quot;:[3950],&quot;469777927&quot;:[0],&quot;469777928&quot;:[1]}\">\u00a0<\/span><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/digilent.com\/blog\/wp-content\/uploads\/2024\/07\/VIO-someRinging-1.png\" alt=\"\" width=\"1920\" height=\"1040\" class=\"alignnone wp-image-30891 size-full\" srcset=\"https:\/\/digilent.com\/blog\/wp-content\/uploads\/2024\/07\/VIO-someRinging-1.png 1920w, https:\/\/digilent.com\/blog\/wp-content\/uploads\/2024\/07\/VIO-someRinging-1-600x325.png 600w, https:\/\/digilent.com\/blog\/wp-content\/uploads\/2024\/07\/VIO-someRinging-1-1024x555.png 1024w, https:\/\/digilent.com\/blog\/wp-content\/uploads\/2024\/07\/VIO-someRinging-1-1536x832.png 1536w\" sizes=\"auto, (max-width: 1920px) 100vw, 1920px\" \/><\/p>\n<p><i><span data-contrast=\"auto\">To really get a sense of differences that can occur due to hardware outside of the FPGA part, let\u2019s look at this 15 MHz signal, comparing the JC1 and JA1 outputs. One of these has a series resistor while the other doesn\u2019t. As a side note, the Scope to Digital feature, which allows us to interpret analog signals in a logic analyzer-style view, with an adjustable threshold, is also extremely useful for this kind of testing.<\/span><\/i><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:278}\">\u00a0<\/span><\/p>\n<p><span data-contrast=\"auto\">While it\u2019s been extremely useful in debugging FPGA projects, my AD3 doesn\u2019t have the input bandwidth to cover the frequency range necessary for this kind of test \u2013 necessitating the bigger scope. As to why, an FFT view of the clock signal \u2013 seen in all of the screenshots above \u2013 shows us an important property of square waves, namely, their many harmonic frequencies, which can impact the quality of a clock edge. An oscilloscope may need to capture many of these harmonics to properly reflect the signal as it\u2019s seen by a device it\u2019s driving, at many times the \u201cbase\u201d frequency of the signal in question.<\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:278}\">\u00a0<\/span><\/p>\n<p><span data-contrast=\"auto\">I need to add one big caveat: All of this testing was done with one specific board and project, with no external circuit other than the oscilloscope connected to the I\/Os. Results would be different as soon as a Pmod was connected to a Pmod port. So your mileage may vary.<\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:278}\">\u00a0<\/span><\/p>\n<p><span data-contrast=\"auto\">If you\u2019re interested in these topics, you might also like this post that we put out on <a href=\"https:\/\/digilent.com\/blog\/visualize-data-integrity-with-eye-diagrams\/\">Eye Diagrams in WaveForms<\/a><\/span><span data-contrast=\"auto\">, or this older article on generating near-square waves by composing them from harmonics in a custom waveform: <a href=\"https:\/\/digilent.com\/reference\/test-and-measurement\/analog-discovery-2\/demos\/measuring-harmonics\">Using the Analog Discovery 2 to Measure Harmonics in a Signal.<\/a><\/span><\/p>\n<p><span data-contrast=\"auto\">Check out the <a href=\"https:\/\/digilent.com\/shop\/adp-5000-series\/\">Analog Discovery Pro 5000 Series<\/a> page on our store, where you can find more reference material and information on their specifications.<\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:278}\">\u00a0<\/span><\/p>\n<div class='watch-action'><div class='watch-position align-left'><div class='action-like'><a class='lbg-style6 like-30877 jlk' data-task='like' data-post_id='30877' data-nonce='d8c4d58d14' rel='nofollow'><img src='https:\/\/digilent.com\/blog\/wp-content\/plugins\/wti-like-post-pro\/images\/pixel.gif' title='Like' \/><span class='lc-30877 lc'>0<\/span><\/a><\/div><div class='action-unlike'><a class='unlbg-style6 unlike-30877 jlk' data-task='unlike' data-post_id='30877' data-nonce='d8c4d58d14' rel='nofollow'><img src='https:\/\/digilent.com\/blog\/wp-content\/plugins\/wti-like-post-pro\/images\/pixel.gif' title='Unlike' \/><span class='unlc-30877 unlc'>0<\/span><\/a><\/div><\/div> <div class='status-30877 status align-left'>Be the 1st to vote.<\/div><\/div><div class='wti-clear'><\/div>","protected":false},"excerpt":{"rendered":"<p>Digilent recently announced the release of two new members of the Analog Discovery Pro 5000 Series, the ADP5470 and ADP5490, which are both four-channel mixed-signal oscilloscopes offering substantially higher bandwidths &hellip; <\/p>\n","protected":false},"author":52,"featured_media":30903,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[35,1563],"tags":[4928,4929,111,4930,4942,4932,4900,4910,4944,4365,4945,4953,4954,4952,1662,4436,4950,4948,4941,1059,499,4951,4943,4368,4940,4559,4955,4949,4443,4946,4947,4581,452],"ppma_author":[4462],"class_list":["post-30877","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-fpga","category-guide","tag-adp5470","tag-adp5490","tag-analog-discovery","tag-analog-discovery-pro-5000-series","tag-arty-s7","tag-bandwidth","tag-clocking","tag-clocking-wizard","tag-current-limiting-resistors","tag-digilent","tag-digital-signal","tag-electronics","tag-engineering","tag-eye-diagrams","tag-fpga","tag-hardware","tag-harmonics","tag-logic-thresholds","tag-lvcmos","tag-measurement","tag-oscilloscope","tag-overshoot","tag-pcb-traces","tag-pmod","tag-sample-rate","tag-scope-to-digital","tag-signal-integrity","tag-slew-rate","tag-testing","tag-voh","tag-vol","tag-waveform","tag-waveforms"],"jetpack_featured_media_url":"https:\/\/digilent.com\/blog\/wp-content\/uploads\/2024\/07\/PmodPortSwitchingFrequency-580.png","jetpack_sharing_enabled":true,"authors":[{"term_id":4462,"user_id":52,"is_guest":0,"slug":"abrown","display_name":"Arthur Brown","avatar_url":"https:\/\/secure.gravatar.com\/avatar\/60e7f8e1b3a55e2e20ee541df1f393c2acbcee9fd05fd3e38d07e25a2e6fd237?s=96&d=mm&r=g","1":"","2":"","3":"","4":"","5":"","6":"","7":"","8":"","9":"","10":""}],"post_mailing_queue_ids":[],"_links":{"self":[{"href":"https:\/\/digilent.com\/blog\/wp-json\/wp\/v2\/posts\/30877","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/digilent.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/digilent.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/digilent.com\/blog\/wp-json\/wp\/v2\/users\/52"}],"replies":[{"embeddable":true,"href":"https:\/\/digilent.com\/blog\/wp-json\/wp\/v2\/comments?post=30877"}],"version-history":[{"count":7,"href":"https:\/\/digilent.com\/blog\/wp-json\/wp\/v2\/posts\/30877\/revisions"}],"predecessor-version":[{"id":30905,"href":"https:\/\/digilent.com\/blog\/wp-json\/wp\/v2\/posts\/30877\/revisions\/30905"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/digilent.com\/blog\/wp-json\/wp\/v2\/media\/30903"}],"wp:attachment":[{"href":"https:\/\/digilent.com\/blog\/wp-json\/wp\/v2\/media?parent=30877"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/digilent.com\/blog\/wp-json\/wp\/v2\/categories?post=30877"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/digilent.com\/blog\/wp-json\/wp\/v2\/tags?post=30877"},{"taxonomy":"author","embeddable":true,"href":"https:\/\/digilent.com\/blog\/wp-json\/wp\/v2\/ppma_author?post=30877"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}