You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by xi...@apache.org on 2024/09/13 04:33:33 UTC

(nuttx-apps) 02/02: drivertest: Modify output format

This is an automated email from the ASF dual-hosted git repository.

xiaoxiang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx-apps.git

commit dad9b5afa32394e227e833981539d935bdee9a0d
Author: Shoukui Zhang <zh...@xiaomi.com>
AuthorDate: Tue May 14 16:02:17 2024 +0800

    drivertest: Modify output format
    
    before:
    slave size 4slave poll read     0       1       2       3
    master write    0       1       2       3
    
    now:
    read size = 4
    slave poll read         0       1       2       3
    master write    0       1       2       3
    
    Signed-off-by: Shoukui Zhang <zh...@xiaomi.com>
---
 testing/drivertest/drivertest_i2c_write.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/testing/drivertest/drivertest_i2c_write.c b/testing/drivertest/drivertest_i2c_write.c
index 3d64d6cc0..ba2193964 100644
--- a/testing/drivertest/drivertest_i2c_write.c
+++ b/testing/drivertest/drivertest_i2c_write.c
@@ -249,7 +249,8 @@ static FAR void *slave_read_thread(FAR void *arg)
       if (rfds.revents == POLLIN)
         {
           size = read(rfds.fd, buffer, sizeof(buffer));
-          printf("slave size %d", size);
+          printf("read size = %d\n", size);
+          assert(size == SIZE_OF_BUFFER);
           printf("slave poll read \t");
           for (i = 0; i < SIZE_OF_BUFFER; i++)
             {