Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
slapos
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Léo-Paul Géneau
slapos
Commits
cf006ece
Commit
cf006ece
authored
Apr 27, 2023
by
Léo-Paul Géneau
👾
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
component/mavsdk: use mavlink v2 headers
parent
363f4bba
Changes
5
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
7695 additions
and
14 deletions
+7695
-14
component/mavsdk/buildout.cfg
component/mavsdk/buildout.cfg
+2
-3
component/mavsdk/common.xml
component/mavsdk/common.xml
+7684
-0
software/js-drone/buildout.hash.cfg
software/js-drone/buildout.hash.cfg
+2
-2
software/js-drone/main.js
software/js-drone/main.js
+4
-4
software/js-drone/worker.js
software/js-drone/worker.js
+3
-5
No files found.
component/mavsdk/buildout.cfg
View file @
cf006ece
...
@@ -13,7 +13,7 @@ parts =
...
@@ -13,7 +13,7 @@ parts =
[c-astral-headers]
[c-astral-headers]
recipe = slapos.recipe.build:gitclone
recipe = slapos.recipe.build:gitclone
repository = https://lab.nexedi.com/nexedi/c-astral-c-library
repository = https://lab.nexedi.com/nexedi/c-astral-c-library
revision = v
1
.0
revision = v
2
.0
git-executable = ${git:location}/bin/git
git-executable = ${git:location}/bin/git
[gcc]
[gcc]
...
@@ -33,8 +33,7 @@ path = ${mavsdk-source:location}
...
@@ -33,8 +33,7 @@ path = ${mavsdk-source:location}
cmake = ${cmake:location}/bin/cmake
cmake = ${cmake:location}/bin/cmake
pre-configure =
pre-configure =
${git:location}/bin/git submodule update --init --recursive
${git:location}/bin/git submodule update --init --recursive
cp -r ${c-astral-headers:location}/* ${mavsdk-source:location}/src/third_party/mavlink/include/mavlink/v2.0/
cp -r ${c-astral-headers:location}/mavlink/v2.0/* ${mavsdk-source:location}/src/third_party/mavlink/include/mavlink/v2.0/
sed -i 's#common/mavlink.h#CAstral/mavlink.h#' ${mavsdk-source:location}/src/core/mavlink_include.h
configure-command =
configure-command =
${:cmake}
${:cmake}
configure-options =
configure-options =
...
...
component/mavsdk/common.xml
0 → 100644
View file @
cf006ece
This diff is collapsed.
Click to expand it.
software/js-drone/buildout.hash.cfg
View file @
cf006ece
...
@@ -26,7 +26,7 @@ md5sum = 1ff50063f5a54712a0bc0ff38fa74630
...
@@ -26,7 +26,7 @@ md5sum = 1ff50063f5a54712a0bc0ff38fa74630
[main]
[main]
filename = main.js
filename = main.js
md5sum =
d0bfcc79cdd7c1e5b8f5d264cc59074e
md5sum =
21217f85fdab2f6307e3edc6ba74d0b6
[pubsub]
[pubsub]
filename = pubsub.js
filename = pubsub.js
...
@@ -34,4 +34,4 @@ md5sum = 1555496ad591a31a845f33488d5c335d
...
@@ -34,4 +34,4 @@ md5sum = 1555496ad591a31a845f33488d5c335d
[worker]
[worker]
filename = worker.js
filename = worker.js
md5sum =
e4b4ca3bde1a21f1dbfc4ff7fa3b872c
md5sum =
9167a47913658d395a328f67b5a80d36
software/js-drone/main.js
View file @
cf006ece
...
@@ -36,10 +36,10 @@ import { open, exit } from "std";
...
@@ -36,10 +36,10 @@ import { open, exit } from "std";
// to prevent it to finish (and so, exit the quickjs process)
// to prevent it to finish (and so, exit the quickjs process)
worker
=
new
Worker
(
"
{{ worker_script }}
"
);
worker
=
new
Worker
(
"
{{ worker_script }}
"
);
function
quit
(
is_a_drone
,
exit_code
)
{
function
quit
(
is_a_drone
,
shutdown
,
exit_code
)
{
stopPubsub
();
stopPubsub
();
if
(
is_a_drone
)
{
if
(
is_a_drone
)
{
stop
();
stop
(
shutdown
);
}
}
exit
(
exit_code
);
exit
(
exit_code
);
}
}
...
@@ -141,10 +141,10 @@ import { open, exit } from "std";
...
@@ -141,10 +141,10 @@ import { open, exit } from "std";
can_update
=
true
;
can_update
=
true
;
}
else
if
(
type
===
'
exited
'
)
{
}
else
if
(
type
===
'
exited
'
)
{
worker
.
onmessage
=
null
;
worker
.
onmessage
=
null
;
quit
(
configuration
.
isADrone
,
e
.
data
.
exit
);
quit
(
configuration
.
isADrone
,
!
configuration
.
isASimulation
,
e
.
data
.
exit
);
}
else
{
}
else
{
console
.
log
(
'
Unsupported message type
'
,
type
);
console
.
log
(
'
Unsupported message type
'
,
type
);
quit
(
configuration
.
isADrone
,
1
);
quit
(
configuration
.
isADrone
,
!
configuration
.
isASimulation
,
1
);
}
}
};
};
}(
arm
,
console
,
exit
,
open
,
scriptArgs
,
setTimeout
,
start
,
stop
,
stopPubsub
,
}(
arm
,
console
,
exit
,
open
,
scriptArgs
,
setTimeout
,
start
,
stop
,
stopPubsub
,
...
...
software/js-drone/worker.js
View file @
cf006ece
/*jslint nomen: true, indent: 2, maxerr: 3, maxlen: 80 */
/*jslint nomen: true, indent: 2, maxerr: 3, maxlen: 80 */
/*global console, getAltitude, getAltitudeRel, getInitialAltitude, getLatitude,
/*global console, getAltitude, getAltitudeRel, getInitialAltitude, getLatitude,
getLongitude, getYaw, execUserScript, initPubsub, l
anded, l
oiter, setAirspeed,
getLongitude, getYaw, execUserScript, initPubsub, loiter, setAirspeed,
setMessage, setTargetCoordinates, std, triggerParachute, Drone, Worker*/
setMessage, setTargetCoordinates, std, triggerParachute, Drone, Worker*/
import
{
import
{
Drone
,
Drone
,
...
@@ -14,7 +14,6 @@ import {
...
@@ -14,7 +14,6 @@ import {
getLongitude
,
getLongitude
,
getYaw
,
getYaw
,
initPubsub
,
initPubsub
,
landed
,
loiter
,
loiter
,
setAirspeed
,
setAirspeed
,
setMessage
,
setMessage
,
...
@@ -24,7 +23,7 @@ import * as std from "std";
...
@@ -24,7 +23,7 @@ import * as std from "std";
import
{
Worker
}
from
"
os
"
;
import
{
Worker
}
from
"
os
"
;
(
function
(
console
,
getAltitude
,
getAltitudeRel
,
getInitialAltitude
,
(
function
(
console
,
getAltitude
,
getAltitudeRel
,
getInitialAltitude
,
getLatitude
,
getLongitude
,
getYaw
,
initPubsub
,
l
anded
,
l
oiter
,
getLatitude
,
getLongitude
,
getYaw
,
initPubsub
,
loiter
,
setAirspeed
,
setMessage
,
setTargetCoordinates
,
std
,
triggerParachute
,
setAirspeed
,
setMessage
,
setTargetCoordinates
,
std
,
triggerParachute
,
Drone
,
Worker
)
{
Drone
,
Worker
)
{
// Every script is evaluated per drone
// Every script is evaluated per drone
...
@@ -58,7 +57,6 @@ import { Worker } from "os";
...
@@ -58,7 +57,6 @@ import { Worker } from "os";
getSpeed
:
getAirspeed
,
getSpeed
:
getAirspeed
,
getClimbRate
:
getClimbRate
,
getClimbRate
:
getClimbRate
,
id
:
configuration
.
id
,
id
:
configuration
.
id
,
landed
:
landed
,
loiter
:
loiter
,
loiter
:
loiter
,
sendMsg
:
function
(
msg
,
id
)
{
sendMsg
:
function
(
msg
,
id
)
{
if
(
id
===
undefined
)
{
id
=
-
1
;
}
if
(
id
===
undefined
)
{
id
=
-
1
;
}
...
@@ -136,5 +134,5 @@ import { Worker } from "os";
...
@@ -136,5 +134,5 @@ import { Worker } from "os";
}
}
};
};
}(
console
,
getAltitude
,
getAltitudeRel
,
getInitialAltitude
,
getLatitude
,
}(
console
,
getAltitude
,
getAltitudeRel
,
getInitialAltitude
,
getLatitude
,
getLongitude
,
getYaw
,
initPubsub
,
l
anded
,
l
oiter
,
setAirspeed
,
setMessage
,
getLongitude
,
getYaw
,
initPubsub
,
loiter
,
setAirspeed
,
setMessage
,
setTargetCoordinates
,
std
,
triggerParachute
,
Drone
,
Worker
));
setTargetCoordinates
,
std
,
triggerParachute
,
Drone
,
Worker
));
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment