Skip to content

Conversation

alligitor
Copy link

Simple function that uses CMD_LOG opcode for sending a string to the host.
Message has:
Log Level
Tag
Length of message
Message

It has a limit of 256 characters for the message.

Messages are not \0 terminated since there is a length field.

I do have a concern about this code but not sure if it's a problem.
The code allocates a 257 byte buffer on the stack.. It is kinda large for embedded systems. Not sure if this is acceptable.

Mark is working on a more robust/comprehensive logging system. Feel free to decline if not in line with future plans.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant