From: Kevin Redon Date: Thu, 19 Oct 2017 07:00:53 +0000 (+0200) Subject: Add a DS2432 test-case. X-Git-Url: https://sigrok.org/gitaction?a=commitdiff_plain;h=cc6b436225ac75f8167e5c8afff2b7e495c70d1f;p=sigrok-test.git Add a DS2432 test-case. This fixes (parts of) bug #1019. --- diff --git a/decoder/test/ds2432/ds2432.output b/decoder/test/ds2432/ds2432.output new file mode 100644 index 0000000..619aef4 --- /dev/null +++ b/decoder/test/ds2432/ds2432.output @@ -0,0 +1,52 @@ +69894-70374 ds2432: text: "Reset/presence: true" +73711-74269 ds2432: text: "Function command: Write scratchpad (0x0f)" +75086-77023 ds2432: text: "Target address: 0x0080" +77840-82619 ds2432: text: "Data: 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00" +83007-84161 ds2432: text: "CRC: ok" +134234-134714 ds2432: text: "Reset/presence: true" +138050-138609 ds2432: text: "Function command: Read scratchpad (0xaa)" +138997-140150 ds2432: text: "Target address: 0x0080" +140191-140748 ds2432: text: "Data status (E/S): 0x5f" +141490-146221 ds2432: text: "Data: 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00" +146964-148117 ds2432: text: "CRC: ok" +204483-204963 ds2432: text: "Reset/presence: true" +208300-208858 ds2432: text: "Function command: Load first secret (0x5a)" +209675-212986 ds2432: text: "Authorization pattern (TA1, TA2, E/S): 0x80,0x00,0x5f" +227178-227734 ds2432: text: "End of operation" +268429-268909 ds2432: text: "Reset/presence: true" +272246-272805 ds2432: text: "Function command: Read scratchpad (0xaa)" +273194-274346 ds2432: text: "Target address: 0x0080" +274387-274944 ds2432: text: "Data status (E/S): 0xdf" +340860-341340 ds2432: text: "Reset/presence: true" +344676-345235 ds2432: text: "Function command: Copy scratchpad (0x55)" +346051-349363 ds2432: text: "Authorization pattern (TA1, TA2, E/S): 0x80,0x00,0xdf" +350179-362169 ds2432: text: "Message authentication code: 0x42,0x42,0x42,0x42,0x42,0x42,0x42,0x42,0x42,0x42,0x42,0x42,0x42,0x42,0x42,0x42,0x42,0x42,0x42,0x42" "MAC: 0x42,0x42,0x42,0x42,0x42,0x42,0x42,0x42,0x42,0x42,0x42,0x42,0x42,0x42,0x42,0x42,0x42,0x42,0x42,0x42" +409233-409713 ds2432: text: "Reset/presence: true" +413050-413609 ds2432: text: "Function command: Read memory (0xf0)" +414425-416363 ds2432: text: "Target address: 0x0000" +416752-417308 ds2432: text: "Data: 0x00" +417349-417904 ds2432: text: "Data: 0x00" +417945-418501 ds2432: text: "Data: 0x00" +418542-419098 ds2432: text: "Data: 0x00" +419138-419694 ds2432: text: "Data: 0x00" +419735-420291 ds2432: text: "Data: 0x00" +420332-420887 ds2432: text: "Data: 0x00" +420928-421484 ds2432: text: "Data: 0x00" +479228-479708 ds2432: text: "Reset/presence: true" +483044-483603 ds2432: text: "Function command: Read authenticated page (0xa5)" +484420-486357 ds2432: text: "Target address: 0x0000" +486749-505799 ds2432: text: "Data: 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00" +506541-507098 ds2432: text: "Padding: ok" +507840-508994 ds2432: text: "CRC: ok" +512916-524822 ds2432: text: "Message authentication code: 0x67,0x51,0x56,0x16,0x9d,0x7b,0x1b,0x89,0x35,0x64,0x1f,0xd5,0xd4,0x1a,0x20,0x83,0xda,0x43,0xe5,0xf3" "MAC: 0x67,0x51,0x56,0x16,0x9d,0x7b,0x1b,0x89,0x35,0x64,0x1f,0xd5,0xd4,0x1a,0x20,0x83,0xda,0x43,0xe5,0xf3" +525565-526718 ds2432: text: "MAC CRC: ok" +544001-544481 ds2432: text: "Reset/presence: true" +547818-548376 ds2432: text: "Function command: Compute next secret (0x33)" +549193-551130 ds2432: text: "Target address: 0x0000" +567958-568514 ds2432: text: "End of operation" +609765-610245 ds2432: text: "Reset/presence: true" +613581-614140 ds2432: text: "Function command: Read scratchpad (0xaa)" +614528-615681 ds2432: text: "Target address: 0x0000" +615722-616278 ds2432: text: "Data status (E/S): 0x5f" +617021-621758 ds2432: text: "Data: 0xaa,0xaa,0xaa,0xaa,0xaa,0xaa,0xaa,0xaa" +622500-623654 ds2432: text: "CRC: ok" diff --git a/decoder/test/ds2432/test.conf b/decoder/test/ds2432/test.conf new file mode 100644 index 0000000..e527a9f --- /dev/null +++ b/decoder/test/ds2432/test.conf @@ -0,0 +1,7 @@ +test ds2432 + protocol-decoder onewire_link channel owr=0 + protocol-decoder onewire_network + protocol-decoder ds2432 + stack onewire_link onewire_network ds2432 + input onewire/ds2432/ds2432.sr + output ds2432 annotation match ds2432.output