I've tried to modify MinimOSD-Extra to show me current APM Copter 3.3 status message on screen. The problem is that I get only couple of messages at startup and then it stops.

This is how I approximately do it:

case MAVLINK_MSG_ID_STATUSTEXT:
{
mavlink_msg_statustext_get_text(&msg, osd_warning);
int length = strlen(osd_warning);
memset(osd_formatted_warning, 0x20, WARNING_PANEL_WIDTH);
memcpy(osd_formatted_warning, osd_warning, length);
};
break;

What happens is that on startup I do get:
Calibrating barometer

Ground start

However if I launch QGroundStation then I see that it gets other messages like "PreArm: GPS horiz error 9.0".

The subscription code looks like this:

void request_mavlink_rates()
{
const int maxStreams = 6;
const uint8_t MAVStreams[maxStreams] = {MAV_DATA_STREAM_RAW_SENSORS,
MAV_DATA_STREAM_EXTENDED_STATUS,
MAV_DATA_STREAM_RC_CHANNELS,
MAV_DATA_STREAM_POSITION,
MAV_DATA_STREAM_EXTRA1,
MAV_DATA_STREAM_EXTRA2};
const uint16_t MAVRates[maxStreams] = {0x02, 0x02, 0x05, 0x02, 0x05, 0x02};
for (int i=0; i < maxStreams; i++) {
mavlink_msg_request_data_stream_send(MAVLINK_COMM_0,
apm_mav_system, apm_mav_component,
MAVStreams[i], MAVRates[i], 1);
}
}

Should I do some extra steps in order to get status text messages?

-----------------------

Update from my experiments:

It looks as if some statustext messages are not set to all GCSs, but the presence of e.g. MAVProxy GCS triggers broadcasting to all stations. Looking at the arducopter code I don't see anything which could trigger such behavior. I do see different ways of sending messages e.g. 

const char *reason = ahrs.prearm_failure_reason();
if (reason) {
GCS_MAVLINK::send_statustext_all(MAV_SEVERITY_CRITICAL, "PreArm: %s", reason);
} else {
gcs_send_text(MAV_SEVERITY_CRITICAL,"PreArm: Need 3D Fix");
}

but those methods look ok internally at first glance.

You need to be a member of diydrones to add comments!

Join diydrones

Email me when people reply –

Replies

  • I have same problem with my Mav2Leds project, I can't get the severity info to manage my leds when prearm errors occurs.

    Found any solution ?

    • My workaround was to send hearbeats to Pixhawk from OSD.

  • OK, after some more experiments I've fixed (or workarounded the issue in my forked Copter-3.3 version): https://github.com/diydrones/ardupilot/issues/3513

  • The interesting this is that if I connect MAVProxy as well, I see all statustext updates via MiminOSD!

  • I've also added a code to display me number of times I've got MAVLINK_MSG_ID_STATUSTEXT and it stuck at 4.

This reply was deleted.

Activity

DIY Drones via Twitter
RT @MarvelmindMaxim: Extreme precision for 60 swarming robots. #marvelmind #autonomousrobotics #robotics #swarmrobotics #rtls #ips #indoor…
23 hours ago
DIY Drones via Twitter
RT @MarvelmindMaxim: Precise (±2cm) tracking for racing boats and autonomous boats. Works outdoor and indoor. #autonomous #AutonomousVehic…
23 hours ago
DIY Drones via Twitter
RT @MarvelmindMaxim: Helping PixHawk folks to fly autonomous quadcopters using PX4 and ArduPilot. https://marvelmind.com/drones/ Equally suitab…
23 hours ago
DIY Robocars via Twitter
RT @chr1sa: The @DIYRobocars @donkey_car virtual AI car race is starting in 15 minutes! Watch it live on Twitch https://www.twitch.tv/mossmann3333 htt…
Saturday
DIY Robocars via Twitter
RT @chr1sa: Don't miss our monthly @DIYRobocars @donkey_car virtual AI car race tomorrow at 10:00am PT live on Twitch. Head-to-head racing…
Friday
DIY Robocars via Twitter
RT @sparkfun: Our completed tutorial on building an @NVIDIA Jetson Nano-powered @Sphero RVR gets your bot up and running via teleoperation…
Thursday
DIY Robocars via Twitter
RT @SmallpixelCar: Freeway test https://t.co/4V5tV9lhIP
Thursday
DIY Robocars via Twitter
Very small autonomous cars racing, thanks to an overhead camera: https://control.ee.ethz.ch/research/team-projects/autonomous-rc-car-racing.html
Wednesday
DIY Robocars via Twitter
Wednesday
DIY Robocars via Twitter
Jul 29
DIY Robocars via Twitter
RT @chr1sa: Don't miss our virtual AI car race this Saturday! Real developers + virtual cars =🏎️🏎️🏎️ Head-to-head battles with thrills, sp…
Jul 28
DIY Robocars via Twitter
Jul 27
DIY Robocars via Twitter
RT @usashirou1: Jetson nano by Isaac Kaya #jetson https://t.co/Mu1N0CyQkN
Jul 23
DIY Robocars via Twitter
RT @GPUsolution: JetRacer mady by Iflytek company #JetsonNANO #Nvidia https://t.co/MimTymIwge
Jul 23
DIY Robocars via Twitter
RT @openmvcam: I love this: Mega or Mini? Image Classification on the 1MB OpenMV Cam H7 by Ish Ot Jr. in OpenMV, Edge Impulse, Internet of…
Jul 23
DIY Robocars via Twitter
RT @RoboticMasters: This is looking pretty good... but still needs a bit more refinement. Pure OpenCV Turning Sign Detection. No Tensorfl…
Jul 23
More…