Hi all,
I'm very new to MAVLink. I've got the jist of how it works and started experimenting sending/receiving messages with my UNO. I've found that when including <mavlink.h> it appears to break the use of Serial.print() for debugging. Is this normal? Here's my code:
#include <mavlink.h>
#include <serial.h>
void setup()
{
Serial.begin(57600);
Serial.println("test");
}
void loop()
{
}
The code will not print my debugging statements. I can also get the following example code to compile, so I know the compiler is gaining access to mavlink.h. It still won't print via Serial.
#include <mavlink.h>
#include <serial.h>
void setup()
{
Serial.begin(57600);
Serial.println("test");
Serial.println(MAVLINK_MAX_PACKET_LEN);
mavlink_message_t msg;
mavlink_msg_heartbeat_pack(100, 200, &msg, MAV_FIXED_WING, MAV_AUTOPILOT_GENERIC);
uint8_t buf[MAVLINK_MAX_PACKET_LEN];
uint16_t len = mavlink_msg_to_send_buffer(buf,&msg);
}
void loop()
{
Serial.println("test");
}
I'm wondering if the ATMEG chip is suffering from a runtime error. I don't understand why my UNO won't print my debug statements. Anyone else experience this?