libsigrokdecode: decoding SOP*'s from 3 k-codes; text output.

Allow detailed decoding of SOP, SOP', SOP", SOP'_Debug, SOP"_Debug.
Allow decoding SOP*, Cable Reset, Hard Reset from 3 valid k-codes,
(instead of all 4), which is specified in the USB PD spec.

Allow text output without running PulseView.

Signed-off-by: Dawei Li <daweili@google.com>

BUG=chrome-os-partner:42703
TEST=BEGIN
The following command will output the pd packets in text format:
sigrok-cli -i test.sr -P usb_pd_bmc:cc=CC1,usb_pd_packet -A usb_pd_packet=text

Change CC1 to CC2, if that is the case.
END

Change-Id: I18ca145b9be5c28770b3ab7c42c2783008dc8754
Reviewed-on: https://chromium-review.googlesource.com/289249
Commit-Ready: Sheng-liang Song <ssl@chromium.org>
Tested-by: Dawei Li <daweili@google.com>
Reviewed-by: Sheng-liang Song <ssl@chromium.org>
2 files changed