summaryrefslogtreecommitdiff
path: root/decoder
AgeCommit message (Collapse)Author
2022-10-03parallel: recent PD implementation flushes last samples upon EOFHEADmasterGerhard Sittig
Catch up with the implementation of the "parallel" decoder, which now flushes previously accumulated information when the end of input data is seen. Which completes the last "item" (data pattern on the bus), and may complete another "word" (data value that spans several bus cycles).
2022-04-23pdtest: add support for input format specs in test.conf filesGerhard Sittig
The pdtest(1) utility interprets test.conf files. Extend the syntax of 'input' lines. These used to accept one filename only. Add support for 'format' and 'option' keywords. These translate to runtc(1) -I options.
2022-04-23runtc: add support for input file formats other than native srzipGerhard Sittig
Introduce the -I command line option for the tstrun(1) utility, accept input file format names, and options for the input module. Take single words in multiple -I specs to simplify the internal interface between the pdtest(1) and the tstrun(1) tools. This follows the existing pattern for decoder options and channel assignments. The first spec is the file format name (use 'match' for automatic detection). Subsequent specs are input module options. This makes all libsigrok supported input file formats available to the sigrok-test environment, which formerly was constrained to .sr archives only. Although the runtc(1) utility resides in the "decoder/" hierarchy, it can both use VCD and other files to stimulate decoder tests, as well as cover file formats and their specific features in future tests by checking that the imported file's content is seen or that their options take effect.
2022-04-23runtc: cope with "late" samplerate announcementGerhard Sittig
The previous implementation expected a rather specific sequence of SR_DF_HEADER with samplerate, then SR_DF_LOGIC. This worked with .sr formatted session files. But does not work with other input formats. Also process SR_DF_META packets. Pass any samplerate that we learn about to decoders' .metadata() method. Defer decoders' .start() until the first logic samples are seen. This improves robustness of the decoder tests.
2022-04-23runtc: avoid the 'class' identifier in C language application codeGerhard Sittig
The 'class' identifier is a reserved word in the C++ language, while development tools may combine C and C++ support and get confused. Avoid conflicts, rename the variable to 'class_' in runtc.c source code.
2021-12-26runtc: optionally send EOF to decoder sessionGerhard Sittig
Communicate EOF to the decoder session (when the library supports it).
2021-12-26ir_irmp: introduce IRMP test cases, cover NEC/RC5/RC6/SIRC and othersGerhard Sittig
The upstream IRMP project's decoder core is only slowly moving, we can consider the IRMP decoder integration to be stable and don't expect the output to change violently any longer. The issue of requiring a single core instance remains and affects the GUI, but not the single threaded test suite. This set of test cases re-uses the NEC, RC5, RC6, and SIRC dumps which are covered by individual decoders, too. Ideally detection results would be identical, but in practise the annotation positions and the level of details will differ between implementations due to their internal operation and design choices. The IRMP test set also covers dumps which are not covered by other IR decoders. It's interesting to see how not all key repetitions are caught and how single press might be missed as well. It's valuable to remain aware during maintenance, and see how occassional failure changes. This is why an empty output for a non-empty dump is kept here, too.
2021-01-13seven_segment: expand the alphabet and show unknown charactersBen Gardiner
Signed-off-by: Ben Gardiner <ben.l.gardiner@gmail.com>
2020-11-12parallel: add missing data file with expected output for SQI trafficGerhard Sittig
2020-11-11pdtest: use less expensive Python routine to get text differencesGerhard Sittig
Python ships with a difflib(3) module which is used in the pdtest(1) utility. The Differ.compare() routine is rather expensive, especially when the set of input text becomes "large" (a few thousand lines). Use the less expensive unified_diff() routine instead which does not suffer from that cost. From the sigrok-test perspective the resulting data is as usable.
2020-11-11parallel: also expect bits count in addition to data valueGerhard Sittig
Catch up with the parallel decoder's implementation. Documented Python output includes the bus width and cycle count for items and words. [ see a word-diff for the commit's essence ]
2020-11-11parallel: add test case for parallel PD on SQI trafficGerhard Sittig
The parallel decoder can also be used to interpret SQI communication. Using the chip select as the reset/enable signal increases robustness. Implement a test case to cover this recently added decoder feature.
2020-11-11parallel: expect demuxed words only after their items were seenGerhard Sittig
Catch up with the "parallel" decoder's implementation. Annotations for demultiplexed words are sent after all their individual bits were seen. Data content remains identical, this is exclusively about emission order.
2020-08-18ir_nec: catch up with STOP bit width adjustmentGerhard Sittig
The decoder implementation changed the STOP width from 0.652ms to 0.562ms, which affects the STOP bit and the REMOTE button code annotations' end.
2020-08-16avr_isp: catch up with support for EEPROM readGerhard Sittig
The decoder implementation got extended to support EEPROM reads. Adjust the test expectation.
2020-08-16avr_isp: catch up with warning class for "unknown command" messageGerhard Sittig
The decoder implementation moved the "Unknown command" message from the PE annotation class (programming enable instruction) to warnings. Adjust the test expectation.
2020-08-12sdq: introduce SDQ decoder test (bits, bytes, break)Gerhard Sittig
Add a simple test on a short snippet of the SDQ capture. This covers the extraction of bits and bytes, and the synchronization on BREAK symbols.
2020-08-08st7735: Extend test to also cover unknown commandsgregor-anich-uibk
[ gsi: rephrased commit message, trimmed down capture for test ]
2020-07-26can: add Python output to std and ext brs test casesGerhard Sittig
The CAN decoder implementation got extended to output Python data. Adjust the test expectation to cover these on some dump files.
2020-07-26ir_nec: add tests for extended NEC protocol (failed and passed)Gerhard Sittig
A capture with extended NEC protocol data became available. Add tests for failed interpretation with the standard approach, and successful interpretation when the extended protocol gets selected.
2020-07-22sirc: introduce test for Sony IR (SIRC)Gerhard Sittig
2020-07-20spdif: Add/update test-cases after decoder changes.Uwe Hermann
2020-07-18rgb_led_ws281x: Add RGBW testcaseSoeren Apel
2020-07-18Test for WS281x RGBWStefan
yet dummy, as I could not execute the test myself. Test data (ws281x_RGBW_4mhz_snippet.sr) is already available.
2020-07-18caliper: introduce tests (pos/neg, mm/inch, change)Gerhard Sittig
Add tests for the caliper decoder. Cover positive and negative numbers, automatic millimeter and inch detection, and omitted annotations when values haven't changed.
2020-07-02pjon: catch up with "communication relation" annotationsGerhard Sittig
2020-06-24pjon: add tests for PJON frames over PJDL link layerGerhard Sittig
2020-06-02nrf905: Update after file move.Uwe Hermann
2020-05-26Add test for Nordic Semiconductor nRF905 protocol decoderJorge Solla
2020-04-11ad5626: Add a test-case.Uwe Hermann
2020-04-11ad79x0: Add a test-case.Uwe Hermann
2020-04-11ltc242x: Add a test-case.Uwe Hermann
2020-04-11ltc26x7: Add some test-cases.Uwe Hermann
2020-04-11adxl345: Add some test-cases.Uwe Hermann
2020-01-13sdcard_sd: Add a few more test-cases.Uwe Hermann
2020-01-13sdcard_sd: Updates after recent PD changes.Uwe Hermann
2020-01-11cjtag: Update after PD changes.Uwe Hermann
2020-01-10ds1307: Updates after annotation class PD fixes.Uwe Hermann
2020-01-10sdcard_sd: Updates after annotation class PD fixes.Uwe Hermann
2020-01-10sdcard_spi: Updates after annotation class PD fixes.Uwe Hermann
2020-01-09cjtag: Add two test-cases.Uwe Hermann
2020-01-05dmx512: Update after new DMX512 PD stacked on UART.Uwe Hermann
2020-01-04dmx512: adjust test.conf, stack dmx512 on top of uartGerhard Sittig
This commit adjusts the test configuration, but does not update the test expectation. This remains for another commit.
2020-01-04ps2: add test for PS/2 data exchange without clock inhibitGerhard Sittig
The capture which was attached to bug #1460 demonstrated a previously unhandled condition, the absence of a host activity after the data byte transmission. Add another test case after the decoder implementation got adjusted.
2020-01-04ps2: adjust to recent implementation, stop ends at rising clock edgeGerhard Sittig
Catch up with a recent change in the PS/2 decoder implementation. End the STOP bit at the rising CLOCK edge already, don't expect a clock inhibit phase after a data byte got transmitted.
2020-01-02flexray: Update test-cases after PD fix.Uwe Hermann
2020-01-02ac97: Add binary output test-cases.Uwe Hermann
2020-01-02ieee488: Enable test-case with empty output.Uwe Hermann
2020-01-01test.conf updates after annotation class/row changes.Uwe Hermann
2020-01-01Updates after annotation class/row changes (singular/plural).Uwe Hermann