Attached is the VHDL code for continuous sampling mode.
Continuous mode is enabled by issuing 0x10 command. The ARM led will blink slowly once data transfer has begun. If there is data overrun, the rate of blinking will increase and the TRIG led will lit up.
Note that triggering is ignored and RLE is not supported.
On my netbook with version 3.0 of the PIC firmware, the system can only achieve a maximum sample rate of 10kHz for 8 bit samples. Currently, the bottleneck is the PIC USB transfer rate.
Included is a test SUMP client to demonstrate this new capability. Select Test Mode and memory depth of 256K. Test mode outputs the contents of a 32 bit counter incremented by the sample rate clock.
Attached is a cleaned up version of the VHDL code with the following enhancements:
New SPI code, works with the latest PIC firmware (v3.0)
Working Metadata command (not sure if the values returned are correct)
New RLE code; n bit counters for n bit data width (except for 24 bits). Additional compression for cases with zero run lengths. RLE stop command is also implemented
Fixed the spurious triggers due to floating external trigger pin
Resolved timing issues
Also attached is the diff for Device.java that handles the RLE data and the fix for the before/after trigger capture.
Don't forget to regenerate the BRAM core before compiling the project.