From f123430a7d84fa71ad59760304e547983468b1cc Mon Sep 17 00:00:00 2001 From: johnny9 <985648+johnny9@users.noreply.github.com> Date: Sun, 28 May 2023 12:48:00 -0400 Subject: [PATCH] bm1397: update job test case values --- components/bm1397/test/test_job_command.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/components/bm1397/test/test_job_command.c b/components/bm1397/test/test_job_command.c index a15e8ef5..90eb39c7 100644 --- a/components/bm1397/test/test_job_command.c +++ b/components/bm1397/test/test_job_command.c @@ -24,13 +24,13 @@ TEST_CASE("Check known working midstate + job command", "[bm1397]") send_init(); uint8_t work1[50] = { - 0xFD, // job id + 0xA3, // job id 0x01, // number of midstates 0x00, 0x00, 0x00, 0x00, // starting nonce 0x3A, 0xAE, 0x05, 0x17, // nbits - 0x1F, 0x80, 0x73, 0x64, // ntime - 0x56, 0x96, 0xFC, 0x6D, // merkle 4 - 0xF4, 0xF7, 0x09, 0x8A, 0x04, 0x2E, 0x14, 0x2A, 0xC5, 0xC8, 0x15, 0x78, 0xB9, 0x8B, 0xFC, 0x3C, 0xB3, 0xB2, 0xE7, 0x2A, 0x4E, 0x00, 0x6A, 0xF3, 0x96, 0xA9, 0x3B, 0xF2, 0x22, 0x3F, 0xB1, 0xF7}; + 0xA0, 0x84, 0x73, 0x64, // ntime + 0x50, 0xE3, 0x71, 0x61, // merkle 4 + 0x7E, 0x02, 0x70, 0x35, 0xB1, 0xAC, 0xBA, 0xF2, 0x3E, 0xA0, 0x1A, 0x52, 0x73, 0x44, 0xFA, 0xF7, 0x6A, 0xB4, 0x76, 0xD3, 0x28, 0x21, 0x61, 0x18, 0xB7, 0x76, 0x0F, 0x7B, 0x1B, 0x22, 0xD2, 0x29}; struct job_packet test_job; memcpy((uint8_t *) &test_job, work1, 50); @@ -43,8 +43,8 @@ TEST_CASE("Check known working midstate + job command", "[bm1397]") struct nonce_response nonce; memcpy((void *) &nonce, buf, sizeof(struct nonce_response)); - // expected nonce CD C0 92 7B - TEST_ASSERT_EQUAL_UINT32(0x7b92c0cd, nonce.nonce); + // expected nonce 9B 04 4C 0A + TEST_ASSERT_EQUAL_UINT32(0x0a4c049b, nonce.nonce); //reset the bm1397 reset_BM1397();