Lua Script upload through MAVFtp Error

I am encountered with an error when trying to upload .lua files. They are being uploaded in a “scripts” folder under the APM. Initially there was a “scripts” folder not under the APM.(I am unsure of if this may be a factor.)
luascript error - VA 20121 1
This is the resulting error message. When expanded, the details tab reveals this.


What may be causing this error, and how would I go about addressing it to get the .lua files to work in the given location?
Setup is using an Orange Cube and herelink, and has worked before.
Arducopter V4.1.5

1 Like

Hi,
same problem here with Arducopter 4.2.2

Solved it by flashing Arduplane firmware on the cube to reset all params, then reflashed Arducopter 4.2.2 and now I don’t get any MavFTP errors anymore, I can upload scripts

Actually, problem appeared again when I flashed my old params on this fresh firmware. I did a “compare” params and now MavFTP is bugged again.
I will try to find which one causes the bug.
Edit : found it.
Parameter ADSB_TYPE , if set to 0, creates this bug.

You have to make sure that ADSB_TYPE is set to 1 in order to make MavFTP and Lua scripts working

That sounds like a potential actual bug. Consider creating an issue on GitHub.

Done :+1:

First time I actually reported a bug on the Ardu Github, since I always thought I was the one missing something

1 Like

Txs for the report.

I tried to re-create the issue using Copter-4.3.0-DEV (aka “latest”) and beta Mission Planner but was unable to. I suspect that we had an issue in MP a few months ago but it’s been fixed now.

Could you try updating MP? Go to MP’s Help screen and push the “Check for Updates” at the bottom. If possible post a screen shot of the MP version you’re using (this is displayed on the top left of the window).

image

2 Likes

Hi,
I answered on the GitHub also, but here is my version (no update was found)
image

Also, I recorded my screen to show you
https://drive.google.com/drive/folders/1QXjP2x7GxKNr4arJ3ZagvT9KwYlfwTiw?usp=sharing

can someone post a tlog of the failure?

I have an Orange Cube here as well that has the same issue with Arducopter 4.2.2
But it works after I reboot using the “Reboot” button on the “Compass” setup screen of Mission Planner.
Btw. can we have a reboot button in Mission Planner that’s more easily accessible?

Had the same issue, @Lupin 's fix above also worked for me

I have the same problem sometimes with PX4 Arduplane v4.2.2 and MP 1.3.77 build 1.3.8110.38294.
I am disabling the “SCR_ENABLE”, i upload the script and then i enable the “SCR_ENABLE”.
Maybe it is not the right way but at least it works.
But i don’t have this problem all the time.

You mean like this one:

image

Or this one (Ctrl-F to access)?

image