mirror of
https://github.com/PX4/PX4-Autopilot.git
synced 2026-05-28 10:46:33 +08:00
Fix RC out
This commit is contained in:
@@ -28,19 +28,18 @@ class RCOutput():
|
|||||||
"# 14000 .. 14999 Tri Y\n"
|
"# 14000 .. 14999 Tri Y\n"
|
||||||
"\n")
|
"\n")
|
||||||
for group in groups:
|
for group in groups:
|
||||||
result += "# GROUP: %s \n\n" % group.GetName()
|
result += "# GROUP: %s\n\n" % group.GetName()
|
||||||
for param in group.GetParams():
|
for param in group.GetParams():
|
||||||
name = param.GetName()
|
|
||||||
path = param.GetPath().rsplit('/', 1)[1]
|
path = param.GetPath().rsplit('/', 1)[1]
|
||||||
id_val = param.GetId()
|
id_val = param.GetId()
|
||||||
name = param.GetFieldValue("short_desc")
|
name = param.GetFieldValue("short_desc")
|
||||||
long_desc = param.GetFieldValue("long_desc")
|
long_desc = param.GetFieldValue("long_desc")
|
||||||
|
|
||||||
result += "#\n"
|
result += "#\n"
|
||||||
result += "# %s\n" % name
|
result += "# %s\n" % param.GetName()
|
||||||
result += "if param compare SYS_AUTOSTART %s\n" % id_val
|
result += "if param compare SYS_AUTOSTART %s\n" % id_val
|
||||||
result += "then\n"
|
result += "then\n"
|
||||||
result += " sh /etc/init.d/%s\n" % path
|
result += "\tsh /etc/init.d/%s\n" % path
|
||||||
result += "fi\n"
|
result += "fi\n"
|
||||||
|
|
||||||
#if long_desc is not None:
|
#if long_desc is not None:
|
||||||
|
|||||||
Reference in New Issue
Block a user