Silicon ChipMicrochip’s new Hello FPGA kit - August 2020 SILICON CHIP
  1. Outer Front Cover
  2. Contents
  3. Publisher's Letter: Businesses need to handle ‘black swan’ events better
  4. Feature: Measuring distance & motion with lidar and SODAR by Dr David Maddison
  5. Project: USB SuperCodec by Phil Prosser
  6. Feature: Microchip’s new Hello FPGA kit by Tim Blythman
  7. Project: A homemade Switchmode 78XX replacement by Tim Blythman
  8. Serviceman's Log: Fixing heaters – it’s a gas by Dave Thompson
  9. Product Showcase
  10. Project: 1MHz-6GHz Arduino-based Digital RF Power Meter by Jim Rowe
  11. Vintage Radio: Velco 1937 'kit' radio restoration by Ken Kranz
  12. PartShop
  13. Project: The Colour Maximite 2 – part two by Geoff Graham & Peter Mather
  14. Feature: Vintage Workbench by Alan Hampel
  15. Market Centre
  16. Advertising Index
  17. Notes & Errata: DIY Reflow Oven, April-May 2020
  18. Outer Back Cover

This is only a preview of the August 2020 issue of Silicon Chip.

You can view 38 of the 112 pages in the full issue, including the advertisments.

For full access, purchase the issue for $10.00 or subscribe for access to the latest issues.

Items relevant to "USB SuperCodec":
  • USB SuperCodec PCB [01106201] (AUD $12.50)
  • USB SuperCodec Balanced Input Attenuator add-on PCB [01106202] (AUD $7.50)
  • Parts source grid for the USB SuperCodec (Software, Free)
  • USB SuperCodec PCB pattern (PDF download) [01106201] (Free)
  • USB SuperCodec Balanced Input Attenuator add-on PCB pattern (PDF download) [01106202] (Free)
  • USB SuperCodec front panel artwork (PDF download) (Free)
  • Drilling and cutting diagrams for the USB SuperCodec Balanced Input Attenuator (PDF download) (Panel Artwork, Free)
Articles in this series:
  • USB SuperCodec (August 2020)
  • USB SuperCodec (August 2020)
  • USB SuperCodec – part two (September 2020)
  • USB SuperCodec – part two (September 2020)
  • USB SuperCodec – part three (October 2020)
  • USB SuperCodec – part three (October 2020)
  • Balanced Input Attenuator for the USB SuperCodec (November 2020)
  • Balanced Input Attenuator for the USB SuperCodec (November 2020)
  • Balanced Input Attenuator for the USB SuperCodec, Part 2 (December 2020)
  • Balanced Input Attenuator for the USB SuperCodec, Part 2 (December 2020)
Items relevant to "A homemade Switchmode 78XX replacement":
  • Switchmode 78xx Replacement PCB [18105201] (AUD $2.50)
  • Kit for the Switchmode 78xx Regulator replacement (Component, AUD $13.50)
  • Switchmode 78xx Regulator PCB pattern (PDF download) [18105201] (Free)
Items relevant to "1MHz-6GHz Arduino-based Digital RF Power Meter":
  • Wideband Digital RF Power Meter PCB [04106201] (AUD $5.00)
  • 16x2 Alphanumeric serial (I²C) LCD module with blue backlight (Component, AUD $12.50)
  • Arduino sketch for the Wideband Digital RF Power Meter (Software, Free)
  • Wideband Digital RF Power Meter PCB pattern (PDF download) [04106201] (Free)
  • Wideband Digital RF Power Meter lid panel artwork & drilling diagrams (PDF download) (Free)
Items relevant to "Velco 1937 'kit' radio restoration":
  • Velco 1937 Radio Files (SPICE models and Valve Data) (Software, Free)
Items relevant to "The Colour Maximite 2 – part two":
  • Colour Maximite 2 PCB [07107201] (AUD $10.00)
  • Colour Maximite 2 front & rear panels (PCB, AUD $10.00)
  • Colour Maximite 2 software and documentation (Free)
  • Colour Maximite 2 PCB pattern (PDF download) [07107201] (Free)
  • Colour Maximite 2 front and rear panel cutting diagrams and front panel artwork (PDF download) (Free)
