├── .github └── workflows │ └── main.yml ├── .vscode ├── extensions.json ├── settings.json └── spellright.dict ├── LICENSE ├── README.md ├── reg └── udral │ ├── README.md │ ├── physics │ ├── acoustics │ │ └── Note.0.1.dsdl │ ├── dynamics │ │ ├── README.md │ │ ├── rotation │ │ │ ├── Planar.0.1.dsdl │ │ │ └── PlanarTs.0.1.dsdl │ │ └── translation │ │ │ ├── Linear.0.1.dsdl │ │ │ └── LinearTs.0.1.dsdl │ ├── electricity │ │ ├── Power.0.1.dsdl │ │ ├── PowerTs.0.1.dsdl │ │ ├── Source.0.1.dsdl │ │ └── SourceTs.0.1.dsdl │ ├── kinematics │ │ ├── README.md │ │ ├── cartesian │ │ │ ├── Point.0.1.dsdl │ │ │ ├── PointState.0.1.dsdl │ │ │ ├── PointStateVar.0.1.dsdl │ │ │ ├── PointStateVarTs.0.1.dsdl │ │ │ ├── PointVar.0.1.dsdl │ │ │ ├── Pose.0.1.dsdl │ │ │ ├── PoseVar.0.1.dsdl │ │ │ ├── PoseVarTs.0.1.dsdl │ │ │ ├── State.0.1.dsdl │ │ │ ├── StateVar.0.1.dsdl │ │ │ ├── StateVarTs.0.1.dsdl │ │ │ ├── Twist.0.1.dsdl │ │ │ ├── TwistVar.0.1.dsdl │ │ │ └── TwistVarTs.0.1.dsdl │ │ ├── geodetic │ │ │ ├── Point.0.1.dsdl │ │ │ ├── PointState.0.1.dsdl │ │ │ ├── PointStateVar.0.1.dsdl │ │ │ ├── PointStateVarTs.0.1.dsdl │ │ │ ├── PointVar.0.1.dsdl │ │ │ ├── Pose.0.1.dsdl │ │ │ ├── PoseVar.0.1.dsdl │ │ │ ├── State.0.1.dsdl │ │ │ ├── StateVar.0.1.dsdl │ │ │ └── StateVarTs.0.1.dsdl │ │ ├── rotation │ │ │ ├── Planar.0.1.dsdl │ │ │ └── PlanarTs.0.1.dsdl │ │ └── translation │ │ │ ├── Linear.0.1.dsdl │ │ │ ├── LinearTs.0.1.dsdl │ │ │ ├── LinearVarTs.0.1.dsdl │ │ │ ├── Velocity1VarTs.0.1.dsdl │ │ │ ├── Velocity3Var.0.1.dsdl │ │ │ └── Velocity3Var.0.2.dsdl │ ├── optics │ │ └── HighColor.0.1.dsdl │ ├── thermodynamics │ │ └── PressureTempVarTs.0.1.dsdl │ └── time │ │ ├── TAI64.0.1.dsdl │ │ ├── TAI64Var.0.1.dsdl │ │ └── TAI64VarTs.0.1.dsdl │ └── service │ ├── actuator │ ├── common │ │ ├── FaultFlags.0.1.dsdl │ │ ├── Feedback.0.1.dsdl │ │ ├── Status.0.1.dsdl │ │ ├── _.0.1.dsdl │ │ └── sp │ │ │ ├── Scalar.0.1.dsdl │ │ │ ├── Vector2.0.1.dsdl │ │ │ ├── Vector3.0.1.dsdl │ │ │ ├── Vector31.0.1.dsdl │ │ │ ├── Vector4.0.1.dsdl │ │ │ ├── Vector6.0.1.dsdl │ │ │ ├── Vector8.0.1.dsdl │ │ │ └── _.0.1.dsdl │ ├── esc │ │ └── _.0.1.dsdl │ └── servo │ │ └── _.0.1.dsdl │ ├── battery │ ├── Error.0.1.dsdl │ ├── Parameters.0.3.dsdl │ ├── Status.0.2.dsdl │ ├── Technology.0.1.dsdl │ └── _.0.1.dsdl │ ├── common │ ├── Heartbeat.0.1.dsdl │ └── Readiness.0.1.dsdl │ └── sensor │ └── Status.0.1.dsdl ├── uavcan ├── diagnostic │ ├── 8184.Record.1.0.dsdl │ ├── 8184.Record.1.1.dsdl │ └── Severity.1.0.dsdl ├── file │ ├── 405.GetInfo.0.1.dsdl │ ├── 405.GetInfo.0.2.dsdl │ ├── 406.List.0.1.dsdl │ ├── 406.List.0.2.dsdl │ ├── 407.Modify.1.0.dsdl │ ├── 407.Modify.1.1.dsdl │ ├── 408.Read.1.0.dsdl │ ├── 408.Read.1.1.dsdl │ ├── 409.Write.1.0.dsdl │ ├── 409.Write.1.1.dsdl │ ├── Error.1.0.dsdl │ ├── Path.1.0.dsdl │ └── Path.2.0.dsdl ├── internet │ └── udp │ │ ├── 500.HandleIncomingPacket.0.1.dsdl │ │ ├── 500.HandleIncomingPacket.0.2.dsdl │ │ ├── 8174.OutgoingPacket.0.1.dsdl │ │ └── 8174.OutgoingPacket.0.2.dsdl ├── metatransport │ ├── can │ │ ├── ArbitrationID.0.1.dsdl │ │ ├── BaseArbitrationID.0.1.dsdl │ │ ├── DataClassic.0.1.dsdl │ │ ├── DataFD.0.1.dsdl │ │ ├── Error.0.1.dsdl │ │ ├── ExtendedArbitrationID.0.1.dsdl │ │ ├── Frame.0.1.dsdl │ │ ├── Frame.0.2.dsdl │ │ ├── Manifestation.0.1.dsdl │ │ └── RTR.0.1.dsdl │ ├── ethernet │ │ ├── EtherType.0.1.dsdl │ │ └── Frame.0.1.dsdl │ ├── serial │ │ ├── Fragment.0.1.dsdl │ │ └── Fragment.0.2.dsdl │ └── udp │ │ ├── DEPRECATED │ │ ├── Endpoint.0.1.dsdl │ │ └── Frame.0.1.dsdl ├── node │ ├── 430.GetInfo.1.0.dsdl │ ├── 434.GetTransportStatistics.0.1.dsdl │ ├── 435.ExecuteCommand.1.0.dsdl │ ├── 435.ExecuteCommand.1.1.dsdl │ ├── 435.ExecuteCommand.1.2.dsdl │ ├── 435.ExecuteCommand.1.3.dsdl │ ├── 7509.Heartbeat.1.0.dsdl │ ├── Health.1.0.dsdl │ ├── ID.1.0.dsdl │ ├── IOStatistics.0.1.dsdl │ ├── Mode.1.0.dsdl │ ├── Version.1.0.dsdl │ └── port │ │ ├── 7510.List.0.1.dsdl │ │ ├── 7510.List.1.0.dsdl │ │ ├── ID.1.0.dsdl │ │ ├── ServiceID.1.0.dsdl │ │ ├── ServiceIDList.0.1.dsdl │ │ ├── ServiceIDList.1.0.dsdl │ │ ├── SubjectID.1.0.dsdl │ │ ├── SubjectIDList.0.1.dsdl │ │ └── SubjectIDList.1.0.dsdl ├── pnp │ ├── 8165.NodeIDAllocationData.2.0.dsdl │ ├── 8166.NodeIDAllocationData.1.0.dsdl │ └── cluster │ │ ├── 390.AppendEntries.1.0.dsdl │ │ ├── 391.RequestVote.1.0.dsdl │ │ ├── 8164.Discovery.1.0.dsdl │ │ └── Entry.1.0.dsdl ├── primitive │ ├── Empty.1.0.dsdl │ ├── String.1.0.dsdl │ ├── Unstructured.1.0.dsdl │ ├── array │ │ ├── Bit.1.0.dsdl │ │ ├── Integer16.1.0.dsdl │ │ ├── Integer32.1.0.dsdl │ │ ├── Integer64.1.0.dsdl │ │ ├── Integer8.1.0.dsdl │ │ ├── Natural16.1.0.dsdl │ │ ├── Natural32.1.0.dsdl │ │ ├── Natural64.1.0.dsdl │ │ ├── Natural8.1.0.dsdl │ │ ├── Real16.1.0.dsdl │ │ ├── Real32.1.0.dsdl │ │ └── Real64.1.0.dsdl │ └── scalar │ │ ├── Bit.1.0.dsdl │ │ ├── Integer16.1.0.dsdl │ │ ├── Integer32.1.0.dsdl │ │ ├── Integer64.1.0.dsdl │ │ ├── Integer8.1.0.dsdl │ │ ├── Natural16.1.0.dsdl │ │ ├── Natural32.1.0.dsdl │ │ ├── Natural64.1.0.dsdl │ │ ├── Natural8.1.0.dsdl │ │ ├── Real16.1.0.dsdl │ │ ├── Real32.1.0.dsdl │ │ └── Real64.1.0.dsdl ├── register │ ├── 384.Access.1.0.dsdl │ ├── 385.List.1.0.dsdl │ ├── Name.1.0.dsdl │ └── Value.1.0.dsdl ├── si │ ├── sample │ │ ├── acceleration │ │ │ ├── Scalar.1.0.dsdl │ │ │ └── Vector3.1.0.dsdl │ │ ├── angle │ │ │ ├── Quaternion.1.0.dsdl │ │ │ └── Scalar.1.0.dsdl │ │ ├── angular_acceleration │ │ │ ├── Scalar.1.0.dsdl │ │ │ └── Vector3.1.0.dsdl │ │ ├── angular_velocity │ │ │ ├── Scalar.1.0.dsdl │ │ │ └── Vector3.1.0.dsdl │ │ ├── duration │ │ │ ├── Scalar.1.0.dsdl │ │ │ └── WideScalar.1.0.dsdl │ │ ├── electric_charge │ │ │ └── Scalar.1.0.dsdl │ │ ├── electric_current │ │ │ └── Scalar.1.0.dsdl │ │ ├── energy │ │ │ └── Scalar.1.0.dsdl │ │ ├── force │ │ │ ├── Scalar.1.0.dsdl │ │ │ └── Vector3.1.0.dsdl │ │ ├── frequency │ │ │ └── Scalar.1.0.dsdl │ │ ├── length │ │ │ ├── Scalar.1.0.dsdl │ │ │ ├── Vector3.1.0.dsdl │ │ │ ├── WideScalar.1.0.dsdl │ │ │ └── WideVector3.1.0.dsdl │ │ ├── luminance │ │ │ └── Scalar.1.0.dsdl │ │ ├── magnetic_field_strength │ │ │ ├── Scalar.1.0.dsdl │ │ │ ├── Scalar.1.1.dsdl │ │ │ ├── Vector3.1.0.dsdl │ │ │ └── Vector3.1.1.dsdl │ │ ├── magnetic_flux_density │ │ │ ├── Scalar.1.0.dsdl │ │ │ └── Vector3.1.0.dsdl │ │ ├── mass │ │ │ └── Scalar.1.0.dsdl │ │ ├── power │ │ │ └── Scalar.1.0.dsdl │ │ ├── pressure │ │ │ └── Scalar.1.0.dsdl │ │ ├── temperature │ │ │ └── Scalar.1.0.dsdl │ │ ├── torque │ │ │ ├── Scalar.1.0.dsdl │ │ │ └── Vector3.1.0.dsdl │ │ ├── velocity │ │ │ ├── Scalar.1.0.dsdl │ │ │ └── Vector3.1.0.dsdl │ │ ├── voltage │ │ │ └── Scalar.1.0.dsdl │ │ ├── volume │ │ │ └── Scalar.1.0.dsdl │ │ └── volumetric_flow_rate │ │ │ └── Scalar.1.0.dsdl │ └── unit │ │ ├── acceleration │ │ ├── Scalar.1.0.dsdl │ │ └── Vector3.1.0.dsdl │ │ ├── angle │ │ ├── Quaternion.1.0.dsdl │ │ └── Scalar.1.0.dsdl │ │ ├── angular_acceleration │ │ ├── Scalar.1.0.dsdl │ │ └── Vector3.1.0.dsdl │ │ ├── angular_velocity │ │ ├── Scalar.1.0.dsdl │ │ └── Vector3.1.0.dsdl │ │ ├── duration │ │ ├── Scalar.1.0.dsdl │ │ └── WideScalar.1.0.dsdl │ │ ├── electric_charge │ │ └── Scalar.1.0.dsdl │ │ ├── electric_current │ │ └── Scalar.1.0.dsdl │ │ ├── energy │ │ └── Scalar.1.0.dsdl │ │ ├── force │ │ ├── Scalar.1.0.dsdl │ │ └── Vector3.1.0.dsdl │ │ ├── frequency │ │ └── Scalar.1.0.dsdl │ │ ├── length │ │ ├── Scalar.1.0.dsdl │ │ ├── Vector3.1.0.dsdl │ │ ├── WideScalar.1.0.dsdl │ │ └── WideVector3.1.0.dsdl │ │ ├── luminance │ │ └── Scalar.1.0.dsdl │ │ ├── magnetic_field_strength │ │ ├── Scalar.1.0.dsdl │ │ ├── Scalar.1.1.dsdl │ │ ├── Vector3.1.0.dsdl │ │ └── Vector3.1.1.dsdl │ │ ├── magnetic_flux_density │ │ ├── Scalar.1.0.dsdl │ │ └── Vector3.1.0.dsdl │ │ ├── mass │ │ └── Scalar.1.0.dsdl │ │ ├── power │ │ └── Scalar.1.0.dsdl │ │ ├── pressure │ │ └── Scalar.1.0.dsdl │ │ ├── temperature │ │ └── Scalar.1.0.dsdl │ │ ├── torque │ │ ├── Scalar.1.0.dsdl │ │ └── Vector3.1.0.dsdl │ │ ├── velocity │ │ ├── Scalar.1.0.dsdl │ │ └── Vector3.1.0.dsdl │ │ ├── voltage │ │ └── Scalar.1.0.dsdl │ │ ├── volume │ │ └── Scalar.1.0.dsdl │ │ └── volumetric_flow_rate │ │ └── Scalar.1.0.dsdl └── time │ ├── 510.GetSynchronizationMasterInfo.0.1.dsdl │ ├── 7168.Synchronization.1.0.dsdl │ ├── SynchronizedTimestamp.1.0.dsdl │ ├── TAIInfo.0.1.dsdl │ └── TimeSystem.0.1.dsdl └── verify /.github/workflows/main.yml: -------------------------------------------------------------------------------- 1 | name: Main Workflow 2 | on: push 3 | 4 | jobs: 5 | build: 6 | runs-on: ubuntu-latest 7 | name: Verify data type definitions 8 | 9 | steps: 10 | - name: Checkout 11 | uses: actions/checkout@v2 12 | 13 | - name: Install dependencies 14 | run: pip3 install pydsdl 15 | 16 | - name: Run data types verification script 17 | run: ./verify 18 | -------------------------------------------------------------------------------- /.vscode/extensions.json: -------------------------------------------------------------------------------- 1 | { 2 | // See http://go.microsoft.com/fwlink/?LinkId=827846 3 | // for the documentation about the extensions.json format 4 | "recommendations": [ 5 | "uavcan.dsdl", 6 | "ban.spellright", 7 | "ctf0.auto-comment-next-line", 8 | ] 9 | } 10 | -------------------------------------------------------------------------------- /.vscode/settings.json: -------------------------------------------------------------------------------- 1 | { 2 | "editor.wordWrapColumn": 120, 3 | "editor.rulers": [ 4 | 120 5 | ], 6 | "files.eol": "\n", 7 | "files.insertFinalNewline": true, 8 | "files.trimFinalNewlines": true, 9 | "files.trimTrailingWhitespace": true, 10 | "spellright.documentTypes": [ 11 | "markdown", 12 | "plaintext", 13 | "dsdl" 14 | ], 15 | "spellright.ignoreFiles": [ 16 | "**/.gitignore", 17 | "**/.spellignore" 18 | ], 19 | "spellright.language": [ 20 | "en_US" 21 | ], 22 | "spellright.parserByClass": { 23 | "dsdl": { 24 | "parser": "code" 25 | } 26 | }, 27 | "auto-comment-next-line.list": [ 28 | { 29 | "char": "#", 30 | "languages": [ 31 | "dsdl" 32 | ] 33 | } 34 | ] 35 | } 36 | -------------------------------------------------------------------------------- /.vscode/spellright.dict: -------------------------------------------------------------------------------- 1 | unicast 2 | UAVCAN 3 | prioritization 4 | deduplication 5 | CRC 6 | big-endian 7 | iostream 8 | cstdint 9 | cstddef 10 | uint 11 | xFFFFU 12 | add const 13 | nodiscard 14 | const 15 | crc 16 | cout 17 | endl 18 | CCITT 19 | xFFFF 20 | DTID 21 | DTMVN 22 | pseudorandom 23 | metadata 24 | deserialization 25 | deserialized 26 | cassert 27 | constexpr 28 | timestamp 29 | autodetect 30 | pseudocode 31 | tid 32 | iface 33 | RPC 34 | DSDL 35 | versioning 36 | namespace 37 | namespaces 38 | foo 39 | bool 40 | downcasting 41 | arg 42 | A-Za-z 43 | A-Za-z0-9_ 44 | endian 45 | BEDA 46 | LSB 47 | prepended 48 | prepending 49 | FOO 50 | interoperate 51 | equivalency 52 | Versioning 53 | Golgafrincham 54 | cryopod 55 | golgafrincham 56 | sirius_cyber_corp 57 | versioned 58 | PSU 59 | CRYOBOX 60 | fortytwo 61 | uavcan.org 62 | Kirienko 63 | microcontrollers 64 | GNSS 65 | Gergeleit 66 | Streich 67 | Ousterhout 68 | Ongaro 69 | semver.org 70 | IEC 71 | UCS 72 | Tx 73 | API 74 | unitless 75 | CANopen 76 | JST 77 | GH 78 | Dronecode 79 | de 80 | pinout 81 | UAV 82 | nanosatellites 83 | AWG 84 | EMI 85 | kbit 86 | ns 87 | PHY 88 | serializable 89 | Zubax 90 | delayable 91 | NMI 92 | microcontroller 93 | TODO 94 | Inv 95 | CSMA 96 | timestamping 97 | Subminiature 98 | Inkscape 99 | SVG 100 | GJ 101 | nano 102 | baz 103 | BAZ 104 | stdout 105 | stderr 106 | tmp 107 | py 108 | Sep 109 | Erlangen 110 | Mainz 111 | pnp 112 | RTCM 113 | config 114 | gigajoule 115 | MTU 116 | detokenize 117 | si 118 | reusability 119 | bootloaders 120 | Datasheet 121 | GPS 122 | GLONASS 123 | Supercapacitor 124 | LNA 125 | MDL 126 | USB 127 | LIS3MDL 128 | u-Blox 129 | NMEA 130 | supercapacitor 131 | MSL 132 | MTTF 133 | Typ 134 | HMC 135 | Kbps 136 | driverless 137 | CLI 138 | DCD 139 | JTAG 140 | SWD 141 | TPWR 142 | SWDIO 143 | SWDCLK 144 | GND 145 | UID 146 | bootloader 147 | bootup 148 | broadcasted 149 | OFFLINE 150 | vcs 151 | ok 152 | Mbit 153 | UTC 154 | num 155 | WGS84 156 | ned 157 | sats 158 | pdop 159 | PDOP 160 | ECEF 161 | ecef 162 | GDOP 163 | HDOP 164 | TDOP 165 | VDOP 166 | NDOP 167 | EDOP 168 | homonymous 169 | ahrs 170 | ga 171 | param 172 | Libuavcan 173 | LF 174 | HC 175 | GL 176 | GN 177 | YX 178 | RMC 179 | functools 180 | GPRMC 181 | lstrip 182 | rstrip 183 | xor 184 | ord 185 | str 186 | GPGGA 187 | GPGSV 188 | HCHDG 189 | YXXDR 190 | GPGSA 191 | xxxxxx 192 | hhmmss 193 | xxxxx 194 | GGA 195 | ddmmyy 196 | Geoidal 197 | GSV 198 | SNR 199 | HDG 200 | XDR 201 | FLD 202 | XYZ 203 | PZUBAX 204 | tesla 205 | cfg 206 | whitespaces 207 | gnssbridge 208 | YAML 209 | minipage 210 | sw 211 | hw 212 | mmm 213 | dd 214 | yyyy 215 | MAVLink 216 | BCI 217 | YMODEM 218 | XMODEM 219 | Autoconfigured 220 | Cancelled 221 | App 222 | fw 223 | Forsberg 224 | NAK 225 | sz 226 | vv 227 | TTFF 228 | sensorless 229 | BLDC 230 | Sapog 231 | ESR 232 | PWM 233 | RCPWM 234 | un-man-ned 235 | wa-ter-craft 236 | multiplatform 237 | FET 238 | PWR 239 | RGB 240 | plaintext 241 | SHA-512 242 | RSA-1024 243 | UTF 244 | POSIX 245 | IETF 246 | mul 247 | dec 248 | oct 249 | nz 250 | dq 251 | ascii 252 | nq 253 | Pygments 254 | regex 255 | SLCAN 256 | LAWICEL 257 | SMD 258 | Mbps 259 | ACK 260 | NACK 261 | loopback 262 | Loopback 263 | DLC 264 | ABCDEF 265 | abcdef 266 | RTR 267 | bitrate 268 | baudrate 269 | uart 270 | Hartkopp 271 | gpio 272 | GPIO 273 | pb0 274 | pb 275 | ol 276 | ih 277 | il 278 | intdd 279 | uintdd 280 | lexerless 281 | schemas 282 | octothorp 283 | Elementwise 284 | metatype 285 | metaserializable 286 | struct 287 | enum 288 | prn 289 | nul 290 | lpt 291 | significand 292 | MSB 293 | microarchitectures 294 | deconstructed 295 | repres 296 | online 297 | surjective 298 | intravehicular 299 | supertype 300 | subtyping 301 | supertypes 302 | polymorphically 303 | IDE 304 | Spellright 305 | Sheremet 306 | WAIC 307 | Epilog 308 | UDP 309 | IP 310 | LUT 311 | concretized 312 | concretizations 313 | CANaerospace 314 | TTCAN 315 | pyuavca 316 | 126BBDAA 317 | org 318 | deduplicated 319 | abc 320 | ijk 321 | schemaless 322 | fn 323 | println 324 | syn-chro-ni-za-tion 325 | com-mu-ni-ca-tion 326 | creativecommons 327 | TBD 328 | unresolvable 329 | ad-hoc 330 | quaternions 331 | quaternion 332 | unscaled 333 | milliampere 334 | suboptimal 335 | Implementers 336 | invariants 337 | USENIX 338 | integrators 339 | Whitespace 340 | runtime 341 | boolean 342 | Bitwise 343 | Cardinality 344 | superset 345 | Unary 346 | pos 347 | booleans 348 | attrib 349 | cmp 350 | equ 351 | geq 352 | leq 353 | neq 354 | lss 355 | grt 356 | Backus-Naur 357 | parameterized 358 | priori 359 | lossy 360 | polymorphism 361 | subtype 362 | Subtype 363 | subtypes 364 | extensibility 365 | th 366 | parameterization 367 | invariance 368 | retransmit 369 | aperiodic 370 | uncommented 371 | Intra 372 | natively 373 | duplications 374 | uptime 375 | incrementing 376 | enqueue 377 | representable 378 | retransmission 379 | merchantability 380 | uncomment 381 | pydsdl 382 | github 383 | texer 384 | vscode 385 | extensionpack 386 | DTH 387 | submodules 388 | Liskov 389 | deserializer 390 | BLS 391 | evolvable 392 | Protobuf 393 | composable 394 | setpoint 395 | ESC 396 | Composability 397 | mocap 398 | DS-015 399 | allocatees 400 | Allocatee 401 | ABCD 402 | srv 403 | sha256 404 | pitot 405 | CAS 406 | OOP 407 | alignee 408 | UML 409 | UDRAL 410 | multirotors 411 | DRone 412 | UAVs 413 | un 414 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2014-2019 UAVCAN Development Team 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | 23 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | Regulated DSDL definitions 2 | ========================== 3 | 4 | [![Main Workflow](https://github.com/OpenCyphal/public_regulated_data_types/actions/workflows/main.yml/badge.svg)](https://github.com/OpenCyphal/public_regulated_data_types/actions/workflows/main.yml) 5 | [![Forum](https://img.shields.io/discourse/https/forum.opencyphal.org/users.svg)](https://forum.opencyphal.org) 6 | 7 | This repository contains definitions of the regulated Cyphal data types. 8 | [Cyphal](http://opencyphal.org) is an open technology for real-time intravehicular distributed computing 9 | and communication based on modern networking standards. 10 | 11 | Contributors must obey the guidelines defined in this document. 12 | Feedback and proposals are welcome on the [Cyphal forum](https://forum.opencyphal.org). 13 | 14 | A web-based DSDL compiler is available at [nunaweb.opencyphal.org](https://nunaweb.opencyphal.org). 15 | 16 | ## Namespaces 17 | 18 | Regulated data types include the standard data types and domain-specific public definitions. 19 | 20 | Per the specification, standard data types are contained in the root namespace `uavcan`, 21 | and domain-specific public regulated definitions are in the root namespace `reg`. 22 | The latter contains nested namespaces named after the domain. 23 | 24 | Vendors are encouraged to define interfaces to their products or systems using the definitions available 25 | in this repository instead of defining custom types in order to facilitate reusability and reduce the 26 | fragmentation of the ecosystem. 27 | 28 | If a fixed regulated port-ID is needed for a new type, 29 | developers are free to choose any unoccupied identifier from the ranges 30 | defined by the specification before submitting the pull request. 31 | 32 | ## Identifier ranges 33 | 34 | Refer to the specification for background information and motivation. 35 | The limits specified here are inclusive. 36 | 37 | The upper part of the non-standard ranges may be repurposed for standard types shall that become necessary, 38 | so new non-standard regulated fixed port-ID allocations should be done near the bottom. 39 | Likewise, the non-standard ranges may be expanded into the unregulated area if their exhaustion becomes imminent. 40 | 41 | ### Subjects 42 | 43 | From | To | Purpose 44 | --------|-----------|------------------------------------- 45 | 0 | 6143 | Unregulated identifiers 46 | 6144 | 7167 | Non-standard regulated identifiers (namespace `reg`) 47 | 7168 | 8191 | Standard regulated identifiers (namespace `uavcan`) 48 | 49 | ### Services 50 | 51 | From | To | Purpose 52 | --------|-----------|------------------------------------------------ 53 | 0 | 255 | Unregulated identifiers 54 | 256 | 383 | Non-standard regulated identifiers (namespace `reg`) 55 | 384 | 511 | Standard regulated identifiers (namespace `uavcan`) 56 | 57 | ## Standard data types 58 | 59 | The standard data types are contained in the root namespace `uavcan`. 60 | 61 | ### Standard fixed identifier allocation 62 | 63 | #### Subjects 64 | 65 | Ordered by priority from high to low. 66 | 67 | Namespace | Lower bound (inclusive) 68 | ----------------------------|------------------------- 69 | `uavcan.time` | 7168 70 | `uavcan.node` | 7509 71 | `uavcan.pnp` | 8164 72 | `uavcan.internet` | 8174 73 | `uavcan.diagnostic` | 8184 74 | 75 | The value 7509 contains the longest possible sequence of alternating bits, 76 | which can be leveraged for automatic bit rate detection (depending on the physical layer). 77 | 78 | #### Services 79 | 80 | Ordered by priority from high to low. 81 | 82 | Namespace | Lower bound (inclusive) 83 | ----------------------------|------------------------- 84 | `uavcan.register` | 384 85 | `uavcan.pnp` | 390 86 | `uavcan.file` | 400 87 | `uavcan.node` | 430 88 | `uavcan.internet` | 500 89 | `uavcan.time` | 510 90 | 91 | ### Generic data type definitions 92 | 93 | #### SI 94 | 95 | The namespace `uavcan.si` contains a collection of generic data types describing commonly used 96 | physical quantities. 97 | The namespace `uavcan.si.unit` contains basic units that can be used as type-safe wrappers over native `float32` 98 | and other scalar and array types. 99 | The namespace `uavcan.si.sample` contains time-stamped versions of these. 100 | 101 | All units follow the [International System of Units](https://en.wikipedia.org/wiki/International_System_of_Units). 102 | All units are unscaled basic units of measure -- meters rather than kilometers, kilograms rather than milligrams. 103 | 104 | All coordinate systems are right-handed. 105 | In relation to body, the preferred standard is as follows: **X** -- forward, **Y** -- right, **Z** -- down. 106 | In case of cameras, the following convention should be preferred: **Z** -- forward, **X** -- right, **Y** -- down. 107 | For world frames, the North-East-Down (NED) notation should be preferred. 108 | 109 | #### Primitives 110 | 111 | A collection of primitive data types is intended as a very generic solution for odd use cases 112 | and prototyping. They permit the user to broadcast a completely arbitrary value via the bus 113 | while not having to deal with custom data type design and distribution. 114 | 115 | Since these types lack any semantic information, their usage in production environments is discouraged. 116 | 117 | Another important application of these types is in the schemaless register protocol defined 118 | in the namespace `uavcan.register`. 119 | 120 | #### Registers 121 | 122 | The register protocol provides a highly generic interface to vendor-specific functionality 123 | and configuration parameters via named registers. 124 | 125 | ## Non-standard data types 126 | 127 | Non-standard regulated data types are contained in the root namespace `reg`. 128 | The root namespace contains nested namespaces, one per application domain, named after the domain. 129 | 130 | Note for authors of ***unregulated*** data type definitions: 131 | the Cyphal specification explicitly bans namespaces that share the same name but differ in their contents. 132 | Users seeking to define unregulated data types shall not put those into the regulated namespace; 133 | instead, a new root namespace (named after the vendor) shall be used. 134 | 135 | ## Guidelines for data type authors 136 | 137 | Follow the interface design guidelines provided in [**The Cyphal Guide**](https://opencyphal.org/guide). 138 | 139 | Every data type definition should have a header comment. 140 | Every field should be followed by a comment, unless it is certain that it is completely self-explanatory. 141 | An exception is made for trivial definitions where the comment would not add useful information. 142 | 143 | When using void fields for alignment, insert them after the alignee. 144 | For example, `bool foo` followed by `void7` is the recommended sequence; the opposite is to be avoided. 145 | To understand the motivation, read the DSDL serialization specification. 146 | 147 | Attributes shall be separated by exactly one blank line, excepting tightly related attributes and 148 | void fields used for post-alignment (e.g., after bit fields), in which case blank lines are not necessary. 149 | More than one blank line is never allowed. 150 | There shall be exactly one blank line at the end of the file. 151 | 152 | The lines of text should not be longer than 120 characters. 153 | 154 | Here is an example: 155 | 156 | # This is a header comment. 157 | # It explains what this data type definition is for and why do we need it. 158 | 159 | void48 # This space is reserved for future use. 160 | 161 | uint8 VALUE_A = 1 # A comment describing the constant. 162 | uint8 VALUE_B = 2 # Another one. Constants go before the field they relate to. 163 | uint8 value 164 | # This is an enumeration. 165 | # We don't need blank lines because the items are tightly related. 166 | 167 | float32[<100] aligned_array 168 | # This is a new field, mind the blank line above. 169 | 170 | Remember, the set of standard data types is an important part of the protocol specification, 171 | so the quality of the documentation is very important. 172 | 173 | ## IDE setup 174 | 175 | For editing DSDL definitions, we recommend Visual Studio Code. 176 | See `.vscode/` for recommended extensions and workspace settings. 177 | -------------------------------------------------------------------------------- /reg/udral/physics/acoustics/Note.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # Description of a generic musical note in terms of basic physical quantities. 2 | # 3 | # This type may be used to control sound notification emitters assuming the best effort policy: 4 | # if the requested parameters exceed the capabilities of the emitter, the closest possible values should be assumed. 5 | 6 | uavcan.si.unit.frequency.Scalar.1.0 frequency 7 | uavcan.si.unit.duration.Scalar.1.0 duration 8 | uavcan.si.unit.power.Scalar.1.0 acoustic_power 9 | @sealed 10 | -------------------------------------------------------------------------------- /reg/udral/physics/dynamics/README.md: -------------------------------------------------------------------------------- 1 | # Dynamic states 2 | 3 | Dynamic states extend kinematic states (defined in the adjacent namespace) with forces acting on the body. 4 | -------------------------------------------------------------------------------- /reg/udral/physics/dynamics/rotation/Planar.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # Positive torque is co-directed with positive position/velocity/acceleration. 2 | # Provided states may allow the consumer to deduce certain hidden states such as the moment of inertia. 3 | reg.udral.physics.kinematics.rotation.Planar.0.1 kinematics 4 | uavcan.si.unit.torque.Scalar.1.0 torque # NaN if unknown 5 | @sealed 6 | -------------------------------------------------------------------------------- /reg/udral/physics/dynamics/rotation/PlanarTs.0.1.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | Planar.0.1 value 3 | @sealed 4 | -------------------------------------------------------------------------------- /reg/udral/physics/dynamics/translation/Linear.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # Positive force is co-directed with positive position/velocity/acceleration. 2 | # Provided kinetic states may allow the consumer to deduce certain hidden states such as the mass of the load. 3 | reg.udral.physics.kinematics.translation.Linear.0.1 kinematics 4 | uavcan.si.unit.force.Scalar.1.0 force # NaN if unknown 5 | @sealed 6 | -------------------------------------------------------------------------------- /reg/udral/physics/dynamics/translation/LinearTs.0.1.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | Linear.0.1 value 3 | @sealed 4 | -------------------------------------------------------------------------------- /reg/udral/physics/electricity/Power.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # DC or AC line electric power quantities. Generally, the following current sign convention applies: 2 | # 3 | # - Positive current flows from the electric power supply network to the load (e.g., an actuator). 4 | # 5 | # - If the electric network is the load itself powered from a source (e.g., battery), the current is negative. 6 | 7 | uavcan.si.unit.electric_current.Scalar.1.0 current 8 | uavcan.si.unit.voltage.Scalar.1.0 voltage 9 | 10 | @sealed 11 | -------------------------------------------------------------------------------- /reg/udral/physics/electricity/PowerTs.0.1.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | Power.0.1 value 3 | @sealed 4 | -------------------------------------------------------------------------------- /reg/udral/physics/electricity/Source.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # A generic source or sink of electric power (battery, turbogenerator, braking resistor, etc.). 2 | # Low-pass filtering should be applied to avoid aliasing effects (as is the case everywhere else). 3 | 4 | Power.0.1 power 5 | # Total instant load power. 6 | # Positive current flows into the source (power sinking). 7 | # Negative current flows from the source to the power supply network (power sourcing). 8 | 9 | uavcan.si.unit.energy.Scalar.1.0 energy 10 | # A pessimistic estimate of the amount of energy that can be reclaimed from the source in its current state. 11 | # This may be dependent on the state of charge/health (for batteries), temperature, load profile, humidity, etc. 12 | # Negative values may be reported to indicate overdischarge or depletion of the reserve energy. 13 | # 14 | # This value approximates (full_energy + int(load_power dt)) plus the environmental influences on the source. 15 | # 16 | # Having the instant power, the time to depletion is estimated as (energy/-power). 17 | # When charging (for batteries), the remaining time to full charge can be found similarly as 18 | # ((full_energy-energy)/power). 19 | # 20 | # For the sake of illustration, if this type was used to represent the state of a braking resistor, 21 | # then this value would be negative indicating the amount of dissipated energy. 22 | 23 | uavcan.si.unit.energy.Scalar.1.0 full_energy 24 | # A pessimistic estimate of the amount of energy that can be reclaimed from a fresh source (fully fueled generator 25 | # or a fully charged battery) under the current conditions (SoH, temperature, load profile, etc). 26 | 27 | @sealed 28 | -------------------------------------------------------------------------------- /reg/udral/physics/electricity/SourceTs.0.1.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | Source.0.1 value 3 | @sealed 4 | -------------------------------------------------------------------------------- /reg/udral/physics/kinematics/README.md: -------------------------------------------------------------------------------- 1 | # Kinematic states 2 | 3 | This namespace contains data types that model basic [kinematic](https://en.wikipedia.org/wiki/Kinematics) states. 4 | 5 | The full kinematic state of a rigid body or fluid includes its position, velocity, acceleration, and orientation. 6 | The data types contained here model either full or partial kinematic states (e.g., there are types for velocity only). 7 | 8 | Forces acting on the body or fluid are part of its *dynamic* state, so they are excluded from the model. 9 | 10 | The modeled kinematic state of a body in `cartesian` space includes its pose (position and orientation) 11 | and twist (here, twist is understood narrowly as the translational and rotational velocity of the body). 12 | A "point state" lacks the rotational component (only position and velocity are defined). 13 | Translational components are always specified before their rotational counterparts. 14 | 15 | There is a dedicated namespace `geodetic` that defines position in spherical coordinates instead of Cartesian. 16 | This is to support large-scale navigation along the surface of celestial bodies where a local 17 | Cartesian approximation is infeasible. 18 | Other than using a different coordinate system to express position, the data types are equal to their Cartesian 19 | counterparts and are to some extent interchangeable thanks to the structural subtyping/aliasing features of DSDL. 20 | 21 | See Cyphal Specification chapter "Application layer" for the applicable conventions. 22 | Key excerpts: 23 | 24 | - For world fixed frames, the North-East-Down (NED) right-handed notation is preferred: 25 | X – northward, Y – eastward, Z – downward. 26 | 27 | - In relation to a body, the convention is as follows, right-handed: 28 | X – forward, Y – rightward, Z – downward. 29 | 30 | - Angular velocities are represented using the right-handed, fixed-axis (extrinsic) convention: 31 | X (roll), Y (pitch), Z (yaw). 32 | 33 | - For NED frames, the initial (zero) rotation of a body is the state where the axes of the body frame are 34 | aligned with the axes of the local NED frame: X points north, Y points east, Z points down. 35 | 36 | - Matrices are represented in the row-major order. 37 | -------------------------------------------------------------------------------- /reg/udral/physics/kinematics/cartesian/Point.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # Cartesian coordinates of a point in space. 2 | 3 | uavcan.si.unit.length.WideVector3.1.0 value 4 | 5 | @sealed 6 | -------------------------------------------------------------------------------- /reg/udral/physics/kinematics/cartesian/PointState.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # The kinematic state of a point, as opposed to that of a body, is devoid of rotation information. 2 | # Therefore, the velocity is specified in the parent coordinate frame. 3 | 4 | Point.0.1 position 5 | uavcan.si.unit.velocity.Vector3.1.0 velocity 6 | 7 | @sealed 8 | -------------------------------------------------------------------------------- /reg/udral/physics/kinematics/cartesian/PointStateVar.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # See PointState for details. 2 | 3 | PointVar.0.1 position 4 | reg.udral.physics.kinematics.translation.Velocity3Var.0.2 velocity 5 | 6 | @sealed 7 | -------------------------------------------------------------------------------- /reg/udral/physics/kinematics/cartesian/PointStateVarTs.0.1.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | PointStateVar.0.1 value 3 | 4 | @sealed 5 | @assert _offset_.count == 1 # This is a fixed-length type. 6 | -------------------------------------------------------------------------------- /reg/udral/physics/kinematics/cartesian/PointVar.0.1.dsdl: -------------------------------------------------------------------------------- 1 | Point.0.1 value 2 | float16[6] covariance_urt # [meter^2] Upper-right triangle of the covariance matrix. 3 | 4 | @sealed 5 | -------------------------------------------------------------------------------- /reg/udral/physics/kinematics/cartesian/Pose.0.1.dsdl: -------------------------------------------------------------------------------- 1 | Point.0.1 position 2 | uavcan.si.unit.angle.Quaternion.1.0 orientation 3 | 4 | @sealed 5 | -------------------------------------------------------------------------------- /reg/udral/physics/kinematics/cartesian/PoseVar.0.1.dsdl: -------------------------------------------------------------------------------- 1 | Pose.0.1 value 2 | 3 | float16[21] covariance_urt 4 | # Upper-right triangle of the covariance matrix: 5 | # 6 | # [parent frame] [child (body) frame] 7 | # translation along axis rotation about axis 8 | # X Y Z X Y Z 9 | # +----------------------------------------------- 10 | # X position | 11 | # Y position | m^2 m*rad 12 | # Z position | 13 | # X rotation | 14 | # Y rotation | rad^2 15 | # Z rotation | 16 | 17 | @sealed 18 | -------------------------------------------------------------------------------- /reg/udral/physics/kinematics/cartesian/PoseVarTs.0.1.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | PoseVar.0.1 value 3 | 4 | @sealed 5 | -------------------------------------------------------------------------------- /reg/udral/physics/kinematics/cartesian/State.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # First-order kinematic state of a body in space: pose and twist. 2 | # The pose defines a coordinate system transformation from the parent frame to the child frame. 3 | # The twist is specified in the child frame (body frame). 4 | 5 | Pose.0.1 pose 6 | Twist.0.1 twist 7 | 8 | @sealed 9 | @assert _offset_.count == 1 # This is a fixed-length type. 10 | -------------------------------------------------------------------------------- /reg/udral/physics/kinematics/cartesian/StateVar.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # See State for details. This type extends it with covariance matrices. 2 | 3 | PoseVar.0.1 pose 4 | TwistVar.0.1 twist 5 | 6 | @sealed 7 | @assert _offset_.count == 1 # This is a fixed-length type. 8 | -------------------------------------------------------------------------------- /reg/udral/physics/kinematics/cartesian/StateVarTs.0.1.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | StateVar.0.1 value 3 | 4 | @sealed 5 | @assert _offset_.count == 1 # This is a fixed-length type. 6 | -------------------------------------------------------------------------------- /reg/udral/physics/kinematics/cartesian/Twist.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # Motion of a rigid body in 3D space defined in the body frame. 2 | 3 | uavcan.si.unit.velocity.Vector3.1.0 linear 4 | # Linear velocity in the body frame. 5 | 6 | uavcan.si.unit.angular_velocity.Vector3.1.0 angular 7 | # Angular velocity about the fixed axes of the body frame (extrinsic). 8 | 9 | @sealed 10 | -------------------------------------------------------------------------------- /reg/udral/physics/kinematics/cartesian/TwistVar.0.1.dsdl: -------------------------------------------------------------------------------- 1 | Twist.0.1 value 2 | 3 | float16[21] covariance_urt 4 | # Upper-right triangle of the covariance matrix: 5 | # 6 | # translation along axis rotation about axis 7 | # X Y Z X Y Z 8 | # +---------------------------------------------- 9 | # X velocity | 10 | # Y velocity | (m/s)^2 (m*rad)/s^2 11 | # Z velocity | 12 | # X angular velocity | 13 | # Y angular velocity | (rad/s)^2 14 | # Z angular velocity | 15 | 16 | @sealed 17 | -------------------------------------------------------------------------------- /reg/udral/physics/kinematics/cartesian/TwistVarTs.0.1.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | TwistVar.0.1 value 3 | 4 | @sealed 5 | -------------------------------------------------------------------------------- /reg/udral/physics/kinematics/geodetic/Point.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # Geodetic position: latitude, longitude, and altitude. 2 | # The order is chosen to match the axis ordering of the NED frame. 3 | # The size and layout of this structure is equal to the Cartesian pose type. 4 | 5 | float64 latitude # [radian] 6 | float64 longitude # [radian] 7 | 8 | uavcan.si.unit.length.WideScalar.1.0 altitude 9 | # Distance between the local mean sea level (MSL) and the focal point of the antenna. Positive altitude above the MSL. 10 | 11 | @sealed 12 | @assert _offset_ == reg.udral.physics.kinematics.cartesian.Point.0.1._bit_length_ 13 | -------------------------------------------------------------------------------- /reg/udral/physics/kinematics/geodetic/PointState.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # The kinematic state of a point, as opposed to that of a body, is devoid of rotation information. 2 | # Therefore, the velocity is specified in the parent coordinate frame. 3 | 4 | Point.0.1 position 5 | uavcan.si.unit.velocity.Vector3.1.0 velocity 6 | 7 | @sealed 8 | @assert _offset_ == reg.udral.physics.kinematics.cartesian.PointState.0.1._bit_length_ 9 | -------------------------------------------------------------------------------- /reg/udral/physics/kinematics/geodetic/PointStateVar.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # See PointState for details. 2 | 3 | PointVar.0.1 position 4 | reg.udral.physics.kinematics.translation.Velocity3Var.0.2 velocity 5 | 6 | @sealed 7 | @assert _offset_ == reg.udral.physics.kinematics.cartesian.PointStateVar.0.1._bit_length_ 8 | -------------------------------------------------------------------------------- /reg/udral/physics/kinematics/geodetic/PointStateVarTs.0.1.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | PointStateVar.0.1 value 3 | 4 | @sealed 5 | @assert _offset_ == reg.udral.physics.kinematics.cartesian.PointStateVarTs.0.1._bit_length_ 6 | -------------------------------------------------------------------------------- /reg/udral/physics/kinematics/geodetic/PointVar.0.1.dsdl: -------------------------------------------------------------------------------- 1 | Point.0.1 value 2 | 3 | float16[6] covariance_urt # [meter^2] 4 | # Upper-right triangle of the covariance matrix. 5 | # The position covariance is defined relative to a tangential plane through the specified latitude/longitude. 6 | # Element ordering: latitude, longitude, altitude. It is chosen to match the axis ordering of the NED frame. 7 | 8 | @sealed 9 | @assert _offset_ == reg.udral.physics.kinematics.cartesian.PointVar.0.1._bit_length_ 10 | -------------------------------------------------------------------------------- /reg/udral/physics/kinematics/geodetic/Pose.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # Zero rotation is the state where the axes of the body frame are aligned with the axes of the local NED frame: 2 | # X points north, Y points east, Z points down. 3 | 4 | Point.0.1 position 5 | uavcan.si.unit.angle.Quaternion.1.0 orientation 6 | 7 | @sealed 8 | @assert _offset_ == reg.udral.physics.kinematics.cartesian.Pose.0.1._bit_length_ 9 | -------------------------------------------------------------------------------- /reg/udral/physics/kinematics/geodetic/PoseVar.0.1.dsdl: -------------------------------------------------------------------------------- 1 | Pose.0.1 value 2 | float16[21] covariance_urt 3 | # Upper-right triangle of the covariance matrix: 4 | # 5 | # [parent frame] [child (body) frame] 6 | # translation along axis rotation about axis 7 | # X Y Z X Y Z 8 | # +----------------------------------------------- 9 | # X position | 10 | # Y position | m^2 m*rad 11 | # Z position | 12 | # X rotation | 13 | # Y rotation | rad^2 14 | # Z rotation | 15 | 16 | @sealed 17 | @assert _offset_ == reg.udral.physics.kinematics.cartesian.PoseVar.0.1._bit_length_ 18 | -------------------------------------------------------------------------------- /reg/udral/physics/kinematics/geodetic/State.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # First-order kinematic state of a body near the surface of a planet. 2 | # The pose defines a coordinate system transformation from the parent frame to the child frame. 3 | # The twist is specified in the child frame (body frame). 4 | 5 | Pose.0.1 pose 6 | reg.udral.physics.kinematics.cartesian.Twist.0.1 twist 7 | 8 | @sealed 9 | @assert _offset_ == reg.udral.physics.kinematics.cartesian.State.0.1._bit_length_ 10 | -------------------------------------------------------------------------------- /reg/udral/physics/kinematics/geodetic/StateVar.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # See State for details. This type extends it with covariance matrices. 2 | 3 | PoseVar.0.1 pose 4 | reg.udral.physics.kinematics.cartesian.TwistVar.0.1 twist 5 | 6 | @sealed 7 | @assert _offset_ == reg.udral.physics.kinematics.cartesian.StateVar.0.1._bit_length_ 8 | -------------------------------------------------------------------------------- /reg/udral/physics/kinematics/geodetic/StateVarTs.0.1.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | StateVar.0.1 value 3 | 4 | @sealed 5 | @assert _offset_ == reg.udral.physics.kinematics.cartesian.StateVarTs.0.1._bit_length_ 6 | -------------------------------------------------------------------------------- /reg/udral/physics/kinematics/rotation/Planar.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # Rotation about an axis. 2 | uavcan.si.unit.angle.Scalar.1.0 angular_position 3 | uavcan.si.unit.angular_velocity.Scalar.1.0 angular_velocity 4 | uavcan.si.unit.angular_acceleration.Scalar.1.0 angular_acceleration 5 | @sealed 6 | -------------------------------------------------------------------------------- /reg/udral/physics/kinematics/rotation/PlanarTs.0.1.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | Planar.0.1 value 3 | @sealed 4 | -------------------------------------------------------------------------------- /reg/udral/physics/kinematics/translation/Linear.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # Movement along an axis. 2 | uavcan.si.unit.length.Scalar.1.0 position 3 | uavcan.si.unit.velocity.Scalar.1.0 velocity 4 | uavcan.si.unit.acceleration.Scalar.1.0 acceleration 5 | @sealed 6 | -------------------------------------------------------------------------------- /reg/udral/physics/kinematics/translation/LinearTs.0.1.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | Linear.0.1 value 3 | @sealed 4 | -------------------------------------------------------------------------------- /reg/udral/physics/kinematics/translation/LinearVarTs.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # This is a structural subtype of LinearTs. 2 | # Use best guess if the error variance is unknown. 3 | 4 | LinearTs.0.1 value 5 | 6 | float16 position_error_variance # [meter^2] 7 | float16 velocity_error_variance # [(meter/second)^2] 8 | float16 acceleration_error_variance # [(meter/second^2)^2] 9 | 10 | @sealed 11 | -------------------------------------------------------------------------------- /reg/udral/physics/kinematics/translation/Velocity1VarTs.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # Linear velocity with timestamp and covariance. 2 | # Observe that this is a structural subtype of uavcan.si.sample.velocity.Scalar.1.0. 3 | # For a non-timestamped estimate without covariance use the raw SI type directly. 4 | 5 | uavcan.si.sample.velocity.Scalar.1.0 value 6 | 7 | float16 error_variance # [(meter/second)^2] 8 | 9 | @sealed 10 | -------------------------------------------------------------------------------- /reg/udral/physics/kinematics/translation/Velocity3Var.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # Linear velocity with covariance. 2 | # Observe that this is a structural subtype of uavcan.si.unit.velocity.Scalar.1.0. 3 | 4 | @deprecated 5 | 6 | uavcan.si.sample.velocity.Vector3.1.0 value 7 | float16[6] covariance_urt # [(meter/second)^2] Upper-right triangle of the covariance matrix. 8 | 9 | @sealed 10 | -------------------------------------------------------------------------------- /reg/udral/physics/kinematics/translation/Velocity3Var.0.2.dsdl: -------------------------------------------------------------------------------- 1 | # Linear velocity with covariance. 2 | # Observe that this is a structural subtype of uavcan.si.unit.velocity.Scalar.1.0. 3 | 4 | uavcan.si.unit.velocity.Vector3.1.0 value 5 | float16[6] covariance_urt # [(meter/second)^2] Upper-right triangle of the covariance matrix. 6 | 7 | @sealed 8 | -------------------------------------------------------------------------------- /reg/udral/physics/optics/HighColor.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # Color in the standard 16-bit 5-6-5 RGB format (green is wider due to non-uniform color sensitivity of the human eye). 2 | # https://en.wikipedia.org/wiki/High_color 3 | # 4 | # For reasons of unification, a monochrome light can be modeled using the same type, 5 | # where the brightness is defined as the mean of the color components normalized to one: 6 | # 7 | # brightness = (red/MAX_RED + green/MAX_GREEN + blue/MAX_BLUE) / 3 8 | 9 | uint5 red 10 | uint6 green 11 | uint5 blue 12 | 13 | uint5 MAX_RED = 2 ** 5 - 1 14 | uint6 MAX_GREEN = 2 ** 6 - 1 15 | uint5 MAX_BLUE = MAX_RED 16 | 17 | @assert _offset_ == {16} 18 | @sealed 19 | -------------------------------------------------------------------------------- /reg/udral/physics/thermodynamics/PressureTempVarTs.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # Timestamped fluid pressure and temperature (sampled synchronously) with covariance. 2 | # Observe that this is a structural subtype of uavcan.si.sample.pressure.Scalar.1.0. 3 | 4 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 5 | 6 | uavcan.si.unit.pressure.Scalar.1.0 pressure 7 | uavcan.si.unit.temperature.Scalar.1.0 temperature 8 | 9 | float16[3] covariance_urt 10 | # The upper-right triangle of the covariance matrix (following the matrix packing rules defined in Specification). 11 | # 0 -- pascal^2 12 | # 1 -- pascal*kelvin 13 | # 2 -- kelvin^2 14 | 15 | @sealed 16 | -------------------------------------------------------------------------------- /reg/udral/physics/time/TAI64.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # Standard TAI64N time label (https://cr.yp.to/libtai/tai64.html). Quote from the source: 2 | # 3 | # TAI stands for Temps Atomique International, the current international real-time standard. 4 | # One TAI second is defined as the duration of 9192631770 periods of the radiation corresponding 5 | # to the transition between the two hyperfine levels of the ground state of the cesium atom. 6 | # TAI also specifies a frame of reference. Further discussion of special relativity is outside 7 | # the scope of this document. 8 | # 9 | # A TAI64 label is an integer between 0 and 2^64 referring to a particular second of real time. Integer s refers to: 10 | # 11 | # - the TAI second beginning exactly 2^62 - s seconds before the beginning of 1970 TAI, 12 | # if s is between 0 inclusive and 2^62 exclusive; or 13 | # 14 | # - the TAI second beginning exactly s - 2^62 seconds after the beginning of 1970 TAI, 15 | # if s is between 2^62 inclusive and 2^63 exclusive. 16 | # 17 | 18 | int64 tai64n # [nanosecond] Nanoseconds elapsed since 1970-01-01T00:00:00Z TAI. 19 | 20 | @sealed 21 | -------------------------------------------------------------------------------- /reg/udral/physics/time/TAI64Var.0.1.dsdl: -------------------------------------------------------------------------------- 1 | TAI64.0.1 value 2 | 3 | float32 error_variance # [second^2] 4 | # Error variance, in second squared, of the time estimate. 5 | # Infinity indicates that the time estimates are not yet available. 6 | # A non-positive value indicates that the error variance is unknown. 7 | 8 | @sealed 9 | -------------------------------------------------------------------------------- /reg/udral/physics/time/TAI64VarTs.0.1.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | TAI64Var.0.1 value 3 | 4 | @sealed 5 | -------------------------------------------------------------------------------- /reg/udral/service/actuator/common/FaultFlags.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # A collection of detailed fault flags indicating problems detected by the service provider. 2 | # A fault flag is set when the corresponding parameter exceeds its safe operating area (SOA) as defined by the vendor; 3 | # see https://en.wikipedia.org/wiki/Safe_operating_area. 4 | # As long as at least one flag is set, the service health should not be NOMINAL. 5 | 6 | bool overload 7 | # The load is above SOA or regeneration below the SOA. 8 | 9 | bool voltage 10 | # Supply voltage is above or below the SOA. 11 | 12 | bool motor_temperature 13 | bool controller_temperature 14 | # Temperature is above or below the SOA. 15 | 16 | bool velocity 17 | # The absolute velocity of the load is above the SOA. 18 | 19 | bool mechanical 20 | # The load cannot be driven due to a mechanical failure. 21 | 22 | bool vibration 23 | # The mechanical vibration level exceeds the SOA. 24 | 25 | bool configuration 26 | # Configuration is missing or invalid. 27 | 28 | bool control_mode 29 | # The requested control mode is not supported by the actuator. 30 | 31 | void6 32 | 33 | bool other 34 | # None of the above (vendor-specific). 35 | 36 | @assert _offset_ == {16} 37 | @sealed 38 | -------------------------------------------------------------------------------- /reg/udral/service/actuator/common/Feedback.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # This high-rate feedback should be published once immediately after a setpoint is applied. 2 | # It follows that the publication rate of these messages equals that of the setpoint messages. 3 | # When setpoint messages are not being emitted, the publication rate is implementation-defined, but it should not 4 | # be lower than the defined limit. 5 | # The priority of this message should be the same as that of the corresponding setpoint message. 6 | 7 | reg.udral.service.common.Heartbeat.0.1 heartbeat 8 | # If ENGAGED, the actuator provides service according to its nominal performance characteristics. 9 | # Otherwise, no availability guarantees are provided. 10 | # Notice that the feedback type is a structural subtype of the heartbeat type, so one can subscribe to a 11 | # feedback subject using the heartbeat type. Similarly, the heartbeat type is a structural subtype of the 12 | # Readiness type, meaning that one can use the Readiness type as well. 13 | 14 | int8 demand_factor_pct # [percent] 15 | # Percentage of the maximum rated output intensity. May exceed +-100% in case of overload. 16 | # Positive value indicates that power is applied to the load; negative indicates that power is being sunk from the 17 | # load into the actuator power source. 18 | # The consumer of this message may leverage this information to manage the control loop saturation. 19 | 20 | @extent 63 * 8 # Single-frame transfer over CAN FD. 21 | -------------------------------------------------------------------------------- /reg/udral/service/actuator/common/Status.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # Auxiliary actuator status information published at a low rate asynchronously, usually at 1 Hz. 2 | # It is mostly intended for diagnostics and logging purposes. 3 | # In this revision this type is common for all kinds of actuators, but in the future it may be replaced 4 | # with per-kind specializations. 5 | 6 | uavcan.si.unit.temperature.Scalar.1.0 motor_temperature 7 | uavcan.si.unit.temperature.Scalar.1.0 controller_temperature 8 | # Sampled temperatures. If multiple values are available, reduction is implementation-defined. 9 | 10 | uint32 error_count 11 | # Incremented once per occurrence. Reset to zero when ENGAGED. 12 | # The exact definition of what constitutes an error is implementation-dependent. 13 | 14 | FaultFlags.0.1 fault_flags 15 | 16 | # TODO: add vibration 17 | 18 | @extent 63 * 8 # Single-frame transfer over CAN FD. 19 | -------------------------------------------------------------------------------- /reg/udral/service/actuator/common/_.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # An actuator is a device that actuates a mechanical load using electric energy from the high-voltage DC power bus. 2 | # There are multiple kinds of actuators with a dedicated namespace for each; additionally, this "common" namespace 3 | # hosts certain elements shared between several (or all) kinds. 4 | 5 | float32 CONTROL_TIMEOUT = 1.0 # [seconds] 6 | # The actuator is allowed to enter a safe state (e.g., stop the controlled mechanism, disconnect itself from 7 | # the load, etc. depending on the specifics of the application at hand) if no setpoint or readiness control messages 8 | # have been received in this amount of time. Implementations are allowed to reduce this value, but never increase it. 9 | 10 | uint8 MAX_PUBLICATION_PERIOD = 1 # [second] 11 | # This is the maximum publication period (minimum frequency) for all subjects described in this service. 12 | # Subjects that are clocked by the setpoint should continue being published at least at this rate when setpoint is not 13 | # being updated, unless the actuator is in the SLEEP state. 14 | # The publication periods should be consistent across the group. 15 | 16 | @extent 0 17 | -------------------------------------------------------------------------------- /reg/udral/service/actuator/common/sp/Scalar.0.1.dsdl: -------------------------------------------------------------------------------- 1 | float16 value 2 | @extent 16 * 256 3 | -------------------------------------------------------------------------------- /reg/udral/service/actuator/common/sp/Vector2.0.1.dsdl: -------------------------------------------------------------------------------- 1 | float16[2] value 2 | @extent 16 * 256 3 | -------------------------------------------------------------------------------- /reg/udral/service/actuator/common/sp/Vector3.0.1.dsdl: -------------------------------------------------------------------------------- 1 | float16[3] value 2 | @extent 16 * 256 3 | -------------------------------------------------------------------------------- /reg/udral/service/actuator/common/sp/Vector31.0.1.dsdl: -------------------------------------------------------------------------------- 1 | float16[31] value 2 | @extent 16 * 256 3 | -------------------------------------------------------------------------------- /reg/udral/service/actuator/common/sp/Vector4.0.1.dsdl: -------------------------------------------------------------------------------- 1 | float16[4] value 2 | @extent 16 * 256 3 | -------------------------------------------------------------------------------- /reg/udral/service/actuator/common/sp/Vector6.0.1.dsdl: -------------------------------------------------------------------------------- 1 | float16[6] value 2 | @extent 16 * 256 3 | -------------------------------------------------------------------------------- /reg/udral/service/actuator/common/sp/Vector8.0.1.dsdl: -------------------------------------------------------------------------------- 1 | float16[8] value 2 | @extent 16 * 256 3 | -------------------------------------------------------------------------------- /reg/udral/service/actuator/common/sp/_.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # This is a collection of weakly-typed primitives used to control groups of actuators synchronously. 2 | # 3 | # Actuators are expected to subscribe using the largest array type. Publishers would choose the array type 4 | # depending on the number of actuators in the group. The actuators would be expecting the largest array type, 5 | # where the missing elements will be zero-filled automatically by the protocol stack thanks to the 6 | # Implicit Zero Extension Rule (refer to the Cyphal Specification for details). 7 | # 8 | # The physical meaning of the values contained in the array is defined by the respective actuator service specification. 9 | # If ratiometric control is used, then the range should be [-1, +1]. 10 | # 11 | # It follows that a standalone actuator (that is not a member of any group) is just a special case of a group of 1, 12 | # where the setpoint type is a single scalar. 13 | # 14 | # The Cyphal Specification might benefit from supporting flexible array fields to avoid having to deal with redundant 15 | # similar types: https://en.wikipedia.org/wiki/Flexible_array_member, so that instead of having multiple types that 16 | # differ only in size of the array fields, one could just say `float16[0] value` such that the size of zero indicates 17 | # that the array is a flex array. 18 | 19 | float16 EPSILON = 2 ** -11 20 | # The float epsilon defined for convenience. 21 | # See https://en.wikipedia.org/wiki/Machine_epsilon. 22 | 23 | @extent 0 # This type is not intended for runtime use. 24 | -------------------------------------------------------------------------------- /reg/udral/service/actuator/servo/_.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # A servo can actuate either a translational or rotary load using electric power from the high-voltage DC bus. 2 | # 3 | # The type of load (translational or rotational) dictates which type is used for commanding the setpoint and reporting 4 | # the status: 5 | # - reg.udral.physics.dynamics.rotation.Planar[Ts] 6 | # - reg.udral.physics.dynamics.translation.Linear[Ts] 7 | # For generality, either or both of these types are referred to as "timestamped dynamics" or "non-timestamped dynamics". 8 | # 9 | # The default readiness state is STANDBY. While in this state, the servo is not allowed to apply force to the load, 10 | # and the setpoint subject is ignored. The servo shall enter the STANDBY state automatically if the readiness subject 11 | # is not updated for CONTROL_TIMEOUT. 12 | # 13 | # The subjects defined by this service are shown on the following canvas. Implementers are encouraged to add 14 | # custom subjects with additional data. Notice that the physics subjects are timestamped. 15 | # 16 | # SUBJECT NAME SUBJECT TYPE RATE 17 | # 18 | # +------------+ setpoint +------------+ (non-timestamped dynamics) (see below) R 19 | # | |--------------------->| | 20 | # | | readiness | | reg.udral.service.common.Readiness any 21 | # | |--------------------->| | 22 | # | | feedback | | reg.udral.service.actuator.common.Feedback R 23 | # | |<---------------------| | 24 | # | Controller | status | Servo | reg.udral.service.actuator.common.Status any 25 | # | |<---------------------| | 26 | # | | power | | reg.udral.physics.electricity.PowerTs R 27 | # | |<---------------------| | 28 | # | | dynamics | | (timestamped dynamics) R 29 | # | |<---------------------| | 30 | # +------------+ +------------+ 31 | # 32 | # Should it be necessary to control a group of servos in lockstep, an arbitrary number of them may subscribe 33 | # to the same setpoint subject (their published subjects would be different of course). 34 | # 35 | # If the servo is ENGAGED, setpoint messages are processed as follows: the first field of the kinematic setpoint type 36 | # that contains a finite value is taken as the commanded setpoint. The following non-negative finite fields define 37 | # the motion profile, where negative and non-finite values are ignored. 38 | # 39 | # For example, a translational dynamics message containing the following values: 40 | # position = +0.35 41 | # velocity = NaN 42 | # acceleration = NaN 43 | # force = 30 44 | # ...is interpreted as follows: position the load at 0.35 meters relative to the neutral, limit the force to 30 newton, 45 | # do not limit the velocity and acceleration. Here is another example: 46 | # angular position = NaN 47 | # angular velocity = +400 48 | # angular acceleration = NaN 49 | # torque = 50 50 | # which is interpreted as follows: reach the angular velocity of 400 radian/second in the forward direction, 51 | # limit the torque to 50 newton*meters, do not limit the acceleration. 52 | # 53 | # The motion profile parameters that are not supported are to be silently ignored by the servo. If the commanded 54 | # parameter cannot be controlled by the servo, the setpoint is to be ignored. For example, in the second example above, 55 | # if the servo does not support angular velocity control, the setpoint message would be discarded. 56 | # 57 | # The above describes the typical use case where each servo is controlled over a dedicated setpoint 58 | # subject independently (or a group of servos are controlled in lockstep using the same setpoint subject). 59 | # Some applications may require synchronous independent control of multiple servos in a group, similar to ESC. 60 | # To address this, a compliant servo should support another operating mode where the controlled quantity 61 | # (position, velocity, force, etc.) is selected statically along with the motion profile (using the register API), 62 | # and the servo subscribes to the setpoint subject of type "reg.udral.service.actuator.common.sp.*". 63 | # Having its index in the group configured statically, the servo fetches the setpoint from the appropriate 64 | # index in the setpoint array. 65 | # The resulting topology closely resembles that of the ESC service: 66 | # 67 | # SUBJECT NAME SUBJECT TYPE 68 | # +----------------+ 69 | # | Controller |---------+------------+----... setpoint reg.udral.service.actuator.common.sp.* 70 | # | |-------+-)----------+-)----... readiness reg.udral.service.common.Readiness 71 | # +----------------+ | | | | 72 | # ^ ^ ^ ^ ^ ^ ^ ^ v v v v 73 | # | | | | | | | | +---------+ +---------+ 74 | # | | | | | | | | |Servo i=0| |Servo i=1| ... 75 | # | | | | | | | | +---------+ +---------+ 76 | # | | | | | | | | | | | | | | | | 77 | # | | | | | | | +-----+ | | | | | | | feedback reg.udral.service.actuator.common.Feedback 78 | # | | | | | | +---------+ | | | | | | status reg.udral.service.actuator.common.Status 79 | # | | | | | +-------------+ | | | | | power reg.udral.physics.electricity.PowerTs 80 | # | | | | +-----------------+ | | | | dynamics (timestamped dynamics) 81 | # | | | | | | | | 82 | # | | | +---------------------------+ | | | 83 | # | | +-------------------------------+ | | 84 | # | +-----------------------------------+ | 85 | # +---------------------------------------+ 86 | # 87 | # If the selected readiness state is SLEEP, the behavior is implementation-defined. Implementations are recommended to 88 | # power off the high-voltage circuitry and all non-essential components (e.g., LED indication, sensors, etc.) 89 | # to minimize the power consumption. The publication rate requirements do not apply if the state is SLEEP. 90 | # 91 | # The worst-case readiness state transition latency is not defined. 92 | # 93 | # The following subjects shall be published immediately after a new setpoint is applied even if the servo is STANDBY: 94 | # 95 | # SUBJECT NAME RECOMMENDED PRIORITY 96 | # --------------------------------------------- 97 | # feedback same as the setpoint 98 | # power second to the setpoint 99 | # dynamics second to the setpoint 100 | # 101 | # If no setpoint is being published, these subjects should continue being updated at least at 1/MAX_PUBLICATION_PERIOD. 102 | # 103 | # If the setpoint publication rate exceeds 50 Hz, implementations are allowed (but not required) to throttle these 104 | # subjects by dropping some of the messages such that the publication rate of each subject does not exceed 50 Hz. 105 | # Implementations operating over Classic CAN are recommended to do this. 106 | # 107 | # The other subjects may be published at an implementation-defined rate and priority, 108 | # which should be consistent across the group. 109 | # 110 | # The measurements carried by the published messages should be low-pass filtered with an adequate cutoff frequency to 111 | # avoid aliasing effects. Implementations should strive to sample all parameters simultaneously. 112 | # 113 | # It is assumed that the servo is powered from a DC electric power supply network. A positive electric current 114 | # represents current flowing from the DC network into the servo (negative represents regeneration). 115 | # 116 | # Excepting edge cases and transients, torque/force and current are generally of the same sign (barring the difference 117 | # introduced by the power dissipated by the servo itself). 118 | # 119 | # +velocity 120 | # ^ 121 | # braking,| forward, 122 | # negative| positive 123 | # power | power 124 | # -----------+----------> +torque/force/current 125 | # reverse,| braking, 126 | # positive| negative 127 | # power | power 128 | # 129 | # An example implementation is available at https://github.com/OpenCyphal/demos 130 | 131 | @extent 0 132 | -------------------------------------------------------------------------------- /reg/udral/service/battery/Error.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # Generic error codes reported by the service provider. 2 | # An error is reported when the corresponding parameter exceeds its safe operating area (SOA) as defined by the vendor; 3 | # see https://en.wikipedia.org/wiki/Safe_operating_area. 4 | # As long as an error condition is present, the service health should not be NOMINAL. 5 | # 6 | # If there are multiple error conditions present, the most severe one should be reported. The severity ordering 7 | # is implementation-defined. Barring special requirements, it is recommended to give preference to errors whose 8 | # code is smaller (e.g., BAD_BATTERY trumps TEMPERATURE_COLD). 9 | 10 | uint8 value 11 | 12 | uint8 NONE = 0 13 | # Normal operation. 14 | 15 | uint8 BAD_BATTERY = 10 16 | # The battery should not be used anymore. Detection criteria are implementation-defined. 17 | 18 | uint8 NEEDS_SERVICE = 11 19 | # The battery requires offline maintenance. 20 | 21 | uint8 BMS_ERROR = 20 22 | # An internal error in the battery management system, not related to the battery itself. 23 | 24 | uint8 CONFIGURATION = 30 25 | # The battery/BMS/node/service configuration is missing or invalid. 26 | 27 | uint8 OVERDISCHARGE = 50 28 | # The battery is discharged beyond the design limits and may have incurred damage. 29 | 30 | uint8 OVERLOAD = 51 31 | # The charge or discharge rate exceeds the safe operating limits. 32 | 33 | uint8 CELL_OVERVOLTAGE = 60 34 | uint8 CELL_UNDERVOLTAGE = 61 35 | # Voltage of one of the battery cells exceeds its SOA. 36 | 37 | uint8 CELL_COUNT = 62 38 | # The sum of cell voltages is far from the total pack voltage. 39 | # The threshold is implementation-defined. 40 | 41 | uint8 TEMPERATURE_HOT = 100 42 | uint8 TEMPERATURE_COLD = 101 43 | # At least one cell is above/below the temperature SOA. 44 | 45 | @sealed 46 | -------------------------------------------------------------------------------- /reg/udral/service/battery/Parameters.0.3.dsdl: -------------------------------------------------------------------------------- 1 | # Smart battery parameter message. It is mostly intended for automated battery charging and maintenance systems. 2 | # This message is modeled after the Smart Battery Data Specification (SBS) and the MAVLink battery status messages. 3 | # 4 | # The values carried by this message are either constant or slow-changing, so, generally, the publishing frequency 5 | # should not be higher than 0.2 Hz, and the priority should be either OPTIONAL or SLOW. 6 | # 7 | # All parameters are required unless specifically stated otherwise. 8 | # For non-rechargeable batteries all "charge_*" parameters should be NaN. 9 | 10 | truncated uint64 unique_id 11 | # A statistically unique number that can be used to identify this exact battery for logging and diagnostic purposes. 12 | # This value should be invariant to the identity of the reporting node unless it is an integral part of the battery. 13 | # If the battery supports SBS, the recommended way to populate this field is from two CRC-32C (Castagnoli) values as: 14 | # - 32 most significant bits identify the vendor as: CRC32C(ManufacturerName) 15 | # - 32 least significant bits identify the battery as: CRC32C(DeviceName + ManufactureDate + SerialNumber) 16 | # If the battery does not support SBS, the vendor may choose arbitrary random numbers. 17 | # Note that these are mere recommendations. The only hard requirement for this field is to be statistically unique. 18 | 19 | uavcan.si.unit.mass.Scalar.1.0 mass 20 | # The total mass of the battery, including the packaging, electronics, cabling, and all auxiliary items, if any. 21 | # May be used for predicting the kinematic parameters of the vehicle. 22 | # NaN if unknown. 23 | 24 | uavcan.si.unit.electric_charge.Scalar.1.0 design_capacity 25 | # The maximum total charge of the pack, at 100% SoH, specified by the manufacturer. 26 | 27 | uavcan.si.unit.voltage.Scalar.1.0[2] design_cell_voltage_min_max 28 | # The minimum (end of discharge) and the maximum (end of charge) resting cell voltage specified by the manufacturer 29 | # at 100% SoH. Example: {2.8, 4.2} V. These voltages correspond to resting voltages; i.e., the stabilized voltages after 30 | # the discharge/charge has been terminated. Voltage below the min may be observed during discharge due to the cell's 31 | # internal resistance. Voltage above the max voltage may be observed during regenerative braking/charging etc due to 32 | # the cell's internal resistance. 33 | 34 | uavcan.si.unit.electric_current.Scalar.1.0 discharge_current 35 | # Recommended continuous discharge current of the battery. 36 | 37 | uavcan.si.unit.electric_current.Scalar.1.0 discharge_current_burst 38 | # Maximum current that may be safely discharged at least for 5 seconds. 39 | 40 | uavcan.si.unit.electric_current.Scalar.1.0 charge_current 41 | # Recommended continuous charge current of the battery. 42 | 43 | uavcan.si.unit.electric_current.Scalar.1.0 charge_current_fast 44 | # Recommended safest highest continuous charge current for the battery. 45 | # This may cause accelerated aging of the battery. 46 | 47 | uavcan.si.unit.electric_current.Scalar.1.0 charge_termination_threshold 48 | # End-of-charging current threshold. Charging may be terminated when the current falls below this threshold. 49 | 50 | uavcan.si.unit.voltage.Scalar.1.0 charge_voltage 51 | # The total voltage (not per-cell) that may be used by the charger to charge the battery pack. 52 | 53 | uint16 cycle_count 54 | # The number of charge-discharge cycles. Zero if the battery is new. May increase at runtime. 55 | # What constitutes a charge-discharge cycle is implementation-defined. 56 | 57 | void8 58 | uint8 series_cell_count 59 | # The number of cells connected in series. This value should match the array of cell voltages reported via Status. 60 | 61 | uint7 state_of_health_pct # [percent] 62 | # The SoH of the battery, or best guess thereof; ranges from 0 (unusable) to 100 (new). 63 | void1 64 | 65 | Technology.0.1 technology 66 | # The battery technology information may be leveraged by the charger to choose the appropriate charging strategy. 67 | 68 | uavcan.si.unit.voltage.Scalar.1.0 nominal_voltage 69 | # The nominal voltage of the battery pack (not per-cell) as defined by the vendor. 70 | # E.g., a typical 22S LiCoO2 pack would usually report 81.4 V here. 71 | 72 | truncated uint40 unix_manufacture_time 73 | # The approximate UNIX Epoch time when the battery was manufactured, zero if unknown. 74 | 75 | uint8[<=64] name 76 | # An arbitrary human-readable textual description of this battery. Empty if unknown/unused. 77 | # Batteries that support SBS are recommended to report the manufacturer name and the device name here. 78 | 79 | @extent 8 * 300 80 | -------------------------------------------------------------------------------- /reg/udral/service/battery/Status.0.2.dsdl: -------------------------------------------------------------------------------- 1 | # This low-rate battery status should be published at least once per second. 2 | 3 | reg.udral.service.common.Heartbeat.0.1 heartbeat 4 | # Note that the health code generally should not reflect the battery charge unless the service provider knows 5 | # that the availability of energy in the battery is critical for the safe operation of the vehicle, which is usually 6 | # not the case. For example, if the vehicle is equipped with several batteries that are discharged in series, one 7 | # after another, the depletion of energy in the first battery is not a fault condition and it should not be reported 8 | # as such. This follows from the good service design principles reviewed in https://opencyphal.org/guide. 9 | # 10 | # The readiness state depicts the ability of the battery (or its power electronics) to deliver full rated power 11 | # and whether the overdischarge protections are active. 12 | # When the battery is not ENGAGED, it may limit the output power below the nominal rated value and disconnect the load 13 | # should the charge level fall below the critical level. 14 | # When the battery is ENGAGED, it is not permitted to limit the output power or energy regardless of the risk of damage. 15 | # If the adaptive protection is not supported, the battery should always report its status as ENGAGED. 16 | 17 | uavcan.si.unit.temperature.Scalar.1.0[2] temperature_min_max 18 | # The minimum and maximum readings of the pack temperature sensors. 19 | # For example, if the pack is equipped with three distributed temperature sensors that read {288, 258.15, 360.5} K, 20 | # the reported array value would be {258.15, 360.5} K. 21 | # If there is only one temperature sensor, both elements shall be of the same value. 22 | 23 | uavcan.si.unit.electric_charge.Scalar.1.0 available_charge 24 | # The estimated electric charge currently stored in the battery. This is intended for charging and maintenance only. 25 | # Do not use this parameter for endurance prediction! Instead, use the correct energy type from the physics namespace. 26 | # The depth of discharge (DoD), or the state of charge (SoC), can be derived by dividing this value by the 27 | # nominal battery capacity reported in the Parameters message. 28 | 29 | Error.0.1 error 30 | 31 | uint8 MAX_CELLS = 255 32 | float16[<=MAX_CELLS] cell_voltages # [volt] 33 | # The voltages of individual cells in the battery pack. 34 | 35 | @extent 600 * 8 36 | -------------------------------------------------------------------------------- /reg/udral/service/battery/Technology.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # Battery chemistry type and its form-factor. 2 | # Observe that there is no item to represent unknown technology because it is required to be known. 3 | # This information may be used by charging systems to select the appropriate charging strategy. 4 | # If the battery is of an uncommon type, it may be preferred to report the closest-matching type listed here 5 | # instead of OTHER. 6 | 7 | uint8 value 8 | 9 | uint8 OTHER = 0 # The technology is not specified in this enumeration. Please submit a pull request. 10 | 11 | # NON-RECHARGEABLE 12 | 13 | uint8 LI_SOCL2 = 10 # Lithium-thionyl chloride (Li-SOCl2) 14 | uint8 LI_BCX = 11 # Lithium-thionyl chloride + bromine chloride (Li-BCX) 15 | uint8 LI_MNO2 = 12 # Lithium-manganese dioxide (Li-MnO2) (e.g., lithium coin cell, lithium 9V) 16 | 17 | uint8 ZN_O2 = 20 # Zinc-Air 18 | uint8 AL_O2 = 21 # Aluminum-Air 19 | 20 | uint8 ZN_MNO2_NH4CL = 30 # Zinc-manganese dioxide - ammonium chloride electrolyte (aka zinc-carbon) 21 | uint8 ZN_MNO2_ZNCL2 = 31 # Zinc-manganese dioxide - zinc chloride electrolyte (aka heavy duty zinc-carbon) 22 | uint8 ZN_MNO2_KOH = 32 # Zinc-manganese dioxide - potassium hydroxide electrolyte (aka alkaline) 23 | 24 | # RECHARGEABLE 25 | 26 | uint8 LI_LCO = 100 # Lithium cobalt oxide (commonly known as just "lithium-ion") 27 | uint8 LI_LFP = 101 # Lithium iron phosphate (LiFePO4) 28 | uint8 LI_NMC = 102 # Lithium nickel manganese cobalt oxide 29 | uint8 LI_NCA = 103 # Lithium nickel cobalt aluminium oxide 30 | uint8 LI_LMO = 104 # Lithium manganese oxide 31 | uint8 LI_S = 105 # Lithium-sulfur (LiS) 32 | 33 | uint8 LI_LCO_POUCH = 110 # LiCoO2 in pouch form factor, commonly known as "lithium-ion polymer" or "LiPo". 34 | uint8 LI_LFP_POUCH = 111 # LiFePO4 in pouch form factor, commonly known as "LiFePO4 polymer". 35 | 36 | uint8 NI_MH = 120 # Nickel-metal hydride 37 | uint8 NI_CD = 121 # Nickel-cadmium 38 | uint8 NI_ZN = 122 # Nickel-zinc 39 | uint8 NI_FE = 123 # Nickel-iron 40 | 41 | uint8 PB_AC = 130 # Lead acid 42 | uint8 PB_AC_SEALED = 131 # Also known as SLA 43 | 44 | uint8 EDLC = 200 # Electrostatic double-layer capacitor 45 | 46 | @sealed 47 | -------------------------------------------------------------------------------- /reg/udral/service/battery/_.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # This is the smart battery monitoring service. A smart battery is required to publish on the following subjects: 2 | # 3 | # SUBJECT TYPE TYP. RATE [Hz] 4 | # energy_source reg.udral.physics.electricity.SourceTs 1...100 5 | # status reg.udral.service.battery.Status ~1 6 | # parameters reg.udral.service.battery.Parameters ~0.2 7 | # 8 | # Observe that only the first subject can be used for estimating the endurance of the power source. The other subjects 9 | # are designed for monitoring, diagnostics, and maintenance. 10 | # 11 | # Optionally, the battery service can subscribe to a readiness control subject (see reg.udral.service.common.Readiness), 12 | # which enables the following two optional capabilities: 13 | # 14 | # - SLEEP mode: when the readiness subject commands the sleep state, the battery management system may enter a 15 | # low power consumption state, possibly deactivating some of its capabilities. 16 | # 17 | # - STANDBY mode: the battery management system may implement additional safety protections that may otherwise 18 | # interfere with the normal operation of the vehicle. For example, the traction battery may limit the maximum 19 | # load current and the depth of discharge unless the commanded state is ENGAGED. By doing so, the battery can 20 | # protect itself and the supplied high-voltage DC network from accidental damage while the vehicle is parked. 21 | # Limiting the output power or discharge of the traction battery might lead to catastrophic consequences in 22 | # an aerial vehicle, hence such safety checks are to be disabled once the battery is commanded into the ENGAGED 23 | # state. 24 | # 25 | # If readiness state selection is not supported, the battery may not subscribe to the readiness control subject, 26 | # in which case it should permanently report its state as ENGAGED unless the battery is unfit for use (e.g., due 27 | # to degradation or a failure). 28 | # 29 | # By convention, positive current flows from the DC network into the battery. Therefore, the current is 30 | # negative when the battery powers the system, and positive when it is being charged. 31 | # 32 | # Systems that leverage multiple battery packs simultaneously should be configured to publish the status of each 33 | # pack on a separate subject. 34 | # 35 | # Published quantities should be low-pass filtered to avoid aliasing effects. 36 | # Publishers should strive to sample all parameters atomically. 37 | # 38 | # The reported quantities are focused on the amount of energy that can be reclaimed from the battery. In a 39 | # simplified view, this can be seen as the amount of energy that is "stored" in the battery; however, this 40 | # interpretation is not strictly correct because the amount of retrievable energy may be dependent on external 41 | # factors such as the temperature of the battery or the load current. Energy estimation is hard and requires 42 | # accurate modeling of the state of the battery, which may be impossible to do without precise tracking of each 43 | # charging cycle. Despite the complications, this is considered to be a superior approach compared to the commonly 44 | # used alternative where the state estimation is focused on the electric charge, because the latter cannot be used 45 | # directly to predict the endurance of the system. 46 | # 47 | # The methods of energy estimation are implementation-defined. 48 | 49 | @extent 0 # This type is not intended for runtime use. 50 | -------------------------------------------------------------------------------- /reg/udral/service/common/Heartbeat.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # The function of the service heartbeat is similar to that of the node heartbeat defined in the standard namespace, 2 | # except that it is used on a per-service basis, meaning that there may be more than one publisher per node. 3 | # 4 | # The service heartbeat should be published either on a separate subject, or as a structural supertype of a 5 | # service-specific status subject. The publication rate is service-specific but it should not be lower than 1 Hz. 6 | # 7 | # This is a structural subtype of the Readiness type. 8 | 9 | uint8 MAX_PUBLICATION_PERIOD = 1 10 | # Any service that is not in the SLEEP state should publish its heartbeat (or a derived status) at least at this rate. 11 | 12 | Readiness.0.1 readiness 13 | uavcan.node.Health.1.0 health 14 | 15 | @sealed 16 | @assert _offset_ / 8 == {2} 17 | -------------------------------------------------------------------------------- /reg/udral/service/common/Readiness.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # The readiness state is used to command or report the availability status of a networked service (subsystem). 2 | # 3 | # Any system shall have at least one readiness command subject that acts as a global power switch. 4 | # Every subsystem controlled in such way would usually report its readiness status back to account for the fact that 5 | # the transition between different readiness states may not be instantaneous. 6 | # The readiness status reporting is done by means of the service heartbeat type that is also defined in this namespace; 7 | # the service heartbeat type is a structural subtype of this type. 8 | # 9 | # +------------+ 10 | # | Controller |----------+----------------+----------------+---------... readiness command subject 11 | # +------------+ | | | 12 | # ^ ^ ^ v v v 13 | # | | | +---------+ +---------+ +---------+ 14 | # | | | | Service | | Service | | Service | ... 15 | # | | | +---------+ +---------+ +---------+ 16 | # | | | | | | 17 | # | | +-------------+ | | 18 | # | +----------------------------------+ | service heartbeat subjects 19 | # +-------------------------------------------------------+ 20 | # 21 | # In a less trivial use case there may be an arbitrary number of such readiness command subjects (local power switches) 22 | # controlling various systems within the vehicle (e.g., propulsion, perception sensors, communication, etc). 23 | # 24 | # The publication rate is defined on a per-service basis, but it should never be lower than 1 Hz, 25 | # excepting services that are in the SLEEP state, in which case it is permitted to cease all network activity. 26 | 27 | truncated uint2 value 28 | 29 | uint2 SLEEP = 0 30 | # The long-term state of minimal power consumption. 31 | # Typically, most subsystems are switched into the SLEEP mode when the vehicle is parked and powered off. 32 | # Subsystems that do not support the SLEEP state should treat it as an equivalent of STANDBY. 33 | # 34 | # A subsystem may require a substantial amount of time to exit the sleep mode (for example, time may be needed to 35 | # boot the operating system and run the self test procedures). 36 | # 37 | # While in the SLEEP mode, the subsystem is allowed to cease service provision and stop all network activity 38 | # regardless of other requirements, except that it shall be able to reactivate itself if a Readiness message is 39 | # received commanding any state other than SLEEP. 40 | 41 | # Value 1 is invalid and shall never be commanded. 42 | # Implementations receiving this value should interpret it either as SLEEP or STANDBY. 43 | 44 | uint2 STANDBY = 2 45 | # The state of being ready to enter the normal operating mode in a short order. 46 | # A subsystem that is in STANDBY state should be able to participate in the normal network activity. 47 | # This is the default state that the subsystem should reside in after power-on until explicitly commanded otherwise. 48 | 49 | uint2 ENGAGED = 3 50 | # When ENGAGED, the subsystem is performing its main intended function at the nominal performance characteristics. 51 | # A subsystem may require a short amount of time, possibly under a few seconds, to switch between the ENGAGED and 52 | # STANDBY states (in any direction). 53 | # Some subsystems may not differentiate between STANDBY and ENGAGED (e.g., offboard communication hardware). 54 | # The subsystem may disengage itself autonomously in the event of a fatal malfunction, in which case 55 | # the reported service health status should be WARNING. 56 | 57 | @sealed 58 | -------------------------------------------------------------------------------- /reg/udral/service/sensor/Status.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # A generic sensor status information. 2 | # This data should be published at a low rate but not lower than the specified limit. 3 | 4 | uint8 MAX_PUBLICATION_PERIOD = 1 # [second] 5 | 6 | uavcan.si.unit.duration.Scalar.1.0 data_validity_period 7 | # Data samples obtained at time Ts are valid at time Tr if: (Tr - Ts) < data_validity_period 8 | # Expired data should be discarded. 9 | 10 | uint32 error_count 11 | # Incremented once per occurrence. Reset to zero when the sensor is ENGAGED. 12 | # The exact definition of what constitutes an error is implementation-dependent. 13 | 14 | uavcan.si.unit.temperature.Scalar.1.0 sensor_temperature 15 | # The temperature of the sensing element. 16 | # If there are multiple sensing elements or multiple temperature probes per sensor, 17 | # the reduction is implementation-defined. 18 | # In a later revision this field may be moved into a separate type. 19 | 20 | @extent 63 * 8 # Single-frame transfer over CAN FD. 21 | -------------------------------------------------------------------------------- /uavcan/diagnostic/8184.Record.1.0.dsdl: -------------------------------------------------------------------------------- 1 | # Generic human-readable text message for logging and displaying purposes. 2 | # Generally, it should be published at the lowest priority level. 3 | 4 | @deprecated 5 | 6 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 7 | # Optional timestamp in the network-synchronized time system; zero if undefined. 8 | # The timestamp value conveys the exact moment when the reported event took place. 9 | 10 | Severity.1.0 severity 11 | 12 | uint8[<=112] text 13 | # Message text. 14 | # Normally, messages should be kept as short as possible, especially those of high severity. 15 | 16 | @extent 300 * 8 17 | @assert _offset_.max <= (124 * 8) # Two CAN FD frames max 18 | -------------------------------------------------------------------------------- /uavcan/diagnostic/8184.Record.1.1.dsdl: -------------------------------------------------------------------------------- 1 | # Generic human-readable text message for logging and displaying purposes. 2 | # Generally, it should be published at the lowest priority level. 3 | 4 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 5 | # Optional timestamp in the network-synchronized time system; zero if undefined. 6 | # The timestamp value conveys the exact moment when the reported event took place. 7 | 8 | Severity.1.0 severity 9 | 10 | uint8[<256] text 11 | # Message text. 12 | # Normally, messages should be kept as short as possible, especially those of high severity. 13 | 14 | @extent 300 * 8 15 | -------------------------------------------------------------------------------- /uavcan/diagnostic/Severity.1.0.dsdl: -------------------------------------------------------------------------------- 1 | # Generic message severity representation. 2 | 3 | uint3 value 4 | # The severity level ranging from 0 to 7, where low values represent low-severity (unimportant) messages, and 5 | # high values represent high-severity (important) messages. Several mnemonics for the severity levels are 6 | # defined below. Nodes are advised to implement output filtering mechanisms, allowing users to select 7 | # the minimal severity for emitted messages; messages of the selected and higher severity levels will 8 | # be published, and messages of lower severity will be suppressed (discarded). 9 | 10 | uint3 TRACE = 0 11 | # Messages of this severity can be used only during development. 12 | # They shall not be used in a fielded operational system. 13 | 14 | uint3 DEBUG = 1 15 | # Messages that can aid in troubleshooting. 16 | # Messages of this severity and lower should be disabled by default. 17 | 18 | uint3 INFO = 2 19 | # General informational messages of low importance. 20 | # Messages of this severity and lower should be disabled by default. 21 | 22 | uint3 NOTICE = 3 23 | # General informational messages of high importance. 24 | # Messages of this severity and lower should be disabled by default. 25 | 26 | uint3 WARNING = 4 27 | # Messages reporting abnormalities and warning conditions. 28 | # Messages of this severity and higher should be enabled by default. 29 | 30 | uint3 ERROR = 5 31 | # Messages reporting problems and error conditions. 32 | # Messages of this severity and higher should be enabled by default. 33 | 34 | uint3 CRITICAL = 6 35 | # Messages reporting serious problems and critical conditions. 36 | # Messages of this severity and higher should be always enabled. 37 | 38 | uint3 ALERT = 7 39 | # Notifications of dangerous circumstances that demand immediate attention. 40 | # Messages of this severity should be always enabled. 41 | 42 | @sealed 43 | -------------------------------------------------------------------------------- /uavcan/file/405.GetInfo.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # Information about a remote file system entry (file, directory, etc). 2 | 3 | @deprecated 4 | 5 | Path.1.0 path 6 | 7 | @extent 300 * 8 8 | 9 | --- 10 | 11 | Error.1.0 error 12 | # Result of the operation. 13 | 14 | truncated uint40 size 15 | # File size in bytes. Should be set to zero for directories. 16 | 17 | truncated uint40 unix_timestamp_of_last_modification 18 | # The UNIX Epoch time when the entry was last modified. Zero if unknown. 19 | 20 | bool is_file_not_directory # True if file, false if directory. 21 | bool is_link # This is a link to another entry; the above flag indicates the type of the target. 22 | bool is_readable # The item can be read by the caller (applies to files and directories). 23 | bool is_writeable # The item can be written by the caller (applies to files and directories). 24 | # If such entry does not exist, all flags should be cleared/ignored. 25 | void4 26 | 27 | @extent 48 * 8 28 | -------------------------------------------------------------------------------- /uavcan/file/405.GetInfo.0.2.dsdl: -------------------------------------------------------------------------------- 1 | # Information about a remote file system entry (file, directory, etc). 2 | 3 | Path.2.0 path 4 | 5 | @extent 300 * 8 6 | 7 | --- 8 | 9 | Error.1.0 error 10 | # Result of the operation. 11 | 12 | truncated uint40 size 13 | # File size in bytes. Should be set to zero for directories. 14 | 15 | truncated uint40 unix_timestamp_of_last_modification 16 | # The UNIX Epoch time when the entry was last modified. Zero if unknown. 17 | 18 | bool is_file_not_directory # True if file, false if directory. 19 | bool is_link # This is a link to another entry; the above flag indicates the type of the target. 20 | bool is_readable # The item can be read by the caller (applies to files and directories). 21 | bool is_writeable # The item can be written by the caller (applies to files and directories). 22 | # If such entry does not exist, all flags should be cleared/ignored. 23 | void4 24 | 25 | @extent 48 * 8 26 | -------------------------------------------------------------------------------- /uavcan/file/406.List.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # This service can be used to list a remote directory, one entry per request. 2 | # 3 | # The client should query each entry independently, iterating 'entry_index' from 0 until the last entry. 4 | # When the index reaches the number of elements in the directory, the server will report that there is 5 | # no such entry by returning an empty name. 6 | # 7 | # The field entry_index shall be applied to an ordered list of directory entries (e.g. alphabetically ordered). 8 | # The exact sorting criteria does not matter as long as it provides the same ordering for subsequent service calls. 9 | # 10 | # Observe that this listing operation is fundamentally non-atomic. The caller shall beware of possible race conditions 11 | # and is responsible for handling them properly. Particularly, consider what happens if a new item is inserted into 12 | # the directory between two subsequent calls: if the item happened to be inserted at the index that is lower than the 13 | # index of the next request, the next returned item (or several, if more items were inserted) will repeat the ones 14 | # that were listed earlier. The caller should handle that properly, either by ignoring the repeated items or by 15 | # restarting the listing operation from the beginning (index 0). 16 | 17 | @deprecated 18 | 19 | uint32 entry_index 20 | 21 | void32 # Reserved for future use. 22 | 23 | Path.1.0 directory_path 24 | 25 | @extent 300 * 8 26 | 27 | --- 28 | 29 | void32 # Reserved for future use. 30 | 31 | Path.1.0 entry_base_name 32 | # The base name of the referenced entry, i.e., relative to the outer directory. 33 | # The outer directory path is not included to conserve bandwidth. 34 | # Empty if such entry does not exist. 35 | # 36 | # For example, suppose there is a file "/foo/bar/baz.bin". Listing the directory with the path "/foo/bar/" (the slash 37 | # at the end is optional) at the index 0 will return "baz.bin". Listing the same directory at the index 1 (or any 38 | # higher) will return an empty name "", indicating that the caller has reached the end of the list. 39 | 40 | @extent 300 * 8 41 | -------------------------------------------------------------------------------- /uavcan/file/406.List.0.2.dsdl: -------------------------------------------------------------------------------- 1 | # This service can be used to list a remote directory, one entry per request. 2 | # 3 | # The client should query each entry independently, iterating 'entry_index' from 0 until the last entry. 4 | # When the index reaches the number of elements in the directory, the server will report that there is 5 | # no such entry by returning an empty name. 6 | # 7 | # The field entry_index shall be applied to an ordered list of directory entries (e.g. alphabetically ordered). 8 | # The exact sorting criteria does not matter as long as it provides the same ordering for subsequent service calls. 9 | # 10 | # Observe that this listing operation is fundamentally non-atomic. The caller shall beware of possible race conditions 11 | # and is responsible for handling them properly. Particularly, consider what happens if a new item is inserted into 12 | # the directory between two subsequent calls: if the item happened to be inserted at the index that is lower than the 13 | # index of the next request, the next returned item (or several, if more items were inserted) will repeat the ones 14 | # that were listed earlier. The caller should handle that properly, either by ignoring the repeated items or by 15 | # restarting the listing operation from the beginning (index 0). 16 | 17 | uint32 entry_index 18 | 19 | void32 # Reserved for future use. 20 | 21 | Path.2.0 directory_path 22 | 23 | @extent 300 * 8 24 | 25 | --- 26 | 27 | void32 # Reserved for future use. 28 | 29 | Path.2.0 entry_base_name 30 | # The base name of the referenced entry, i.e., relative to the outer directory. 31 | # The outer directory path is not included to conserve bandwidth. 32 | # Empty if such entry does not exist. 33 | # 34 | # For example, suppose there is a file "/foo/bar/baz.bin". Listing the directory with the path "/foo/bar/" (the slash 35 | # at the end is optional) at the index 0 will return "baz.bin". Listing the same directory at the index 1 (or any 36 | # higher) will return an empty name "", indicating that the caller has reached the end of the list. 37 | 38 | @extent 300 * 8 39 | -------------------------------------------------------------------------------- /uavcan/file/407.Modify.1.0.dsdl: -------------------------------------------------------------------------------- 1 | # Manipulate a remote file system entry. Applies to files, directories, and links alike. 2 | # If the remote entry is a directory, all nested entries will be affected, too. 3 | # 4 | # The server should perform all operations atomically, unless atomicity is not supported by 5 | # the underlying file system. 6 | # 7 | # Atomic copying can be effectively employed by remote nodes before reading or after writing 8 | # the file to minimize the possibility of race conditions. 9 | # For example, before reading a large file from the server, the cilent might opt to create 10 | # a temporary copy of it first, then read the copy, and delete it upon completion. Likewise, 11 | # a similar strategy can be employed for writing, where the file is first written at a 12 | # temporary location, and then moved to its final destination. These approaches, however, 13 | # may lead to creation of dangling temporary files if the client failed to dispose of them 14 | # properly, so that risk should be taken into account. 15 | # 16 | # Move/Copy 17 | # Specify the source path and the destination path. 18 | # If the source does not exist, the operation will fail. 19 | # Set the preserve_source flag to copy rather than move. 20 | # If the destination exists and overwrite_destination is not set, the operation will fail. 21 | # If the target path includes non-existent directories, they will be created (like "mkdir -p"). 22 | # 23 | # Touch 24 | # Specify the destination path and make the source path empty. 25 | # If the path exists (file/directory/link), its modification time will be updated. 26 | # If the path does not exist, an empty file will be created. 27 | # If the target path includes non-existent directories, they will be created (like "mkdir -p"). 28 | # Flags are ignored. 29 | # 30 | # Remove 31 | # Specify the source path (file/directory/link) and make the destination path empty. 32 | # Fails if the path does not exist. 33 | # Flags are ignored. 34 | 35 | @deprecated 36 | 37 | bool preserve_source # Do not remove the source. Used to copy instead of moving. 38 | bool overwrite_destination # If the destination exists, remove it beforehand. 39 | void30 40 | 41 | Path.1.0 source 42 | Path.1.0 destination 43 | 44 | @extent 600 * 8 45 | 46 | --- 47 | 48 | Error.1.0 error 49 | 50 | @extent 48 * 8 51 | -------------------------------------------------------------------------------- /uavcan/file/407.Modify.1.1.dsdl: -------------------------------------------------------------------------------- 1 | # Manipulate a remote file system entry. Applies to files, directories, and links alike. 2 | # If the remote entry is a directory, all nested entries will be affected, too. 3 | # 4 | # The server should perform all operations atomically, unless atomicity is not supported by 5 | # the underlying file system. 6 | # 7 | # Atomic copying can be effectively employed by remote nodes before reading or after writing 8 | # the file to minimize the possibility of race conditions. 9 | # For example, before reading a large file from the server, the cilent might opt to create 10 | # a temporary copy of it first, then read the copy, and delete it upon completion. Likewise, 11 | # a similar strategy can be employed for writing, where the file is first written at a 12 | # temporary location, and then moved to its final destination. These approaches, however, 13 | # may lead to creation of dangling temporary files if the client failed to dispose of them 14 | # properly, so that risk should be taken into account. 15 | # 16 | # Move/Copy 17 | # Specify the source path and the destination path. 18 | # If the source does not exist, the operation will fail. 19 | # Set the preserve_source flag to copy rather than move. 20 | # If the destination exists and overwrite_destination is not set, the operation will fail. 21 | # If the target path includes non-existent directories, they will be created (like "mkdir -p"). 22 | # 23 | # Touch 24 | # Specify the destination path and make the source path empty. 25 | # If the path exists (file/directory/link), its modification time will be updated. 26 | # If the path does not exist, an empty file will be created. 27 | # If the target path includes non-existent directories, they will be created (like "mkdir -p"). 28 | # Flags are ignored. 29 | # 30 | # Remove 31 | # Specify the source path (file/directory/link) and make the destination path empty. 32 | # Fails if the path does not exist. 33 | # Flags are ignored. 34 | 35 | bool preserve_source # Do not remove the source. Used to copy instead of moving. 36 | bool overwrite_destination # If the destination exists, remove it beforehand. 37 | void30 38 | 39 | Path.2.0 source 40 | Path.2.0 destination 41 | 42 | @extent 600 * 8 43 | 44 | --- 45 | 46 | Error.1.0 error 47 | 48 | @extent 48 * 8 49 | -------------------------------------------------------------------------------- /uavcan/file/408.Read.1.0.dsdl: -------------------------------------------------------------------------------- 1 | # Read file from a remote node. 2 | # 3 | # There are two possible outcomes of a successful call: 4 | # 1. Data array size equals its capacity. This means that the end of the file is not reached yet. 5 | # 2. Data array size is less than its capacity, possibly zero. This means that the end of the file is reached. 6 | # 7 | # Thus, if the client needs to fetch the entire file, it should repeatedly call this service while increasing the 8 | # offset, until a non-full data array is returned. 9 | # 10 | # If the object pointed by 'path' cannot be read (e.g. it is a directory or it does not exist), an appropriate error 11 | # code will be returned, and the data array will be empty. 12 | # 13 | # It is easy to see that this protocol is prone to race conditions because the remote file can be modified 14 | # between read operations which might result in the client obtaining a damaged file. To combat this, 15 | # application designers are recommended to adhere to the following convention. Let every file whose integrity 16 | # is of interest have a hash or a digital signature, which is stored in an adjacent file under the same name 17 | # suffixed with the appropriate extension according to the type of hash or digital signature used. 18 | # For example, let there be file "image.bin", integrity of which shall be ensured by the client upon downloading. 19 | # Suppose that the file is hashed using SHA-256, so the appropriate file extension for the hash would be 20 | # ".sha256". Following this convention, the hash of "image.bin" would be stored in "image.bin.sha256". 21 | # After downloading the file, the client would read the hash (being small, the hash can be read in a single 22 | # request) and check it against a locally computed value. Some servers may opt to generate such hash files 23 | # automatically as necessary; for example, if such file is requested but it does not exist, the server would 24 | # compute the necessary signature or hash (the type of hash/signature can be deduced from the requested file 25 | # extension) and return it as if the file existed. Obviously, this would be impractical for very large files; 26 | # in that case, hash/signature should be pre-computed and stored in a real file. If this approach is followed, 27 | # implementers are advised to use only SHA-256 for hashing, in order to reduce the number of fielded 28 | # incompatible implementations. 29 | 30 | @deprecated 31 | 32 | truncated uint40 offset 33 | 34 | Path.1.0 path 35 | 36 | @extent 300 * 8 37 | 38 | --- 39 | 40 | Error.1.0 error 41 | 42 | uint8[<=256] data 43 | 44 | @extent 300 * 8 45 | -------------------------------------------------------------------------------- /uavcan/file/408.Read.1.1.dsdl: -------------------------------------------------------------------------------- 1 | # Read file from a remote node. 2 | # 3 | # There are two possible outcomes of a successful call: 4 | # 1. Data array size equals its capacity. This means that the end of the file is not reached yet. 5 | # 2. Data array size is less than its capacity, possibly zero. This means that the end of the file is reached. 6 | # 7 | # Thus, if the client needs to fetch the entire file, it should repeatedly call this service while increasing the 8 | # offset, until a non-full data array is returned. 9 | # 10 | # If the object pointed by 'path' cannot be read (e.g. it is a directory or it does not exist), an appropriate error 11 | # code will be returned, and the data array will be empty. 12 | # 13 | # It is easy to see that this protocol is prone to race conditions because the remote file can be modified 14 | # between read operations which might result in the client obtaining a damaged file. To combat this, 15 | # application designers are recommended to adhere to the following convention. Let every file whose integrity 16 | # is of interest have a hash or a digital signature, which is stored in an adjacent file under the same name 17 | # suffixed with the appropriate extension according to the type of hash or digital signature used. 18 | # For example, let there be file "image.bin", integrity of which shall be ensured by the client upon downloading. 19 | # Suppose that the file is hashed using SHA-256, so the appropriate file extension for the hash would be 20 | # ".sha256". Following this convention, the hash of "image.bin" would be stored in "image.bin.sha256". 21 | # After downloading the file, the client would read the hash (being small, the hash can be read in a single 22 | # request) and check it against a locally computed value. Some servers may opt to generate such hash files 23 | # automatically as necessary; for example, if such file is requested but it does not exist, the server would 24 | # compute the necessary signature or hash (the type of hash/signature can be deduced from the requested file 25 | # extension) and return it as if the file existed. Obviously, this would be impractical for very large files; 26 | # in that case, hash/signature should be pre-computed and stored in a real file. If this approach is followed, 27 | # implementers are advised to use only SHA-256 for hashing, in order to reduce the number of fielded 28 | # incompatible implementations. 29 | 30 | truncated uint40 offset 31 | 32 | Path.2.0 path 33 | 34 | @extent 300 * 8 35 | 36 | --- 37 | 38 | Error.1.0 error 39 | 40 | uavcan.primitive.Unstructured.1.0 data 41 | 42 | @extent 300 * 8 43 | -------------------------------------------------------------------------------- /uavcan/file/409.Write.1.0.dsdl: -------------------------------------------------------------------------------- 1 | # Write into a remote file. 2 | # The server shall place the contents of the field 'data' into the file pointed by 'path' at the offset specified by 3 | # the field 'offset'. 4 | # 5 | # When writing a file, the client should repeatedly call this service with data while advancing the offset until the 6 | # file is written completely. When the write sequence is completed, the client shall call the service one last time, 7 | # with the offset set to the size of the file and with the data field empty, which will signal the server that the 8 | # transfer is finished. 9 | # 10 | # When the write operation is complete, the server shall truncate the resulting file past the specified offset. 11 | 12 | @deprecated 13 | 14 | truncated uint40 offset 15 | 16 | Path.1.0 path 17 | 18 | uint8[<=192] data # 192 = 128 + 64; the write protocol permits usage of smaller chunks. 19 | 20 | @extent 600 * 8 21 | 22 | --- 23 | 24 | Error.1.0 error 25 | 26 | @extent 48 * 8 27 | -------------------------------------------------------------------------------- /uavcan/file/409.Write.1.1.dsdl: -------------------------------------------------------------------------------- 1 | # Write into a remote file. 2 | # The server shall place the contents of the field 'data' into the file pointed by 'path' at the offset specified by 3 | # the field 'offset'. 4 | # 5 | # When writing a file, the client should repeatedly call this service with data while advancing the offset until the 6 | # file is written completely. When the write sequence is completed, the client shall call the service one last time, 7 | # with the offset set to the size of the file and with the data field empty, which will signal the server that the 8 | # transfer is finished. 9 | # 10 | # When the write operation is complete, the server shall truncate the resulting file past the specified offset. 11 | 12 | truncated uint40 offset 13 | 14 | Path.2.0 path 15 | 16 | uavcan.primitive.Unstructured.1.0 data 17 | 18 | @extent 600 * 8 19 | 20 | --- 21 | 22 | Error.1.0 error 23 | 24 | @extent 48 * 8 25 | -------------------------------------------------------------------------------- /uavcan/file/Error.1.0.dsdl: -------------------------------------------------------------------------------- 1 | # Nested type. 2 | # Result of a file system operation. 3 | 4 | uint16 OK = 0 5 | uint16 UNKNOWN_ERROR = 65535 6 | 7 | uint16 NOT_FOUND = 2 8 | uint16 IO_ERROR = 5 9 | uint16 ACCESS_DENIED = 13 10 | uint16 IS_DIRECTORY = 21 # I.e., attempted read/write on a path that points to a directory 11 | uint16 INVALID_VALUE = 22 # E.g., file name is not valid for the target file system 12 | uint16 FILE_TOO_LARGE = 27 13 | uint16 OUT_OF_SPACE = 28 14 | uint16 NOT_SUPPORTED = 38 15 | 16 | uint16 value 17 | 18 | @sealed 19 | -------------------------------------------------------------------------------- /uavcan/file/Path.1.0.dsdl: -------------------------------------------------------------------------------- 1 | # Nested type. 2 | # A file system path encoded in UTF8. The only valid separator is the forward slash "/". 3 | # A single slash ("/") refers to the root directory (the location of which is defined by the server). 4 | # Relative references (e.g. "..") are not defined and not permitted (although this may change in the future). 5 | # Conventions (not enforced): 6 | # - A path pointing to a file or a link to file should not end with a separator. 7 | # - A path pointing to a directory or to a link to directory should end with a separator. 8 | # 9 | # The maximum path length limit is chosen as a trade-off between compatibility with deep directory structures and 10 | # the worst-case transfer length. The limit is 112 bytes, which allows all transfers containing a single instance 11 | # of path and no other large data chunks to fit into two CAN FD frames. 12 | 13 | @deprecated 14 | 15 | uint8 SEPARATOR = '/' 16 | uint8 MAX_LENGTH = 112 17 | 18 | uint8[<=MAX_LENGTH] path 19 | 20 | @sealed 21 | -------------------------------------------------------------------------------- /uavcan/file/Path.2.0.dsdl: -------------------------------------------------------------------------------- 1 | # Nested type. 2 | # A file system path encoded in UTF8. The only valid separator is the forward slash "/". 3 | # A single slash ("/") refers to the root directory (the location of which is defined by the server). 4 | # Relative references (e.g. "..") are not defined and not permitted (although this may change in the future). 5 | # Conventions (not enforced): 6 | # - A path pointing to a file or a link to file should not end with a separator. 7 | # - A path pointing to a directory or to a link to directory should end with a separator. 8 | 9 | uint8 SEPARATOR = '/' 10 | uint8 MAX_LENGTH = 2 ** 8 - 1 11 | 12 | uint8[<=MAX_LENGTH] path 13 | 14 | @sealed 15 | -------------------------------------------------------------------------------- /uavcan/internet/udp/500.HandleIncomingPacket.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # This message carries UDP packets sent from a remote host on the Internet or a LAN to a node on the local Cyphal bus. 2 | # Please refer to the definition of the message type OutgoingPacket for a general overview of the packet forwarding 3 | # logic. 4 | # 5 | # This data type has been made a service type rather than a message type in order to make its transfers addressable, 6 | # allowing nodes to employ hardware acceptance filters for filtering out forwarded datagrams that are not addressed 7 | # to them. Additionally, requiring the destination nodes to always respond upon reception of the forwarded datagram 8 | # opens interesting opportunities for future extensions of the forwarding protocol. If the service invocation times 9 | # out, the modem node is permitted to remove the corresponding entry from the NAT table immediately, not waiting 10 | # for its TTL to expire. 11 | # 12 | # It should be noted that this data type definition intentionally leaves out the source address. This is done in 13 | # order to simplify the implementation, reduce the bus traffic overhead, and because the nature of the 14 | # communication patterns proposed by this set of messages does not provide a valid way to implement server hosts 15 | # on the local Cyphal bus. It is assumed that local nodes can be only clients, and therefore, they will be able to 16 | # determine the address of the sender simply by mapping the field session_id to their internally maintained states. 17 | # Furthermore, it is uncertain what is the optimal way of representing the source address for 18 | # client nodes: it is assumed that the local nodes will mostly use DNS names rather than IP addresses, so if there 19 | # was a source address field, modem nodes would have to perform reverse mapping from the IP address they received 20 | # the datagram from to the corresponding DNS name that was used by the local node with the outgoing message. This 21 | # approach creates a number of troubling corner cases and adds a fair amount of hidden complexities to the 22 | # implementation of modem nodes. 23 | # 24 | # It is recommended to perform service invocations at the same transfer priority level as was used for broadcasting 25 | # the latest matching message of type OutgoingPacket. However, meeting this recommendation would require the modem 26 | # node to implement additional logic, which may be undesirable. Therefore, implementers are free to deviate from 27 | # this recommendation and resort to a fixed priority level instead. In the case of a fixed priority level, it is 28 | # advised to use the lowest transfer priority level. 29 | 30 | @deprecated 31 | 32 | uint16 session_id 33 | # This field shall contain the same value that was used by the local node when sending the corresponding outgoing 34 | # packet using the message type OutgoingPacket. This value will be used by the local node to match the response 35 | # with its local context. 36 | 37 | uint8[<=309] payload 38 | # Effective payload. This data will be forwarded from the remote host verbatim. 39 | # UDP packets that contain more than 508 bytes of payload may be dropped by some types of 40 | # communication equipment. Refer to RFC 791 and 2460 for an in-depth review. 41 | # Cyphal further limits the maximum packet size to reduce the memory and traffic burden on the nodes. 42 | # Datagrams that exceed the capacity of this field should be discarded by the modem node. 43 | 44 | @extent 600 * 8 45 | @assert _offset_ % 8 == {0} 46 | @assert _offset_.max == (313 * 8) # At most five CAN FD frames 47 | 48 | --- 49 | 50 | @extent 63 * 8 51 | -------------------------------------------------------------------------------- /uavcan/internet/udp/500.HandleIncomingPacket.0.2.dsdl: -------------------------------------------------------------------------------- 1 | # This message carries UDP packets sent from a remote host on the Internet or a LAN to a node on the local Cyphal bus. 2 | # Please refer to the definition of the message type OutgoingPacket for a general overview of the packet forwarding 3 | # logic. 4 | # 5 | # This data type has been made a service type rather than a message type in order to make its transfers addressable, 6 | # allowing nodes to employ hardware acceptance filters for filtering out forwarded datagrams that are not addressed 7 | # to them. Additionally, requiring the destination nodes to always respond upon reception of the forwarded datagram 8 | # opens interesting opportunities for future extensions of the forwarding protocol. If the service invocation times 9 | # out, the modem node is permitted to remove the corresponding entry from the NAT table immediately, not waiting 10 | # for its TTL to expire. 11 | # 12 | # It should be noted that this data type definition intentionally leaves out the source address. This is done in 13 | # order to simplify the implementation, reduce the bus traffic overhead, and because the nature of the 14 | # communication patterns proposed by this set of messages does not provide a valid way to implement server hosts 15 | # on the local Cyphal bus. It is assumed that local nodes can be only clients, and therefore, they will be able to 16 | # determine the address of the sender simply by mapping the field session_id to their internally maintained states. 17 | # Furthermore, it is uncertain what is the optimal way of representing the source address for 18 | # client nodes: it is assumed that the local nodes will mostly use DNS names rather than IP addresses, so if there 19 | # was a source address field, modem nodes would have to perform reverse mapping from the IP address they received 20 | # the datagram from to the corresponding DNS name that was used by the local node with the outgoing message. This 21 | # approach creates a number of troubling corner cases and adds a fair amount of hidden complexities to the 22 | # implementation of modem nodes. 23 | # 24 | # It is recommended to perform service invocations at the same transfer priority level as was used for broadcasting 25 | # the latest matching message of type OutgoingPacket. However, meeting this recommendation would require the modem 26 | # node to implement additional logic, which may be undesirable. Therefore, implementers are free to deviate from 27 | # this recommendation and resort to a fixed priority level instead. In the case of a fixed priority level, it is 28 | # advised to use the lowest transfer priority level. 29 | 30 | uint16 session_id 31 | # This field shall contain the same value that was used by the local node when sending the corresponding outgoing 32 | # packet using the message type OutgoingPacket. This value will be used by the local node to match the response 33 | # with its local context. 34 | 35 | uint8[<=508] payload 36 | # Effective payload. This data will be forwarded from the remote host verbatim. 37 | # UDP packets that contain more than 508 bytes of payload may be dropped by some types of 38 | # communication equipment. Refer to RFC 791 and 2460 for an in-depth review. 39 | # Datagrams that exceed the capacity of this field should be discarded by the modem node. 40 | 41 | @extent 600 * 8 42 | 43 | --- 44 | 45 | @extent 63 * 8 46 | -------------------------------------------------------------------------------- /uavcan/internet/udp/8174.OutgoingPacket.0.2.dsdl: -------------------------------------------------------------------------------- 1 | # This message carries UDP packets from a node on the local bus to a remote host on the Internet or a LAN. 2 | # 3 | # Any node can broadcast a message of this type. 4 | # 5 | # All nodes that are capable of communication with the Internet or a LAN should subscribe to messages 6 | # of this type and forward the payload to the indicated host and port using exactly one UDP datagram 7 | # per message (i.e. additional fragmentation is to be avoided). Such nodes will be referred to as 8 | # "modem nodes". 9 | # 10 | # It is expected that some systems will have more than one modem node available. 11 | # Each modem node is supposed to forward every message it sees, which will naturally create 12 | # some degree of modular redundancy and fault tolerance. The remote host should therefore be able to 13 | # properly handle possibly duplicated messages from different source addresses, in addition to 14 | # possible duplications introduced by the UDP/IP protocol itself. There are at least two obvious 15 | # strategies that can be employed by the remote host: 16 | # 17 | # - Accept only the first message, ignore duplicates. This approach requires that the UDP stream 18 | # should contain some metadata necessary for the remote host to determine the source and ordering 19 | # of each received datum. This approach works best for periodic data, such as telemetry, where 20 | # the sender does not expect any responses. 21 | # 22 | # - Process all messages, including duplicates. This approach assumes that the remote host acts 23 | # as a server, processing all received requests and providing responses to each. This arrangement 24 | # implies that the client may receive duplicated responses. It is therefore the client's 25 | # responsibility to resolve the possible ambiguity. An obvious solution is to accept the first 26 | # arrived response and ignore the later ones. 27 | # 28 | # Applications are free to choose whatever redundancy management strategy works best for them. 29 | # 30 | # If the source node expects that the remote host will send some data back, it shall explicitly notify 31 | # the modem nodes about this, so that they could prepare to perform reverse forwarding when the 32 | # expected data arrives from the remote host. The technique of reverse forwarding is known in 33 | # networking as IP Masquerading, or (in general) Network Address Translation (NAT). The notification 34 | # is performed by means of setting one of the corresponding flags defined below. 35 | # 36 | # In order to be able to match datagrams received from remote hosts and the local nodes they should 37 | # be forwarded to, modem nodes are required to keep certain metadata about outgoing datagrams. Such 38 | # metadata is stored in a data structure referred to as "NAT table", where every entry would normally 39 | # contain at least the following fields: 40 | # - The local UDP port number that was used to send the outgoing datagram from. 41 | # Per RFC 4787, the port number is chosen by the modem node automatically. 42 | # - The node-ID of the local node that has sent the outgoing datagram. 43 | # - Value of the field session_id defined below. 44 | # - Possibly some other data, depending on the implementation. 45 | # 46 | # The modem nodes are required to keep each NAT table entry for at least NAT_ENTRY_MIN_TTL seconds 47 | # since the last reverse forwarding action was performed. Should the memory resources of the modem node 48 | # be exhausted, it is allowed to remove old NAT entries earlier, following the policy of least recent use. 49 | # 50 | # Having received a UDP packet from a remote host, the modem node would check the NAT table in order 51 | # to determine where on the Cyphal bus the received data should be forwarded to. If the NAT table 52 | # contains no matches, the received data should be silently dropped. If a match is found, the 53 | # modem node will forward the data to the recipient node using the service HandleIncomingPacket. 54 | # If the service invocation times out, the modem node is permitted to remove the corresponding entry from 55 | # the NAT table immediately (but it is not required). This will ensure that the modem nodes will not be 56 | # tasked with translations for client nodes that are no longer online or are unreachable. 57 | # Additionally, client nodes will be able to hint the modem nodes to remove translation entries they no 58 | # longer need by simply refusing to respond to the corresponding service invocation. Please refer to 59 | # the definition of that service data type for a more in-depth review of the reverse forwarding process. 60 | # 61 | # Modem nodes can also perform traffic shaping, if needed, by means of delaying or dropping UDP 62 | # datagrams that exceed the quota. 63 | # 64 | # To summarize, a typical data exchange occurrence should amount to the following actions: 65 | # 66 | # - A local Cyphal node broadcasts a message of type OutgoingPacket with the payload it needs 67 | # to forward. If the node expects the remote host to send any data back, it sets the masquerading flag. 68 | # 69 | # - Every modem node on the bus receives the message and performs the following actions: 70 | # 71 | # - The domain name is resolved, unless the destination address provided in the message 72 | # is already an IP address, in which case this step should be skipped. 73 | # 74 | # - The domain name to IP address mapping is added to the local DNS cache, although this 75 | # part is entirely implementation defined and is not required. 76 | # 77 | # - The masquerading flag is checked. If it is set, a new entry is added to the NAT table. 78 | # If such entry already existed, its expiration timeout is reset. If no such entry existed 79 | # and a new one cannot be added because of memory limitations, the least recently used 80 | # (i.e. oldest) entry of the NAT table is replaced with the new one. 81 | # 82 | # - The payload is forwarded to the determined IP address. 83 | # 84 | # - At this point, direct forwarding is complete. Should any of the modem nodes receive an incoming 85 | # packet, they would attempt to perform a reverse forwarding according to the above provided algorithm. 86 | # 87 | # It is recommended to use the lowest transport priority level when broadcasting messages of this type, 88 | # in order to avoid interference with a real-time traffic on the bus. Usage of higher priority levels is 89 | # unlikely to be practical because the latency and throughput limitations introduced by the on-board radio 90 | # communication equipment are likely to vastly exceed those of the local CAN bus. 91 | 92 | uint32 NAT_ENTRY_MIN_TTL = 24 * 60 * 60 # [second] 93 | # Modem nodes are required to keep the NAT table entries alive for at least this amount of time, unless the 94 | # table is overflowed, in which case they are allowed to remove least recently used entries in favor of 95 | # newer ones. Modem nodes are required to be able to accommodate at least 100 entries in the NAT table. 96 | 97 | uint16 session_id 98 | # This field is set to an arbitrary value by the transmitting node in order to be able to match the response 99 | # with the locally kept context. The function of this field is virtually identical to that of UDP/IP port 100 | # numbers. This value can be set to zero safely if the sending node does not have multiple contexts to 101 | # distinguish between. 102 | 103 | uint16 destination_port 104 | # UDP destination port number. 105 | 106 | uint8[<=45] destination_address 107 | # Domain name or IP address where the payload should be forwarded to. 108 | # Note that broadcast addresses are allowed here, for example, 255.255.255.255. 109 | # Broadcasting with masquerading enabled works the same way as unicasting with masquerading enabled: the modem 110 | # node should take care to channel all traffic arriving at the opened port from any source to the node that 111 | # requested masquerading. 112 | # The full domain name length may not exceed 253 octets, according to the DNS specification. 113 | # Cyphal imposes a stricter length limit in order to reduce the memory and traffic burden on the bus: 45 characters. 114 | # 45 characters is the amount of space that is required to represent the longest possible form of an IPv6 address 115 | # (an IPv4-mapped IPv6 address). Examples: 116 | # "forum.opencyphal.org" - domain name 117 | # "192.168.1.1" - IPv4 address 118 | # "2001:0db8:85a3:0000:0000:8a2e:0370:7334" - IPv6 address, full form 119 | # "2001:db8:85a3::8a2e:370:7334" - IPv6 address, same as above, short form (preferred) 120 | # "ABCD:ABCD:ABCD:ABCD:ABCD:ABCD:192.168.158.190" - IPv4-mapped IPv6, full form (length limit, 45 characters) 121 | 122 | @assert _offset_ % 8 == {0} 123 | 124 | bool use_masquerading # Expect data back (i.e., instruct the modem to use the NAT table). 125 | bool use_dtls # Use Datagram Transport Layer Security. Drop the packet if DTLS is not supported. 126 | # Option flags. 127 | void6 128 | 129 | uint8[<=508] payload 130 | # Effective payload. This data will be forwarded to the remote host verbatim. 131 | # UDP packets that contain more than 508 bytes of payload may be dropped by some types of 132 | # communication equipment. Refer to RFC 791 and 2460 for an in-depth review. 133 | 134 | @extent 600 * 8 135 | -------------------------------------------------------------------------------- /uavcan/metatransport/can/ArbitrationID.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # CAN frame arbitration field. 2 | 3 | @union 4 | 5 | BaseArbitrationID.0.1 base 6 | ExtendedArbitrationID.0.1 extended 7 | 8 | @sealed 9 | @assert _offset_ == {40} 10 | -------------------------------------------------------------------------------- /uavcan/metatransport/can/BaseArbitrationID.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # 11-bit identifier. 2 | 3 | truncated uint11 value 4 | void21 5 | 6 | @sealed 7 | -------------------------------------------------------------------------------- /uavcan/metatransport/can/DataClassic.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # Classic data frame payload. 2 | 3 | ArbitrationID.0.1 arbitration_id 4 | uint8[<=8] data 5 | 6 | @sealed 7 | @assert _offset_.min == 48 8 | @assert _offset_ % 8 == {0} 9 | -------------------------------------------------------------------------------- /uavcan/metatransport/can/DataFD.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # CAN FD data frame payload. 2 | 3 | ArbitrationID.0.1 arbitration_id 4 | uint8[<=64] data 5 | 6 | @sealed 7 | @assert _offset_.min == 48 8 | @assert _offset_ % 8 == {0} 9 | -------------------------------------------------------------------------------- /uavcan/metatransport/can/Error.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # CAN bus error report: either an intentionally generated error frame or a disturbance. 2 | 3 | void32 4 | 5 | @sealed 6 | -------------------------------------------------------------------------------- /uavcan/metatransport/can/ExtendedArbitrationID.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # 29-bit identifier. 2 | 3 | truncated uint29 value 4 | void3 5 | 6 | @sealed 7 | -------------------------------------------------------------------------------- /uavcan/metatransport/can/Frame.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # CAN 2.0 or CAN FD frame representation. This is the top-level data type in its namespace. 2 | 3 | @deprecated # See next version. 4 | 5 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 6 | 7 | Manifestation.0.1 manifestation 8 | 9 | @sealed # Sealed because the structure is rigidly dictated by an external standard. 10 | @assert _offset_ % 8 == {0} 11 | @assert _offset_.min == 12 * 8 12 | @assert _offset_.max == 78 * 8 13 | -------------------------------------------------------------------------------- /uavcan/metatransport/can/Frame.0.2.dsdl: -------------------------------------------------------------------------------- 1 | # Classic CAN or CAN FD frame representation. This is the top-level data type in its namespace. 2 | 3 | @union 4 | 5 | Error.0.1 error # CAN error (intentional or disturbance) 6 | DataFD.0.1 data_fd # Bit rate switch flag active 7 | DataClassic.0.1 data_classic # Bit rate switch flag not active 8 | RTR.0.1 remote_transmission_request # Bit rate switch flag not active 9 | 10 | @sealed # Sealed because the structure is rigidly dictated by an external standard. 11 | @assert _offset_.min == 8 + 32 12 | @assert _offset_.max == 8 + 8 + 32 + 8 + 64 * 8 13 | -------------------------------------------------------------------------------- /uavcan/metatransport/can/Manifestation.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # CAN frame properties that can be manifested on the bus. 2 | 3 | @deprecated # See Frame.0.2 as a replacement 4 | @union 5 | 6 | Error.0.1 error # CAN error (intentional or disturbance) 7 | DataFD.0.1 data_fd # Bit rate switch flag active 8 | DataClassic.0.1 data_classic # Bit rate switch flag not active 9 | RTR.0.1 remote_transmission_request # Bit rate switch flag not active 10 | 11 | @sealed 12 | @assert _offset_.min == 8 + 32 13 | @assert _offset_.max == 8 + 8 + 32 + 8 + 64 * 8 14 | @assert _offset_ % 8 == {0} 15 | -------------------------------------------------------------------------------- /uavcan/metatransport/can/RTR.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # Classic remote transmission request (not defined for CAN FD). 2 | 3 | ArbitrationID.0.1 arbitration_id 4 | 5 | @sealed 6 | @assert _offset_ == {40} 7 | -------------------------------------------------------------------------------- /uavcan/metatransport/ethernet/EtherType.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # Standard EtherType constants as defined by IEEE Registration Authority and IANA. 2 | # This list is only a small subset of constants that are considered to be relevant for Cyphal. 3 | 4 | uint16 value 5 | 6 | uint16 IP_V4 = 0x0800 7 | uint16 ARP = 0x0806 8 | uint16 IP_V6 = 0x86DD 9 | 10 | @sealed 11 | -------------------------------------------------------------------------------- /uavcan/metatransport/ethernet/Frame.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # IEEE 802.3 Ethernet frame encapsulation. 2 | # In terms of libpcap/tcpdump, the corresponding link type is LINKTYPE_ETHERNET/DLT_EN10MB. 3 | 4 | uint8[6] destination 5 | uint8[6] source 6 | 7 | EtherType.0.1 ethertype 8 | 9 | uint8[<=9216] payload # Supports conventional jumbo frames (up to 9 KiB). 10 | 11 | @sealed # Sealed because the format is defined by external specifications. 12 | -------------------------------------------------------------------------------- /uavcan/metatransport/serial/Fragment.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # A chunk of raw bytes exchanged over a serial transport. Serial links do not support framing natively. 2 | # The chunk may be of arbitrary size. 3 | 4 | @deprecated # See next version. 5 | 6 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 7 | 8 | uint9 CAPACITY_BYTES = 256 9 | uint8[<=CAPACITY_BYTES] data 10 | 11 | @sealed 12 | @assert _offset_ % 8 == {0} 13 | @assert _offset_.max / 8 <= 313 14 | -------------------------------------------------------------------------------- /uavcan/metatransport/serial/Fragment.0.2.dsdl: -------------------------------------------------------------------------------- 1 | # A chunk of raw bytes exchanged over a serial transport. Serial links do not support framing natively. 2 | # The chunk may be of arbitrary size. 3 | # 4 | # If this data type is used to encapsulate Cyphal/serial, then it is recommended to ensure that each message 5 | # contains at most one Cyphal/serial transport frame (frames are separated by zero-valued delimiter bytes). 6 | 7 | uint12 CAPACITY_BYTES = 2048 8 | uint8[<=CAPACITY_BYTES] data 9 | 10 | @sealed 11 | -------------------------------------------------------------------------------- /uavcan/metatransport/udp/DEPRECATED: -------------------------------------------------------------------------------- 1 | All data types in this namespace are deprecated. Find replacement under uavcan.metatransport.ethernet. 2 | -------------------------------------------------------------------------------- /uavcan/metatransport/udp/Endpoint.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # A UDP/IP endpoint address specification. 2 | 3 | @deprecated # Replaced by uavcan.metatransport.ethernet 4 | 5 | uint8[16] ip_address 6 | # The IP address of the host in the network byte order (big endian). 7 | # IPv6 addresses are represented as-is. 8 | # IPv4 addresses are represented using IPv4-mapped IPv6 addresses. 9 | 10 | uint8[6] mac_address 11 | # MAC address of the host in the network byte order (big endian). 12 | 13 | uint16 port 14 | # The UDP port number. 15 | 16 | void64 17 | 18 | @sealed 19 | @assert _offset_ == {32} * 8 20 | -------------------------------------------------------------------------------- /uavcan/metatransport/udp/Frame.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # A generic UDP/IP frame. 2 | # Jumboframes are supported in the interest of greater application compatibility. 3 | 4 | @deprecated # Replaced by uavcan.metatransport.ethernet 5 | 6 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 7 | 8 | void8 9 | @assert _offset_ % 64 == {0} 10 | 11 | Endpoint.0.1 source 12 | Endpoint.0.1 destination 13 | 14 | @assert _offset_ % 64 == {0} 15 | 16 | uint14 MTU = 1024 * 9 - 20 - 8 # Max jumbo frame 9 KiB, IP header min 20 B, UDP header 8 B. 17 | uint8[<=MTU] data 18 | 19 | @extent 1024 * 10 * 8 # The auto-deduced extent would be unreasonably large for this type. 20 | @assert _offset_ % 8 == {0} 21 | -------------------------------------------------------------------------------- /uavcan/node/430.GetInfo.1.0.dsdl: -------------------------------------------------------------------------------- 1 | # Full node info request. 2 | # All of the returned information shall be static (unchanged) while the node is running. 3 | # It is highly recommended to support this service on all nodes. 4 | 5 | @sealed 6 | 7 | --- 8 | 9 | Version.1.0 protocol_version 10 | # The Cyphal protocol version implemented on this node, both major and minor. 11 | # Not to be changed while the node is running. 12 | 13 | Version.1.0 hardware_version 14 | Version.1.0 software_version 15 | # The version information shall not be changed while the node is running. 16 | # The correct hardware version shall be reported at all times, excepting software-only nodes, in which 17 | # case it should be set to zeros. 18 | # If the node is equipped with a Cyphal-capable bootloader, the bootloader should report the software 19 | # version of the installed application, if there is any; if no application is found, zeros should be reported. 20 | 21 | uint64 software_vcs_revision_id 22 | # A version control system (VCS) revision number or hash. Not to be changed while the node is running. 23 | # For example, this field can be used for reporting the short git commit hash of the current 24 | # software revision. 25 | # Set to zero if not used. 26 | 27 | uint8[16] unique_id 28 | # The unique-ID (UID) is a 128-bit long sequence that is likely to be globally unique per node. 29 | # The vendor shall ensure that the probability of a collision with any other node UID globally is negligibly low. 30 | # UID is defined once per hardware unit and should never be changed. 31 | # All zeros is not a valid UID. 32 | # If the node is equipped with a Cyphal-capable bootloader, the bootloader shall use the same UID. 33 | 34 | @assert _offset_ == {30 * 8} 35 | # Manual serialization note: only fixed-size fields up to this point. The following fields are dynamically sized. 36 | 37 | uint8[<=50] name 38 | # Human-readable non-empty ASCII node name. An empty name is not permitted. 39 | # The name shall not be changed while the node is running. 40 | # Allowed characters are: a-z (lowercase ASCII letters) 0-9 (decimal digits) . (dot) - (dash) _ (underscore). 41 | # Node name is a reversed Internet domain name (like Java packages), e.g. "com.manufacturer.project.product". 42 | 43 | uint64[<=1] software_image_crc 44 | # The value of an arbitrary hash function applied to the software image. Not to be changed while the node is running. 45 | # This field can be used to detect whether the software or firmware running on the node is an exact 46 | # same version as a certain specific revision. This field provides a very strong identity guarantee, 47 | # unlike the version fields above, which can be the same for different builds of the software. 48 | # As can be seen from its definition, this field is optional. 49 | # 50 | # The exact hash function and the methods of its application are implementation-defined. 51 | # However, implementations are recommended to adhere to the following guidelines, fully or partially: 52 | # - The hash function should be CRC-64-WE. 53 | # - The hash function should be applied to the entire application image padded to 8 bytes. 54 | # - If the computed image CRC is stored within the software image itself, the value of 55 | # the hash function becomes ill-defined, because it becomes recursively dependent on itself. 56 | # In order to circumvent this issue, while computing or checking the CRC, its value stored 57 | # within the image should be zeroed out. 58 | 59 | uint8[<=222] certificate_of_authenticity 60 | # The certificate of authenticity (COA) of the node, 222 bytes max, optional. This field can be used for 61 | # reporting digital signatures (e.g., RSA-1776, or ECDSA if a higher degree of cryptographic strength is desired). 62 | # Leave empty if not used. Not to be changed while the node is running. 63 | 64 | @assert _offset_ % 8 == {0} 65 | @assert _offset_.max == (313 * 8) # At most five CAN FD frames 66 | @extent 448 * 8 67 | -------------------------------------------------------------------------------- /uavcan/node/434.GetTransportStatistics.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # Returns a set of general low-level transport statistical counters. 2 | # Servers are encouraged but not required to sample the data atomically. 3 | 4 | @sealed 5 | 6 | --- 7 | 8 | uint8 MAX_NETWORK_INTERFACES = 3 9 | # Cyphal supports up to triply modular redundant interfaces. 10 | 11 | IOStatistics.0.1 transfer_statistics 12 | # Cyphal transfer performance statistics: 13 | # the number of Cyphal transfers successfully sent, successfully received, and failed. 14 | # The methods of error counting are implementation-defined. 15 | 16 | IOStatistics.0.1[<=MAX_NETWORK_INTERFACES] network_interface_statistics 17 | # Network interface statistics, separate per interface. 18 | # E.g., for a doubly redundant transport, this array would contain two elements, 19 | # the one at the index zero would apply to the first interface, the other to the second interface. 20 | # The methods of counting are implementation-defined. 21 | 22 | @assert _offset_.max <= (63 * 8) # One CAN FD frame 23 | @extent 192 * 8 24 | -------------------------------------------------------------------------------- /uavcan/node/435.ExecuteCommand.1.0.dsdl: -------------------------------------------------------------------------------- 1 | # Instructs the server node to execute or commence execution of a simple predefined command. 2 | # All standard commands are optional; i.e., not guaranteed to be supported by all nodes. 3 | 4 | @deprecated 5 | 6 | uint16 command 7 | # Standard pre-defined commands are at the top of the range (defined below). 8 | # Vendors can define arbitrary, vendor-specific commands in the bottom part of the range (starting from zero). 9 | # Vendor-specific commands shall not use identifiers above 32767. 10 | 11 | uint16 COMMAND_RESTART = 65535 12 | # Reboot the node. 13 | # Note that some standard commands may or may not require a restart in order to take effect; e.g., factory reset. 14 | 15 | uint16 COMMAND_POWER_OFF = 65534 16 | # Shut down the node; further access will not be possible until the power is turned back on. 17 | 18 | uint16 COMMAND_BEGIN_SOFTWARE_UPDATE = 65533 19 | # Begin the software update process using uavcan.file.Read. This command makes use of the "parameter" field below. 20 | # The parameter contains the path to the new software image file to be downloaded by the server from the client 21 | # using the standard service uavcan.file.Read. Observe that this operation swaps the roles of the client and 22 | # the server. 23 | # 24 | # Upon reception of this command, the server (updatee) will evaluate whether it is possible to begin the 25 | # software update process. If that is deemed impossible, the command will be rejected with one of the 26 | # error codes defined in the response section of this definition (e.g., BAD_STATE if the node is currently 27 | # on-duty and a sudden interruption of its activities is considered unsafe, and so on). 28 | # If an update process is already underway, the updatee should abort the process and restart with the new file, 29 | # unless the updatee can determine that the specified file is the same file that is already being downloaded, 30 | # in which case it is allowed to respond SUCCESS and continue the old update process. 31 | # If there are no other conditions precluding the requested update, the updatee will return a SUCCESS and 32 | # initiate the file transfer process by invoking the standard service uavcan.file.Read repeatedly until the file 33 | # is transferred fully (please refer to the documentation for that data type for more information about its usage). 34 | # 35 | # While the software is being updated, the updatee should set its mode (the field "mode" in uavcan.node.Heartbeat) 36 | # to MODE_SOFTWARE_UPDATE. Please refer to the documentation for uavcan.node.Heartbeat for more information. 37 | # 38 | # It is recognized that most systems will have to interrupt their normal services to perform the software update 39 | # (unless some form of software hot swapping is implemented, as is the case in some high-availability systems). 40 | # 41 | # Microcontrollers that are requested to update their firmware may need to stop execution of their current firmware 42 | # and start the embedded bootloader (although other approaches are possible as well). In that case, 43 | # while the embedded bootloader is running, the mode reported via the message uavcan.node.Heartbeat should be 44 | # MODE_SOFTWARE_UPDATE as long as the bootloader is runing, even if no update-related activities 45 | # are currently underway. For example, if the update process failed and the bootloader cannot load the software, 46 | # the same mode MODE_SOFTWARE_UPDATE will be reported. 47 | # It is also recognized that in a microcontroller setting, the application that served the update request will have 48 | # to pass the update-related metadata (such as the node-ID of the server and the firmware image file path) to 49 | # the embedded bootloader. The tactics of that transaction lie outside of the scope of this specification. 50 | 51 | uint16 COMMAND_FACTORY_RESET = 65532 52 | # Return the node's configuration back to the factory default settings (may require restart). 53 | # Due to the uncertainty whether a restart is required, generic interfaces should always force a restart. 54 | 55 | uint16 COMMAND_EMERGENCY_STOP = 65531 56 | # Cease activities immediately, enter a safe state until restarted. 57 | # Further operation may no longer be possible until a restart command is executed. 58 | 59 | uint16 COMMAND_STORE_PERSISTENT_STATES = 65530 60 | # This command instructs the node to store the current configuration parameter values and other persistent states 61 | # to the non-volatile storage. Nodes are allowed to manage persistent states automatically, obviating the need for 62 | # this command by committing all such data to the non-volatile memory automatically as necessary. However, some 63 | # nodes may lack this functionality, in which case this parameter should be used. Generic interfaces should always 64 | # invoke this command in order to ensure that the data is stored even if the node doesn't implement automatic 65 | # persistence management. 66 | 67 | uint8[<=uavcan.file.Path.1.0.MAX_LENGTH] parameter 68 | # A string parameter supplied to the command. The format and interpretation is command-specific. 69 | # The standard commands do not use this field (ignore it), excepting the following: 70 | # - COMMAND_BEGIN_SOFTWARE_UPDATE 71 | 72 | @assert _offset_ % 8 == {0} 73 | @assert _offset_.max <= (124 * 8) # Two CAN FD frames max 74 | @extent 300 * 8 75 | 76 | --- 77 | 78 | uint8 STATUS_SUCCESS = 0 # Started or executed successfully 79 | uint8 STATUS_FAILURE = 1 # Could not start or the desired outcome could not be reached 80 | uint8 STATUS_NOT_AUTHORIZED = 2 # Denied due to lack of authorization 81 | uint8 STATUS_BAD_COMMAND = 3 # The requested command is not known or not supported 82 | uint8 STATUS_BAD_PARAMETER = 4 # The supplied parameter cannot be used with the selected command 83 | uint8 STATUS_BAD_STATE = 5 # The current state of the node does not permit execution of this command 84 | uint8 STATUS_INTERNAL_ERROR = 6 # The operation should have succeeded but an unexpected failure occurred 85 | uint8 status 86 | # The result of the request. 87 | 88 | @extent 48 * 8 89 | -------------------------------------------------------------------------------- /uavcan/node/435.ExecuteCommand.1.1.dsdl: -------------------------------------------------------------------------------- 1 | # Instructs the server node to execute or commence execution of a simple predefined command. 2 | # All standard commands are optional; i.e., not guaranteed to be supported by all nodes. 3 | 4 | @deprecated 5 | 6 | uint16 command 7 | # Standard pre-defined commands are at the top of the range (defined below). 8 | # Vendors can define arbitrary, vendor-specific commands in the bottom part of the range (starting from zero). 9 | # Vendor-specific commands shall not use identifiers above 32767. 10 | 11 | uint16 COMMAND_RESTART = 65535 12 | # Reboot the node. 13 | # Note that some standard commands may or may not require a restart in order to take effect; e.g., factory reset. 14 | 15 | uint16 COMMAND_POWER_OFF = 65534 16 | # Shut down the node; further access will not be possible until the power is turned back on. 17 | 18 | uint16 COMMAND_BEGIN_SOFTWARE_UPDATE = 65533 19 | # Begin the software update process using uavcan.file.Read. This command makes use of the "parameter" field below. 20 | # The parameter contains the path to the new software image file to be downloaded by the server from the client 21 | # using the standard service uavcan.file.Read. Observe that this operation swaps the roles of the client and 22 | # the server. 23 | # 24 | # Upon reception of this command, the server (updatee) will evaluate whether it is possible to begin the 25 | # software update process. If that is deemed impossible, the command will be rejected with one of the 26 | # error codes defined in the response section of this definition (e.g., BAD_STATE if the node is currently 27 | # on-duty and a sudden interruption of its activities is considered unsafe, and so on). 28 | # If an update process is already underway, the updatee should abort the process and restart with the new file, 29 | # unless the updatee can determine that the specified file is the same file that is already being downloaded, 30 | # in which case it is allowed to respond SUCCESS and continue the old update process. 31 | # If there are no other conditions precluding the requested update, the updatee will return a SUCCESS and 32 | # initiate the file transfer process by invoking the standard service uavcan.file.Read repeatedly until the file 33 | # is transferred fully (please refer to the documentation for that data type for more information about its usage). 34 | # 35 | # While the software is being updated, the updatee should set its mode (the field "mode" in uavcan.node.Heartbeat) 36 | # to MODE_SOFTWARE_UPDATE. Please refer to the documentation for uavcan.node.Heartbeat for more information. 37 | # 38 | # It is recognized that most systems will have to interrupt their normal services to perform the software update 39 | # (unless some form of software hot swapping is implemented, as is the case in some high-availability systems). 40 | # 41 | # Microcontrollers that are requested to update their firmware may need to stop execution of their current firmware 42 | # and start the embedded bootloader (although other approaches are possible as well). In that case, 43 | # while the embedded bootloader is running, the mode reported via the message uavcan.node.Heartbeat should be 44 | # MODE_SOFTWARE_UPDATE as long as the bootloader is runing, even if no update-related activities 45 | # are currently underway. For example, if the update process failed and the bootloader cannot load the software, 46 | # the same mode MODE_SOFTWARE_UPDATE will be reported. 47 | # It is also recognized that in a microcontroller setting, the application that served the update request will have 48 | # to pass the update-related metadata (such as the node-ID of the server and the firmware image file path) to 49 | # the embedded bootloader. The tactics of that transaction lie outside of the scope of this specification. 50 | 51 | uint16 COMMAND_FACTORY_RESET = 65532 52 | # Return the node's configuration back to the factory default settings (may require restart). 53 | # Due to the uncertainty whether a restart is required, generic interfaces should always force a restart. 54 | 55 | uint16 COMMAND_EMERGENCY_STOP = 65531 56 | # Cease activities immediately, enter a safe state until restarted. 57 | # Further operation may no longer be possible until a restart command is executed. 58 | 59 | uint16 COMMAND_STORE_PERSISTENT_STATES = 65530 60 | # This command instructs the node to store the current configuration parameter values and other persistent states 61 | # to the non-volatile storage. Nodes are allowed to manage persistent states automatically, obviating the need for 62 | # this command by committing all such data to the non-volatile memory automatically as necessary. However, some 63 | # nodes may lack this functionality, in which case this parameter should be used. Generic interfaces should always 64 | # invoke this command in order to ensure that the data is stored even if the node doesn't implement automatic 65 | # persistence management. 66 | 67 | uint8[<=uavcan.file.Path.2.0.MAX_LENGTH] parameter 68 | # A string parameter supplied to the command. The format and interpretation is command-specific. 69 | # The standard commands do not use this field (ignore it), excepting the following: 70 | # - COMMAND_BEGIN_SOFTWARE_UPDATE 71 | 72 | @extent 300 * 8 73 | 74 | --- 75 | 76 | uint8 STATUS_SUCCESS = 0 # Started or executed successfully 77 | uint8 STATUS_FAILURE = 1 # Could not start or the desired outcome could not be reached 78 | uint8 STATUS_NOT_AUTHORIZED = 2 # Denied due to lack of authorization 79 | uint8 STATUS_BAD_COMMAND = 3 # The requested command is not known or not supported 80 | uint8 STATUS_BAD_PARAMETER = 4 # The supplied parameter cannot be used with the selected command 81 | uint8 STATUS_BAD_STATE = 5 # The current state of the node does not permit execution of this command 82 | uint8 STATUS_INTERNAL_ERROR = 6 # The operation should have succeeded but an unexpected failure occurred 83 | uint8 status 84 | # The result of the request. 85 | 86 | @extent 48 * 8 87 | -------------------------------------------------------------------------------- /uavcan/node/435.ExecuteCommand.1.2.dsdl: -------------------------------------------------------------------------------- 1 | # Instructs the server node to execute or commence execution of a simple predefined command. 2 | # All standard commands are optional; i.e., not guaranteed to be supported by all nodes. 3 | 4 | @deprecated 5 | 6 | uint16 command 7 | # Standard pre-defined commands are at the top of the range (defined below). 8 | # Vendors can define arbitrary, vendor-specific commands in the bottom part of the range (starting from zero). 9 | # Vendor-specific commands shall not use identifiers above 32767. 10 | 11 | uint16 COMMAND_RESTART = 65535 12 | # Reboot the node. 13 | # Note that some standard commands may or may not require a restart in order to take effect; e.g., factory reset. 14 | 15 | uint16 COMMAND_POWER_OFF = 65534 16 | # Shut down the node; further access will not be possible until the power is turned back on. 17 | 18 | uint16 COMMAND_BEGIN_SOFTWARE_UPDATE = 65533 19 | # Begin the software update process using uavcan.file.Read. This command makes use of the "parameter" field below. 20 | # The parameter contains the path to the new software image file to be downloaded by the server from the client 21 | # using the standard service uavcan.file.Read. Observe that this operation swaps the roles of the client and 22 | # the server. 23 | # 24 | # Upon reception of this command, the server (updatee) will evaluate whether it is possible to begin the 25 | # software update process. If that is deemed impossible, the command will be rejected with one of the 26 | # error codes defined in the response section of this definition (e.g., BAD_STATE if the node is currently 27 | # on-duty and a sudden interruption of its activities is considered unsafe, and so on). 28 | # If an update process is already underway, the updatee should abort the process and restart with the new file, 29 | # unless the updatee can determine that the specified file is the same file that is already being downloaded, 30 | # in which case it is allowed to respond SUCCESS and continue the old update process. 31 | # If there are no other conditions precluding the requested update, the updatee will return a SUCCESS and 32 | # initiate the file transfer process by invoking the standard service uavcan.file.Read repeatedly until the file 33 | # is transferred fully (please refer to the documentation for that data type for more information about its usage). 34 | # 35 | # While the software is being updated, the updatee should set its mode (the field "mode" in uavcan.node.Heartbeat) 36 | # to MODE_SOFTWARE_UPDATE. Please refer to the documentation for uavcan.node.Heartbeat for more information. 37 | # 38 | # It is recognized that most systems will have to interrupt their normal services to perform the software update 39 | # (unless some form of software hot swapping is implemented, as is the case in some high-availability systems). 40 | # 41 | # Microcontrollers that are requested to update their firmware may need to stop execution of their current firmware 42 | # and start the embedded bootloader (although other approaches are possible as well). In that case, 43 | # while the embedded bootloader is running, the mode reported via the message uavcan.node.Heartbeat should be 44 | # MODE_SOFTWARE_UPDATE as long as the bootloader is runing, even if no update-related activities 45 | # are currently underway. For example, if the update process failed and the bootloader cannot load the software, 46 | # the same mode MODE_SOFTWARE_UPDATE will be reported. 47 | # It is also recognized that in a microcontroller setting, the application that served the update request will have 48 | # to pass the update-related metadata (such as the node-ID of the server and the firmware image file path) to 49 | # the embedded bootloader. The tactics of that transaction lie outside of the scope of this specification. 50 | 51 | uint16 COMMAND_FACTORY_RESET = 65532 52 | # Return the node's configuration back to the factory default settings (may require restart). 53 | # Due to the uncertainty whether a restart is required, generic interfaces should always force a restart. 54 | 55 | uint16 COMMAND_EMERGENCY_STOP = 65531 56 | # Cease activities immediately, enter a safe state until restarted. 57 | # Further operation may no longer be possible until a restart command is executed. 58 | 59 | uint16 COMMAND_STORE_PERSISTENT_STATES = 65530 60 | # This command instructs the node to store the current configuration parameter values and other persistent states 61 | # to the non-volatile storage. Nodes are allowed to manage persistent states automatically, obviating the need for 62 | # this command by committing all such data to the non-volatile memory automatically as necessary. However, some 63 | # nodes may lack this functionality, in which case this parameter should be used. Generic interfaces should always 64 | # invoke this command in order to ensure that the data is stored even if the node doesn't implement automatic 65 | # persistence management. 66 | 67 | uint16 COMMAND_IDENTIFY = 65529 68 | # This command instructs the node to physically identify itself in some way--e.g., by flashing a light or 69 | # emitting a sound. The duration and the nature of the identification process is implementation-defined. 70 | # This command can be useful for human operators to match assigned node-ID values to physical nodes during setup. 71 | 72 | uint8[<=uavcan.file.Path.2.0.MAX_LENGTH] parameter 73 | # A string parameter supplied to the command. The format and interpretation is command-specific. 74 | # The standard commands do not use this field (ignore it), excepting the following: 75 | # - COMMAND_BEGIN_SOFTWARE_UPDATE 76 | 77 | @extent 300 * 8 78 | 79 | --- 80 | 81 | uint8 STATUS_SUCCESS = 0 # Started or executed successfully 82 | uint8 STATUS_FAILURE = 1 # Could not start or the desired outcome could not be reached 83 | uint8 STATUS_NOT_AUTHORIZED = 2 # Denied due to lack of authorization 84 | uint8 STATUS_BAD_COMMAND = 3 # The requested command is not known or not supported 85 | uint8 STATUS_BAD_PARAMETER = 4 # The supplied parameter cannot be used with the selected command 86 | uint8 STATUS_BAD_STATE = 5 # The current state of the node does not permit execution of this command 87 | uint8 STATUS_INTERNAL_ERROR = 6 # The operation should have succeeded but an unexpected failure occurred 88 | uint8 status 89 | # The result of the request. 90 | 91 | @extent 48 * 8 92 | -------------------------------------------------------------------------------- /uavcan/node/435.ExecuteCommand.1.3.dsdl: -------------------------------------------------------------------------------- 1 | # Instructs the server node to execute or commence execution of a simple predefined command. 2 | # All standard commands are optional; i.e., not guaranteed to be supported by all nodes. 3 | 4 | uint16 command 5 | # Standard pre-defined commands are at the top of the range (defined below). 6 | # Vendors can define arbitrary, vendor-specific commands in the bottom part of the range (starting from zero). 7 | # Vendor-specific commands shall not use identifiers above 32767. 8 | 9 | uint16 COMMAND_RESTART = 65535 10 | # Reboot the node. 11 | # Note that some standard commands may or may not require a restart in order to take effect; e.g., factory reset. 12 | 13 | uint16 COMMAND_POWER_OFF = 65534 14 | # Shut down the node; further access will not be possible until the power is turned back on. 15 | 16 | uint16 COMMAND_BEGIN_SOFTWARE_UPDATE = 65533 17 | # Begin the software update process using uavcan.file.Read. This command makes use of the "parameter" field below. 18 | # The parameter contains the path to the new software image file to be downloaded by the server from the client 19 | # using the standard service uavcan.file.Read. Observe that this operation swaps the roles of the client and 20 | # the server. 21 | # 22 | # Upon reception of this command, the server (updatee) will evaluate whether it is possible to begin the 23 | # software update process. If that is deemed impossible, the command will be rejected with one of the 24 | # error codes defined in the response section of this definition (e.g., BAD_STATE if the node is currently 25 | # on-duty and a sudden interruption of its activities is considered unsafe, and so on). 26 | # If an update process is already underway, the updatee should abort the process and restart with the new file, 27 | # unless the updatee can determine that the specified file is the same file that is already being downloaded, 28 | # in which case it is allowed to respond SUCCESS and continue the old update process. 29 | # If there are no other conditions precluding the requested update, the updatee will return a SUCCESS and 30 | # initiate the file transfer process by invoking the standard service uavcan.file.Read repeatedly until the file 31 | # is transferred fully (please refer to the documentation for that data type for more information about its usage). 32 | # 33 | # While the software is being updated, the updatee should set its mode (the field "mode" in uavcan.node.Heartbeat) 34 | # to MODE_SOFTWARE_UPDATE. Please refer to the documentation for uavcan.node.Heartbeat for more information. 35 | # 36 | # It is recognized that most systems will have to interrupt their normal services to perform the software update 37 | # (unless some form of software hot swapping is implemented, as is the case in some high-availability systems). 38 | # 39 | # Microcontrollers that are requested to update their firmware may need to stop execution of their current firmware 40 | # and start the embedded bootloader (although other approaches are possible as well). In that case, 41 | # while the embedded bootloader is running, the mode reported via the message uavcan.node.Heartbeat should be 42 | # MODE_SOFTWARE_UPDATE as long as the bootloader is runing, even if no update-related activities 43 | # are currently underway. For example, if the update process failed and the bootloader cannot load the software, 44 | # the same mode MODE_SOFTWARE_UPDATE will be reported. 45 | # It is also recognized that in a microcontroller setting, the application that served the update request will have 46 | # to pass the update-related metadata (such as the node-ID of the server and the firmware image file path) to 47 | # the embedded bootloader. The tactics of that transaction lie outside of the scope of this specification. 48 | 49 | uint16 COMMAND_FACTORY_RESET = 65532 50 | # Return the node's configuration back to the factory default settings (may require restart). 51 | # Due to the uncertainty whether a restart is required, generic interfaces should always force a restart. 52 | 53 | uint16 COMMAND_EMERGENCY_STOP = 65531 54 | # Cease activities immediately, enter a safe state until restarted. 55 | # Further operation may no longer be possible until a restart command is executed. 56 | 57 | uint16 COMMAND_STORE_PERSISTENT_STATES = 65530 58 | # This command instructs the node to store the current configuration parameter values and other persistent states 59 | # to the non-volatile storage. Nodes are allowed to manage persistent states automatically, obviating the need for 60 | # this command by committing all such data to the non-volatile memory automatically as necessary. However, some 61 | # nodes may lack this functionality, in which case this parameter should be used. Generic interfaces should always 62 | # invoke this command in order to ensure that the data is stored even if the node doesn't implement automatic 63 | # persistence management. 64 | 65 | uint16 COMMAND_IDENTIFY = 65529 66 | # This command instructs the node to physically identify itself in some way--e.g., by flashing a light or 67 | # emitting a sound. The duration and the nature of the identification process is implementation-defined. 68 | # This command can be useful for human operators to match assigned node-ID values to physical nodes during setup. 69 | 70 | uint8[<=uavcan.file.Path.2.0.MAX_LENGTH] parameter 71 | # A string parameter supplied to the command. The format and interpretation is command-specific. 72 | # The standard commands do not use this field (ignore it), excepting the following: 73 | # - COMMAND_BEGIN_SOFTWARE_UPDATE 74 | 75 | @extent 300 * 8 76 | 77 | --- 78 | 79 | uint8 STATUS_SUCCESS = 0 # Started or executed successfully 80 | uint8 STATUS_FAILURE = 1 # Could not start or the desired outcome could not be reached 81 | uint8 STATUS_NOT_AUTHORIZED = 2 # Denied due to lack of authorization 82 | uint8 STATUS_BAD_COMMAND = 3 # The requested command is not known or not supported 83 | uint8 STATUS_BAD_PARAMETER = 4 # The supplied parameter cannot be used with the selected command 84 | uint8 STATUS_BAD_STATE = 5 # The current state of the node does not permit execution of this command 85 | uint8 STATUS_INTERNAL_ERROR = 6 # The operation should have succeeded but an unexpected failure occurred 86 | uint8 status 87 | # The result of the request. 88 | 89 | uint8[<=46] output 90 | # Any output that could be useful that has the capability to convey detailed information. 91 | # Users can send commands and receive specific data, like device status or measurements back in a streamlined manner. 92 | # The standard commands should leave this field empty unless explicitly specified otherwise. 93 | 94 | @extent 48 * 8 95 | -------------------------------------------------------------------------------- /uavcan/node/7509.Heartbeat.1.0.dsdl: -------------------------------------------------------------------------------- 1 | # Abstract node status information. 2 | # This is the only high-level function that shall be implemented by all nodes. 3 | # 4 | # All Cyphal nodes that have a node-ID are required to publish this message to its fixed subject periodically. 5 | # Nodes that do not have a node-ID (also known as "anonymous nodes") shall not publish to this subject. 6 | # 7 | # The default subject-ID 7509 is 1110101010101 in binary. The alternating bit pattern at the end helps transceiver 8 | # synchronization (e.g., on CAN-based networks) and on some transports permits automatic bit rate detection. 9 | # 10 | # Network-wide health monitoring can be implemented by subscribing to the fixed subject. 11 | 12 | uint16 MAX_PUBLICATION_PERIOD = 1 # [second] 13 | # The publication period shall not exceed this limit. 14 | # The period should not change while the node is running. 15 | 16 | uint16 OFFLINE_TIMEOUT = 3 # [second] 17 | # If the last message from the node was received more than this amount of time ago, it should be considered offline. 18 | 19 | uint32 uptime # [second] 20 | # The uptime seconds counter should never overflow. The counter will reach the upper limit in ~136 years, 21 | # upon which time it should stay at 0xFFFFFFFF until the node is restarted. 22 | # Other nodes may detect that a remote node has restarted when this value leaps backwards. 23 | 24 | Health.1.0 health 25 | # The abstract health status of this node. 26 | 27 | Mode.1.0 mode 28 | # The abstract operating mode of the publishing node. 29 | # This field indicates the general level of readiness that can be further elaborated on a per-activity basis 30 | # using various specialized interfaces. 31 | 32 | uint8 vendor_specific_status_code 33 | # Optional, vendor-specific node status code, e.g. a fault code or a status bitmask. 34 | 35 | @assert _offset_ % 8 == {0} 36 | @assert _offset_ == {56} # Fits into a single-frame Classic CAN transfer (least capable transport, smallest MTU). 37 | @extent 12 * 8 38 | -------------------------------------------------------------------------------- /uavcan/node/Health.1.0.dsdl: -------------------------------------------------------------------------------- 1 | # Abstract component health information. If the node performs multiple activities (provides multiple network services), 2 | # its health status should reflect the status of the worst-performing activity (network service). 3 | # Follows: 4 | # https://www.law.cornell.edu/cfr/text/14/23.1322 5 | # https://www.faa.gov/documentLibrary/media/Advisory_Circular/AC_25.1322-1.pdf section 6 6 | 7 | uint2 value 8 | 9 | uint2 NOMINAL = 0 10 | # The component is functioning properly (nominal). 11 | 12 | uint2 ADVISORY = 1 13 | # A critical parameter went out of range or the component encountered a minor failure that does not prevent 14 | # the subsystem from performing any of its real-time functions. 15 | 16 | uint2 CAUTION = 2 17 | # The component encountered a major failure and is performing in a degraded mode or outside of its designed limitations. 18 | 19 | uint2 WARNING = 3 20 | # The component suffered a fatal malfunction and is unable to perform its intended function. 21 | 22 | @sealed 23 | -------------------------------------------------------------------------------- /uavcan/node/ID.1.0.dsdl: -------------------------------------------------------------------------------- 1 | # Defines a node-ID. 2 | # The maximum valid value is dependent on the underlying transport layer. 3 | # Values lower than 128 are always valid for all transports. 4 | # Refer to the specification for more info. 5 | 6 | uint16 value 7 | 8 | @sealed 9 | @assert _offset_ == {16} 10 | -------------------------------------------------------------------------------- /uavcan/node/IOStatistics.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # A standard set of generic input/output statistical counters that generally should not overflow. 2 | # If a 40-bit counter is incremented every millisecond, it will overflow in ~35 years. 3 | # If an overflow occurs, the value will wrap over to zero. 4 | # 5 | # The values should not be reset while the node is running. 6 | 7 | truncated uint40 num_emitted 8 | # The number of successfully emitted entities. 9 | 10 | truncated uint40 num_received 11 | # The number of successfully received entities. 12 | 13 | truncated uint40 num_errored 14 | # How many errors have occurred. 15 | # The exact definition of "error" and how they are counted are implementation-defined, 16 | # unless specifically defined otherwise. 17 | 18 | @sealed 19 | -------------------------------------------------------------------------------- /uavcan/node/Mode.1.0.dsdl: -------------------------------------------------------------------------------- 1 | # The operating mode of a node. 2 | # Reserved values can be used in future revisions of the specification. 3 | 4 | uint3 value 5 | 6 | uint3 OPERATIONAL = 0 7 | # Normal operating mode. 8 | 9 | uint3 INITIALIZATION = 1 10 | # Initialization is in progress; this mode is entered immediately after startup. 11 | 12 | uint3 MAINTENANCE = 2 13 | # E.g., calibration, self-test, etc. 14 | 15 | uint3 SOFTWARE_UPDATE = 3 16 | # New software/firmware is being loaded or the bootloader is running. 17 | 18 | @sealed 19 | -------------------------------------------------------------------------------- /uavcan/node/Version.1.0.dsdl: -------------------------------------------------------------------------------- 1 | # A shortened semantic version representation: only major and minor. 2 | # The protocol generally does not concern itself with the patch version. 3 | 4 | uint8 major 5 | uint8 minor 6 | 7 | @sealed 8 | -------------------------------------------------------------------------------- /uavcan/node/port/7510.List.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # A list of ports that this node is using: 2 | # - Subjects published by this node (whether periodically or ad-hoc). 3 | # - Subjects that this node is subscribed to (a datalogger or a debugger would typically subscribe to all subjects). 4 | # - RPC services consumed by this node (i.e., service clients). 5 | # - RPC services provided by this node (i.e., service servers). 6 | # 7 | # All nodes should implement this capability to provide network introspection and diagnostic capabilities. 8 | # This message should be published using the fixed subject-ID as follows: 9 | # - At the OPTIONAL priority level at least every MAX_PUBLICATION_PERIOD seconds. 10 | # - At the OPTIONAL or SLOW priority level within MAX_PUBLICATION_PERIOD after the port configuration is changed. 11 | 12 | @deprecated # Replaced with v1. 13 | 14 | uint8 MAX_PUBLICATION_PERIOD = 10 # [seconds] 15 | # If the port configuration is not updated in this amount of time, the node should publish this message anyway. 16 | 17 | SubjectIDList.0.1 publishers 18 | SubjectIDList.0.1 subscribers 19 | ServiceIDList.0.1 clients 20 | ServiceIDList.0.1 servers 21 | 22 | @sealed 23 | -------------------------------------------------------------------------------- /uavcan/node/port/7510.List.1.0.dsdl: -------------------------------------------------------------------------------- 1 | # A list of ports that this node is using: 2 | # - Subjects published by this node (whether periodically or ad-hoc). 3 | # - Subjects that this node is subscribed to (a datalogger or a debugger would typically subscribe to all subjects). 4 | # - RPC services consumed by this node (i.e., service clients). 5 | # - RPC services provided by this node (i.e., service servers). 6 | # 7 | # All nodes should implement this capability to provide network introspection and diagnostic capabilities. 8 | # This message should be published using the fixed subject-ID as follows: 9 | # - At the OPTIONAL priority level at least every MAX_PUBLICATION_PERIOD seconds. 10 | # - At the OPTIONAL or SLOW priority level within MAX_PUBLICATION_PERIOD after the port configuration is changed. 11 | 12 | uint8 MAX_PUBLICATION_PERIOD = 10 # [seconds] 13 | # If the port configuration is not updated in this amount of time, the node should publish this message anyway. 14 | 15 | SubjectIDList.1.0 publishers 16 | SubjectIDList.1.0 subscribers 17 | ServiceIDList.1.0 clients 18 | ServiceIDList.1.0 servers 19 | 20 | @sealed 21 | -------------------------------------------------------------------------------- /uavcan/node/port/ID.1.0.dsdl: -------------------------------------------------------------------------------- 1 | # Used to refer either to a Service or to a Subject. 2 | # The chosen tag identifies the kind of the port, then the numerical ID identifies the port within the kind. 3 | 4 | @union 5 | 6 | SubjectID.1.0 subject_id 7 | ServiceID.1.0 service_id 8 | 9 | @sealed 10 | @assert _offset_ == {24} 11 | -------------------------------------------------------------------------------- /uavcan/node/port/ServiceID.1.0.dsdl: -------------------------------------------------------------------------------- 1 | # Service-ID. The ranges are defined by the specification. 2 | 3 | uint9 MAX = 511 4 | 5 | uint9 value 6 | 7 | @sealed 8 | -------------------------------------------------------------------------------- /uavcan/node/port/ServiceIDList.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # A list of service identifiers. 2 | # This is a trivial constant-size bitmask with some reserved space in case the range of service-ID is increased 3 | # in a future revision of the protocol. 4 | 5 | @deprecated # Replaced with v1. 6 | 7 | uint16 CAPACITY = ServiceID.1.0.MAX + 1 8 | 9 | bool[CAPACITY] mask 10 | # The index represents the identifier value. True -- present/used. False -- absent/unused. 11 | 12 | @extent 1024 # Reserve space in case the range is extended in the future. 13 | 14 | @assert CAPACITY % 8 == 0 15 | @assert _offset_ == {CAPACITY} 16 | -------------------------------------------------------------------------------- /uavcan/node/port/ServiceIDList.1.0.dsdl: -------------------------------------------------------------------------------- 1 | # A list of service identifiers. 2 | # This is a trivial constant-size bitmask with some reserved space in case the range of service-ID is increased 3 | # in a future revision of the protocol. 4 | 5 | uint16 CAPACITY = ServiceID.1.0.MAX + 1 6 | 7 | bool[CAPACITY] mask 8 | # The index represents the identifier value. True -- present/used. False -- absent/unused. 9 | 10 | @extent 1024 # Reserve space in case the range is extended in the future. 11 | 12 | @assert CAPACITY % 8 == 0 13 | @assert _offset_ == {CAPACITY} 14 | -------------------------------------------------------------------------------- /uavcan/node/port/SubjectID.1.0.dsdl: -------------------------------------------------------------------------------- 1 | # Subject-ID. The ranges are defined by the specification. 2 | 3 | uint13 MAX = 8191 4 | 5 | uint13 value 6 | 7 | @sealed 8 | -------------------------------------------------------------------------------- /uavcan/node/port/SubjectIDList.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # A list of subject identifiers. 2 | # The range of subject-ID is large, so using a fixed-size bitmask would make this type difficult to handle on 3 | # resource-constrained systems. To address that, we provide two extra options: a simple variable-length list, 4 | # and a special case that indicates that every subject-ID is in use. 5 | 6 | @deprecated # Replaced with v1. 7 | @union 8 | 9 | uint16 CAPACITY = SubjectID.1.0.MAX + 1 10 | 11 | bool[CAPACITY] mask 12 | # The index represents the identifier value. True -- present/used. False -- absent/unused. 13 | 14 | SubjectID.1.0[<256] sparse_list 15 | # A list of identifiers that can be used instead of the mask if most of the identifiers are unused. 16 | 17 | uavcan.primitive.Empty.1.0 total 18 | # A special case indicating that all identifiers are in use. 19 | 20 | @extent 8 + 2 ** 15 # Reserve space in case the range is extended in the future. 21 | -------------------------------------------------------------------------------- /uavcan/node/port/SubjectIDList.1.0.dsdl: -------------------------------------------------------------------------------- 1 | # A list of subject identifiers. 2 | # The range of subject-ID is large, so using a fixed-size bitmask would make this type difficult to handle on 3 | # resource-constrained systems. To address that, we provide two extra options: a simple variable-length list, 4 | # and a special case that indicates that every subject-ID is in use. 5 | 6 | @union 7 | 8 | uint16 CAPACITY = SubjectID.1.0.MAX + 1 9 | 10 | bool[CAPACITY] mask 11 | # The index represents the identifier value. True -- present/used. False -- absent/unused. 12 | 13 | SubjectID.1.0[<256] sparse_list 14 | # A list of identifiers that can be used instead of the mask if most of the identifiers are unused. 15 | 16 | uavcan.primitive.Empty.1.0 total 17 | # A special case indicating that all identifiers are in use. 18 | 19 | @extent 8 + 2 ** 15 # Reserve space in case the range is extended in the future. 20 | -------------------------------------------------------------------------------- /uavcan/pnp/8166.NodeIDAllocationData.1.0.dsdl: -------------------------------------------------------------------------------- 1 | # This definition of the allocation message is intended for use with transports where anonymous transfers are limited 2 | # to 7 bytes of payload, such as Classic CAN. The definition is carried over from the original UAVCAN v0 specification 3 | # with some modifications. For transports other than Classic CAN (e.g., CAN FD, serial, etc.) there is a more 4 | # general, more capable definition NodeIDAllocationData v2.0. The PnP protocol itself is described in the documentation 5 | # for the v2 definition. The documentation provided here builds upon the general case, so read that first please. 6 | # 7 | # The full 128-bit unique-ID can't be accommodated in a single-frame anonymous message transfer over Classic CAN, so 8 | # this definition substitutes the full 128-bit ID with a smaller 48-bit hash of it. The 48-bit hash is obtained by 9 | # applying an arbitrary hash function to the unique-ID that outputs at least 48 bit of data. The recommended hash 10 | # function is the standard CRC-64WE where only the lowest 48 bit of the result are used. 11 | # 12 | # Allocators that support allocation messages of different versions should maintain a shared allocation table for all. 13 | # Requests received via the v1 message obviously do not contain the full unique-ID; the allocators are recommended 14 | # to left-zero-pad the small 48-bit hash in order to obtain a "pseudo unique-ID", and use this value in the 15 | # allocation table as a substitute for the real unique-ID. It is recognized that this behavior will have certain 16 | # side effects, such as the same allocatee obtaining different allocated node-ID values depending on which version 17 | # of the message is used, but they are considered tolerable. 18 | # 19 | # Allocatees that may need to operate over Classic CAN along with high-MTU transports may choose to use 20 | # only this constrained method of allocation for consistency and simplification. 21 | # 22 | # In order to save space for the hash, the preferred node-ID is removed from the request. The allocated node-ID 23 | # is provided in the response, however; this is achieved by means of an optional field that is not populated in 24 | # the request but is populated in the response. This implies that the response may be a multi-frame transfer, 25 | # which is acceptable since responses are sent by allocators, which are regular nodes, and therefore they are 26 | # allowed to use regular message transfers rather than being limited to anonymous message transfers as allocatees are. 27 | # 28 | # On the allocatee's side the protocol is defined through the following set of rules: 29 | # 30 | # Rule A. On initialization: 31 | # 1. The allocatee subscribes to this message. 32 | # 2. The allocatee starts the Request Timer with a random interval of Trequest. 33 | # 34 | # Rule B. On expiration of the Request Timer (started as per rules A, B, or C): 35 | # 1. Request Timer restarts with a random interval of Trequest (chosen anew). 36 | # 2. The allocatee broadcasts an allocation request message, where the fields are populated as follows: 37 | # unique_id_hash - a 48-bit hash of the unique-ID of the allocatee. 38 | # allocated_node_id - empty (not populated). 39 | # 40 | # Rule C. On any allocation message, even if other rules also match: 41 | # 1. Request Timer restarts with a random interval of Trequest (chosen anew). 42 | # 43 | # Rule D. On an allocation message WHERE (source node-ID is non-anonymous, i.e., regular allocation response) 44 | # AND (the field unique_id_hash matches the allocatee's 48-bit unique-ID hash) 45 | # AND (the field allocated_node_id is populated): 46 | # 1. Request Timer stops. 47 | # 2. The allocatee initializes its node-ID with the received value. 48 | # 3. The allocatee terminates its subscription to allocation messages. 49 | # 4. Exit. 50 | 51 | truncated uint48 unique_id_hash 52 | # An arbitrary 48-bit hash of the unique-ID of the local node. 53 | 54 | uavcan.node.ID.1.0[<=1] allocated_node_id 55 | # Shall be empty in request messages. 56 | # Shall be populated in response messages. 57 | 58 | @sealed 59 | @assert _offset_.min / 8 == 7 # This is for requests only. 60 | @assert _offset_.max / 8 == 9 # Responses are non-anonymous, so they can be multi-frame. 61 | -------------------------------------------------------------------------------- /uavcan/pnp/cluster/390.AppendEntries.1.0.dsdl: -------------------------------------------------------------------------------- 1 | # This type is a part of the Raft consensus algorithm. The Raft consensus is used for the maintenance of the 2 | # distributed allocation table between redundant allocators. The following description is focused on the exchanges 3 | # between redundant PnP node-ID allocators. It does not apply to the case of non-redundant allocators, because 4 | # in that case the allocation table is stored locally and the process of node-ID allocation is trivial and fully local. 5 | # Exchanges between allocatees and allocators are documented in the appropriate message type definition. 6 | # 7 | # The algorithm used for replication of the allocation table across redundant allocators is a fairly direct 8 | # implementation of the Raft consensus algorithm, as published in the paper 9 | # "In Search of an Understandable Consensus Algorithm (Extended Version)" by Diego Ongaro and John Ousterhout. 10 | # The following text assumes that the reader is familiar with the paper. 11 | # 12 | # The Raft log contains entries of type Entry (in the same namespace), where every entry contains the Raft term 13 | # number, the unique-ID, and the corresponding node-ID value (or zeros if it could not be requested from a static 14 | # node). Therefore, the Raft log is the allocation table itself. 15 | # 16 | # Since the maximum number of entries in the allocation table is limited by the range of node-ID values, the log 17 | # capacity is bounded. Therefore, the snapshot transfer and log compaction functions are not required, 18 | # so they are not used in this implementation of the Raft algorithm. 19 | # 20 | # When an allocator becomes the leader of the Raft cluster, it checks if the Raft log contains an entry for its own 21 | # node-ID, and if it doesn't, the leader adds its own allocation entry to the log (the unique-ID can be replaced with 22 | # zeros at the discretion of the implementer). This behavior guarantees that the Raft log always contains at least 23 | # one entry, therefore it is not necessary to support negative log indices, as proposed by the Raft paper. 24 | # 25 | # Since the log is write-only and limited in growth, all allocations are permanent. This restriction is acceptable, 26 | # since Cyphal is a vehicle bus, and configuration of vehicle's components is not expected to change frequently. 27 | # Old allocations can be removed in order to free node-IDs for new allocations by clearing the Raft log on all 28 | # allocators; such clearing shall be performed simultaneously while the network is down, otherwise the Raft cluster 29 | # will automatically attempt to restore the lost state on the allocators where the table was cleared. 30 | # 31 | # The allocators need to be aware of each other's node-ID in order to form a cluster. In order to learn each other's 32 | # node-ID values, the allocators broadcast messages of type Discovery (in the same namespace) until the cluster is 33 | # fully discovered and all allocators know of each other's node-ID. This extension to the Raft algorithm makes the 34 | # cluster almost configuration-free - the only parameter that shall be configured on all allocators of the cluster 35 | # is the number of nodes in the cluster (everything else will be auto-detected). 36 | # 37 | # Runtime cluster membership changes are not supported, since they are not needed for a vehicle bus. 38 | # 39 | # As has been explained in the general description of the PnP node-ID allocation feature, allocators shall watch for 40 | # unknown static nodes appearing on the bus. In the case of a non-redundant allocator, the task is trivial, since the 41 | # allocation table can be updated locally. In the case of a Raft cluster, however, the network monitoring task shall 42 | # be performed by the leader only, since other cluster members cannot commit to the shared allocation table (i.e., 43 | # the Raft log) anyway. Redundant allocators should not attempt to obtain the true unique-ID of the newly detected 44 | # static nodes (use zeros instead), because the allocation table is write-only: if the unique-ID of a static node 45 | # ever changes (e.g., a replacement unit is installed, or network configuration is changed manually), the change 46 | # will be impossible to reflect in the allocation table. 47 | # 48 | # Only the current Raft leader can process allocation requests and engage in communication with allocatees. 49 | # An allocator is allowed to send allocation responses only if both conditions are met: 50 | # 51 | # - The allocator is currently the Raft leader. 52 | # - Its replica of the Raft log does not contain uncommitted entries (i.e. the last allocation request has been 53 | # completed successfully). 54 | # 55 | # All cluster maintenance traffic should normally use either the lowest or the next-to-lowest transfer priority level. 56 | 57 | uint8 DEFAULT_MIN_ELECTION_TIMEOUT = 2 # [second] 58 | uint8 DEFAULT_MAX_ELECTION_TIMEOUT = 4 # [second] 59 | # Given the minimum election timeout and the cluster size, 60 | # the maximum recommended request interval can be derived as follows: 61 | # 62 | # max recommended request interval = (min election timeout) / 2 requests / (cluster size - 1) 63 | # 64 | # The equation assumes that the Leader requests one Follower at a time, so that there's at most one pending call 65 | # at any moment. Such behavior is optimal as it creates a uniform bus load, although it is implementation-specific. 66 | # Obviously, the request interval can be lower than that if needed, but higher values are not recommended as they may 67 | # cause Followers to initiate premature elections in case of frame losses or delays. 68 | # 69 | # The timeout value is randomized in the range (MIN, MAX], according to the Raft paper. The randomization granularity 70 | # should be at least one millisecond or higher. 71 | 72 | uint32 term 73 | uint32 prev_log_term 74 | uint16 prev_log_index 75 | uint16 leader_commit 76 | # Refer to the Raft paper for explanation. 77 | 78 | Entry.1.0[<=1] entries 79 | # Worst case replication time per Follower can be computed as: 80 | # 81 | # worst replication time = (node-ID capacity) * (2 trips of next_index) * (request interval per Follower) 82 | # 83 | # E.g., given the request interval of 0.5 seconds, the worst case replication time for CAN bus is: 84 | # 85 | # 128 nodes * 2 trips * 0.5 seconds = 128 seconds. 86 | # 87 | # This is the amount of time it will take for a new Follower to reconstruct a full replica of the distributed log. 88 | 89 | @assert _offset_ % 8 == {0} 90 | @extent 96 * 8 91 | 92 | --- 93 | 94 | uint32 term 95 | bool success 96 | # Refer to the Raft paper for explanation. 97 | 98 | @extent 48 * 8 99 | -------------------------------------------------------------------------------- /uavcan/pnp/cluster/391.RequestVote.1.0.dsdl: -------------------------------------------------------------------------------- 1 | # This type is a part of the Raft consensus algorithm. Please refer to the type AppendEntries for details. 2 | 3 | uint32 term 4 | uint32 last_log_term 5 | uint16 last_log_index 6 | # Refer to the Raft paper for explanation. 7 | 8 | @extent 48 * 8 9 | 10 | --- 11 | 12 | uint32 term 13 | bool vote_granted 14 | # Refer to the Raft paper for explanation. 15 | 16 | @extent 48 * 8 17 | -------------------------------------------------------------------------------- /uavcan/pnp/cluster/8164.Discovery.1.0.dsdl: -------------------------------------------------------------------------------- 1 | # This message is used by redundant allocators to find each other's node-ID. 2 | # Please refer to the type AppendEntries for details. 3 | # 4 | # An allocator should stop publishing this message as soon as it has discovered all other allocators in the cluster. 5 | # 6 | # An exception applies: when an allocator receives a Discovery message where the list of known nodes is incomplete 7 | # (i.e. len(known_nodes) < configured_cluster_size), it shall publish a Discovery message once. This condition 8 | # allows other allocators to quickly re-discover the cluster after a restart. 9 | 10 | uint8 BROADCASTING_PERIOD = 1 # [second] 11 | # This message should be broadcasted by the allocator at this interval until all other allocators are discovered. 12 | 13 | uint3 MAX_CLUSTER_SIZE = 5 14 | # The redundant allocator cluster cannot contain more than 5 allocators. 15 | 16 | uint3 configured_cluster_size 17 | # The number of allocators in the cluster as configured on the sender. 18 | # This value shall be the same across all allocators. 19 | 20 | void5 21 | 22 | uavcan.node.ID.1.0[<=5] known_nodes 23 | # Node-IDs of the allocators that are known to the publishing allocator, including the publishing allocator itself. 24 | 25 | @assert _offset_ % 8 == {0} 26 | @extent 96 * 8 27 | -------------------------------------------------------------------------------- /uavcan/pnp/cluster/Entry.1.0.dsdl: -------------------------------------------------------------------------------- 1 | # One PnP node-ID allocation entry. 2 | # This type is a part of the Raft consensus algorithm. Please refer to the type AppendEntries for details. 3 | 4 | uint32 term # Refer to the Raft paper for explanation. 5 | 6 | uint8[16] unique_id # Unique-ID of this allocation; zero if unknown. 7 | 8 | uavcan.node.ID.1.0 node_id # Node-ID of this allocation. 9 | 10 | @sealed 11 | @assert _offset_ % 8 == {0} 12 | -------------------------------------------------------------------------------- /uavcan/primitive/Empty.1.0.dsdl: -------------------------------------------------------------------------------- 1 | @sealed 2 | -------------------------------------------------------------------------------- /uavcan/primitive/String.1.0.dsdl: -------------------------------------------------------------------------------- 1 | # A UTF8-encoded string of text. 2 | # Since the string is represented as a dynamic array of bytes, it is not null-terminated. Like Pascal string. 3 | 4 | uint8[<=256] value 5 | 6 | @sealed 7 | @assert _offset_ % 8 == {0} 8 | @assert _offset_.max / 8 == 258 9 | -------------------------------------------------------------------------------- /uavcan/primitive/Unstructured.1.0.dsdl: -------------------------------------------------------------------------------- 1 | # An unstructured collection of bytes, e.g., raw binary image. 2 | 3 | uint8[<=256] value 4 | 5 | @sealed 6 | @assert _offset_ % 8 == {0} 7 | @assert _offset_.max / 8 == 258 8 | -------------------------------------------------------------------------------- /uavcan/primitive/array/Bit.1.0.dsdl: -------------------------------------------------------------------------------- 1 | # 2048 bits + 11 bit length + 4 bit padding = 2064 bits = 258 bytes 2 | 3 | bool[<=2048] value 4 | 5 | @sealed 6 | @assert _offset_.min == 16 7 | @assert _offset_.max / 8 == 258 8 | -------------------------------------------------------------------------------- /uavcan/primitive/array/Integer16.1.0.dsdl: -------------------------------------------------------------------------------- 1 | int16[<=128] value 2 | @assert _offset_ % 8 == {0} 3 | @assert _offset_.max / 8 == 257 4 | @sealed 5 | -------------------------------------------------------------------------------- /uavcan/primitive/array/Integer32.1.0.dsdl: -------------------------------------------------------------------------------- 1 | int32[<=64] value 2 | @assert _offset_ % 8 == {0} 3 | @assert _offset_.max / 8 == 257 4 | @sealed 5 | -------------------------------------------------------------------------------- /uavcan/primitive/array/Integer64.1.0.dsdl: -------------------------------------------------------------------------------- 1 | int64[<=32] value 2 | @assert _offset_ % 8 == {0} 3 | @assert _offset_.max / 8 == 257 4 | @sealed 5 | -------------------------------------------------------------------------------- /uavcan/primitive/array/Integer8.1.0.dsdl: -------------------------------------------------------------------------------- 1 | int8[<=256] value 2 | @assert _offset_ % 8 == {0} 3 | @assert _offset_.max / 8 == 258 4 | @sealed 5 | -------------------------------------------------------------------------------- /uavcan/primitive/array/Natural16.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uint16[<=128] value 2 | @assert _offset_ % 8 == {0} 3 | @assert _offset_.max / 8 == 257 4 | @sealed 5 | -------------------------------------------------------------------------------- /uavcan/primitive/array/Natural32.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uint32[<=64] value 2 | @assert _offset_ % 8 == {0} 3 | @assert _offset_.max / 8 == 257 4 | @sealed 5 | -------------------------------------------------------------------------------- /uavcan/primitive/array/Natural64.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uint64[<=32] value 2 | @assert _offset_ % 8 == {0} 3 | @assert _offset_.max / 8 == 257 4 | @sealed 5 | -------------------------------------------------------------------------------- /uavcan/primitive/array/Natural8.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uint8[<=256] value 2 | @assert _offset_ % 8 == {0} 3 | @assert _offset_.max / 8 == 258 4 | @sealed 5 | -------------------------------------------------------------------------------- /uavcan/primitive/array/Real16.1.0.dsdl: -------------------------------------------------------------------------------- 1 | # Exactly representable integers: [-2048, +2048] 2 | 3 | float16[<=128] value 4 | 5 | @sealed 6 | @assert _offset_ % 8 == {0} 7 | @assert _offset_.max / 8 == 257 8 | -------------------------------------------------------------------------------- /uavcan/primitive/array/Real32.1.0.dsdl: -------------------------------------------------------------------------------- 1 | # Exactly representable integers: [-16777216, +16777216] 2 | 3 | float32[<=64] value 4 | 5 | @sealed 6 | @assert _offset_ % 8 == {0} 7 | @assert _offset_.max / 8 == 257 8 | -------------------------------------------------------------------------------- /uavcan/primitive/array/Real64.1.0.dsdl: -------------------------------------------------------------------------------- 1 | # Exactly representable integers: [-2**53, +2**53] 2 | 3 | float64[<=32] value 4 | 5 | @sealed 6 | @assert _offset_ % 8 == {0} 7 | @assert _offset_.max / 8 == 257 8 | -------------------------------------------------------------------------------- /uavcan/primitive/scalar/Bit.1.0.dsdl: -------------------------------------------------------------------------------- 1 | bool value 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/primitive/scalar/Integer16.1.0.dsdl: -------------------------------------------------------------------------------- 1 | int16 value 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/primitive/scalar/Integer32.1.0.dsdl: -------------------------------------------------------------------------------- 1 | int32 value 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/primitive/scalar/Integer64.1.0.dsdl: -------------------------------------------------------------------------------- 1 | int64 value 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/primitive/scalar/Integer8.1.0.dsdl: -------------------------------------------------------------------------------- 1 | int8 value 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/primitive/scalar/Natural16.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uint16 value 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/primitive/scalar/Natural32.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uint32 value 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/primitive/scalar/Natural64.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uint64 value 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/primitive/scalar/Natural8.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uint8 value 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/primitive/scalar/Real16.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float16 value # Exactly representable integers: [-2048, +2048] 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/primitive/scalar/Real32.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float32 value # Exactly representable integers: [-16777216, +16777216] 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/primitive/scalar/Real64.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float64 value # Exactly representable integers: [-2**53, +2**53] 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/register/385.List.1.0.dsdl: -------------------------------------------------------------------------------- 1 | # This service allows the caller to discover the names of all registers available on the server 2 | # by iterating the index field from zero until an empty name is returned. 3 | # 4 | # The ordering of the registers shall remain constant while the server is running. 5 | # The ordering is not guaranteed to remain unchanged when the server node is restarted. 6 | 7 | uint16 index 8 | 9 | @sealed 10 | 11 | --- 12 | 13 | Name.1.0 name 14 | # Empty name in response means that the index is out of bounds, i.e., discovery is finished. 15 | 16 | @sealed 17 | -------------------------------------------------------------------------------- /uavcan/register/Name.1.0.dsdl: -------------------------------------------------------------------------------- 1 | # An UTF8-encoded register name. 2 | 3 | uint8[<256] name 4 | 5 | @sealed 6 | -------------------------------------------------------------------------------- /uavcan/register/Value.1.0.dsdl: -------------------------------------------------------------------------------- 1 | # This union contains all possible value types supported by the register protocol. 2 | # Numeric types can be either scalars or arrays; the former is a special case of the latter. 3 | 4 | @union 5 | 6 | uavcan.primitive.Empty.1.0 empty # Tag 0 Used to represent an undefined value 7 | uavcan.primitive.String.1.0 string # Tag 1 UTF-8 encoded text 8 | uavcan.primitive.Unstructured.1.0 unstructured # Tag 2 Raw unstructured binary image 9 | uavcan.primitive.array.Bit.1.0 bit # Tag 3 Bit array 10 | 11 | uavcan.primitive.array.Integer64.1.0 integer64 # Tag 4 12 | uavcan.primitive.array.Integer32.1.0 integer32 # Tag 5 13 | uavcan.primitive.array.Integer16.1.0 integer16 # Tag 6 14 | uavcan.primitive.array.Integer8.1.0 integer8 # Tag 7 15 | 16 | uavcan.primitive.array.Natural64.1.0 natural64 # Tag 8 17 | uavcan.primitive.array.Natural32.1.0 natural32 # Tag 9 18 | uavcan.primitive.array.Natural16.1.0 natural16 # Tag 10 19 | uavcan.primitive.array.Natural8.1.0 natural8 # Tag 11 20 | 21 | uavcan.primitive.array.Real64.1.0 real64 # Tag 12 Exactly representable integers: [-2**53, +2**53] 22 | uavcan.primitive.array.Real32.1.0 real32 # Tag 13 Exactly representable integers: [-16777216, +16777216] 23 | uavcan.primitive.array.Real16.1.0 real16 # Tag 14 Exactly representable integers: [-2048, +2048] 24 | 25 | @sealed 26 | @assert _offset_.min == 8 # Empty and the tag 27 | @assert _offset_.max == 258 * 8 + 8 # 258 bytes per field max and the tag 28 | -------------------------------------------------------------------------------- /uavcan/si/sample/acceleration/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float32 meter_per_second_per_second 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/sample/acceleration/Vector3.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float32[3] meter_per_second_per_second 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/sample/angle/Quaternion.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float32[4] wxyz 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/sample/angle/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float32 radian 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/sample/angular_acceleration/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float32 radian_per_second_per_second 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/sample/angular_acceleration/Vector3.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float32[3] radian_per_second_per_second 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/sample/angular_velocity/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float32 radian_per_second 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/sample/angular_velocity/Vector3.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float32[3] radian_per_second 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/sample/duration/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float32 second 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/sample/duration/WideScalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float64 second 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/sample/electric_charge/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float32 coulomb 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/sample/electric_current/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float32 ampere 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/sample/energy/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float32 joule 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/sample/force/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float32 newton 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/sample/force/Vector3.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float32[3] newton 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/sample/frequency/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float32 hertz 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/sample/length/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float32 meter 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/sample/length/Vector3.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float32[3] meter 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/sample/length/WideScalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float64 meter 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/sample/length/WideVector3.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float64[3] meter 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/sample/luminance/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float32 candela_per_square_meter 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/sample/magnetic_field_strength/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | @deprecated # Use v1.1 instead where the unit of measure is named correctly. 2 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 3 | float32 tesla 4 | @sealed 5 | -------------------------------------------------------------------------------- /uavcan/si/sample/magnetic_field_strength/Scalar.1.1.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float32 ampere_per_meter 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/sample/magnetic_field_strength/Vector3.1.0.dsdl: -------------------------------------------------------------------------------- 1 | @deprecated # Use v1.1 instead where the unit of measure is named correctly. 2 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 3 | float32[3] tesla 4 | @sealed 5 | -------------------------------------------------------------------------------- /uavcan/si/sample/magnetic_field_strength/Vector3.1.1.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float32[3] ampere_per_meter 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/sample/magnetic_flux_density/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float32 tesla 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/sample/magnetic_flux_density/Vector3.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float32[3] tesla 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/sample/mass/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float32 kilogram 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/sample/power/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float32 watt 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/sample/pressure/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float32 pascal 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/sample/temperature/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float32 kelvin 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/sample/torque/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float32 newton_meter 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/sample/torque/Vector3.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float32[3] newton_meter 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/sample/velocity/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float32 meter_per_second 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/sample/velocity/Vector3.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float32[3] meter_per_second 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/sample/voltage/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float32 volt 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/sample/volume/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float32 cubic_meter 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/sample/volumetric_flow_rate/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | uavcan.time.SynchronizedTimestamp.1.0 timestamp 2 | float32 cubic_meter_per_second 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/unit/acceleration/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float32 meter_per_second_per_second 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/si/unit/acceleration/Vector3.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float32[3] meter_per_second_per_second 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/si/unit/angle/Quaternion.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float32[4] wxyz 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/si/unit/angle/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float32 radian 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/si/unit/angular_acceleration/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float32 radian_per_second_per_second 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/si/unit/angular_acceleration/Vector3.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float32[3] radian_per_second_per_second 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/si/unit/angular_velocity/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float32 radian_per_second 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/si/unit/angular_velocity/Vector3.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float32[3] radian_per_second 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/si/unit/duration/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float32 second 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/si/unit/duration/WideScalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float64 second 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/si/unit/electric_charge/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float32 coulomb 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/si/unit/electric_current/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float32 ampere 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/si/unit/energy/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float32 joule 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/si/unit/force/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float32 newton 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/si/unit/force/Vector3.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float32[3] newton 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/si/unit/frequency/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float32 hertz 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/si/unit/length/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float32 meter 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/si/unit/length/Vector3.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float32[3] meter 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/si/unit/length/WideScalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float64 meter 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/si/unit/length/WideVector3.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float64[3] meter 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/si/unit/luminance/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float32 candela_per_square_meter 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/si/unit/magnetic_field_strength/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | @deprecated # Use v1.1 instead where the unit of measure is named correctly. 2 | float32 tesla 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/unit/magnetic_field_strength/Scalar.1.1.dsdl: -------------------------------------------------------------------------------- 1 | float32 ampere_per_meter 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/si/unit/magnetic_field_strength/Vector3.1.0.dsdl: -------------------------------------------------------------------------------- 1 | @deprecated # Use v1.1 instead where the unit of measure is named correctly. 2 | float32[3] tesla 3 | @sealed 4 | -------------------------------------------------------------------------------- /uavcan/si/unit/magnetic_field_strength/Vector3.1.1.dsdl: -------------------------------------------------------------------------------- 1 | float32[3] ampere_per_meter 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/si/unit/magnetic_flux_density/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float32 tesla 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/si/unit/magnetic_flux_density/Vector3.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float32[3] tesla 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/si/unit/mass/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float32 kilogram 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/si/unit/power/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float32 watt 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/si/unit/pressure/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float32 pascal 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/si/unit/temperature/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float32 kelvin 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/si/unit/torque/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float32 newton_meter 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/si/unit/torque/Vector3.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float32[3] newton_meter 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/si/unit/velocity/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float32 meter_per_second 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/si/unit/velocity/Vector3.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float32[3] meter_per_second 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/si/unit/voltage/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float32 volt 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/si/unit/volume/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float32 cubic_meter 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/si/unit/volumetric_flow_rate/Scalar.1.0.dsdl: -------------------------------------------------------------------------------- 1 | float32 cubic_meter_per_second 2 | @sealed 3 | -------------------------------------------------------------------------------- /uavcan/time/510.GetSynchronizationMasterInfo.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # Every node that acts as a time synchronization master, or is capable of acting as such, 2 | # should support this service. 3 | # Its objective is to provide information about which time system is currently used in the network. 4 | # 5 | # Once a time system is chosen, it cannot be changed as long as at least one node on the network is running. 6 | # In other words, the time system cannot be changed while the network is operating. 7 | # An implication of this is that if there are redundant time synchronization masters, they all shall 8 | # use the same time system always. 9 | 10 | @extent 48 * 8 11 | 12 | --- 13 | 14 | float32 error_variance # [second^2] 15 | # Error variance, in second^2, of the time value reported by this master. 16 | # This value is allowed to change freely while the master is running. 17 | # For example, if the master's own clock is synchronized with a GNSS, the error variance is expected to increase 18 | # as signal reception deteriorates. If the signal is lost, this value is expected to grow steadily, the rate of 19 | # growth would be dependent on the quality of the time keeping hardware available locally (bad hardware yields 20 | # faster growth). Once the signal is regained, this value would drop back to nominal. 21 | 22 | TimeSystem.0.1 time_system 23 | # Time system currently in use by the master. 24 | # Cannot be changed while the network is operating. 25 | 26 | TAIInfo.0.1 tai_info 27 | # Actual information about TAI provided by this master, if supported. 28 | # The fields in this data type are optional. 29 | 30 | @extent 192 * 8 31 | -------------------------------------------------------------------------------- /uavcan/time/SynchronizedTimestamp.1.0.dsdl: -------------------------------------------------------------------------------- 1 | # Nested data type used for representing a network-wide synchronized timestamp with microsecond resolution. 2 | # This data type is highly recommended for use both in standard and vendor-specific messages alike. 3 | 4 | uint56 UNKNOWN = 0 # Zero means that the time is not known. 5 | 6 | truncated uint56 microsecond 7 | # The number of microseconds that have passed since some arbitrary moment in the past. 8 | # The moment of origin (i.e., the time base) is defined per-application. The current time base in use 9 | # can be requested from the time synchronization master, see the corresponding service definition. 10 | # 11 | # This value is to never overflow. The value is 56-bit wide because: 12 | # 13 | # - 2^56 microseconds is about 2285 years, which is plenty. A 64-bit microsecond counter would be 14 | # unnecessarily wide and its overflow interval of 585 thousand years induces a mild existential crisis. 15 | # 16 | # - Classic-CAN (not FD) transports carry up to 7 bytes of payload per frame. 17 | # Time sync messages shall use single-frame transfers, which means that the value can't be wider than 56 bits. 18 | 19 | @sealed 20 | -------------------------------------------------------------------------------- /uavcan/time/TAIInfo.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # This data types defines constants and runtime values pertaining to the International Atomic Time, also known as TAI. 2 | # See https://en.wikipedia.org/wiki/International_Atomic_Time. 3 | # 4 | # The relationship between the three major time systems -- TAI, GPS, and UTC -- is as follows: 5 | # 6 | # TAI = GPS + 19 seconds 7 | # TAI = UTC + LS + 10 seconds 8 | # 9 | # Where "LS" is the current number of leap seconds: https://en.wikipedia.org/wiki/Leap_second. 10 | # 11 | # Cyphal applications should only rely on TAI whenever a global time system is needed. 12 | # GPS time is strongly discouraged for reasons of consistency across different positioning systems and applications. 13 | 14 | uint8 DIFFERENCE_TAI_MINUS_GPS = 19 # [second] 15 | # The fixed difference, in seconds, between TAI and GPS time. Does not change ever. 16 | # Systems that use GPS time as a reference should convert that to TAI by adding this difference. 17 | 18 | uint10 DIFFERENCE_TAI_MINUS_UTC_UNKNOWN = 0 19 | uint10 difference_tai_minus_utc 20 | # The current difference between TAI and UTC, if known. If unknown, set to zero. 21 | # 22 | # This value may change states between known and unknown while the master is running, 23 | # depending on its ability to obtain robust values from external sources. 24 | # 25 | # This value may change twice a year, possibly while the system is running; https://en.wikipedia.org/wiki/Leap_second. 26 | # Since the rotation of Earth is decelerating, this value may only be positive. Do not use outside Earth. 27 | # 28 | # For reference, here is the full list of recorded TAI-UTC difference values, valid at the time of writing: 29 | # 30 | # Date | TAI-UTC difference [second] 31 | # ----------|----------------------------- 32 | # Jan 1972 | 10 33 | # Jul 1972 | 11 34 | # Jan 1973 | 12 35 | # Jan 1974 | 13 36 | # Jan 1975 | 14 37 | # Jan 1976 | 15 38 | # Jan 1977 | 16 39 | # Jan 1978 | 17 40 | # Jan 1979 | 18 41 | # Jan 1980 | 19 42 | # Jul 1981 | 20 43 | # Jul 1982 | 21 44 | # Jul 1983 | 22 45 | # Jul 1985 | 23 46 | # Jan 1988 | 24 47 | # Jan 1990 | 25 48 | # Jan 1991 | 26 49 | # Jul 1992 | 27 50 | # Jul 1993 | 28 51 | # Jul 1994 | 29 52 | # Jan 1996 | 30 53 | # Jul 1997 | 31 54 | # Jan 1999 | 32 55 | # Jan 2006 | 33 56 | # Jan 2009 | 34 57 | # Jul 2012 | 35 58 | # Jul 2015 | 36 59 | # Jan 2017 | 37 60 | # 61 | # As of 2020, the future of the leap second and the relation between UTC and TAI remains uncertain. 62 | 63 | @sealed 64 | -------------------------------------------------------------------------------- /uavcan/time/TimeSystem.0.1.dsdl: -------------------------------------------------------------------------------- 1 | # Time system enumeration. 2 | # The time system shall be the same for all masters in the network. 3 | # It cannot be changed while the network is running. 4 | 5 | truncated uint4 value 6 | 7 | uint4 MONOTONIC_SINCE_BOOT = 0 8 | # Monotonic time since boot. 9 | # Monotonic time is a time reference that doesn't change rate or make leaps. 10 | 11 | uint4 TAI = 1 12 | # International Atomic Time; https://en.wikipedia.org/wiki/International_Atomic_Time. 13 | # The timestamp value contains the number of microseconds elapsed since 1970-01-01T00:00:00Z TAI. 14 | # TAI is always a fixed integer number of seconds ahead of GPS time. 15 | # Systems that use GPS time as a reference should convert that to TAI by adding the fixed difference. 16 | # GPS time is not supported for reasons of consistency across different positioning systems and applications. 17 | 18 | uint4 APPLICATION_SPECIFIC = 15 19 | # Application-specific time system of unknown properties. 20 | 21 | @sealed 22 | -------------------------------------------------------------------------------- /verify: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python3 2 | 3 | import sys 4 | import string 5 | import pydsdl 6 | from functools import partial 7 | 8 | 9 | MAX_LINE_LENGTH = 120 10 | ALLOWED_CHARACTERS = set(string.digits + string.ascii_letters + string.punctuation + ' ') 11 | 12 | 13 | def die_at(ty, line_index, *text): 14 | prefix = '%s:%d:' % (ty.source_file_path, line_index + 1) 15 | print(prefix, *text, file=sys.stderr) 16 | sys.exit(1) 17 | 18 | 19 | def on_print(file_path, line, value): 20 | print('%s:%d: %s' % (file_path, line, value), file=sys.stderr) 21 | 22 | 23 | ns_list = [ 24 | 'uavcan', 25 | 'reg', 26 | ] 27 | output = [] 28 | for ns in ns_list: 29 | output += pydsdl.read_namespace(ns, ns_list, print_output_handler=on_print) 30 | 31 | longest_name = max(map(lambda x: len(str(x)), output)) 32 | print('Full data type name'.ljust(longest_name), 'Fixed port-ID', 'Bytes'.ljust(10), sep='\t') 33 | for t in output: 34 | if isinstance(t, pydsdl.ServiceType): 35 | n_bytes = ' '.join([f'{max(x.bit_length_set) // 8: 4}' for x in (t.request_type, t.response_type)]) 36 | else: 37 | n_bytes = str(max(t.bit_length_set) // 8) 38 | 39 | print(str(t).ljust(longest_name), 40 | str(t.fixed_port_id if t.has_fixed_port_id else '').rjust(13), 41 | n_bytes.rjust(10) + ' ', 42 | sep='\t') 43 | 44 | for t in output: 45 | text = open(t.source_file_path).read() 46 | for index, line in enumerate(text.split('\n')): 47 | line = line.strip('\r\n') 48 | abort = partial(die_at, t, index) 49 | 50 | # Check trailing comment placement. 51 | # TODO: this test breaks on string literals containing "#". 52 | if not line.startswith('#') and '#' in line and ' #' not in line: 53 | abort('Trailing line comments shall be separated from the preceding text with at least two spaces') 54 | 55 | if line != '#' and '#' in line and '# ' not in line: 56 | abort('The text of a comment shall be separated from the comment character with a single space') 57 | 58 | if line.endswith(' '): 59 | abort('Trailing spaces are not permitted') 60 | 61 | # Check line length limit 62 | if len(line) > MAX_LINE_LENGTH: 63 | abort('Line is too long:', len(line), '>', MAX_LINE_LENGTH, 'chars') 64 | 65 | # Make sure we're not using any weird characters such as tabs or non-ASCII-printable 66 | for char_index, char in enumerate(line): 67 | if char not in ALLOWED_CHARACTERS: 68 | abort('Disallowed character', repr(char), 'code', ord(char), 'at column', char_index + 1) 69 | 70 | if not text.endswith('\n') or text.endswith('\n' * 2): 71 | abort('A file shall contain exactly one blank line at the end') 72 | --------------------------------------------------------------------------------