Exclave tests for NeTV2
Clone or download
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
bin extend times for gtp tests to accommodate more memory testing Nov 15, 2018
.gitignore don't commit/store .o files Nov 7, 2018
.gitmodules add flterm as a submodule dependency Oct 17, 2018
README.md update README Oct 29, 2018
exclave.service cleanup missing files, add systemd service files Oct 25, 2018
full-sequence.scenario extend times for gtp tests to accommodate more memory testing Nov 15, 2018
hotplug.trigger cleanup missing files, add systemd service files Oct 25, 2018
leds.interface some rudimentary "hello world" infrastracture tests Oct 14, 2018
netv2-burn-spi.test full sequence for auto-full PCB tester complete Oct 25, 2018
netv2-check-all-voltage.test add "quick" test scenario Oct 26, 2018
netv2-check-idcode.test add "quick" test scenario Oct 26, 2018
netv2-check-repl.test update test times to accommodate bios ramtest Nov 15, 2018
netv2-check-repl2.test extend times for gtp tests to accommodate more memory testing Nov 15, 2018
netv2-check-voltage.test add "quick" test scenario Oct 26, 2018
netv2-duton.test cleanup missing files, add systemd service files Oct 25, 2018
netv2-gtp-test.test update test times to accommodate bios ramtest Nov 15, 2018
netv2-main-test.test full test sequence for the "main" test is now complete Oct 21, 2018
netv2-ping-test.test add ping test, audible alerts, try to fix dependency graph Oct 22, 2018
netv2-quick-idcode.test add "quick" test scenario Oct 26, 2018
netv2-quick-repl.test add "quick" test scenario Oct 26, 2018
netv2-quick-setupfpga.test add "quick" test scenario Oct 26, 2018
netv2-quicktest.test add "quick" test scenario Oct 26, 2018
netv2-setup-gtptest.test extend times for gtp tests to accommodate more memory testing Nov 15, 2018
netv2-setup-maintest.test full test sequence for the "main" test is now complete Oct 21, 2018
netv2-tests-pass.test add a pass-test test Oct 29, 2018
netv2.jig some rudimentary "hello world" infrastracture tests Oct 14, 2018
quick-sequence.scenario add "quick" test scenario Oct 26, 2018
run_exclave.sh start pulse audio, root user doesn't have it by default Oct 29, 2018
start.trigger some rudimentary "hello world" infrastracture tests Oct 14, 2018
test-done.test full sequence for auto-full PCB tester complete Oct 25, 2018
webserver.interface full test sequence for the "main" test is now complete Oct 21, 2018

README.md

netv2-tests

Factory tests for NeTV2.

Overview

"Full scenario" requires the following cables and hardware to be installed:

  • TX0->Overlay
  • TX1->RX0
  • PCI express loopback header
  • Rpi loopback/breakout
  • Ping test network cable
  • USB loopback
  • A microSD card
  • A fan

The hardware design that accompanies this test program can be downloaded at: https://github.com/AlphamaxMedia/netv2-testhat

This will check every port and every function. The test requires two passes because a "fully-loaded" FPGA at the current litex rev has difficulty routing clocks to four GTP interfaces (it can route to one easily, and two with some finagling). Some optimization of PLL resource usage and clocks globally would alleviate this, but to make testing expedient we do one test where we test all the features, and then a second, quick GTP-only test to confirm all four GTP channels are soldered correctly.

Once the test completes, it also burns the production firmware into the SPI ROM.

The test is meant to be triggered automatically when the PCI cards are detected as plugged in.

The test directory itself is structured to refer to all of the helper JTAG scripts & firmware images through submodules. The netv-fpga repository is actually included twice, but one on the "master" branch, and other on the "tester-master" branch. Each of these include a copy of the production binary, and the method for updating the tester is thus to do a git pull of the alphamax repository and pull in the latest published binary.

"Quick scenario" requires no cables to be installed, but it does assume you have a jig which can measure all the voltage test points on the PCB. Quick scenario confirms about 80% of the solder connections and also quickly shuts down the board if any voltages are out of spec, thus preventing further damage.

The quick scenario is meant to be a fast check of the PCB to screen gross solder issues before burning the labor and time to run the full scenario. It's meant to be triggered using a mechanical pushbutton.

This is meant to be run using the "exclave" tester infrastructure, which you can get here:

https://github.com/exclave/exclave

And there's an exclave.service file which you can use to install it as a boot service, which means your Rpi will boot into a tester automatically.

This tester depends on the system having a number of libraries installed, including "expect", pulseaudio, and a web interface module which can be downloaded at https://github.com/AlphamaxMedia/jig-20-interface-http. The openocd scripts built into the submodule assume you have the alphamax fork of openocd built and installed, which is necessary because of some critical bugs in the bcm2835 driver that have been submitted to the maintainers for mainline inclusion but it's unclear if it will ever be incorporated. There are also some gpio helper scripts that need to be compiled and setuid to run correctly; those instructions are documented in the ".trigger" files.

A final note is that the scripts include hard-coded paths, because the earlier version of exclave used during development has no option to fix the run path (so the relative path is shifting depending upon where you start exclave, and this is annoying especially when you need it to start as a system service file). Thus the scripts assume you have done a "git clone" of the netv2-tests repository in a directory called /home/pi/code, that you've pulled in the submodules. If you change the username, you'll have to recode all the scripts, unfortunately.