Skip to content

Problems debugging the library #48

Open
@SWoto

Description

@SWoto

Hey everyone,
hope you're all safe and sound (as possible) during these dark times.

Aditional Information

  • SAMD based board
  • Arduino IDE 1.8.13

Problem

I'm using the ArduinoModbus library and so far so good. However, yesterday, I tried communicating with a different hardware with the Arduino as the slave to have its input registers read. The code, Modbus RTU Server Kitchen Sink with little modifications, receives the message right (added print function to the .cpp) but doesn't reply as it should.

Due to most past of the core code being in c i can't use Serial.print() to debug and looks like printf and fprintf doesn't work (at least not for me).

Have anyone managed to make those two functions work? How are you debugging it?

(Slave/Server) Serial Monitor

21:23:06.865 -> Received: 2A040000000137D1 
21:23:06.902 -> RETURN: modbus_reply: 7

(Master/Client) Serial Monitor

Master send:2A040000000137D1
Master received:

Metadata

Metadata

Assignees

No one assigned

    Labels

    type: imperfectionPerceived defect in any part of project

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions