From: Jiri Kubias <jiri.kubias(a)addat.cz>
---
app/digi_can/spi_com.c | 8 ++++++--
1 files changed, 6 insertions(+), 2 deletions(-)
diff --git a/app/digi_can/spi_com.c b/app/digi_can/spi_com.c
index 917d512..a0f875b 100644
--- a/app/digi_can/spi_com.c
+++ b/app/digi_can/spi_com.c
@@ -285,7 +285,7 @@ char read_msg_from_buf(canmsg_t *msg)
{
uint8_t count = get_num_rec_canmsg();
- if(count < 0)
+ if(count == 0)
return 1;
@@ -304,7 +304,11 @@ void com_read_can(struct recv_message_s *msg)
char req_to_send = msg->data[0];
- PRINT_STR("\nlen");
+ PRINT_STR("\nread ");
+ PRINT_INT(can_buffer.read);
+ PRINT_STR("\nwrite ");
+ PRINT_INT(can_buffer.write);
+ PRINT_STR("\nlen ");
PRINT_INT(len);
--
1.6.4.4
---