DSDL parser

This commit is contained in:
Pavel Kirienko
2014-03-01 23:13:26 +04:00
parent 1f7054b6ca
commit 954b3e4bf3
12 changed files with 572 additions and 0 deletions
@@ -0,0 +1 @@
+18
View File
@@ -0,0 +1,18 @@
#!/usr/bin/env python3
#
# UAVCAN DSDL compiler for libuavcan
#
# Copyright (C) 2014 Pavel Kirienko <pavel.kirienko@gmail.com>
#
import sys, os
RUNNING_FROM_SRC_DIR = os.path.abspath(__file__).endswith(os.path.join('libuavcan', 'dsdl_compiler', 'dsdlc.py'))
if RUNNING_FROM_SRC_DIR:
print('Running from the source directory')
scriptdir = os.path.dirname(os.path.abspath(__file__))
sys.path.append(os.path.join(scriptdir, '..', '..', 'pyuavcan'))
from pyuavcan import dsdl
print('Hello')