APM Mission Planner with APC220 RF module

Dear All,

Firt...let me thank you guys working very hard with all these Ardu-things (ArduPilot, ArduCopter, APM, ...). Very nice and I love it!

I have bought a set of APC220 RF sender/receivers for using as telemtry link for my ArduCopter. I could not connect with the APM Mission Planner...got a time-out for "no heartbeat sent". It did however work with HK GCS and QGroundStation so I started to dig into why it did not work with APM. Luckily, the code is available and hence I have now managed to get it to work.

The APC220 requires the RTS and DTR to be false at all times as no handshaking can be used. I also found that the version of ArduCopter (2.4.1) that I have does not send heartbeats on the telemetry port...have I set something up badly here?

To get this to work you can edit the code to change how the OpenBg() is executed in the MavLink.cs according to:

lock (objlock) // so we dont have random traffic

{
log.Info("Open port with " + BaseStream.PortName + " " + BaseStream.BaudRate);

if (useAPC220)
{
// No RTS/DTR at all for this one...
BaseStream.RtsEnable = false;
BaseStream.DtrEnable = false;

BaseStream.Open();

BaseStream.DiscardInBuffer();
}
else
{
BaseStream.Open();

BaseStream.DiscardInBuffer();

BaseStream.toggleDTR();
}

Thread.Sleep(1000);
}

I added a small "useAPC220" propery that I set to "true".

I also added/changed a setting where the code expects the heartbeats to come:

if (useAPC220)
{
// No hearbeats coming from my 2.4.1 FW using APC220...why?
// firmware issue?
sysid = 1;
compid = 1;
mavlinkversion = 2;
aptype = 2;
break;
}
else
{
// incase we are in setup mode
BaseStream.WriteLine("planner\rgcs\r");

buffer = getHeartBeat();

// incase we are in setup mode
BaseStream.WriteLine("planner\rgcs\r");

System.Threading.Thread.Sleep(1);

buffer1 = getHeartBeat();
}

So, I hardcoded some values (version, id's etc) that is coming from the heartbeat package normally.

Anyhow, this is a rather bad approach (but quick and dirty and works for my special case). So, now I wonder if it would be possible to add a few settings in the APM Mission Planner to handle this? Maybe one can have a setting for "use handshake" and one for "expect heartbeat". This would make the APM to be compatible with the APC220 as well.

Well...that was what I had in mind. Thanx once again for your hard work!

/Stefan

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

Join diydrones

Email me when people reply –

Replies

  • Moderator

    Seems to work now?? Except for Read Waypoints:

    3692680839?profile=original

  • APC220 RF module works now & has been working for the last 2 release. MP setting has to be modified in configuration 
    unchecked reset USB on reset .
  • Moderator

    So close yet so far. 212 of 238 received...

    I haven't thrown them away just yet, just thought I'd try check and see if anything has changed. Nope

    3692565277?profile=original

  • Moderator

    OK, I can connect, get parameters and get flight data, but if I change a parameter and hit 'Write' it's fine but I can only do that once, then I get a "set param_xx failed" error. However even though I get that error the parameter appears to have been written because if I hit Refresh the parameter that I changed shows correctly. HOWEVER, more often than not on Refresh I get a "serial link isn't fast enough" error.


    These APC220's are really frustrating, maybe I must just throw them away!

  • Mine works with MP 1.1.92

  • Moderator

    Confirmed, no connection at all with MP v1.1.85

  • Hello to everybody:

    I am new here,

    I have being flying with Arducopter since 6 months ago, I hade The APMplanner and I connected to my Acopter with dhw Wireless APC220

    everyting was OK but I have upgrade today and I cant not connet again with the wireless, I can do it with the USB cable but no with the APC220.

    The modems are OK because I use then to connect an MK to the MK tools and it works good.

    I receive the message " No Heatbeats packets received"

    Where is the problem??

    Thanks

    Alberto 

  • 100KM

    With mission planner 1.1.59 and APM 2.5.3 (git 21880a5d1750 ) no joy in connecting anymore.  It used to work with the sending rate of params / 3 on 1.1.56, but now even that won't connect.  I get a timeout (no heartbeat) and it won't even try to load params anymore...

    ctrl-T also doesn't want to connect.

    Damn this is annoying, what can I do to help troubleshoot this ?  I can modify ACM code, but I don't have visual studio and am not familiar with the mission planner code.

  • My module are still working on 2.5 & I have them duplexed 57600 baud rate ! use the latest misson planer! but not on APM2

  • I can confirm APM2 serial interface not connecting with APC220, RN-XV WiFly Module, RN-42 AT Bluetooth Modem - BlueSMiRF Silver. all these are working with APM1 any thing I can do to help resolve this issue?

This reply was deleted.

Activity

DIY Robocars via Twitter
RT @knightsautoteam: Hi @diyrobocars, we are Orlando's first Autonomous racing club and would love your support. We are hosting our first K…
Jan 20
DIY Robocars via Twitter
RT @Heavy02011: #VirtualRaceLeague: @DIYRobocars Race #14 - #ParkingLotNerds join us January 15th for #AutonomousRacing #RoboRace ⁦@DAVGtec…
Jan 16
DIY Robocars via Twitter
RT @chr1sa: And after that came our races, 50 in all. This battle between these two Russians was the best we've ever seen -- incredible fig…
Jan 16
DIY Robocars via Twitter
RT @chr1sa: Before our @DIYRobocars virtual race this weekend, we had a presentation from the team that won the Indy Autonomous Challenge i…
Jan 16
DIY Drones via Twitter
Dec 12, 2021
DIY Robocars via Twitter
Dec 12, 2021
DIY Robocars via Twitter
RT @chr1sa: Just a week to go before our next @DIYRobocars race at @circuitlaunch, complete with famous Brazilian BBQ. It's free, fun for k…
Dec 4, 2021
DIY Robocars via Twitter
How to use the new @donkey_car graphical UI to edit driving data for better training https://www.youtube.com/watch?v=J5-zHNeNebQ
Nov 28, 2021
DIY Robocars via Twitter
RT @SmallpixelCar: Wrote a program to find the light positions at @circuitlaunch. Here is the hypothesis of the light locations updating ba…
Nov 26, 2021
DIY Robocars via Twitter
RT @SmallpixelCar: Broke my @HokuyoUsa Lidar today. Luckily the non-cone localization, based on @a1k0n LightSLAM idea, works. It will help…
Nov 25, 2021
DIY Robocars via Twitter
@gclue_akira CC @NVIDIAEmbedded
Nov 23, 2021
DIY Robocars via Twitter
RT @luxonis: OAK-D PoE Autonomous Vehicle (Courtesy of zonyl in our Discord: https://discord.gg/EPsZHkg9Nx) https://t.co/PNDewvJdrb
Nov 23, 2021
DIY Robocars via Twitter
RT @f1tenth: It is getting dark and rainy on the F1TENTH racetrack in the @LGSVLSimulator. Testing out the new flood lights for the racetra…
Nov 23, 2021
DIY Robocars via Twitter
RT @JoeSpeeds: Live Now! Alex of @IndyAChallenge winning @TU_Muenchen team talking about their racing strategy and open source @OpenRobotic…
Nov 20, 2021
DIY Robocars via Twitter
RT @DAVGtech: Live NOW! Alexander Wischnewski of Indy Autonomous Challenge winning TUM team talking racing @diyrobocars @Heavy02011 @Ottawa…
Nov 20, 2021
DIY Robocars via Twitter
Incredible training performance with Donkeycar https://www.youtube.com/watch?v=9yy7ASttw04
Nov 9, 2021
More…