Articles in this series:
  • The all-new Colour Maximite 2 (July 2020)
  • The all-new Colour Maximite 2 (July 2020)
  • The Colour Maximite 2 – part two (August 2020)
  • The Colour Maximite 2 – part two (August 2020)
Items relevant to "Vintage Workbench":
  • Tektronix T-130 LC Meter Supplemental Materials (Software, Free)
Articles in this series:
  • Vintage Workbench (June 2020)
  • Vintage Workbench (June 2020)
  • Vintage Workbench (July 2020)
  • Vintage Workbench (July 2020)
  • Vintage Workbench (August 2020)
  • Vintage Workbench (August 2020)

Purchase a printed copy of this issue for $10.00.

“First look” at Microchip’s new FPGA kit . . . by Tim Blythman Hello FPGA Field Programmable Gate Arrays (FPGAs) are powerful chips which are getting easier to use all the time. This Microchip Hello FPGA Kit is targeted towards entry-level users. It comes with demonstration software for image processing, signal processing and artificial intelligence. We took one for a test-drive, to see what’s possible for even those with minimal knowledge of FPGAs. F ield programmable gate arrays are incredibly powerful and useful. They are regularly used to simulate many microchip designs before they are committed to ASICs (application-specific integrated circuits). Making custom chips is a very costly process, so you want to be sure your chip will work before pulling the trigger! FPGAs are one of the essential tools to achieve that. An FPGA is effectively a lot of configurable logic gates; it’s a bit like the old 300-in-1 electronics kits with the spring connectors and wires, but more like 1,000,000-in-1, much smaller in size and electronically configurable. Having basic elements equivalent to individual logic gates and flip-flops means that they can emulate almost any chip. Most modern FPGAs also have specialised functional blocks to provide, siliconchip.com.au for example, RAM, adders, multipliers, DSP functions and even complete microprocessor cores! In some respects, they are a counterpoint to microcontrollers and microprocessors. Microcontrollers and microprocessors typically work in a linear fashion, processing instructions one at a time. On the other hand, the gates in an FPGA can all work in a massively parallel manner, doing many things simultaneously. We’ve described some FPGA boards previously. The Arduino Vidor MKR utilises an FPGA to produce HDMI video (amongst other things). We reviewed this in March 2019; see siliconchip.com.au/Article/11448 The Vidor also allows the FPGA to be configured to provide custom peripherals, although, for the most part, it is a microcontroller board. We also reviewed the Lattice iceAustralia’s electronics magazine Stick in April 2019 (siliconchip.com. au/Article/11521). That is a development board that can be programmed using the open-source IceStorm software and even the block-based IceStudio software. The iceStick combined with the IceStudio software is one of the cheapest and easiest ways to get an introduction to FPGAs. We even showed our readers how to turn the iceStick into a VGA Terminal for displaying retro computer text and graphics in that issue (siliconchip. com.au/Article/11525). So to sum up, FPGAs are incredibly powerful but also very complicated and sometimes difficult to work with. The Hello FPGA Kit The Hello FPGA Kit is an evaluation board, originally from a company called Microsemi. For many years, they were known as a supplier of elecAugust 2020  31 The Hello FPGA Kit consists of an LCD board, a main FPGA board and a camera board which are usually sandwiched together, as seen on page 31. tronics for military, aerospace and other high-reliability applications. Some of their products were used in the Mars Curiosity rover and unsurprisingly, one of their key product lines is FPGAs; their PolarFire FPGA was named Product of the Year in 2017 by Electronic Products China and 21ic.com. In 2018, they were taken over by Microchip Technology, better known as manufacturers of PIC microcontrollers (and now also Atmel AVR microcontrollers since their takeover of Atmel). The Hello FPGA Kit reviewed here was kindly loaned to us by Microchip Technology Australia. The Hello FPGA Kit is a set of three boards which are sandwiched together. One board has a camera lens poking out and a set of headers; it is fitted with an OmniVision OV7725 camera. There aren’t many electronic components on that board; a switchmode regulator and its associated passives take 5V in to provide a 1.8V rail for the camera. Its underside has headers to attach to the FPGA motherboard, labelled as “Expansion” and “Arduino”. Its top sports a MikroBus socket. The second outer board features an LCD panel. The PCB itself is not much larger than the LCD, although neither the board nor schematics give any indication about the model or capabilities of the LCD controller. It measures 3.5in (89mm) diagonally, and the documentation states that it has a resolution of 480 x 320 pixels. 32  Silicon Chip A solitary DFN-6 package and two passives provide PWM control of the display’s LCD backlighting. The schematic indicates that the LCD uses a parallel 8-bit bus. It connects to the FPGA board via an “Expansion” header. The LCD panel appears to be similar to the type used in our Micromite LCD Backpack V3 (siliconchip.com. au/Article/11764). The main board (see below), sandwiched and normally hidden in between the other two, carries the FPGA and a microcontroller. But the block User Push Buttons Power LEDs 20-pin Expansion Header diagram, Fig.2, shows that there’s a lot more on the board than just those two chips. The PIC32MX795F512 micro provides an interface for uploading of the demonstration software to the FPGA and monitoring its operation. The PIC32MX795F512 is the same chip that we used for both the Maximite and Colour Maximite computers (see siliconchip.com.au/Series/30 and siliconchip.com.au/Series/22 for more information). The FPGA is a Microsemi SmartUser LEDs FPGA JTAG Header PICkit Header SmartFusion FPGA PIC32MX79SFS12L USB 2.0 20-pin Expansion Header Arduino Compatible Interface Australia’s electronics magazine Fig.1: there is no shortage of connectivity on the Hello FPGA main board. USB, JTAG and even Arduinocompatible headers are provided. siliconchip.com.au Fig.2: the Hello FPGA main board consists of an M2S010VF256 FPGA communicating with a PIC32MX795F512 micro. The PIC32MX795F512 communicates with the GUI app over a USB-serial link, while the FPGA connects with the camera and LCD board via headers. Fusion2 M2S010-VF256 in a BGA (ball grid array) package, with 256 ‘pins’ (actually lands). Microsemi M2S010-VF256 FPGA The M2S010-VF256 is described as an SoC (system on a chip). It incorporates a 166MHz 32-bit ARM Cortex M3 processor, which has 64KB of integrated RAM and 512KB of embedded non-volatile memory. The processor also has, among other typical microcontroller peripherals such as SPI, I2C and UART, a USB OTG controller, an Ethernet controller and a CAN bus controller. It can interface directly to the FPGA as well, since they are on the same die. Such an arrangement appears to be typical of many modern FPGA devices. While it is certainly possible to create a processor in the ‘FPGA fabric’, to do so is less efficient in terms of power and FPGA resources than having dedicated silicon for this purpose. And since the processor is on the same die as the FPGA, communication is much faster than if the processor was a separate chip. In terms of ‘power’, it is interesting to compare the M2S010-VF256 to the Lattice iCE40HX1K chip used in the iceStick that we previously reviewed. It isn’t always easy to make a direct comparison between FPGAs from different brands or even families, as their siliconchip.com.au Fig.3: the GUI app is simple and easy to use. The main things to remember are to use the controls at top right to connect to the Hello FPGA Kit and ensure that the correct Action is selected before clicking Run. internal structures can be quite different, even though they achieve a similar result. Nonetheless, we can say that the M2S010-VF256 has roughly 9.5 times the logic elements of the Lattice FPGA, at 12,084 total, compared to 1280. It also has many more Logic Array Blocks (1007 vs 160). Its maximum operating frequency is not given, but we suspect that it will be lower than the 1066MHz for the iCE40HX1K, given that the M2S010 series is designed for power efficiency. Low power normally does not translate to blistering clock speeds. Despite that, its large number of logic blocks means that it can be configured to do a lot of work per clock cycle. One of the interesting features of the Hello FPGA Kit is that it can measure and report its own power consumption. So it’s clear that making the best use of power is a focus of the SmartFusion2 range. Their power analysis tool can estimate and evaluate power usage before committing to a design. The FPGA component of the M2S010-VF256 also has several ‘SerDes’ interfaces. SerDes is an abbreviation for “Serialiser-Deserialiser”, and as the name suggests, they convert data between serial and parallel formats. For example, the SerDes on the M2S010-VF256 can be configured to Australia’s electronics magazine provide a 10Gbps Ethernet interface. Many modern high-speed buses are serial in nature; HDMI and USB are other examples. The SerDes may include features such as clocking, encoding and framing. Data is processed internally in parallel and then serialised for output. Beyond this, there are many socalled ‘IP cores’ that can add further configurable peripherals to the chip. Their page also notes some potential applications in fields such as medical imaging, radar processing, automotive and military systems. Medical imaging and radar processing are examples of applications which require a large amount of data to be processed; the parallel nature of an FPGA allows it to process this data in parallel and the results to be then fed to the processor for storage and display. See siliconchip.com.au/link/ab3o for more information on the FPGA chip. A guide for the Hello FPGA Kit can be found at siliconchip.com.au/ link/ab3p Now let’s have a look at some features on the Hello FPGA Kit’s main PCB (see Fig.1). The block diagram for the FPGA board is shown in Fig.2. The FPGA itself is labelled U1 while the PIC microcontroller is labelled U13. The latter has an 8MHz crystal (Y1), while a 50MHz oscillator (X1) provides the clock signal for the FPGA. August 2020  33 Fig.4: the FPGA Demo tab for the AI Demo offers several sample digit sets to test out the AI recognition system, and displays the output from the FPGA too. Four regulators are present: U9, U10, U11 and U16. U16 derives 3.3V from the 5V rail. This feeds into U9, providing 1.2V for the FPGA core; and U10, supplying 1.5V for a DRAM chip. U11 provides the VTT (terminator voltage) for the DDR DRAM. U2 is a current-monitoring device with an I2C interface; it is used to measure the FPGA current via a current sense resistor connected to the output of the 1.2V regulator which powers the FPGA core. The USB function is not provided by the PIC (although it is capable of doing so), but by a dedicated USB-serial IC (U5; MCP2221A). This can also interface to an I2C bus. There are also a great many passive devices on this side of the PCB; the power decoupling section shows over 50 bypass capacitors connecting across several rails. The underside of the board is not quite as busy, although still littered with many tiny parts, including the 8Gb MT41K1G8RKB DRAM IC (U4), in a BGA package. There is also non-volatile storage in the form of U8, a 64Mb SST26VF064B serial flash IC. Many FPGAs are designed to load their configuration from a flash IC during startup. On the other hand, the Microsemi M2S010 has its own internal flash, which reduces power consumption and is more secure in that the flash 34  Silicon Chip Fig.5: the Image Processing Demo is simple enough, offering some sliders to change the way the image from the camera is displayed on the LCD screen. memory cannot be easily read by unauthorised persons. The remaining ICs on this side of the PCB are U14 (a 74CBTLV3257 four-channel multiplexer) and U15 (a 74LVC1G157 single-channel multiplexer), which combine into a fivechannel multiplexer to switch the JTAG programming lines between the PIC and a set of header pins. This is controlled from the PIC and defaults to the header pins, allowing the PIC to take control of these lines if needed, but allowing connection to the JTAG header when it is not. Software While we earlier alluded to the fact that some FPGAs are hard to work with, the demonstration software for the Hello FPGA Kit is the opposite. We could only see downloads for the Windows operating system; our test system used Windows 10. You will need a Microsemi account to download the software. Registration is simple and does not require a confirmation email (but does need an email address). This is done at the following web page: https://soc.microsemi.com/ Portal/Default.aspx?v=2 You can then go to www.microsemi. com/existing-parts/parts/150925 and click on the Resources tab and download the Hello FPGA GUI Application. The design project files are listed Australia’s electronics magazine separately, but the necessary demonstration files are included with the GUI application. You can download the various user guides too. The installer is packaged in a zip file, so you should extract the entire file and then run the installer. While the zip file was around 250MB, the install only appears to be 9MB. After installing the software, we were prompted to disable fast-start, which we did not do. But we did need to reboot the computer to complete the installation. A copy of the MCP2221 drivers is included. We found the files at C:\Microchip\Hello_FPGA_GUI\MCP2221_ Drivers on our system, although they installed automatically. It appears that a copy of the PIC firmware image (HEX file) is also installed along with the software. Fig.3 shows the rather terse screen you are greeted with when you open the GUI app (it has an “M” icon). At upper right, connecting to the Hello FPGA Kit requires selecting its COM port and pressing the connect/disconnect button next to it. If it lights up green, then you have successfully connected. AI digit recognition We found the AI Digit Recognition demonstration to be the most interesting. Once the Hello FPGA Kit is connected to the host application, siliconchip.com.au Fig.6: the FIR demo shows several stages in the signal processing sequence, from defining and selecting a filter to testing it and validating the result through FFT analysis of the output. the demo firmware is easy to upload. Under “DAT File”, browse to the file named “Demo3_HF10_DIGIT_ CNN_FF_V1.1.dat”. On our system, this was located at C:\Microchip\ Hello_FPGA_GUI\DatFiles. Ensure “PROGRAM” is selected under the “Action” drop-down and then click Run. The process takes almost a minute, and prompts you to unplug and replug the board; this appeared to be unnecessary, although we did need to press the “Connect” button to restart communication. One upside of this demo is that it doesn’t need the GUI app to work, as much information is displayed on the onboard LCD screen. The LCD should show what the camera sees, with some other information overlaid. The centre of the LCD is marked by a green square, which indicates the area that the FPGA is processing. This is scaled down to a 28x28 greyscale image, a preview of which is shown in the LCD’s upper-left corner. It shows the AI Digit Recognition output at lower left, as a digit between 0 and 9. You can click on the FPGA Demo tab of the GUI app to see some more information (Fig.4). Some testing digit sets are available. It is a simple case of pointing the camera at the digits in the GUI app to see that it recognises them. The Hello FPGA Kit had no trouble identifying the sample digits shown, siliconchip.com.au Fig.7: a major focus of the Hello FPGA Kit is on power consumption, and the Power Graph tab allows this to be seen in real time, including during and after applying the Flash Freeze mode. as long as the camera was correctly aligned with the image. Since this is how the ‘AI’ has been trained, that is to be expected. The More Info button and CNN Structure tab both show some background about how the neural network in the AI is organised. AI and neural networks are a field which is seeing more interest of late. The demo on the Hello FPGA kit is impressive, but also telling of how narrow its capabilities are. Other demos There are two other demos included with the Hello FPGA GUI App. These are the FIR Filter demo (found by loading and programming the “Demo1_ FIR_FILTER_V1.3.dat” file) and the CAM LCD demo (“Demo2_HF10_ CAM_LCD_FF_V1.1.dat”). These both rely on the GUI App to control and interface to the Hello The LCD screen on the Hello FPGA Kit displays the number that it recognises, so the AI demo can be used without the GUI app or even a computer connected. Australia’s electronics magazine August 2020  35 Fig.8: the Libero design software allows graphical editing of advanced functional blocks. The design files for the three supplied demos can be viewed and edited, so you can see how they work. That makes it much easier to design your own firmware, rather than starting from scratch. FPGA Kit. Select the appropriate DAT file, select “PROGRAM” and click Run. The CAM LCD demo (Fig.5) shows some basic image processing; the controls are seen in the accompanying image and include brightness, contrast and colour balance. The image from the camera is processed by the FPGA and then displayed on the LCD. The FIR filter demo (Fig.6) shows how the Hello FPGA Kit can be used in a signal processing application. FIR stands for Finite Impulse Response and is a technique usually used to implement a digital filter. An FIR filter consists of several coefficients which are applied to a window of samples to produce the output. The important thing is that the process involves a large number of multiplications (by coefficients) happening almost simultaneously. Since the Smartfusion2 FPGA has many hardware multipliers, this becomes a lot easier to implement in real-time. Having the multipliers in hardware means the processing is fast, which can be critical if the processing needs to occur with low latency. An FIR filter has advantages over discrete filters in that the characteristics are set by the coefficients. The same hardware can be set to behave as low-pass, high-pass, bandpass or band-stop by changing the coefficients. The cut-off frequencies can be changed, and the filter may even be Fig.9: 16 sets of digits are supplied for use with the AI Demo. They shows that it can recognise digits regardless of how they are drawn. You could test it with your own writing, too! 36  Silicon Chip something that is not even possible with discrete components. With the FIR Filter demo, a filter is generated and the coefficients can be seen. This filter can then be applied to a signal to see its effect; the FFT (Fast Fourier Transform) is also displayed so that the frequency response of the filter can be validated. Power and Flash Freeze As we noted earlier, power use and monitoring is an important feature of the Hello FPGA Kit. The app provides a Power tab to explore this. A time vs power graph dominates this view (Fig.7), with a live power reading at lower left. There are also buttons to switch the Flash Freeze feature on and off. Flash Freeze is akin to sleep or suspend modes in microcontrollers, and the demos allow users not only to see the standby power levels, but also measure how long it takes for the unit to wake up from Flash Freeze. Libero design software The demonstration programs are quite interesting, but somewhat limited in scope. To develop further applications requires the Libero design Australia’s electronics magazine siliconchip.com.au software. To program and debug a device requires a licence, but it’s also possible to get a 60-day free licence which allows you to see how the Libero design software works. As mentioned earlier, we tested on Windows 10, although there are also versions for Linux. The Libero design software is a 7GB download from the Microsemi website, at http://siliconchip.com.au/link/ab3q You will need to register to do this. The install involves unzipping the file and then installing it, which requires another 15GB of hard drive space. During the install, you’ll also be prompted to provide a license; the trial license can be requested as part of this process, although it may take up to 45 minutes to be processed. Once granted, follow the instructions to install the license; this involves setting an environment variable to a path. We also downloaded the design files for the three demos from www.microsemi.com/existing-parts/ parts/150925#resources There is even a design guide for using the Libero software with the Hello FPGA hardware, at siliconchip.com. au/link/ab3r You’ll need to unzip these to work with them. The actual project is another compressed archive inside this. We opened the Image Processing demo project (“HF10_OV7725_LCD_ FF.prjx”). As shown in Fig.8, the overall view is a similar block-based editor to what we saw when we reviewed the iceStick hardware and tested the IceStudio software (siliconchip.com.au/ Article/11521). So even if you have minimal experience with FPGAs or coding in HDL, it is possible to create a custom design using the Hello FPGA hardware, al- though you will need a different license to do so, on top of the cost of the board. Conclusion The Hello FPGA Kit is simple to use and demonstrates several diverse features and applications. The GUI app is straightforward to use. The free trial license of the Libero design software is a good way to investigate its suitability for designing for your custom applications. The Hello FPGA Kit is well-provisioned; it is currently listed for sale at around AU$300. The FPGA chip costs around AU$50 by itself, in multiples of 119 (in a 7 x 17 chip tray). You can order a Kit from Digi-key (siliconchip.com.au/link/ab3s) or Mouser (siliconchip.com.au/link/ab3t). Both companies offer free international express (courier) delivery for this item (and any other items you order at the SC same time). Would you like to work for Australia's No.1 electronics magazine? We have an entry-level, full-time position available that's ideal for someone who's enthusiastic about electronics. If you enjoy reading about the projects we publish – and probably even build some of them – we want to hear from you! You don't have to be an expert – just keen to learn! Or maybe you already have plenty of knowledge but are looking for a change of pace in your employment. IS HIRING! It will require travel to our office in Brookvale (on Sydney’s Northern Beaches) each weekday. We are only one minute away from the major bus route from the city and ferry wharf, or a car space is available. On-the-job training will be provided. There are definitely opportunities for advancement in this position. To start with, we need someone who can: Identify components and create kits of parts from a parts list. Program microcontrollers using existing software (HEX files). Yes, we’ll train you! Order components and manage stock. Pick parts and pack orders. Help subscribers with renewals, changes of address and other queries. Answer and direct e-mails and take phone calls. Proofread articles. Maybe even write some articles! Ideal applicants will be self-motivated and able to work well by themselves as well as in a small team. If you are unable to work full-time, we may be able to accommodate you. Successful candidates will be given a six-month paid trial, followed by a permanent position, if you have what it takes! If this sounds like we're talking about you, email your resume/CV (along with contact details!) to jobs<at>siliconchip.com.au siliconchip.com.au Australia’s electronics magazine August 2020  37
<
<