├── .dockerignore ├── .github └── workflows │ ├── build-images-dunfell.yml │ └── docker-dunfell.yml ├── .gitignore ├── .gitmodules ├── DEVELOPPER.md ├── DOCKER.md ├── Dockerfile ├── Makefile ├── README.md └── meta-iotlab ├── conf ├── bblayers.conf.sample ├── conf-notes.txt ├── distro │ └── iotlab.conf ├── layer.conf ├── local.conf.sample └── machine │ ├── var-som-am35-mtd-rw.conf │ └── var-som-am35.conf ├── recipes-bsp ├── libubootenv │ ├── files │ │ └── fw_env.config │ └── libubootenv_%.bbappend └── u-boot │ ├── files │ └── fw_env.config │ ├── u-boot-fw-utils_2015.01.bb │ ├── u-boot-fw-utils_2015.01.bbappend │ ├── u-boot-iotlab-release.inc │ ├── u-boot.inc │ └── u-boot_2015.01.bb ├── recipes-connectivity ├── mosquitto-rsmb │ └── mosquitto-rsmb_git.bb ├── ntp │ ├── files │ │ └── ntp_wait_synced.sh │ └── ntp_4.2.%.bbappend ├── oml2 │ ├── files │ │ ├── 0001-Use-python3-binary.patch │ │ ├── 0001-configure-use-pkg-config.patch │ │ └── oml2-2.11.0.tar.gz │ ├── oml2-native_2.11.0.bb │ └── oml2_2.11.0.bb ├── openssh │ └── openssh_8.%.bbappend └── wpantund │ └── wpantund_0.07.01.bb ├── recipes-core ├── base-config │ ├── base-config_0.1.bb │ └── files │ │ ├── bashrc │ │ ├── hostname │ │ ├── hosts │ │ ├── inputrc │ │ └── profile ├── base-files │ ├── base-files_3.0.14.bbappend │ └── files │ │ └── etc_hosts ├── icedtea │ └── icedtea7-native_%.bbappend ├── images │ ├── iotlab-image-gateway-rpi2.bb │ ├── iotlab-image-gateway-rpi3.bb │ ├── iotlab-image-gateway-rpi4.bb │ ├── iotlab-image-gateway.bb │ ├── iotlab-image-open-a8-autotest.bb │ ├── iotlab-image-open-a8.bb │ ├── iotlab-image-rpi2-autotest.bb │ ├── iotlab-image-rpi2.bb │ ├── iotlab-image-rpi3-autotest.bb │ ├── iotlab-image-rpi3.bb │ ├── iotlab-image-rpi4-autotest.bb │ ├── iotlab-image-rpi4.bb │ └── iotlab-image.inc ├── initrdscripts │ ├── files │ │ ├── gateway │ │ │ ├── gateway-server-network │ │ │ └── nfs_mount_conf_users │ │ ├── linux-node │ │ │ ├── flash_idle │ │ │ ├── ipv6.profile │ │ │ ├── networking_ipv6 │ │ │ ├── nfs_mount_conf_shared │ │ │ └── serial_redirection │ │ ├── set_default_values_to_volatile.sh │ │ └── set_time.sh │ └── initrdscripts_0.1.bb ├── initscripts │ ├── files │ │ ├── checkroot.sh │ │ └── read-only-rootfs-hook.sh │ └── initscripts_1.0.bbappend ├── packagegroups │ ├── base-packagegroup.bb │ ├── gateway-packagegroup.bb │ └── linux-node-packagegroup.bb └── ssh-keys │ ├── files │ ├── ssh_host_rsa_key │ ├── ssh_host_rsa_key.pub │ └── sshd_volatile_keys │ ├── sshd-keys-gw_1.0.bb │ └── sshd-keys-linux-node_1.0.bb ├── recipes-devtools ├── avarice │ └── avarice_git.bb ├── avrdude │ ├── avrdude.inc │ ├── avrdude_6.0.1.bb │ └── avrdude_svn.bb ├── edbg │ └── edbg_0.1.0.bb ├── jimtcl │ ├── jimtcl-git.bb │ ├── jimtcl_0.74.bb │ └── jimtcl_0.76.bb ├── openjdk │ ├── files │ │ └── openjdk8-enable-hotSpot-builds-on-5.x-linux-kernels.patch │ ├── openjdk-8-native_%.bbappend │ ├── openjdk-8_%.bbappend │ └── openjre-8_%.bbappend ├── openocd │ ├── files │ │ ├── 0001-static-library.patch │ │ ├── openocd-link-static.patch │ │ └── remove-raggedright.patch │ ├── openocd-git.bb │ ├── openocd-ti.bb │ ├── openocd_0.10.0.bb │ ├── openocd_0.11.0.bb │ ├── openocd_0.7.0.bb │ └── openocd_0.9.0.bb ├── python │ ├── python3-beautifulsoup4_4.6.0.bb │ ├── python3-bottle_0.12.18.bb │ ├── python3-cbor_1.0.0.bb │ ├── python3-cc2538-bsl_2.1.bb │ ├── python3-codecov_2.1.7.bb │ ├── python3-distlib_0.3.1.bb │ ├── python3-filelock_3.0.10.bb │ ├── python3-gcovr_4.2.bb │ ├── python3-hkdf_git.bb │ ├── python3-intelhex_2.2.1.bb │ ├── python3-mccabe_0.2.1.bb │ ├── python3-mock_4.0.2.bb │ ├── python3-paste_3.4.1.bb │ ├── python3-pep8_1.7.1.bb │ ├── python3-pluggy_0.6.0.bb │ ├── python3-pydispatcher_2.0.5.bb │ ├── python3-pyelftools_0.26.bb │ ├── python3-pyocd_0.27.0.bb │ ├── python3-pyserial │ │ └── run-ptest │ ├── python3-pyserial_3.4.bb │ ├── python3-pytest-cov_2.10.0.bb │ ├── python3-setuptools-scm-git-archive_1.0.bb │ ├── python3-testfixtures_6.14.1.bb │ ├── python3-toml_0.10.0.bb │ ├── python3-tox_3.6.0.bb │ ├── python3-virtualenv_20.4.3.bb │ ├── python3-webob_1.8.2.bb │ ├── python3-webtest_2.0.35.bb │ └── python3_%.bbappend └── segger-jlink │ └── segger-jlink_760b.bb ├── recipes-extended ├── procps │ ├── procps │ │ └── sysctl.conf │ └── procps_%.bbappend └── sudo │ └── sudo_1.8.%.bbappend ├── recipes-kernel └── linux │ ├── files │ ├── 0001-var-som-am35-add-device-tree.patch │ ├── 0002-davinci_emac-allow-setting-the-mac-address-with-an-e.patch │ └── defconfig │ └── linux_5.4.bb ├── recipes-support ├── control-node-serial │ └── control-node-serial_git.bb ├── flash-scripts │ ├── files │ │ ├── debug_a8_m3 │ │ ├── flash_a8_m3 │ │ └── reset_a8_m3 │ └── flash-scripts-open-a8_0.1.bb ├── ftdi-utils │ ├── ftdi-utils_1.1.0.bb │ └── src │ │ └── .gitignore ├── gateway-code │ ├── files │ │ ├── start_dc_on │ │ └── stop_dc_on │ └── gateway-code_git.bb ├── jemalloc │ └── jemalloc_4.0.4.bb ├── libjaylink │ └── libjaylink.bb ├── lora-gateway-bridge │ ├── lora-gateway-bridge │ │ ├── lora-gateway-bridge.init │ │ └── lora-gateway-bridge.toml │ └── lora-gateway-bridge_2.6.0.bb ├── lora-gateway │ ├── lora-gateway │ │ ├── library.cfg │ │ ├── lora-gateway-add-fpga-version-28-31-33.patch │ │ ├── lora-gateway-add-spi-path-function.patch │ │ └── lora-gateway-v28-skip-IQ-invert.patch │ └── lora-gateway_5.0.1.bb ├── lora-packet-forwarder │ ├── lora-packet-forwarder │ │ ├── README.md │ │ ├── global_conf.json │ │ ├── local_conf.json │ │ ├── lora-packet-forwarder-add-no-header-option.patch │ │ ├── lora-packet-forwarder-add-spi-dev-path.patch │ │ ├── lora-packet-forwarder-custom-conf-dir.patch │ │ ├── lora-packet-forwarder-parse-config-params-when-radio-disabled.patch │ │ ├── lora-packet-forwarder-remove-jit-power-check.patch │ │ └── start.sh │ └── lora-packet-forwarder_4.0.1.bb ├── mjpg-streamer │ ├── files │ │ └── vchiq-udev-rule │ ├── mjpg-streamer │ │ ├── 0001-Updated-RaspiCamControl-source-file.patch │ │ ├── 0001-slightly-unbreak-raspi-cmake.patch │ │ └── d0dcc2e0bbe84ef0937def2d7d226eee88150739.patch │ └── mjpg-streamer_git.bb ├── pycom-utils │ ├── files │ │ ├── __init__.py │ │ ├── esptool.py │ │ ├── pypic.py │ │ └── updater.py │ └── pycom-utils_0.1.bb ├── rtl-sdr │ ├── files │ │ └── 0001-Do-not-store-build-system-CFLAGS-in-the-pkgconfig-fi.patch │ └── rtl-sdr_git.bb ├── uhubctl │ └── uhubctl_git.bb └── ykush │ ├── ykush │ └── fix_makefile.patch │ └── ykush_git.bb └── recipes.txt /.dockerignore: -------------------------------------------------------------------------------- 1 | build*/ 2 | meta-*/ 3 | poky/ 4 | -------------------------------------------------------------------------------- /.github/workflows/build-images-dunfell.yml: -------------------------------------------------------------------------------- 1 | name: Dunfell Yocto images 2 | 3 | on: 4 | push: 5 | branches: 6 | - master 7 | tags: 8 | - '*' 9 | pull_request: 10 | branches: 11 | - master 12 | 13 | jobs: 14 | build_images: 15 | name: Build Yocto images 16 | runs-on: self-hosted 17 | timeout-minutes: 720 18 | strategy: 19 | matrix: 20 | target: [a8, rpi2, rpi3, rpi4] 21 | fail-fast: false 22 | env: 23 | BUILD_IN_DOCKER: 1 24 | BUILD_DOWNLOAD_DIR: /home/ci 25 | DISTRO_RELEASE: dunfell 26 | steps: 27 | - name: Check out install-lib repo 28 | uses: actions/checkout@v2 29 | with: 30 | repository: iot-lab/iot-lab-dev 31 | token: ${{ secrets.IOTLAB_TOKEN }} 32 | - name: Check out the repo 33 | uses: actions/checkout@v2 34 | with: 35 | path: ./parts/iot-lab-yocto 36 | - name: Build images 37 | run: | 38 | make TARGET=${{ matrix.target }} build-and-upload-images 39 | - name: Cleanup images 40 | run: | 41 | make TARGET=${{ matrix.target }} clean-images 42 | -------------------------------------------------------------------------------- /.github/workflows/docker-dunfell.yml: -------------------------------------------------------------------------------- 1 | name: Dunfell Docker image 2 | 3 | on: 4 | push: 5 | branches: 6 | - master 7 | tags: 8 | - '*' 9 | pull_request: 10 | branches: 11 | - master 12 | 13 | jobs: 14 | push_to_registry: 15 | name: Push Docker image to Docker Hub 16 | runs-on: ubuntu-latest 17 | steps: 18 | - name: Check out the repo 19 | uses: actions/checkout@v2 20 | - name: Log in to Docker Hub 21 | uses: docker/login-action@v1 22 | with: 23 | username: ${{ secrets.DOCKER_USERNAME }} 24 | password: ${{ secrets.DOCKER_PASSWORD }} 25 | - name: Push to Docker Hub 26 | uses: docker/build-push-action@v2 27 | with: 28 | push: true 29 | tags: fitiotlab/iot-lab-yocto:latest 30 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | *.orig 2 | 3 | cache/ 4 | downloads/ 5 | sstate-cache/ 6 | tmp/ 7 | *.log 8 | sanity_info 9 | templateconf.cfg 10 | .idea/ 11 | -------------------------------------------------------------------------------- /.gitmodules: -------------------------------------------------------------------------------- 1 | [submodule "poky"] 2 | path = poky 3 | url = git://git.yoctoproject.org/poky 4 | branch = dunfell 5 | [submodule "meta-openembedded"] 6 | path = meta-openembedded 7 | url = git://git.openembedded.org/meta-openembedded 8 | branch = dunfell 9 | [submodule "meta-java"] 10 | path = meta-java 11 | url = git://git.yoctoproject.org/meta-java 12 | branch = dunfell 13 | [submodule "meta-raspberrypi"] 14 | path = meta-raspberrypi 15 | url = git://git.yoctoproject.org/meta-raspberrypi 16 | branch = dunfell 17 | -------------------------------------------------------------------------------- /DEVELOPPER.md: -------------------------------------------------------------------------------- 1 | ## IoT-LAB Layer 2 | 3 | The OpenEmbedded build system supports organizing Metadata into multiple layers. Layers are basically a group of directories and meta data in configuration and recipes files. Layers allow you to isolate different types of customizations from each other. Folders that represent layers typically have names that begin with the string meta-*. So you can find the custom IoT-LAB layer in the meta-iotlab directory with its configuration and the layer.conf file. (eg. directory meta-iotlab/conf). 4 | 5 | ``` 6 | # We have a conf and classes directory, add to BBPATH 7 | BBPATH .= ":${LAYERDIR}" 8 | 9 | # We have a recipes-* directories, add to BBFILES 10 | BBFILES += "${LAYERDIR}/recipes-*/*/*.bb ${LAYERDIR}/recipes-*/*/*.bbappend" 11 | 12 | BBFILE_COLLECTIONS += "iotlab" 13 | BBFILE_PATTERN_iotlab = "^${LAYERDIR}" 14 | BBFILE_PRIORITY_iotlab = "10" 15 | 16 | LAYERSERIES_COMPAT_iotlab = "krogoth" 17 | ``` 18 | You can note for example that the Bitbake recipes for the layer are appended to **BBFILES** variable, the layer name is appended to **BBFILE_COLLECTIONS** and you define layer priority (allows to choose the layer that takes precedence) in **BBFILE_PRIORITY_iotlab**. 19 | 20 | If you want that OpenEmbedded build system use your new layer you must enable it. The layer's path is adding to the BBLAYERS variable in the bblayers.conf file of your build directory (eg. build/conf/) 21 | 22 | ``` 23 | # LAYER_CONF_VERSION is increased each time build/conf/bblayers.conf 24 | # changes incompatibly 25 | POKY_BBLAYERS_CONF_VERSION = "2" 26 | 27 | BBPATH = "${TOPDIR}" 28 | BBFILES ?= "" 29 | 30 | BBLAYERS ?= " \ 31 | ${TOPDIR}/../poky/meta \ 32 | ${TOPDIR}/../poky/meta-poky \ 33 | ${TOPDIR}/../meta-openembedded/meta-oe \ 34 | ${TOPDIR}/../meta-openembedded/meta-networking \ 35 | ${TOPDIR}/../meta-openembedded/meta-python \ 36 | ${TOPDIR}/../meta-java/ \ 37 | ${TOPDIR}/../meta-iotlab/ \ 38 | " 39 | BBLAYERS_NON_REMOVABLE ?= " \ 40 | ${TOPDIR}/../poky/meta \ 41 | ${TOPDIR}/../poky/meta-poky \ 42 | ``` 43 | 44 | You can see that we have two build directories, build and build-rpi3, which correspond respectively to the IoT-LAB A8 and RPI3 hardware. 45 | 46 | ### Bitbake recipes 47 | 48 | Recipes used to append Metadata are called BitBake append files (.bbappend or .bb suffix). You can find all recipes of a layer in directories recipes-*. A bitbake recipe file is a set of instructions from creating one, or more, packages for installation on the target device (eg. ipkg package). For example we have written a bitbake append file (eg. ftdi-utils_1.1.0.bb) for IoT-LAB FTDI tools (ftdi-devices-list and ftdi-eeprom-config). 49 | 50 | ``` 51 | DESCRIPTION = "IOT-LAB ftdi list and configuration" 52 | LICENSE = "CECILL-2.0" 53 | LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/CECILL-2.0;md5=574109ac4bdff61f9c3e0de892ecbd19" 54 | 55 | PACKAGES =+ "${PN}-list ${PN}-config" 56 | S = "${WORKDIR}" 57 | FILESEXTRAPATHS_prepend := "${THISDIR}/src:" 58 | 59 | # metapackage 60 | DEPENDS = "libftdi libusb1" 61 | 62 | RDEPENDS_${PN} += "${PN}-list ${PN}-config" 63 | ALLOW_EMPTY_${PN} = "1" 64 | 65 | 66 | DESCRIPTION_${PN}-list = "IOT-LAB ftdi list" 67 | FILES_${PN}-list = "${bindir}/ftdi-devices-list" 68 | RDEPENDS_${PN}-list = "libftdi libusb1" 69 | 70 | DESCRIPTION_${PN}-config = "IOT-LAB ftdi eeprom config" 71 | FILES_${PN}-config = "${bindir}/ftdi-eeprom-config" 72 | RDEPENDS_${PN}-config = "libftdi libusb1" 73 | 74 | SRC_URI = "git://github.com/iot-lab/iot-lab-ftdi-utils.git;protocol=git;tag=${PV}" 75 | S = "${WORKDIR}/git/" 76 | 77 | 78 | do_compile () { 79 | export LDFLAGS="$(pkg-config --libs libftdi1) ${LDFLAGS}" 80 | export CFLAGS="$(pkg-config --cflags-only-I libftdi1) -DLIBFTDI1=1 ${CFLAGS}" 81 | 82 | oe_runmake 83 | } 84 | 85 | do_install () { 86 | install -d ${D}${bindir} 87 | install -m 755 ${S}/ftdi-devices-list ${D}${bindir}/ 88 | install -m 755 ${S}/ftdi-eeprom-config ${D}${bindir}/ 89 | } 90 | ``` 91 | 92 | You can view in this file: 93 | * **DEPENDS**: lists a recipe's build-time dependencies (other recipes files). 94 | * **PACKAGES**: the list of packages the recipe creates ($PN is the recipe name) 95 | * **ALLOW_EMPTY**: is used to control the creation of empty packages (rg. virtual package) which will install other packages 96 | * **SRC_URI**: the list of source files and here IoT-LAB public GitHub repository iot-lab-ftdi-utils 97 | * **do_compile**: provide a compile task which tells Bitbake how to compile. We set CFLAGS and LDFLAGS environment variables and launch oe_runmake used to run make 98 | * **do_install**: provide install task files 99 | 100 | The result on A8 node: 101 | ``` 102 | root@a8-1:~# opkg list | grep ftdi 103 | ftdi-utils - 1.0.0-r0 104 | ftdi-utils-config - 1.0.0-r0 105 | ftdi-utils-list - 1.0.0-r0 106 | 107 | root@a8-1:~# opkg files ftdi-utils 108 | Package ftdi-utils (1.0.0-r0) is installed on root and has the following files: 109 | 110 | root@a8-1:~# opkg files ftdi-utils-list 111 | Package ftdi-utils-list (1.0.0-r0) is installed on root and has the following files: 112 | /usr/bin/ftdi-devices-list 113 | 114 | root@a8-1:~# opkg files ftdi-utils-config 115 | Package ftdi-utils-config (1.0.0-r0) is installed on root and has the following files: 116 | /usr/bin/ftdi-eeprom-config 117 | ``` 118 | 119 | ### Customizing Images 120 | 121 | You can customize an image by creating a custom image recipe file that defines additional software as part of the image. The easiest way is to use **IMAGE_INSTALL** variable which specify the **packagegroup** to install into an image. View the iotlab-image-open-a8.bb recipe file for the open A8 image generation. (eg. meta-iotlab/recipes-core/images directory) 122 | 123 | ``` 124 | DESCRIPTION = "IoT-LAB image for Open A8 used by users" 125 | include iotlab-image.inc 126 | 127 | IMAGE_INSTALL += "open-a8-packagegroup" 128 | ``` 129 | This file include a generic iotlab-image.inc file with the minimal IoT-LAB requirements and Linux node package group. Thus you can simply add in the package group recipe file (eg. recipes-core/packagegroups/linux-node-packagegroup.bb) your custom package in RDEPENDS_${PN} variable. 130 | 131 | ``` 132 | DESCRIPTION = "IoT-LAB image for Open A8 used by users" 133 | include iotlab-image.inc 134 | 135 | IMAGE_INSTALL += " \ 136 | linux-node-packagegroup \ 137 | u-boot-fw-utils \ 138 | flash-scripts-open-a8 \ 139 | " 140 | ``` 141 | 142 | In the iotlab-image.inc you can view that we inherit of core-image which is the most basic image allowing a device to boot to a Linux. We also use **IMAGE_FEATURES** variable to enable or high-level feature like use openssh server instead of minimal dropbear or activate read_only filesystem and **DISTRO_FEATURES** with ipv6 support. 143 | 144 | ``` 145 | DESCRIPTION = "IoT-LAB base image, supports target devices" 146 | LICENSE = "GPLv2" 147 | inherit core-image 148 | 149 | 150 | IMAGE_FEATURES += " \ 151 | ssh-server-openssh \ 152 | package-management \ 153 | tools-sdk \ 154 | tools-debug \ 155 | read-only-rootfs \ 156 | " 157 | 158 | DISTRO_FEATURES += "nfs ipv6" 159 | 160 | IMAGE_INSTALL +=" \ 161 | lsb \ 162 | tzdata \ 163 | cronie \ 164 | ``` 165 | 166 | ### Recipes structure 167 | 168 | 169 | | Recipes directory | Recipes | 170 | |----------------------|---------------------------------------------------| 171 | | recipes-core | Images, package groups, sshd keys, initrd scripts | 172 | | recipes-bsp | U-boot (eg. A8 nodes) | 173 | | recipes-kernel | Linux kernel (eg. A8 nodes) | 174 | | recipes-support | Gateway python app | 175 | | recipes-connectivity | OpenSSL/SSH, OML, websocket, MQTT, NTP | 176 | | recipes-devtools | OpenOCD, Edbg, Python2/3 dependencies | 177 | 178 | 179 | 180 | -------------------------------------------------------------------------------- /DOCKER.md: -------------------------------------------------------------------------------- 1 | ## Docker image 2 | 3 | We provide a Docker image with all requirements to build and cross-compile IoT-LAB Yocto Linux images. 4 | 5 | ### Build Yocto images and packages using the Docker container 6 | 7 | To build the `iotlab-image` using the Docker container, just add 8 | `BUILD_IN_DOCKER=1` to the make command: 9 | 10 | ``` 11 | BUILD_IN_DOCKER=1 make iotlab-image 12 | ``` 13 | 14 | And the `make iotlab-image` is run inside the container. 15 | 16 | The local host user ids are automatically mapped to the `dev` user inside the 17 | container so the files created by the container have the right ownership. 18 | 19 | Other make target can also be used the same way: 20 | 21 | - build the `iotlab-image-gateway` image: 22 | 23 | ``` 24 | BUILD_IN_DOCKER=1 make iotlab-image 25 | ``` 26 | 27 | - build a package (replace `` at the end): 28 | 29 | ``` 30 | BUILD_IN_DOCKER=1 make build-pkg- 31 | ``` 32 | 33 | By default, the target architecture is the var-som-am35 (e.g. the A8 chips). If 34 | you want to build for `rpi3`, add `TARGET=rpi3` option to the make command, as 35 | usual: 36 | 37 | ``` 38 | BUILD_IN_DOCKER=1 TARGET=rpi3 make iotlab-image 39 | ``` 40 | 41 | ### Build the Docker image locally 42 | 43 | Simply build the Docker image with the following command: 44 | 45 | ``` 46 | docker image build . -t fitiotlab/iot-lab-yocto 47 | ``` 48 | -------------------------------------------------------------------------------- /Dockerfile: -------------------------------------------------------------------------------- 1 | FROM debian:stretch 2 | 3 | RUN apt-get update -yq \ 4 | && DEBIAN_FRONTEND=noninteractive \ 5 | apt-get install -yq --no-install-recommends \ 6 | ca-certificates \ 7 | # Yocto requirements 8 | build-essential \ 9 | chrpath \ 10 | cmake \ 11 | cpio \ 12 | curl \ 13 | debianutils \ 14 | diffstat \ 15 | gawk \ 16 | gcc-multilib \ 17 | git-core \ 18 | iputils-ping \ 19 | libbz2-dev \ 20 | libegl1-mesa \ 21 | libreadline-dev \ 22 | libsdl1.2-dev \ 23 | libssl-dev \ 24 | locales \ 25 | ntpdate \ 26 | python3 \ 27 | python3-pip \ 28 | python3-pexpect \ 29 | python3-jinja2 \ 30 | python-dev \ 31 | screen \ 32 | texinfo \ 33 | time \ 34 | unzip \ 35 | wget \ 36 | xterm \ 37 | xz-utils \ 38 | # Oml2 requirements 39 | autoconf \ 40 | automake \ 41 | libtool \ 42 | gnulib \ 43 | check \ 44 | libpopt-dev \ 45 | libsqlite3-dev \ 46 | libtool \ 47 | libxml2-dev \ 48 | libxml2-utils \ 49 | pkg-config \ 50 | python-matplotlib \ 51 | ruby \ 52 | sqlite3 \ 53 | valgrind \ 54 | && apt-get clean && rm -rf /var/lib/apt/lists/* 55 | 56 | RUN mkdir /var/www && chown www-data:www-data /var/www 57 | 58 | RUN git clone https://github.com/mytestbed/oml.git && \ 59 | cd oml && \ 60 | git checkout tags/v2.11.0 && \ 61 | ./autogen.sh && \ 62 | ./configure --disable-doc --disable-doxygen-doc --disable-doxygen-dot \ 63 | --disable-android --disable-doxygen-html --disable-option-checking && \ 64 | make && \ 65 | make install && \ 66 | cd .. && rm -rf oml 67 | 68 | RUN sed -i '/en_US.UTF-8/s/^# //g' /etc/locale.gen \ 69 | && locale-gen 70 | ENV LANG en_US.UTF-8 71 | ENV LANGUAGE en_US.UTF-8 72 | ENV LC_ALL en_US.UTF-8 73 | 74 | WORKDIR /shared 75 | 76 | RUN groupadd -g 1000 dev 77 | RUN useradd -u 1000 -g 1000 -m -N dev 78 | 79 | RUN chown -R dev:dev /shared 80 | 81 | USER dev 82 | 83 | RUN git config --global user.email "admin@iot-lab.info" 84 | RUN git config --global user.name "IoT-LAB" 85 | # bug with ca-certificates 86 | RUN git config --global http.sslverify false 87 | 88 | CMD ["/bin/bash"] 89 | -------------------------------------------------------------------------------- /Makefile: -------------------------------------------------------------------------------- 1 | # 2 | # Makefile for building IoT-LAB images and packages 3 | # 4 | # 5 | 6 | TARGET ?= a8 7 | 8 | IMAGES = iotlab-image 9 | IMAGES += iotlab-image-gateway 10 | IMAGES += iotlab-image-autotest 11 | 12 | EXTRA_BUILDS = 13 | 14 | # Define variables specific to the given target 15 | ifeq ($(TARGET), a8) 16 | BUILD_DIR = build 17 | TARGET_ARCH = cortexa8hf-neon 18 | TARGET_IMG = var-som-am35 19 | KERNEL_IMG = uImage 20 | 21 | # Use a mapping between image target of make with image name in yocto 22 | iotlab-image = iotlab-image-open-a8 23 | iotlab-image-gateway = iotlab-image-gateway 24 | iotlab-image-autotest = iotlab-image-open-a8-autotest 25 | 26 | # We also build a mtd-rw version of the kernel for A8 27 | EXTRA_BUILDS = build-kernel-mtd-rw 28 | else ifeq ($(TARGET), rpi2) 29 | BUILD_DIR = build-rpi2 30 | TARGET_ARCH = cortexa7t2hf-neon-vfpv4 31 | TARGET_IMG = raspberrypi2 32 | KERNEL_IMG = zImage 33 | 34 | # Use a mapping between image target of make with image name in yocto 35 | iotlab-image = iotlab-image-rpi2 36 | iotlab-image-gateway = iotlab-image-gateway-rpi2 37 | iotlab-image-autotest = iotlab-image-rpi2-autotest 38 | else ifeq ($(TARGET), rpi3) 39 | BUILD_DIR = build-rpi3 40 | TARGET_ARCH = cortexa7t2hf-neon-vfpv4 41 | TARGET_IMG = raspberrypi3 42 | KERNEL_IMG = zImage 43 | 44 | # Use a mapping between image target of make with image name in yocto 45 | iotlab-image = iotlab-image-rpi3 46 | iotlab-image-gateway = iotlab-image-gateway-rpi3 47 | iotlab-image-autotest = iotlab-image-rpi3-autotest 48 | else ifeq ($(TARGET), rpi4) 49 | BUILD_DIR = build-rpi4 50 | TARGET_ARCH = cortexa7t2hf-neon-vfpv4 51 | TARGET_IMG = raspberrypi4 52 | KERNEL_IMG = zImage 53 | 54 | # Use a mapping between image target of make with image name in yocto 55 | iotlab-image = iotlab-image-rpi4 56 | iotlab-image-gateway = iotlab-image-gateway-rpi4 57 | iotlab-image-autotest = iotlab-image-rpi4-autotest 58 | else 59 | $(error Unsupported target, '$(TARGET)') 60 | endif 61 | 62 | PKGS_DIR = $(BUILD_DIR)/tmp/deploy/ipk/$(TARGET_ARCH) 63 | IMGS_DIR = $(BUILD_DIR)/tmp/deploy/images/$(TARGET_IMG) 64 | IMGS_MTD_RW_DIR = $(IMGS_DIR)-mtd-rw 65 | 66 | .PHONY: init submodules $(BUILD_DIR)/conf/local.conf 67 | 68 | ifeq (0,$(BUILD_IN_DOCKER)) 69 | # BUILD_IN_DOCKER set to 0 means we are running inside the container 70 | IN_DOCKER = 1 71 | endif 72 | 73 | # only init when not in docker 74 | init: $(if $(IN_DOCKER),,submodules $(BUILD_DIR)/conf/local.conf) 75 | 76 | $(BUILD_DIR)/conf/local.conf: 77 | sed -i "s/^BB_NUMBER_THREADS.*$$/BB_NUMBER_THREADS ?= \"$$(( $$(nproc) * 2 ))\"/" $@ 78 | sed -i "s/^PARALLEL_MAKE.*$$/PARALLEL_MAKE ?= \"-j $$(( $$(nproc) * 2 ))\"/" $@ 79 | ifdef BUILD_DOWNLOAD_DIR 80 | sed -i "s/^\DL_DIR.*$$/DL_DIR ?= \"$(subst /,\/,$(BUILD_DOWNLOAD_DIR))\/downloads\"/" $@ 81 | endif 82 | 83 | submodules: 84 | git submodule update --init --force --remote 85 | 86 | # # # # # # # # # # # # # # # # # # # # # 87 | # Building images and packages targets # 88 | # # # # # # # # # # # # # # # # # # # # # 89 | 90 | .PHONY: target-info build-all build-img-% iotlab-image-% 91 | 92 | target-info: 93 | @echo Using target: $(TARGET) 94 | @echo "" 95 | @echo "Available image targets:" 96 | @for img in $(IMAGES); do echo " - $$img"; done; 97 | @if [ ! -z "$(EXTRA_BUILDS)" ]; \ 98 | then \ 99 | echo "\nOther build targets:"; \ 100 | for target in $(EXTRA_BUILDS); do echo " - $$target"; done; \ 101 | fi 102 | 103 | build-all: $(IMAGES) $(EXTRA_BUILDS) 104 | 105 | $(IMAGES): %: build-img-% clean-img-% 106 | 107 | DOCKER_IMAGE ?= fitiotlab/iot-lab-yocto 108 | DOCKER_IMAGE_VERSION ?= latest 109 | # Use BUILD_IN_DOCKER=0 env to disable build in docker for sub-make, to avoid 110 | # recursive calls to docker 111 | DOCKER_CMD = docker run --rm --hostname yocto \ 112 | -v $(shell pwd):/shared \ 113 | $(if $(BUILD_DOWNLOAD_DIR),-v $(BUILD_DOWNLOAD_DIR):$(BUILD_DOWNLOAD_DIR),) \ 114 | -e BUILD_IN_DOCKER=0 \ 115 | -e TARGET=$(TARGET) \ 116 | -u $(shell id -u):$(shell id -g) \ 117 | $(DOCKER_IMAGE):$(DOCKER_IMAGE_VERSION) 118 | 119 | .PHONY: build-pkg-% 120 | build-pkg-%: init 121 | ifeq (1,$(BUILD_IN_DOCKER)) 122 | $(DOCKER_CMD) make $@ 123 | else 124 | @# build package 125 | time bash -c \ 126 | "source ./poky/oe-init-build-env $(BUILD_DIR); bitbake -k $*" 127 | @echo "" 128 | @echo "" 129 | @echo "$*" ipk package files should be found here: 130 | @ls $(PKGS_DIR)/$** 131 | endif 132 | 133 | .PHONY: build-pkg-%-native 134 | build-pkg-%-native: init 135 | ifeq (1,$(BUILD_IN_DOCKER)) 136 | $(DOCKER_CMD) make $@ 137 | else 138 | @# build native package 139 | time bash -c \ 140 | "source ./poky/oe-init-build-env $(BUILD_DIR); bitbake -k $*-native" 141 | endif 142 | 143 | .PHONY: clean-pkg-% 144 | clean-pkg-%: init 145 | ifeq (1,$(BUILD_IN_DOCKER)) 146 | $(DOCKER_CMD) make $@ 147 | else 148 | @# clean package 149 | time bash -c \ 150 | "source ./poky/oe-init-build-env $(BUILD_DIR); bitbake -c cleanall $*" 151 | endif 152 | 153 | .PHONY: build-uboot 154 | build-uboot: init 155 | ifeq (1,$(BUILD_IN_DOCKER)) 156 | $(DOCKER_CMD) make $@ 157 | else 158 | @# build u-Boot 159 | time bash -c \ 160 | "source ./poky/oe-init-build-env $(BUILD_DIR); bitbake -k virtual/bootloader" 161 | @echo "" 162 | @echo "" 163 | @echo "$*" U-Boot files should be found here: 164 | @ls $(IMGS_DIR)/u-boot* 165 | @ls $(IMGS_DIR)/MLO* 166 | endif 167 | 168 | .PHONY: clean-uboot 169 | clean-uboot: init 170 | ifeq (1,$(BUILD_IN_DOCKER)) 171 | $(DOCKER_CMD) make $@ 172 | else 173 | @# clean u-boot 174 | time bash -c \ 175 | "source ./poky/oe-init-build-env $(BUILD_DIR); bitbake -c cleanall virtual/bootloader" 176 | endif 177 | 178 | .PHONY: build-kernel 179 | build-kernel: init 180 | ifeq (1,$(BUILD_IN_DOCKER)) 181 | $(DOCKER_CMD) make $@ 182 | else 183 | @# build kernel 184 | time bash -c \ 185 | "source ./poky/oe-init-build-env $(BUILD_DIR); bitbake -k virtual/kernel" 186 | @echo "" 187 | @echo "" 188 | @echo "$*" Kernel files should be found here: 189 | @ls $(IMGS_DIR)/$(KERNEL_IMG)* 190 | endif 191 | 192 | .PHONY: clean-kernel 193 | clean-kernel: init 194 | ifeq (1,$(BUILD_IN_DOCKER)) 195 | $(DOCKER_CMD) make $@ 196 | else 197 | @# clean kernel 198 | time bash -c \ 199 | "source ./poky/oe-init-build-env $(BUILD_DIR); bitbake -c cleanall virtual/kernel" 200 | endif 201 | 202 | .PHONY: build-kernel-mtd-rw 203 | build-kernel-mtd-rw: init 204 | ifeq (1,$(BUILD_IN_DOCKER)) 205 | $(DOCKER_CMD) make $@ 206 | else 207 | @# build mtd writeable Kernel 208 | time bash -c \ 209 | "source ./poky/oe-init-build-env $(BUILD_DIR); MACHINE=$(TARGET_IMG)-mtd-rw bitbake -k virtual/kernel" 210 | @echo "" 211 | @echo "" 212 | @echo "$*" Kernel mtd writeable files should be found here: 213 | @ls $(IMGS_MTD_RW_DIR)/$(KERNEL_IMG)* 214 | endif 215 | 216 | .PHONY: clean-kernel-mtd-rw 217 | clean-kernel-mtd-rw: init 218 | ifeq (1,$(BUILD_IN_DOCKER)) 219 | $(DOCKER_CMD) make $@ 220 | else 221 | @# clean kernel mtd writeable package 222 | time bash -c \ 223 | "source ./poky/oe-init-build-env $(BUILD_DIR); MACHINE=$(TARGET_IMG)-mtd-rw bitbake -c cleanall virtual/kernel" 224 | endif 225 | 226 | .PHONY: build-img-% 227 | build-img-%: init 228 | ifeq (1,$(BUILD_IN_DOCKER)) 229 | $(DOCKER_CMD) make $@ 230 | else 231 | @# build image 232 | time bash -c \ 233 | "source ./poky/oe-init-build-env $(BUILD_DIR); bitbake -k $($*)" 234 | @echo "" 235 | @echo "" 236 | @echo "$*" image files should be found here: 237 | @ls $(IMGS_DIR)/$($*)* 238 | endif 239 | 240 | .PHONY: clean-img-% 241 | clean-img-%: 242 | @# keep only the last one 243 | @# don't match the symlink or the last build image 244 | rm -f $(shell find $(IMGS_DIR)/ -name '$($*)-$(TARGET_IMG)*' -type f \ 245 | ! -name $(shell readlink $(IMGS_DIR)/$($*)-$(TARGET_IMG).tar.gz) \ 246 | ! -name $(shell readlink $(IMGS_DIR)/$($*)-$(TARGET_IMG).manifest) \ 247 | ) 248 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | Build IoT-LAB images and packages 2 | ================================= 3 | 4 | [Yocto Project](https://www.yoctoproject.org/) aim to develop embedded Linux images and user-space applications that run on targeted devices like IoT-LAB Open A8 and RPI3 hardware. 5 | 6 | The process of building images and packages has been wrapped in a Makefile for easier use. This will setup you environment if it hasn't been set before, update the configuration for your machine and build the images or packages. 7 | 8 | 9 | System Requirements 10 | ------------------- 11 | 12 | For Ubuntu and Debian Linux distributions 13 | 14 | $ sudo apt-get install gawk wget git-core diffstat unzip texinfo gcc-multilib \ 15 | build-essential chrpath socat libsdl1.2-dev xterm 16 | 17 | For others distributions view the [Yocto official documentation](https://www.yoctoproject.org/documentation). 18 | 19 | Build images 20 | --------------- 21 | 22 | To build images you can run: 23 | 24 | $ make build-all 25 | # or one by one 26 | $ make iotlab-image 27 | 28 | By default the Makefile builds an image for IoT-LAB A8 hardware. If you want to build image for RPI3 hardware you should specify the target as follows: 29 | 30 | $ make TARGET=rpi3 iotlab-image 31 | 32 | Build packages 33 | ----------------- 34 | 35 | To build package you can run: 36 | 37 | $ make build-pkg- 38 | 39 | Build Linux kernel/U-boot 40 | ----------------- 41 | 42 | $ make build-kernel 43 | $ make build-uboot 44 | 45 | Manual process 46 | -------------- 47 | 48 | $ git submodule update --init --remote (eg. only the first time) 49 | $ source ./poky/oe-init-build-env build 50 | $ bitbake -k iotlab-image-open-a8 51 | $ bitbake -k 52 | 53 | If you want to build for RPI3 hardware: 54 | 55 | $ source ./poky/oe-init-build-env build-rpi3 56 | $ bitbake -k iotlab-image-rpi3 57 | 58 | 59 | Yocto and OpenEmbedded 60 | ---------------------- 61 | 62 | At the top of the directory you can find a local copy of: 63 | 64 | * Yocto project (poky) 65 | * [OpenEmbedded](https://www.openembedded.org/wiki/Main_Page) layers (meta-openembedded) 66 | * Raspberry Pi boards layer (meta-raspberrypi) 67 | * Java OpenJDK layer (meta-java) 68 | 69 | The build system uses sub-modules and were initialized as follows: 70 | 71 | $ git submodule add -b dunfell git://git.yoctoproject.org/poky 72 | $ git submodule add -b dunfell git://git.openembedded.org/meta-openembedded 73 | $ git submodule add -b dunfell git://git.yoctoproject.org/meta-java 74 | $ git submodule add -b dunfell git://git.yoctoproject.org/meta-raspberrypi 75 | $ git commit -m "Add submodules meta-openembedded/poky/meta-java/meta-raspberrypi" 76 | 77 | Use `git submodule status` and/or check file .gitmodules for details. 78 | 79 | $ git submodule status 80 | -67e48693501bddb80745b9735b7b3d4d28dce9a1 meta-java 81 | -55c8a76da5dc099a7bc3838495c672140cedb78e meta-openembedded 82 | -a5f9b07a820d50ae5fb62e07306cd4e72d8638a9 meta-raspberrypi 83 | -50fdd784231299bedb008f20adeaeeca3eb1452d poky 84 | 85 | The sub-modules are set to allow for tracking of upstream updates 86 | on branch dunfell, current TLS release version of Yocto. You may 87 | update the sub-modules to use the latest upstream version using: 88 | 89 | $ git submodule update --remote 90 | 91 | Should you need to update either of the sub-modules to a specific version, 92 | simply cd to it, git pull, inspect changes, then git checkout the desired 93 | version or tag. Then cd .. and git commit the new sub-module(s) setup. 94 | If switching to another branch, update .gitmodules accordingly. 95 | -------------------------------------------------------------------------------- /meta-iotlab/conf/bblayers.conf.sample: -------------------------------------------------------------------------------- 1 | # LAYER_CONF_VERSION is increased each time build/conf/bblayers.conf 2 | # changes incompatibly 3 | LCONF_VERSION = "6" 4 | 5 | BBPATH = "${TOPDIR}" 6 | BBFILES ?= "" 7 | 8 | BBLAYERS ?= " \ 9 | ${TOPDIR}/../poky/meta \ 10 | ${TOPDIR}/../poky/meta-yocto \ 11 | ${TOPDIR}/../meta-openembedded/meta-oe \ 12 | ${TOPDIR}/../meta-openembedded/meta-networking \ 13 | ${TOPDIR}/../meta-openembedded/meta-python \ 14 | ${TOPDIR}/../meta-iotlab/ \ 15 | " 16 | BBLAYERS_NON_REMOVABLE ?= " \ 17 | ${TOPDIR}/../poky/meta \ 18 | ${TOPDIR}/../poky/meta-yocto \ 19 | " 20 | -------------------------------------------------------------------------------- /meta-iotlab/conf/conf-notes.txt: -------------------------------------------------------------------------------- 1 | Common targets are: 2 | core-image-minimal 3 | core-image-sato 4 | meta-toolchain 5 | meta-toolchain-sdk 6 | adt-installer 7 | meta-ide-support 8 | 9 | IoT-LAB 10 | iotlab-image-open-a8 11 | iotlab-image-gateway 12 | -------------------------------------------------------------------------------- /meta-iotlab/conf/distro/iotlab.conf: -------------------------------------------------------------------------------- 1 | #@-------------------------------------------------------------------- 2 | #@TYPE: Distribution 3 | #@NAME: IoT-LAB Linux 4 | #@-------------------------------------------------------------------- 5 | 6 | require conf/distro/poky.conf 7 | 8 | DISTRO = "iotlab" 9 | DISTRO_NAME = "IoT-LAB Linux" 10 | DISTRO_VERSION = "2020-devel" 11 | DISTRO_REVISION = "1" 12 | DISTRO_PR = ".1" 13 | DISTRO_TYPE = "dev" 14 | 15 | DEFAULT_TIMEZONE ?= "Europe/Paris" 16 | -------------------------------------------------------------------------------- /meta-iotlab/conf/layer.conf: -------------------------------------------------------------------------------- 1 | # We have a conf and classes directory, add to BBPATH 2 | BBPATH .= ":${LAYERDIR}" 3 | 4 | # We have a recipes-* directories, add to BBFILES 5 | BBFILES += "${LAYERDIR}/recipes-*/*/*.bb ${LAYERDIR}/recipes-*/*/*.bbappend" 6 | 7 | BBFILE_COLLECTIONS += "iotlab" 8 | BBFILE_PATTERN_iotlab = "^${LAYERDIR}" 9 | BBFILE_PRIORITY_iotlab = "10" 10 | 11 | LAYERSERIES_COMPAT_iotlab = "dunfell" 12 | -------------------------------------------------------------------------------- /meta-iotlab/conf/local.conf.sample: -------------------------------------------------------------------------------- 1 | MACHINE ??= "qemuarm" 2 | MACHINE ?= "var-som-am35" 3 | 4 | LICENSE_FLAGS_WHITELIST = "iotlab" 5 | 6 | # Where to place downloads 7 | #DL_DIR ?= "${TOPDIR}/downloads" 8 | 9 | # Where to place shared-state files 10 | #SSTATE_DIR ?= "${TOPDIR}/sstate-cache" 11 | 12 | # Where to place the build output 13 | #TMPDIR = "${TOPDIR}/tmp" 14 | 15 | # cleanup after build of sources 16 | INHERIT += "rm_work" 17 | 18 | # Default policy config 19 | DISTRO ?= "iotlab" 20 | 21 | # Package Management configuration 22 | PACKAGE_CLASSES ?= "package_ipk" 23 | 24 | # Extra image configuration defaults 25 | # 26 | # The EXTRA_IMAGE_FEATURES variable allows extra packages to be added to the generated 27 | # images. Some of these options are added to certain image types automatically. The 28 | # variable can contain the following options: 29 | # "dbg-pkgs" - add -dbg packages for all installed packages 30 | # (adds symbol information for debugging/profiling) 31 | # "dev-pkgs" - add -dev packages for all installed packages 32 | # (useful if you want to develop against libs in the image) 33 | # "ptest-pkgs" - add -ptest packages for all ptest-enabled packages 34 | # (useful if you want to run the package test suites) 35 | # "tools-sdk" - add development tools (gcc, make, pkgconfig etc.) 36 | # "tools-debug" - add debugging tools (gdb, strace) 37 | # "eclipse-debug" - add Eclipse remote debugging support 38 | # "tools-profile" - add profiling tools (oprofile, exmap, lttng, valgrind) 39 | # "tools-testapps" - add useful testing tools (ts_print, aplay, arecord etc.) 40 | # "debug-tweaks" - make an image suitable for development 41 | # e.g. ssh root access has a blank password 42 | # There are other application targets that can be used here too, see 43 | # meta/classes/image.bbclass and meta/classes/core-image.bbclass for more details. 44 | # We default to enabling the debugging tweaks. 45 | EXTRA_IMAGE_FEATURES = "read-only-rootfs" 46 | 47 | 48 | # 49 | # Additional image features 50 | # 51 | # The following is a list of additional classes to use when building images which 52 | # enable extra features. Some available options which can be included in this variable 53 | # are: 54 | # - 'buildstats' collect build statistics 55 | # - 'image-mklibs' to reduce shared library files size for an image 56 | # - 'image-prelink' in order to prelink the filesystem image 57 | # - 'image-swab' to perform host system intrusion detection 58 | # NOTE: if listing mklibs & prelink both, then make sure mklibs is before prelink 59 | # NOTE: mklibs also needs to be explicitly enabled for a given image, see local.conf.extended 60 | #USER_CLASSES ?= "buildstats image-mklibs image-prelink" 61 | 62 | # Interactive shell configuration 63 | PATCHRESOLVE = "noop" 64 | 65 | # Disk Space Monitoring during the build 66 | # 67 | # Monitor the disk space during the build. If there is less that 1GB of space or less 68 | # than 100K inodes in any key build location (TMPDIR, DL_DIR, SSTATE_DIR), gracefully 69 | # shutdown the build. If there is less that 100MB or 1K inodes, perform a hard abort 70 | # of the build. The reason for this is that running completely out of space can corrupt 71 | # files and damages the build in ways which may not be easily recoverable. 72 | BB_DISKMON_DIRS = "\ 73 | STOPTASKS,${TMPDIR},1G,100K \ 74 | STOPTASKS,${DL_DIR},1G,100K \ 75 | STOPTASKS,${SSTATE_DIR},1G,100K \ 76 | ABORT,${TMPDIR},100M,1K \ 77 | ABORT,${DL_DIR},100M,1K \ 78 | ABORT,${SSTATE_DIR},100M,1K" 79 | 80 | # CONF_VERSION is increased each time build/conf/ changes incompatibly and is used to 81 | # track the version of this file when it was generated. This can safely be ignored if 82 | # this doesn't mean anything to you. 83 | CONF_VERSION = "1" 84 | -------------------------------------------------------------------------------- /meta-iotlab/conf/machine/var-som-am35-mtd-rw.conf: -------------------------------------------------------------------------------- 1 | #@TYPE: Machine 2 | #@NAME: var-som-am35-mtd-rw 3 | 4 | #@DESCRIPTION: Machine configuration for var-som-am35 mtd writeable systems 5 | 6 | DEFAULTTUNE ?= "cortexa8hf-neon" 7 | SOC_FAMILY = "omap3" 8 | require conf/machine/include/soc-family.inc 9 | require conf/machine/include/tune-cortexa8.inc 10 | 11 | SERIAL_CONSOLE = "115200 ttyO2" 12 | USE_VT = "2" 13 | 14 | # kernel 15 | PREFERRED_PROVIDER_virtual/kernel ?= "linux" 16 | PREFERRED_VERSION_linux ?= "5.4%" 17 | KERNEL_IMAGETYPE = "zImage" 18 | KERNEL_EXTRA_ARGS = "LOADADDR=0x80008000" 19 | KERNEL_DEVICETREE = "var-som-am35-mtd-rw.dtb" 20 | KERNEL_DEVICETREE_BUNDLE = "1" 21 | 22 | # u-boot 23 | # dirty hack to compile and install libubootenv (fw_|) package 24 | # use 2020.01 U-boot version with am3517 defconfig as we don't have a var-som-am35 25 | # (AM3505) port. 26 | PREFERRED_VERSION_u-boot ?= "2020.01%" 27 | UBOOT_MACHINE = "am3517_evm_defconfig" 28 | 29 | ## ---------------------------------------- 30 | ## image formats and filesystems 31 | ## ---------------------------------------- 32 | 33 | IMAGE_FSTYPES += "tar.gz" 34 | 35 | -------------------------------------------------------------------------------- /meta-iotlab/conf/machine/var-som-am35.conf: -------------------------------------------------------------------------------- 1 | #@TYPE: Machine 2 | #@NAME: var-som-am35 3 | 4 | #@DESCRIPTION: Machine configuration for var-som-am35 systems 5 | 6 | DEFAULTTUNE ?= "cortexa8hf-neon" 7 | SOC_FAMILY = "omap3" 8 | require conf/machine/include/soc-family.inc 9 | require conf/machine/include/tune-cortexa8.inc 10 | 11 | SERIAL_CONSOLE = "115200 ttyO2" 12 | USE_VT = "2" 13 | 14 | # kernel 15 | PREFERRED_PROVIDER_virtual/kernel ?= "linux" 16 | PREFERRED_VERSION_linux ?= "5.4%" 17 | KERNEL_IMAGETYPE = "zImage" 18 | KERNEL_EXTRA_ARGS = "LOADADDR=0x80008000" 19 | KERNEL_DEVICETREE = "var-som-am35.dtb" 20 | KERNEL_DEVICETREE_BUNDLE = "1" 21 | 22 | # u-boot 23 | # dirty hack to compile and install libubootenv (fw_|) package 24 | # use 2020.01 U-boot version with am3517 defconfig as we don't have a var-som-am35 25 | # (AM3505) port. 26 | PREFERRED_VERSION_u-boot ?= "2020.01%" 27 | UBOOT_MACHINE = "am3517_evm_defconfig" 28 | 29 | ## ---------------------------------------- 30 | ## image formats and filesystems 31 | ## ---------------------------------------- 32 | 33 | IMAGE_FSTYPES += "tar.gz" 34 | 35 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-bsp/libubootenv/files/fw_env.config: -------------------------------------------------------------------------------- 1 | # Configuration file for fw_(printenv/setenv) utility. 2 | # Up to two entries are valid, in this case the redundant 3 | # environment sector is assumed present. 4 | # Notice, that the "Number of sectors" is not required on NOR and SPI-dataflash. 5 | # Futhermore, if the Flash sector size is ommitted, this value is assumed to 6 | # be the same as the Environment size, which is valid for NOR and SPI-dataflash 7 | 8 | # NAND config 9 | # MTD device name Device offset Env. size Flash sector size Number of sectors 10 | /dev/mtd2 0x0000 0x20000 0x20000 2 11 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-bsp/libubootenv/libubootenv_%.bbappend: -------------------------------------------------------------------------------- 1 | FILESEXTRAPATHS_prepend := "${THISDIR}/files:" 2 | 3 | SRC_URI_append = " file://fw_env.config" 4 | 5 | do_install_append() { 6 | install -d ${D}${sysconfdir} 7 | install -m 644 ${WORKDIR}/fw_env.config ${D}${sysconfdir} 8 | } 9 | 10 | FILES_${PN}_append = " ${sysconfdir}" 11 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-bsp/u-boot/files/fw_env.config: -------------------------------------------------------------------------------- 1 | # Configuration file for fw_(printenv/setenv) utility. 2 | # Up to two entries are valid, in this case the redundant 3 | # environment sector is assumed present. 4 | # Notice, that the "Number of sectors" is not required on NOR and SPI-dataflash. 5 | # Futhermore, if the Flash sector size is ommitted, this value is assumed to 6 | # be the same as the Environment size, which is valid for NOR and SPI-dataflash 7 | 8 | # NAND config 9 | # MTD device name Device offset Env. size Flash sector size Number of sectors 10 | /dev/mtd2 0x0000 0x20000 0x20000 2 11 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-bsp/u-boot/u-boot-fw-utils_2015.01.bb: -------------------------------------------------------------------------------- 1 | SUMMARY = "U-Boot bootloader fw_printenv/setenv utilities" 2 | LICENSE = "GPLv2+" 3 | LIC_FILES_CHKSUM = "file://Licenses/README;md5=c7383a594871c03da76b3707929d2919" 4 | SECTION = "bootloader" 5 | DEPENDS = "mtd-utils" 6 | 7 | require u-boot-iotlab-release.inc 8 | 9 | SRC_URI += "file://fw_env.config" 10 | 11 | PV = "v2015.01+git${SRCPV}" 12 | PR[vardepsxeclude]="DATETIME" 13 | 14 | S = "${WORKDIR}/git" 15 | 16 | INSANE_SKIP_${PN} = "already-stripped" 17 | EXTRA_OEMAKE_class-target = 'CROSS_COMPILE=${TARGET_PREFIX} CC="${CC} ${CFLAGS} ${LDFLAGS}" V=1' 18 | EXTRA_OEMAKE_class-cross = 'ARCH=${TARGET_ARCH} CC="${CC} ${CFLAGS} ${LDFLAGS}" V=1' 19 | 20 | inherit uboot-config 21 | 22 | do_compile () { 23 | oe_runmake ${UBOOT_MACHINE} 24 | oe_runmake env 25 | } 26 | 27 | do_install () { 28 | install -d ${D}${base_sbindir} 29 | install -d ${D}${sysconfdir} 30 | install -m 755 ${S}/tools/env/fw_printenv ${D}${base_sbindir}/fw_printenv 31 | install -m 755 ${S}/tools/env/fw_printenv ${D}${base_sbindir}/fw_setenv 32 | install -m 0644 ${S}/tools/env/fw_env.config ${D}${sysconfdir}/fw_env.config 33 | } 34 | 35 | do_install_class-cross () { 36 | install -d ${D}${bindir_cross} 37 | install -m 755 ${S}/tools/env/fw_printenv ${D}${bindir_cross}/fw_printenv 38 | install -m 755 ${S}/tools/env/fw_printenv ${D}${bindir_cross}/fw_setenv 39 | } 40 | 41 | SYSROOT_PREPROCESS_FUNCS_class-cross = "uboot_fw_utils_cross" 42 | uboot_fw_utils_cross() { 43 | sysroot_stage_dir ${D}${bindir_cross} ${SYSROOT_DESTDIR}${bindir_cross} 44 | } 45 | 46 | PACKAGE_ARCH = "${MACHINE_ARCH}" 47 | BBCLASSEXTEND = "cross" 48 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-bsp/u-boot/u-boot-fw-utils_2015.01.bbappend: -------------------------------------------------------------------------------- 1 | ## -*-conf-*- 2 | 3 | SRCREV_FORMAT = "uboot_iotlab" 4 | 5 | #do_install_append_iotlab-a8 () { 6 | do_install_append () { 7 | install -d ${D}${sysconfdir} 8 | install -m 0644 ${WORKDIR}/fw_env.config ${D}${sysconfdir} 9 | } 10 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-bsp/u-boot/u-boot-iotlab-release.inc: -------------------------------------------------------------------------------- 1 | SRC_URI = "git://github.com/iot-lab/iot-lab-uboot.git;protocol=https;branch=2015.01;name=uboot" 2 | 3 | SRCREV_uboot = "2015.01" 4 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-bsp/u-boot/u-boot_2015.01.bb: -------------------------------------------------------------------------------- 1 | require u-boot.inc 2 | require u-boot-iotlab-release.inc 3 | 4 | DEPENDS += "dtc-native" 5 | 6 | PV = "v2015.01+git${SRCPV}" 7 | PR[vardepsxeclude]="DATETIME" 8 | 9 | EXTRA_OEMAKE_append = " KCFLAGS=-fgnu89-inline" 10 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-connectivity/mosquitto-rsmb/mosquitto-rsmb_git.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "RSMB: Really Small Message Broker" 2 | HOMEPAGE = "https://github.com/eclipse/mosquitto.rsmb" 3 | 4 | LICENSE = "EPL-1.0 | EDL-1.0" 5 | 6 | LIC_FILES_CHKSUM = " \ 7 | file://edl-v10;md5=3adfcc70f5aeb7a44f3f9b495aa1fbf3 \ 8 | file://epl-v10;md5=659c8e92a40b6df1d9e3dccf5ae45a08 \ 9 | " 10 | 11 | PR = "r2" 12 | 13 | PV = "git-src${SRCDATE}-r${SRCPV}" 14 | 15 | SRC_URI = "git://github.com/eclipse/mosquitto.rsmb.git;protocol=https" 16 | SRCREV = "${AUTOREV}" 17 | 18 | S = "${WORKDIR}/git/" 19 | B = "${S}/rsmb/src" 20 | 21 | # run make in ${B} 22 | inherit base 23 | 24 | do_install() { 25 | install -d ${D}${bindir} 26 | install -m 0755 ${B}/broker ${D}${bindir}/broker 27 | install -m 0755 ${B}/broker_dbg ${D}${bindir}/broker_dbg 28 | install -m 0755 ${B}/broker_mqtts ${D}${bindir}/broker_mqtts 29 | install ${B}/Messages.1.3.0.2 ${D}${bindir}/Messages.1.3.0.2 30 | } 31 | 32 | INSANE_SKIP_${PN} = "ldflags" 33 | INSANE_SKIP_${PN}-dev = "ldflags" 34 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-connectivity/ntp/files/ntp_wait_synced.sh: -------------------------------------------------------------------------------- 1 | #! /bin/sh 2 | 3 | NTPQ="/usr/sbin/ntpq" 4 | REFTIME_CMD="${NTPQ} -c rv | sed -n '/reftime/ s/reftime=\([^ ]*\) .*/\1/p'" 5 | 6 | reftime() { 7 | ${NTPQ} -c rv | sed -n '/reftime/ s/reftime=\([^ ]*\) .*/\1/p' 8 | } 9 | 10 | wait_synced() { 11 | while [[ "00000000.00000000" == $(reftime) ]] 12 | do 13 | echo 14 | ${NTPQ} -c rv | grep -e reftime -e clock 15 | sleep 15 16 | done 17 | } 18 | 19 | 20 | time wait_synced 21 | 22 | echo 23 | ${NTPQ} -c rv 24 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-connectivity/ntp/ntp_4.2.%.bbappend: -------------------------------------------------------------------------------- 1 | LICENSE = "NTP" 2 | 3 | PR_append = "-iotlab0" 4 | # inspired by: https://github.com/sarnold/meta-alt-desktop-extras/blob/master/recipes-support/ntp/ntp_4.2.6p5.bbappend 5 | 6 | FILESEXTRAPATHS_prepend := "${THISDIR}/files:" 7 | SRC_URI += "file://ntp_wait_synced.sh" 8 | 9 | # Add Configure 10 | do_configure_prepend() { 11 | sed -i \ 12 | -e "s|time.server.example.com|networkgateway|" \ 13 | -e "s|# server|server|" \ 14 | -e "s|^server 127|#server 127|" \ 15 | -e "s|^fudge 127|#fudge 127|" \ 16 | ${WORKDIR}/ntp.conf 17 | } 18 | 19 | # Add ntpq tool 20 | PACKAGES =+ "${PN}-waitsync" 21 | 22 | do_install_append() { 23 | find ${WORKDIR} 24 | install -m 0755 ${WORKDIR}/ntp_wait_synced.sh ${D}/${sbindir}/ 25 | } 26 | 27 | FILES_${PN}-waitsync += "${sbindir}/ntp_wait_synced.sh" 28 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-connectivity/oml2/files/0001-Use-python3-binary.patch: -------------------------------------------------------------------------------- 1 | From 10b81e43ebbeeb417de42ac8ede5bfd94770782e Mon Sep 17 00:00:00 2001 2 | From: root 3 | Date: Thu, 16 Jul 2020 10:20:30 +0200 4 | Subject: [PATCH] Use python3 binary 5 | 6 | --- 7 | test/lib/stddev.py | 2 +- 8 | 1 file changed, 1 insertion(+), 1 deletion(-) 9 | 10 | diff --git a/test/lib/stddev.py b/test/lib/stddev.py 11 | index b814819..fd2be8e 100755 12 | --- a/test/lib/stddev.py 13 | +++ b/test/lib/stddev.py 14 | @@ -1,4 +1,4 @@ 15 | -#!/usr/bin/env python 16 | +#!/usr/bin/env python3 17 | 18 | import math 19 | import sys 20 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-connectivity/oml2/files/0001-configure-use-pkg-config.patch: -------------------------------------------------------------------------------- 1 | From b6c751330553835e0966c835a463efeae7e5cbf4 Mon Sep 17 00:00:00 2001 2 | From: =?UTF-8?q?Ga=C3=ABtan=20Harter?= 3 | Date: Tue, 9 May 2017 17:01:47 +0200 4 | Subject: [PATCH] configure: use pkg-config 5 | 6 | --- 7 | configure.ac | 5 ++++- 8 | 1 file changed, 4 insertions(+), 1 deletion(-) 9 | 10 | diff --git a/configure.ac b/configure.ac 11 | index 7fc1243..d879ca8 100644 12 | --- a/configure.ac 13 | +++ b/configure.ac 14 | @@ -110,7 +110,10 @@ AC_SEARCH_LIBS([xmlParseFile], [xml2], [ 15 | AS_IF([test "$LIBS" != "$oldLIBS"], [AC_SUBST([XML2_LIBS], $ac_res)]) 16 | 17 | AS_IF([test x$cross_compiling = xno], [ 18 | - AC_PATH_PROG([HAVE_XML2CFG], [xml2-config]) 19 | + # Try using 'pkg-config' if available, else check xml2-config 20 | + PKG_CHECK_MODULES([LIBXML], [libxml-2.0], 21 | + [HAVE_XML2CFG="pkg-config libxml-2.0"], 22 | + [AC_PATH_PROG([HAVE_XML2CFG], [xml2-config])]) 23 | AS_IF([test "x$HAVE_XML2CFG" != "x" ], 24 | [ 25 | xxCFLAGS=`$HAVE_XML2CFG --cflags` 26 | -- 27 | 1.9.1 28 | 29 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-connectivity/oml2/files/oml2-2.11.0.tar.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iot-lab/iot-lab-yocto/HEAD/meta-iotlab/recipes-connectivity/oml2/files/oml2-2.11.0.tar.gz -------------------------------------------------------------------------------- /meta-iotlab/recipes-connectivity/oml2/oml2-native_2.11.0.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "oml2 OML is a measurement library that allows to define measurement points inside applications" 2 | 3 | LICENSE = "MIT" 4 | LIC_FILES_CHKSUM ?= "file://${COMMON_LICENSE_DIR}/MIT;md5=0835ade698e0bcf8506ecda2f7b4f302" 5 | 6 | require oml2_${PV}.bb 7 | inherit native 8 | 9 | DEPENDS += "libxml2-native pkgconfig-native gnulib-native python3" 10 | 11 | SRC_URI += "file://0001-configure-use-pkg-config.patch" 12 | 13 | S = "${WORKDIR}/oml2-${PV}" 14 | 15 | # do autogen to apply configure.ac patch 16 | do_configure_prepend() { 17 | cd ${S} 18 | ./autogen.sh 19 | cd ${B} 20 | } 21 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-connectivity/oml2/oml2_2.11.0.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "oml2 OML is a measurement library that allows to define measurement points inside applications" 2 | 3 | LICENSE = "MIT" 4 | LIC_FILES_CHKSUM ?= "file://${COMMON_LICENSE_DIR}/MIT;md5=0835ade698e0bcf8506ecda2f7b4f302" 5 | 6 | PR = "r2" 7 | 8 | DEPENDS += "ruby-native popt libxml2 sqlite3 python3" 9 | RDEPENDS_${PN} += "libxml2 libtool sqlite3" 10 | # oml2-scaffold needed for gateway-code 11 | RDEPENDS_${PN} += "ruby" 12 | 13 | SRC_URI += "file://oml2-2.11.0.tar.gz" 14 | SRC_URI += "file://0001-Use-python3-binary.patch" 15 | 16 | S = "${WORKDIR}/${PN}-${PV}" 17 | 18 | inherit autotools pkgconfig 19 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-connectivity/openssh/openssh_8.%.bbappend: -------------------------------------------------------------------------------- 1 | do_install_append () { 2 | sed -i -e 's:#UseDNS yes:UseDNS no:' ${D}${sysconfdir}/ssh/sshd_config_readonly ${D}${sysconfdir}/ssh/sshd_config 3 | } 4 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-connectivity/wpantund/wpantund_0.07.01.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "wpantund: Wireless Network Interface Daemon for Low-Power Wireless SoCs " 2 | HOMEPAGE = "https://github.com/openthread/wpantund" 3 | 4 | LICENSE = "Apache-2.0" 5 | LIC_FILES_CHKSUM = "file://LICENSE;md5=3b83ef96387f14655fc854ddc3c6bd57" 6 | 7 | DEPENDS += "autoconf-archive-native" 8 | DEPENDS += "dbus readline boost" 9 | 10 | RDEPENDS_${PN} += "dbus readline boost" 11 | 12 | SRC_URI = "git://github.com/openthread/wpantund.git;protocol=https" 13 | # Tag full/0.07.01 based on this commit 14 | SRCREV = "85d5e61b0138b362d02e244e122c8f5aaddafe09" 15 | 16 | S = "${WORKDIR}/git/" 17 | 18 | inherit autotools pkgconfig 19 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/base-config/base-config_0.1.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "Basic configuration for iotlab images" 2 | LICENSE = "CECILL-2.0" 3 | LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/CECILL-2.0;md5=574109ac4bdff61f9c3e0de892ecbd19" 4 | 5 | S = "${WORKDIR}" 6 | 7 | SRC_URI += "file://hosts" 8 | SRC_URI += "file://hostname" 9 | SRC_URI += "file://inputrc" 10 | SRC_URI += "file://bashrc" 11 | SRC_URI += "file://profile" 12 | 13 | do_install () { 14 | # create local conf directory 15 | install -d ${D}${localstatedir}/local/config 16 | install -m 0644 ${S}/hostname ${D}${localstatedir}/local/config/ 17 | 18 | # set hosts default file 19 | # didn't manage to dynamically copy original 'netbase' file 20 | install -d ${D}${sysconfdir}/default 21 | install -m 0644 ${S}/hosts ${D}${sysconfdir}/default/ 22 | 23 | # hostame link 24 | ln -s ${localstatedir}/local/config/hostname ${D}${sysconfdir}/hostname 25 | 26 | install -d ${D}${sysconfdir}/iotlab-config/ 27 | install -m 0755 ${S}/bashrc ${D}${sysconfdir}/iotlab-config/bashrc 28 | install -m 0755 ${S}/profile ${D}${sysconfdir}/iotlab-config/profile 29 | install -m 0600 ${S}/inputrc ${D}${sysconfdir}/iotlab-config/inputrc 30 | } 31 | 32 | pkg_postinst_${PN} () { 33 | install -m 0600 $D${sysconfdir}/iotlab-config/bashrc $D${ROOT_HOME}/.bashrc 34 | install -m 0600 $D${sysconfdir}/iotlab-config/profile $D${ROOT_HOME}/.profile 35 | install -m 0600 $D${sysconfdir}/iotlab-config/inputrc $D${ROOT_HOME}/.inputrc 36 | } 37 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/base-config/files/bashrc: -------------------------------------------------------------------------------- 1 | # ~/.bashrc: executed by bash(1) for non-login shells. 2 | 3 | export PS1='\u@\h:\w\$ ' 4 | umask 022 5 | 6 | # You may uncomment the following lines if you want `ls' to be colorized: 7 | export LS_OPTIONS='--color=auto' 8 | eval `dircolors` 9 | alias ls='ls $LS_OPTIONS' 10 | alias ll='ls $LS_OPTIONS -l' 11 | alias l='ls $LS_OPTIONS -lA' 12 | 13 | # Some more alias to avoid making mistakes: 14 | alias rm='rm -i' 15 | alias cp='cp -i' 16 | alias mv='mv -i' 17 | 18 | # Set locale 19 | export LC_ALL=en_US.UTF-8 20 | export LANG=en_US.UTF-8 21 | export LANGUAGE=en_US.UTF-8 22 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/base-config/files/hostname: -------------------------------------------------------------------------------- 1 | iotlab-board 2 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/base-config/files/hosts: -------------------------------------------------------------------------------- 1 | 127.0.0.1 localhost.localdomain localhost 2 | 3 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/base-config/files/inputrc: -------------------------------------------------------------------------------- 1 | "\e[1;5C": forward-word 2 | "\e[1;5D": backward-word 3 | "\e[5C": forward-word 4 | "\e[5D": backward-word 5 | "\e\e[C": forward-word 6 | "\e\e[D": backward-word 7 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/base-config/files/profile: -------------------------------------------------------------------------------- 1 | # ~/.profile: executed by Bourne-compatible login shells. 2 | 3 | if [ -f ~/.bashrc ]; then 4 | . ~/.bashrc 5 | fi 6 | 7 | # path set by /etc/profile 8 | # export PATH 9 | 10 | mesg n 11 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/base-files/base-files_3.0.14.bbappend: -------------------------------------------------------------------------------- 1 | PR_append = "-v0" 2 | FILESEXTRAPATHS_prepend := "${THISDIR}/files:" 3 | SRC_URI += "file://etc_hosts" 4 | 5 | # base-files should not create 'hostname' file 6 | # it will be created by iotlab-base-config 7 | hostname = "" 8 | 9 | # Make '/etc/hosts' volatile 10 | 11 | do_install_append() { 12 | rm ${D}${sysconfdir}/hosts 13 | 14 | install -d ${D}${sysconfdir}/default/volatiles 15 | install -m 0644 ${WORKDIR}/etc_hosts ${D}${sysconfdir}/default/volatiles/10_etc_hosts 16 | } 17 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/base-files/files/etc_hosts: -------------------------------------------------------------------------------- 1 | # /etc/hosts should be separated between nodes 2 | l root root 0644 /etc/hosts /var/run/hosts 3 | f root root 0644 /var/run/hosts none 4 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/icedtea/icedtea7-native_%.bbappend: -------------------------------------------------------------------------------- 1 | # GCC 6.3 invalid option 2 | CFLAGS_remove = "-Wno-error=stringop-overflow" 3 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/images/iotlab-image-gateway-rpi2.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "IoT-LAB image for RPI2 gateway" 2 | include iotlab-image.inc 3 | 4 | # Include modules in rootfs 5 | IMAGE_INSTALL += " \ 6 | kernel-modules \ 7 | gateway-packagegroup \ 8 | mjpg-streamer \ 9 | sudo \ 10 | rtl-sdr \ 11 | ykush \ 12 | linux-firmware-bcm43430 \ 13 | linux-firmware-rtl8192cu \ 14 | lldpd \ 15 | " 16 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/images/iotlab-image-gateway-rpi3.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "IoT-LAB image for RPI3 gateways" 2 | include iotlab-image.inc 3 | 4 | # Include modules in rootfs 5 | IMAGE_INSTALL += " \ 6 | kernel-modules \ 7 | gateway-packagegroup \ 8 | mjpg-streamer \ 9 | sudo \ 10 | rtl-sdr \ 11 | ykush \ 12 | lora-gateway-utils \ 13 | lora-packet-forwarder \ 14 | lora-gateway-bridge \ 15 | mosquitto \ 16 | uhubctl \ 17 | " 18 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/images/iotlab-image-gateway-rpi4.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "IoT-LAB image for RPI4 used by users" 2 | include iotlab-image.inc 3 | 4 | # Include modules in rootfs 5 | IMAGE_INSTALL += " \ 6 | kernel-modules \ 7 | gateway-packagegroup \ 8 | mjpg-streamer \ 9 | sudo \ 10 | rtl-sdr \ 11 | ykush \ 12 | " 13 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/images/iotlab-image-gateway.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "IoT-LAB image for Gateways" 2 | include iotlab-image.inc 3 | 4 | IMAGE_INSTALL += " \ 5 | libubootenv \ 6 | gateway-packagegroup \ 7 | " 8 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/images/iotlab-image-open-a8-autotest.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "IoT-LAB image for Open A8 autotest" 2 | include iotlab-image.inc 3 | 4 | EXTRA_IMAGE_FEATURES += "debug-tweaks" 5 | 6 | IMAGE_INSTALL += "linux-node-packagegroup" 7 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/images/iotlab-image-open-a8.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "IoT-LAB image for Open A8 used by users" 2 | include iotlab-image.inc 3 | 4 | IMAGE_INSTALL += " \ 5 | libubootenv \ 6 | linux-node-packagegroup \ 7 | flash-scripts-open-a8 \ 8 | " 9 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/images/iotlab-image-rpi2-autotest.bb: -------------------------------------------------------------------------------- 1 | include iotlab-image.inc 2 | 3 | EXTRA_IMAGE_FEATURES += "debug-tweaks" 4 | 5 | # Include modules in rootfs 6 | IMAGE_INSTALL += " \ 7 | kernel-modules \ 8 | linux-node-packagegroup \ 9 | linux-firmware-bcm43430 \ 10 | linux-firmware-rtl8192cu \ 11 | " 12 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/images/iotlab-image-rpi2.bb: -------------------------------------------------------------------------------- 1 | include iotlab-image.inc 2 | 3 | # Include modules in rootfs 4 | IMAGE_INSTALL += " \ 5 | kernel-modules \ 6 | linux-node-packagegroup \ 7 | linux-firmware-bcm43430 \ 8 | linux-firmware-rtl8192cu \ 9 | " 10 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/images/iotlab-image-rpi3-autotest.bb: -------------------------------------------------------------------------------- 1 | include iotlab-image.inc 2 | 3 | EXTRA_IMAGE_FEATURES += "debug-tweaks" 4 | 5 | # Include modules in rootfs 6 | IMAGE_INSTALL += " \ 7 | kernel-modules \ 8 | linux-node-packagegroup \ 9 | " 10 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/images/iotlab-image-rpi3.bb: -------------------------------------------------------------------------------- 1 | include iotlab-image.inc 2 | 3 | # Include modules in rootfs 4 | IMAGE_INSTALL += " \ 5 | kernel-modules \ 6 | linux-node-packagegroup \ 7 | " 8 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/images/iotlab-image-rpi4-autotest.bb: -------------------------------------------------------------------------------- 1 | include iotlab-image.inc 2 | 3 | EXTRA_IMAGE_FEATURES += "debug-tweaks" 4 | 5 | # Include modules in rootfs 6 | IMAGE_INSTALL += " \ 7 | kernel-modules \ 8 | linux-node-packagegroup \ 9 | " 10 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/images/iotlab-image-rpi4.bb: -------------------------------------------------------------------------------- 1 | include iotlab-image.inc 2 | 3 | # Include modules in rootfs 4 | IMAGE_INSTALL += " \ 5 | kernel-modules \ 6 | linux-node-packagegroup \ 7 | " 8 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/images/iotlab-image.inc: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "IoT-LAB base image, supports target devices" 2 | LICENSE = "GPLv2" 3 | inherit core-image 4 | 5 | 6 | IMAGE_FEATURES += " \ 7 | ssh-server-openssh \ 8 | package-management \ 9 | tools-sdk \ 10 | tools-debug \ 11 | read-only-rootfs \ 12 | " 13 | 14 | re_add_rw_to_rootfs() { 15 | # revert 'ro' modification done by core-image by calling 16 | # oe-core/meta/classes/image.bbclass 17 | # 18 | # we want 'read-only-rootfs' for not writing in shared nfs directories 19 | # but not readonly filesystem 20 | sed -i -e '/^[#[:space:]]*\/dev\/root/{s/ ro / defaults /}' ${IMAGE_ROOTFS}/etc/fstab 21 | 22 | # move opkg status files to an nfs shared folder 23 | mkdir -p ${IMAGE_ROOTFS}/var/lib_nfs_shared/ 24 | mv ${IMAGE_ROOTFS}/var/lib/opkg ${IMAGE_ROOTFS}/var/lib_nfs_shared/ 25 | # ln should be relative to work on rootfs command 26 | ln -s ../lib_nfs_shared/opkg ${IMAGE_ROOTFS}/var/lib/opkg 27 | 28 | } 29 | # do it after inheriting core-image 30 | ROOTFS_POSTPROCESS_COMMAND += "re_add_rw_to_rootfs; " 31 | 32 | ROOTFS_RO_UNNEEDED = "${VIRTUAL-RUNTIME_update-alternatives} ${ROOTFS_BOOTSTRAP_INSTALL}" 33 | 34 | DISTRO_FEATURES += "nfs ipv6" 35 | DISTRO_FEATURES_remove += "ptest" 36 | 37 | IMAGE_INSTALL +=" \ 38 | tzdata \ 39 | cronie \ 40 | logrotate \ 41 | tmux \ 42 | screen \ 43 | iptables \ 44 | iproute2 \ 45 | socat \ 46 | iputils \ 47 | rsync \ 48 | ntp \ 49 | ntp-waitsync \ 50 | ntp-utils \ 51 | python3 \ 52 | python3-dev \ 53 | python3-misc \ 54 | python3-modules \ 55 | python3-pip \ 56 | python3-magic \ 57 | python3-setuptools \ 58 | vim \ 59 | " 60 | 61 | IMAGE_INSTALL +=" \ 62 | base-files \ 63 | i2c-tools \ 64 | coreutils \ 65 | tzdata-europe \ 66 | rsyslog \ 67 | dhcp-client \ 68 | usbutils \ 69 | " 70 | 71 | # pour le super ps 72 | IMAGE_INSTALL +=" \ 73 | gawk \ 74 | findutils \ 75 | curl \ 76 | wget \ 77 | lsof \ 78 | procps \ 79 | htop \ 80 | " 81 | 82 | IMAGE_INSTALL += " \ 83 | mtd-utils \ 84 | \ 85 | cmake \ 86 | flex \ 87 | bison \ 88 | \ 89 | git \ 90 | git-perltools \ 91 | \ 92 | \ 93 | \ 94 | htop \ 95 | \ 96 | gcov \ 97 | gcov-symlinks \ 98 | \ 99 | \ 100 | tcpdump \ 101 | \ 102 | valgrind \ 103 | \ 104 | " 105 | 106 | IMAGE_INSTALL += " \ 107 | bash \ 108 | bind-utils \ 109 | oml2-dev \ 110 | jansson \ 111 | jansson-dev \ 112 | c-ares \ 113 | c-ares-dev \ 114 | libev \ 115 | libev-dev \ 116 | libevent \ 117 | libevent-dev \ 118 | boost \ 119 | boost-dev \ 120 | jemalloc \ 121 | jemalloc-dev \ 122 | cunit \ 123 | cunit-dev \ 124 | openssl \ 125 | openssl-dev \ 126 | \ 127 | \ 128 | \ 129 | nfs-utils-client \ 130 | \ 131 | openssh-ssh \ 132 | openssh-scp \ 133 | openssh-sftp-server \ 134 | \ 135 | curl \ 136 | \ 137 | " 138 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/initrdscripts/files/gateway/gateway-server-network: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | # Startup script for setup network configuration of Open Nodes 4 | # configured on the gateway 5 | 6 | NAME=gateway-server-network 7 | 8 | : ${CONFDIR:="/var/local/config"} 9 | 10 | network_control() { 11 | local command=$1 12 | local bind_ip=$2 13 | 14 | case "${command}" in 15 | start) 16 | echo "Adding ${bind_ip} address ... " 17 | ip addr add ${bind_ip}/21 brd + dev eth0 18 | ;; 19 | stop) 20 | echo "Deleting ${bind_ip} address ... " 21 | ip addr del ${bind_ip}/21 dev eth0 22 | ;; 23 | restart) 24 | $0 stop 25 | sleep 2 26 | $0 start 27 | ;; 28 | *) 29 | echo "Usage: /etc/init.d/${NAME} {start|stop|restart}" 30 | exit 1 31 | ;; 32 | esac 33 | } 34 | 35 | get_primary_ip() { 36 | primary_ip=$(ip -4 addr show eth0 | grep -v "secondary" | grep -Po '(?<=inet )[\d.]+') 37 | } 38 | 39 | main() { 40 | # Exit if only one Open Node is configured on the gateway 41 | if [ -f "${CONFDIR}/board_type" ]; then exit 0; fi 42 | get_primary_ip 43 | for on_conf_path in $(find ${CONFDIR} -mindepth 1 -type d | sort) 44 | do 45 | local ip_file="${on_conf_path}"/ip 46 | if [ -f "${ip_file}" ] 47 | then 48 | local bind_ip=$(cat "${ip_file}") 49 | if [ "${bind_ip}" != "${primary_ip}" ] 50 | then 51 | network_control "$1" "${bind_ip}" 52 | fi 53 | fi 54 | done 55 | } 56 | 57 | COMMAND="$1" 58 | shift # pop $1 from $@ 59 | 60 | main ${COMMAND} 61 | 62 | exit 0 63 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/initrdscripts/files/gateway/nfs_mount_conf_users: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | 4 | DESC="Gateway node nfs mount conf and users homedir" 5 | NAME=iotlab_nfs_conf_users 6 | RUNNING=/var/run/${NAME} 7 | 8 | SERVER_IP='nfsserver' 9 | IP_ADDR=$(ip addr show dev eth0 | sed -n '/inet/ s/ *inet \([\.0-9]*\).*/\1/p') 10 | 11 | # configuration 12 | BASE_PATH="/iotlab/images/${IP_ADDR}" 13 | MOUNT_OPTIONS="rw,relatime,vers=3,rsize=131072,wsize=131072,namlen=255,hard,nolock,proto=tcp,timeo=600,retrans=2,mountvers=3" 14 | #MOUNT_OPTIONS="mountaddr=${SERVER_IP},rw,relatime,vers=3,rsize=131072,wsize=131072,namlen=255,hard,nolock,proto=tcp,timeo=600,retrans=2,sec=sys,mountvers=3,mountproto=tcp,local_lock=all" 15 | 16 | case "$1" in 17 | start) 18 | echo "Starting $DESC ... " 19 | if [ -e $RUNNING ]; then 20 | echo "$0 already mounted" 21 | exit 1 22 | fi 23 | 24 | mount -n -t nfs -o "$MOUNT_OPTIONS" "$SERVER_IP":${BASE_PATH}/conf /var/local/config/ 25 | mount -n -t nfs -o "$MOUNT_OPTIONS" "$SERVER_IP":/iotlab/users /iotlab/users 26 | hostname $(cat /etc/hostname) 27 | ;; 28 | stop) 29 | echo "Stopping $DESC ... " 30 | umount /var/local/config/ 31 | umount /iotlab/users 32 | 33 | rm -f $RUNNING 34 | ;; 35 | restart) 36 | echo -n "Restarting $DESC ... " 37 | $0 stop 38 | sleep 5 39 | $0 start 40 | ;; 41 | *) 42 | echo "Usage: /etc/init.d/$0 {start|stop|restart}" 43 | exit 1 44 | ;; 45 | esac 46 | 47 | exit 0 48 | 49 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/initrdscripts/files/linux-node/flash_idle: -------------------------------------------------------------------------------- 1 | #! /bin/sh 2 | ### BEGIN INIT INFO 3 | # Provides: flash_idle_on_boot 4 | # Required-Start: $local_fs $time $named 5 | # Required-Stop: $local_fs $time $named 6 | # Default-Start: 7 | # Default-Stop: 8 | # Short-Description: Flash idle firmware on linux open node boot 9 | ### END INIT INFO 10 | 11 | PATH=/bin:/usr/bin:/usr/local/bin 12 | NAME=flash_idle 13 | 14 | # flash open node with an idle firmware 15 | FW=idle /usr/bin/iotlab_flash 16 | exit $? 17 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/initrdscripts/files/linux-node/ipv6.profile: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | # Put in /etc/profile.d/ 4 | IPV6_CONFIG="/var/local/config/ipv6" 5 | 6 | if [ -f ${IPV6_CONFIG} ]; then 7 | source ${IPV6_CONFIG} 8 | fi 9 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/initrdscripts/files/linux-node/networking_ipv6: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | DESC="Open A8 IPv6 configuration" 4 | NAME=iotlab_ipv6_setup 5 | RUNNING=/var/run/${NAME} 6 | 7 | IPV6_CFG="/var/local/config/ipv6" 8 | 9 | 10 | if [ ! -f "${IPV6_CFG}" ] 11 | then 12 | echo "${DESC}: No IPv6 config found in ${IPV6_CFG}" >&2 13 | exit 0 14 | fi 15 | source ${IPV6_CFG} 16 | 17 | 18 | case "$1" in 19 | start) 20 | echo "Starting $DESC ... " 21 | if [ -e $RUNNING ]; then 22 | echo "$0 already configured" 23 | exit 1 24 | fi 25 | touch $RUNNING 26 | ip -6 addr add ${INET6_ADDR} dev eth0 27 | ip -6 route add default via ${GATEWAY6_ADDR} 28 | ;; 29 | stop) 30 | echo "Stopping $DESC ... " 31 | ip -6 route del default via ${GATEWAY6_ADDR} 32 | ip -6 addr del ${INET6_ADDR} dev eth0 33 | rm -f $RUNNING 34 | ;; 35 | restart) 36 | echo "Restarting $DESC ... " 37 | $0 stop 38 | sleep 5 39 | $0 start 40 | ;; 41 | *) 42 | echo "Usage: /etc/init.d/$0 {start|stop|restart}" 43 | exit 1 44 | ;; 45 | esac 46 | 47 | exit 0 48 | 49 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/initrdscripts/files/linux-node/nfs_mount_conf_shared: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | 4 | DESC="Linux node nfs mount conf and shared directory" 5 | NAME=nfs_mount_conf_shared 6 | RUNNING=/var/run/${NAME} 7 | 8 | SERVER_IP='nfsserver' 9 | IP_ADDR=$(ip addr show dev eth0 | sed -n '/inet/ s/ *inet \([\.0-9]*\).*/\1/p') 10 | 11 | # configuration 12 | BASE_PATH="/iotlab/images/${IP_ADDR}" 13 | MOUNT_OPTIONS="rw,relatime,vers=3,rsize=131072,wsize=131072,namlen=255,hard,nolock,proto=tcp,timeo=600,retrans=2,mountvers=3" 14 | #MOUNT_OPTIONS="mountaddr=${SERVER_IP},rw,relatime,vers=3,rsize=131072,wsize=131072,namlen=255,hard,nolock,proto=tcp,timeo=600,retrans=2,sec=sys,mountvers=3,mountproto=tcp,local_lock=all" 15 | 16 | 17 | case "$1" in 18 | start) 19 | echo "Starting $DESC ... " 20 | if [ -e $RUNNING ]; then 21 | echo "$0 already mounted" 22 | exit 1 23 | fi 24 | 25 | mount -n -t nfs -o "$MOUNT_OPTIONS" "$SERVER_IP":${BASE_PATH}/conf /var/local/config/ 26 | mount -n -t nfs -o "$MOUNT_OPTIONS" "$SERVER_IP":${BASE_PATH}/shared /home/root/shared 27 | 28 | hostname $(cat /etc/hostname) 29 | ;; 30 | stop) 31 | echo "Stopping $DESC ... " 32 | umount /var/local/config/ 33 | umount /home/root/shared 34 | 35 | rm -f $RUNNING 36 | ;; 37 | restart) 38 | echo -n "Restarting $DESC ... " 39 | $0 stop 40 | sleep 5 41 | $0 start 42 | ;; 43 | *) 44 | echo "Usage: /etc/init.d/$0 {start|stop|restart}" 45 | exit 1 46 | ;; 47 | esac 48 | 49 | exit 0 50 | 51 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/initrdscripts/files/linux-node/serial_redirection: -------------------------------------------------------------------------------- 1 | #! /bin/sh 2 | ### BEGIN INIT INFO 3 | # Provides: serial_redirection 4 | # Required-Start: $local_fs $time $network $named 5 | # Required-Stop: $local_fs $time $network $named 6 | # Default-Start: 7 | # Default-Stop: 8 | # Short-Description: Start/stop serial_redirection 9 | # Description: The serial_redirection init script will start/stop socat to 10 | # redirect serial port to a tcp socket on port 20000 11 | ### END INIT INFO 12 | 13 | NAME=serial_redirection 14 | DAEMON=/usr/bin/${NAME} 15 | PIDFILE=/var/run/${NAME}.pid 16 | 17 | PATH=/bin:/usr/bin:/sbin:/usr/sbin 18 | 19 | . /etc/init.d/functions 20 | 21 | [ -x $DAEMON ] || exit 0 22 | 23 | start_redirection() { 24 | start-stop-daemon --start \ 25 | --pidfile ${PIDFILE} \ 26 | --background --make-pidfile \ 27 | --exec $DAEMON 28 | } 29 | 30 | stop_redirection() { 31 | start-stop-daemon --stop --pidfile ${PIDFILE} 32 | rm -f ${PIDFILE} 33 | } 34 | 35 | start () { 36 | echo -n "Starting ${NAME}: " 37 | start_redirection 38 | echo $? 39 | return $? 40 | } 41 | 42 | stop () { 43 | echo -n "Stopping ${NAME}: " 44 | for PIDFILE in `ls ${PIDFILE} 2> /dev/null`; do 45 | NAME=`echo $PIDFILE | cut -c16-` 46 | NAME=${NAME%%.pid} 47 | stop_redirection 48 | done 49 | echo $? 50 | } 51 | 52 | case "$1" in 53 | start) 54 | start 55 | ;; 56 | stop) 57 | stop 58 | ;; 59 | restart) 60 | stop 61 | start 62 | ;; 63 | status) 64 | status $DAEMON 65 | exit $? 66 | ;; 67 | *) 68 | echo "Usage: /etc/init.d/$NAME {start|stop|restart|status}" 69 | exit 3 70 | ;; 71 | esac 72 | 73 | exit 0 74 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/initrdscripts/files/set_default_values_to_volatile.sh: -------------------------------------------------------------------------------- 1 | #! /bin/sh 2 | 3 | # set default values to /var/run/ files 4 | 5 | # 6 | # /etc/resolv.conf 7 | # 8 | grep -e "nameserver" -e "domain" /proc/net/pnp >> /var/run/resolv.conf 9 | 10 | # 11 | # /etc/hosts 12 | # 13 | NFS_SERVER_IP=$(grep -oE "([0-9]{1,3}\.){3}[0-9]{1,3}" /proc/net/nfsfs/servers) 14 | NETWORK_GATEWAY=$(ip route show dev eth0 | sed -n '/default/ {s/.*via //;s/ dev.*//;p}') 15 | # copy default and add other entries 16 | cp /etc/default/hosts /var/run/hosts 17 | echo "$NFS_SERVER_IP nfsserver" >> /var/run/hosts 18 | echo "$NETWORK_GATEWAY networkgateway" >> /var/run/hosts 19 | 20 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/initrdscripts/files/set_time.sh: -------------------------------------------------------------------------------- 1 | #! /bin/sh 2 | 3 | DESC="NTP set_time.sh" 4 | NAME=set_time.sh 5 | 6 | set -x 7 | 8 | date 9 | timeout 30 /usr/sbin/ntpd -g -q -d 10 | date 11 | /etc/init.d/hwclock.sh reload 12 | date 13 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/initrdscripts/initrdscripts_0.1.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "Initscripts provide the basic system startup initialization scripts for the system" 2 | LICENSE = "CECILL-2.0" 3 | LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/CECILL-2.0;md5=574109ac4bdff61f9c3e0de892ecbd19" 4 | 5 | S = "${WORKDIR}" 6 | 7 | FILESEXTRAPATHS_prepend = "${THISDIR}/files/linux-node/:" 8 | FILESEXTRAPATHS_prepend = "${THISDIR}/files/gateway/:" 9 | SRC_URI += "file://set_default_values_to_volatile.sh" 10 | SRC_URI += "file://set_time.sh" 11 | SRC_URI += "file://networking_ipv6" 12 | SRC_URI += "file://ipv6.profile" 13 | SRC_URI += "file://flash_idle" 14 | SRC_URI += "file://nfs_mount_conf_shared" 15 | SRC_URI += "file://nfs_mount_conf_users" 16 | SRC_URI += "file://gateway-server-network" 17 | SRC_URI += "file://serial_redirection" 18 | 19 | # split package to use update-rc.d class 20 | ALLOW_EMPTY_${PN} = "1" 21 | 22 | RDEPENDS_${PN} = "${PN}-settime ${PN}-volatile ${PN}-ipv6 ${PN}-flashidle ${PN}-mountnode ${PN}-mountgw ${PN}-networkgw ${PN}-serial" 23 | PACKAGES =+ "${PN}-settime ${PN}-volatile ${PN}-ipv6 ${PN}-flashidle ${PN}-mountnode ${PN}-mountgw ${PN}-networkgw ${PN}-serial" 24 | 25 | inherit update-rc.d 26 | INITSCRIPT_PACKAGES = "${PN}-settime ${PN}-volatile ${PN}-ipv6 ${PN}-flashidle ${PN}-mountnode ${PN}-mountgw ${PN}-networkgw" 27 | 28 | INITSCRIPT_NAME_${PN}-volatile = "set_default_values_to_volatile.sh" 29 | INITSCRIPT_PARAMS_${PN}-volatile = "start 80 S ." 30 | FILES_${PN}-volatile = "${sysconfdir}/init.d/set_default_values_to_volatile.sh" 31 | 32 | # requires /etc/hosts to be configured by set_default_values 33 | RDEPENDS_${PN}-settime += "coreutils" 34 | INITSCRIPT_NAME_${PN}-settime = "set_time.sh" 35 | INITSCRIPT_PARAMS_${PN}-settime = "start 81 S ." 36 | FILES_${PN}-settime = "${sysconfdir}/init.d/set_time.sh" 37 | 38 | INITSCRIPT_NAME_${PN}-mountnode = "nfs_mount_conf_shared" 39 | INITSCRIPT_PARAMS_${PN}-mountnode = "defaults 82 18" 40 | FILES_${PN}-mountnode = "${sysconfdir}/init.d/nfs_mount_conf_shared" 41 | 42 | INITSCRIPT_NAME_${PN}-mountgw = "nfs_mount_conf_users" 43 | INITSCRIPT_PARAMS_${PN}-mountgw = "defaults 82 18" 44 | FILES_${PN}-mountgw += "${sysconfdir}/init.d/nfs_mount_conf_users" 45 | FILES_${PN}-mountgw += "/iotlab/users" 46 | 47 | # start AFTER nfs mount (check eth0 ip to mount nfs directory) 48 | 49 | INITSCRIPT_NAME_${PN}-networkgw = "gateway-server-network" 50 | INITSCRIPT_PARAMS_${PN}-networkgw = "defaults 83 17" 51 | FILES_${PN}-networkgw += "${sysconfdir}/init.d/gateway-server-network" 52 | 53 | INITSCRIPT_NAME_${PN}-ipv6 = "networking_ipv6" 54 | INITSCRIPT_PARAMS_${PN}-ipv6 = "defaults 84 16" 55 | FILES_${PN}-ipv6 += "${sysconfdir}/init.d/networking_ipv6" 56 | FILES_${PN}-ipv6 += "${sysconfdir}/profile.d/ipv6.sh" 57 | 58 | # don't start by default by update-rc.d 59 | RDEPENDS_${PN}-serial += "gateway-code" 60 | FILES_${PN}-serial = "${sysconfdir}/init.d/serial_redirection" 61 | 62 | # don't try to check elf files 63 | INHIBIT_PACKAGE_STRIP = "1" 64 | INHIBIT_PACKAGE_DEBUG_STRIP = "1" 65 | INHIBIT_PACKAGE_DEBUG_SPLIT = "1" 66 | INHIBIT_SYSROOT_STRIP = "1" 67 | INSANE_SKIP_${PN}-flashidle += "arch" 68 | INSANE_SKIP_${PN}-flashidle-dbg += "arch" 69 | 70 | RDEPENDS_${PN}-flashidle += "gateway-code" 71 | INITSCRIPT_NAME_${PN}-flashidle = "flash_idle" 72 | INITSCRIPT_PARAMS_${PN}-flashidle = "start 85 S ." 73 | FILES_${PN}-flashidle += "${sysconfdir}/init.d/flash_idle" 74 | 75 | # release files 76 | do_install() { 77 | install -d ${D}/${sysconfdir}/init.d 78 | 79 | # set time 80 | install -m 0755 ${S}/set_time.sh ${D}/${sysconfdir}/init.d/ 81 | 82 | # volatile 83 | install -m 0755 ${S}/set_default_values_to_volatile.sh ${D}/${sysconfdir}/init.d/ 84 | 85 | # ipv6 network 86 | install -m 0755 ${S}/networking_ipv6 ${D}/${sysconfdir}/init.d/ 87 | install -d ${D}/${sysconfdir}/profile.d 88 | install -m 0755 ${S}/ipv6.profile ${D}/${sysconfdir}/profile.d/ipv6.sh 89 | 90 | # flash idle 91 | install -m 0755 ${S}/flash_idle ${D}/${sysconfdir}/init.d/ 92 | 93 | # mount gateway 94 | install -m 0755 ${S}/nfs_mount_conf_users ${D}/${sysconfdir}/init.d/ 95 | install -d ${D}/iotlab/users 96 | 97 | # mount linux node 98 | install -m 0755 ${S}/nfs_mount_conf_shared ${D}/${sysconfdir}/init.d/ 99 | 100 | # gateway-server network (virtual ip for open nodes) 101 | install -m 0755 ${S}/gateway-server-network ${D}/${sysconfdir}/init.d/ 102 | 103 | # serial redirection 104 | install -m 0755 ${S}/serial_redirection ${D}/${sysconfdir}/init.d/ 105 | } 106 | 107 | pkg_postinst_${PN}-mountnode() { 108 | install -m 0755 -d $D${ROOT_HOME}/shared 109 | # add A8 symlink to shared directory (eg. A8 Open node backward compatibility) 110 | ln -s -r $D${ROOT_HOME}/shared $D${ROOT_HOME}/A8 111 | } 112 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/initscripts/files/checkroot.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | ### BEGIN INIT INFO 3 | # Provides: checkroot 4 | # Required-Start: udev 5 | # Required-Stop: 6 | # Default-Start: S 7 | # Default-Stop: 8 | # Short-Description: Check to root file system. 9 | ### END INIT INFO 10 | 11 | . /etc/default/rcS 12 | 13 | # 14 | # Set SULOGIN in /etc/default/rcS to yes if you want a sulogin to be spawned 15 | # from this script *before anything else* with a timeout, like SCO does. 16 | # 17 | test "$SULOGIN" = yes && sulogin -t 30 $CONSOLE 18 | 19 | # 20 | # Read /etc/fstab. 21 | # 22 | exec 9< /etc/fstab 23 | rootmode=rw 24 | rootopts=rw 25 | rootcheck=$ENABLE_ROOTFS_FSCK 26 | swap_on_md=no 27 | devfs= 28 | while read fs mnt type opts dump pass junk <&9 29 | do 30 | case "$fs" in 31 | ""|\#*) 32 | continue; 33 | ;; 34 | /dev/md*) 35 | # Swap on md device. 36 | test "$type" = swap && swap_on_md=yes 37 | ;; 38 | /dev/*) 39 | ;; 40 | *) 41 | # Might be a swapfile. 42 | test "$type" = swap && swap_on_md=yes 43 | ;; 44 | esac 45 | test "$type" = devfs && devfs="$fs" 46 | test "$mnt" != / && continue 47 | rootopts="$opts" 48 | test "$pass" = 0 -o "$pass" = "" && rootcheck=no 49 | case "$opts" in 50 | ro|ro,*|*,ro|*,ro,*) 51 | rootmode=ro 52 | ;; 53 | esac 54 | done 55 | exec 0>&9 9>&- 56 | 57 | # Check for conflicting configurations 58 | if [ "$rootmode" = "ro" -a "$ROOTFS_READ_ONLY" = "no" ] || \ 59 | [ "$rootmode" = "rw" -a "$ROOTFS_READ_ONLY" = "yes" ]; then 60 | echo "" 61 | echo "Running 'read-only-rootfs' with 'rw' root." 62 | echo "It is to handle the 'nfs shared filesystem' problems." 63 | echo "" 64 | fi 65 | 66 | 67 | # 68 | # Activate the swap device(s) in /etc/fstab. This needs to be done 69 | # before fsck, since fsck can be quite memory-hungry. 70 | # 71 | test "$VERBOSE" != no && echo "Activating swap" 72 | swapon -a 2> /dev/null 73 | 74 | # 75 | # Check the root filesystem. 76 | # 77 | if test -f /fastboot || test $rootcheck = no 78 | then 79 | test $rootcheck = yes && echo "Fast boot, no filesystem check" 80 | else 81 | # 82 | # Ensure that root is quiescent and read-only before fsck'ing. 83 | # 84 | mount -n -o remount,ro / 85 | if test $? = 0 86 | then 87 | if test -f /forcefsck 88 | then 89 | force="-f" 90 | else 91 | force="" 92 | fi 93 | if test "$FSCKFIX" = yes 94 | then 95 | fix="-y" 96 | else 97 | fix="-a" 98 | fi 99 | spinner="-C" 100 | case "$TERM" in 101 | dumb|network|unknown|"") spinner="" ;; 102 | esac 103 | test `uname -m` = s390 && spinner="" # This should go away 104 | test "$VERBOSE" != no && echo "Checking root filesystem..." 105 | fsck $spinner $force $fix / 106 | # 107 | # If there was a failure, drop into single-user mode. 108 | # 109 | # NOTE: "failure" is defined as exiting with a return code of 110 | # 2 or larger. A return code of 1 indicates that filesystem 111 | # errors were corrected but that the boot may proceed. 112 | # 113 | if test "$?" -gt 1 114 | then 115 | # Surprise! Re-directing from a HERE document (as in 116 | # "cat << EOF") won't work, because the root is read-only. 117 | echo 118 | echo "fsck failed. Please repair manually and reboot. Please note" 119 | echo "that the root filesystem is currently mounted read-only. To" 120 | echo "remount it read-write:" 121 | echo 122 | echo " # mount -n -o remount,rw /" 123 | echo 124 | echo "CONTROL-D will exit from this shell and REBOOT the system." 125 | echo 126 | # Start a single user shell on the console 127 | /sbin/sulogin $CONSOLE 128 | reboot -f 129 | fi 130 | else 131 | echo "*** ERROR! Cannot fsck root fs because it is not mounted read-only!" 132 | echo 133 | fi 134 | fi 135 | 136 | # 137 | # If the root filesystem was not marked as read-only in /etc/fstab, 138 | # remount the rootfs rw but do not try to change mtab because it 139 | # is on a ro fs until the remount succeeded. Then clean up old mtabs 140 | # and finally write the new mtab. 141 | # 142 | mount -n -o remount,$rootmode / 143 | if test "$rootmode" = rw 144 | then 145 | ln -sf /proc/mounts /dev/mtab 146 | fi 147 | 148 | : exit 0 149 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/initscripts/files/read-only-rootfs-hook.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | . /etc/default/rcS 4 | 5 | [ "$ROOTFS_READ_ONLY" = "no" ] && exit 0 6 | 7 | is_on_read_only_partition () { 8 | echo "yes" 9 | } 10 | 11 | if [ "$1" = "start" ] ; then 12 | if [ `is_on_read_only_partition /var/lib` = "yes" ]; then 13 | grep -q "tmpfs /var/volatile" /proc/mounts || mount /var/volatile 14 | mkdir -p /var/volatile/lib 15 | cp -a /var/lib/* /var/volatile/lib 16 | mount --bind /var/volatile/lib /var/lib 17 | fi 18 | fi 19 | 20 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/initscripts/initscripts_1.0.bbappend: -------------------------------------------------------------------------------- 1 | # tag to identify a recipe as an extension of another recipe 2 | PR_append = "-v0" 3 | 4 | # checkroot.sh and read-only-rootfs-hook.sh scripts are loaded from here 5 | # and not from original initscripts recipe 6 | FILESEXTRAPATHS_prepend := "${THISDIR}/files:" 7 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/packagegroups/base-packagegroup.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "default package group list for images" 2 | LICENSE = "GPLv2" 3 | 4 | inherit packagegroup 5 | 6 | RDEPENDS_${PN} += " \ 7 | avarice \ 8 | avrdude \ 9 | base-files \ 10 | base-config \ 11 | initrdscripts-settime \ 12 | initrdscripts-volatile \ 13 | openocd \ 14 | openocd-git \ 15 | openocd-ti \ 16 | python3-pyserial \ 17 | python3-intelhex \ 18 | python3-cc2538-bsl \ 19 | python3-pyocd \ 20 | edbg \ 21 | pycom-utils \ 22 | segger-jlink \ 23 | " 24 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/packagegroups/gateway-packagegroup.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "Package group list for gateway image" 2 | LICENSE = "GPLv2" 3 | 4 | inherit packagegroup 5 | 6 | RDEPENDS_${PN} += " \ 7 | base-packagegroup \ 8 | gateway-code \ 9 | gateway-code-server \ 10 | ftdi-utils \ 11 | initrdscripts-mountgw \ 12 | initrdscripts-networkgw \ 13 | sshd-keys-gw \ 14 | " 15 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/packagegroups/linux-node-packagegroup.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "Package group list for open A8 image" 2 | LICENSE = "GPLv2" 3 | 4 | inherit packagegroup 5 | 6 | # gateway-code-standalone 7 | RDEPENDS_${PN} += " \ 8 | base-packagegroup \ 9 | gateway-code \ 10 | sshd-keys-linux-node \ 11 | ftdi-utils-list \ 12 | initrdscripts-mountnode \ 13 | initrdscripts-ipv6 \ 14 | initrdscripts-flashidle \ 15 | initrdscripts-serial \ 16 | " 17 | 18 | # OpenWSN python package dependencies 19 | RDEPENDS_${PN} += " \ 20 | python3-scons \ 21 | python3-bottle \ 22 | python3-pydispatcher \ 23 | python3-yappi \ 24 | python3-pyzmq \ 25 | python3-netifaces \ 26 | python3-cbor \ 27 | python3-hkdf \ 28 | python3-pycryptodome \ 29 | python3-numpy \ 30 | " 31 | 32 | # nghttp2 package dependencies 33 | RDEPENDS_${PN} += " \ 34 | python3-cython \ 35 | " 36 | 37 | RDEPENDS_${PN} += " \ 38 | mosquitto \ 39 | mosquitto-rsmb \ 40 | paho-mqtt-c \ 41 | openjdk-8 \ 42 | openjre-8 \ 43 | openvpn \ 44 | python3-paho-mqtt \ 45 | wpantund \ 46 | " 47 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/ssh-keys/files/ssh_host_rsa_key: -------------------------------------------------------------------------------- 1 | -----BEGIN RSA PRIVATE KEY----- 2 | MIIEpAIBAAKCAQEAo4kp21Ix80MHEPShwawpHR2X78n71UPHAj/cwQZlmYU6TUNU 3 | BwO3sM+KyIYbPHYvWHmVN8xaWxpnl5yFEuYleY9ZgpE5+Xg84cg5SOQRibOn+77W 4 | U6dgfa4XU5/jeWSDF6zsVrGziJuimKERveyNvpqT2Urg/pyx/uQGhAzAFOTYtbfD 5 | z2jLGuMLDwogjrbq+USKSB6Lwma9ARC5rFvKf5m313QBiZKzr2Lbk6HmzV/QbWQ+ 6 | +zu05p5QtXbrObD+Si7sy1cOu6nLtpoGLI50G+rVjMZiMzzFAi2vdBrl4+BF4A0u 7 | rEkaGvIfRd07RoPMCY9jdbD7rBLPTNGcqFMMaQIDAQABAoIBABIInygDYWS9AHt7 8 | LpdH3+TJDacws+epqLlzx2k1xmBuk6ZPhWWcoFYMHPbN6xT4x3HPPog/rbscJ05N 9 | wVL7NCi6iRlf4G/FNZmEVeTW2aRAvoaBXestqvNRDlt3Z0NMtTQYKpvIzs6CsyR3 10 | ppg2DM93BlTQ8AzDxNEh3iITsd7bzHLCIcnN3UwgwnlnAgMJ/OebHkkLCbZC1fSj 11 | 6Nnp0GRxQMTiw0c/7Xkta1+y4scmzoqvuT8WusHAGkM9AIgZcBBqFr6XNph7WqO8 12 | n/WTj+k3dyY4XQZFRbwEl0/V9+xB773tcNzvRZAR79fxCj5ntgZ1r6vLhO+IEOMZ 13 | luTaaTECgYEA0SrEdHDjVCRr1pk2GnbDrBrqecSeOfkLZJoWsfVVM+DmJurrlc7e 14 | hR/LRqaLQAxcBed2lLLQ1vjaPMS9By7/5FKWt0H9qRu0EV2P4J/xpVMMIYmXSCIb 15 | P6/iJAQQmM5aM5cCAnv4H4fdoaxBqebIltblzTQfuBJTMQUOl7fWm50CgYEAyCbc 16 | VjVEJEA/yE8YF3Lzfts72k+qlmPHzVDXngUS55ZRnWNJU79oYxbN76O4BTmbw/PV 17 | 7y/MrKyX1Z6kbsn5v2WBf15rGgsmm2KYKsjiLwAmxoOk36r2F6R22uAtu30az7sZ 18 | LAijWrwwKKkggLWiCtyYcA2qmdFToo+C54XaWD0CgYEArgSixS1WNB7JCRUWihXc 19 | 3UbXZM9LxHeKHvyDfTLa2/p0AFTaAxzEzISTHghZOcQOm2rioPvT+8W163DSwzM6 20 | +b4sXfKtExBVU00/8mWfKShao1xRXFXjzayKu+QV2stzCBDOPzrcR39FyMgDKVMz 21 | 9yp6rap76Sx1wgavCVKNXZECgYBEUY9wFap2vT+IPgc5KdGXgXnCoOLXhqOSn3+Z 22 | vp2fUx30nQlQfstA123f2IBduDZFApwJksVIQ3loP0hdUK/g9uLm+PGR6DB7ZYIP 23 | SJZ7+I9Dv3etqQtrMoYnW9IAZ0mZkoGbGC+6LvY5StF/XYA8OOQHi4KqElt754SF 24 | Rpkq+QKBgQCvwqobcClg/x0de7Jgnn9CTL+3Jx31nMyfJAzLnJyIGRgqPHK/lRMr 25 | 4b7keAokGnXjUbVe7+JQMkBlLGBM2xDS43XowxasPhlI98A3u7IyaB+dJjgjXOR3 26 | Rt+I4kKbqxhWVfHgUsR8Lq+Ya85VuDwQlH9opiv1mD+UFb5GCLYfaw== 27 | -----END RSA PRIVATE KEY----- 28 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/ssh-keys/files/ssh_host_rsa_key.pub: -------------------------------------------------------------------------------- 1 | ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCjiSnbUjHzQwcQ9KHBrCkdHZfvyfvVQ8cCP9zBBmWZhTpNQ1QHA7ewz4rIhhs8di9YeZU3zFpbGmeXnIUS5iV5j1mCkTn5eDzhyDlI5BGJs6f7vtZTp2B9rhdTn+N5ZIMXrOxWsbOIm6KYoRG97I2+mpPZSuD+nLH+5AaEDMAU5Ni1t8PPaMsa4wsPCiCOtur5RIpIHovCZr0BELmsW8p/mbfXdAGJkrOvYtuToebNX9BtZD77O7TmnlC1dus5sP5KLuzLVw67qcu2mgYsjnQb6tWMxmIzPMUCLa90GuXj4EXgDS6sSRoa8h9F3TtGg8wJj2N1sPusEs9M0ZyoUwxp fsaintma@gueuze 2 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/ssh-keys/files/sshd_volatile_keys: -------------------------------------------------------------------------------- 1 | d root root 0755 /var/run/ssh/ none 2 | l root root 0644 /var/run/ssh/ssh_host_rsa_key /home/root/.ssh/id_rsa 3 | l root root 0644 /var/run/ssh/ssh_host_rsa_key.pub /home/root/.ssh/id_rsa.pub 4 | l root root 0644 /var/run/ssh/ssh_host_dsa_key /home/root/.ssh/id_dsa 5 | l root root 0644 /var/run/ssh/ssh_host_dsa_key.pub /home/root/.ssh/id_dsa.pub 6 | l root root 0644 /var/run/ssh/ssh_host_ecdsa_key /home/root/.ssh/id_ecdsa 7 | l root root 0644 /var/run/ssh/ssh_host_ecdsa_key.pub /home/root/.ssh/id_ecdsa.pub 8 | l root root 0644 /var/run/ssh/ssh_host_ed25519_key /home/root/.ssh/id_ed25519 9 | l root root 0644 /var/run/ssh/ssh_host_ed25519_key.pub /home/root/.ssh/id_ed25519.pub 10 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/ssh-keys/sshd-keys-gw_1.0.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "Generation of dummy sshd server keys" 2 | LICENSE = "CECILL-2.0" 3 | LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/CECILL-2.0;md5=574109ac4bdff61f9c3e0de892ecbd19" 4 | 5 | SRC_URI += "file://ssh_host_rsa_key" 6 | SRC_URI += "file://ssh_host_rsa_key.pub" 7 | 8 | S = "${WORKDIR}" 9 | 10 | # we copy a dummy server key because in poky/meta/classes/rootfs-postcommands.bbclass 11 | # the read_only_rootfs_hook test if this file exist and otherwise use /etc/ssh/sshd_config_readonly 12 | # and the keys under /var/run/ssh. 13 | 14 | # Do not use same keys for your project 15 | # You are expected to create user own ssh keys 16 | 17 | do_install() { 18 | install -d ${D}${sysconfdir}/ssh/ 19 | install -m 0600 ${S}/ssh_host_rsa_key ${D}/${sysconfdir}/ssh/ 20 | install -m 0600 ${S}/ssh_host_rsa_key.pub ${D}/${sysconfdir}/ssh/ 21 | } 22 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-core/ssh-keys/sshd-keys-linux-node_1.0.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "Dynamic generation of sshd volatile server keys" 2 | LICENSE = "CECILL-2.0" 3 | LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/CECILL-2.0;md5=574109ac4bdff61f9c3e0de892ecbd19" 4 | 5 | S = "${WORKDIR}" 6 | SRC_URI = "file://sshd_volatile_keys" 7 | 8 | # Use systemd-tmpfiles to create volatiles files and dirs 9 | # root@node-a8-:~# ls /run/ssh/ssh_host_* 10 | # ssh_host_rsa_key ssh_host_rsa_key.pub 11 | 12 | 13 | do_install() { 14 | install -d ${D}/${sysconfdir}/default/volatiles 15 | install -m 0644 ${WORKDIR}/sshd_volatile_keys ${D}/${sysconfdir}/default/volatiles/20_sshd_volatile_keys 16 | } 17 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/avarice/avarice_git.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "AVaRICE is a program which interfaces the GNU Debugger GDB with the AVR JTAG ICE available from Atmel." 2 | HOMEPAGE = "http://avarice.sourceforge.net/" 3 | SECTION = "console" 4 | LICENSE = "GPLv2" 5 | LIC_FILES_CHKSUM = "file://COPYING;md5=0636e73ff0215e8d672dc4c32c317bb3" 6 | 7 | SRC_URI[md5sum] = "346ec2e46393a54ac152b95abf1d9850" 8 | SRC_URI[sha256sum] = "c6804668dfa96b23185dfe2e8239089af4e4ae0b11aa7435bebb28c3260ede41" 9 | 10 | PR = "r1" 11 | # Use git version master 12 | SRC_URI = "git://github.com/multiplemonomials/avarice.git;protocol=https" 13 | SRCREV = "9a0e122fb0d74ab69d9d5922ca8f6b157ae2aa1d" 14 | 15 | S = "${WORKDIR}/git" 16 | 17 | DEPENDS = "libusb libftdi hidapi" 18 | 19 | inherit cmake 20 | 21 | do_install_append () { 22 | rm -rf ${D}/usr/bin/ice-gdb 23 | rm -rf ${D}/usr/data/gdb-avarice-script 24 | rm -rf ${D}/usr/data 25 | } 26 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/avrdude/avrdude.inc: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "AVRDUDE is software for programming Atmel AVR Microcontrollers." 2 | HOMEPAGE = "http://www.nongnu.org/avrdude/" 3 | SECTION = "console" 4 | LICENSE = "GPLv2" 5 | LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f" 6 | 7 | PR = "r1" 8 | 9 | DEPENDS = "bison-native libusb ncurses elfutils readline libftdi" 10 | 11 | SRC_URI = "http://savannah.nongnu.org/download/avrdude/avrdude-${PV}.tar.gz" 12 | 13 | inherit autotools 14 | 15 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/avrdude/avrdude_6.0.1.bb: -------------------------------------------------------------------------------- 1 | require avrdude.inc 2 | LIC_FILES_CHKSUM = "file://COPYING;md5=4f51bb496ef8872ccff73f440f2464a8" 3 | 4 | SRC_URI[md5sum] = "346ec2e46393a54ac152b95abf1d9850" 5 | SRC_URI[sha256sum] = "c6804668dfa96b23185dfe2e8239089af4e4ae0b11aa7435bebb28c3260ede41" 6 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/avrdude/avrdude_svn.bb: -------------------------------------------------------------------------------- 1 | SUMMARY = "AVRDUDE is a utility to download/upload/manipulate the ROM and EEPROM contents of AVR microcontrollers using the in-system programming technique (ISP)." 2 | 3 | LICENSE = "GPLv2" 4 | LIC_FILES_CHKSUM = "file://COPYING;md5=4f51bb496ef8872ccff73f440f2464a8" 5 | 6 | DEPENDS = "bison-native libusb elfutils hidapi libftdi readline" 7 | 8 | inherit autotools 9 | 10 | PV = "6.3+svn${SRCPV}" 11 | SRC_URI = "svn://svn.savannah.nongnu.org/svn/avrdude/;protocol=http;module=trunk;rev=1425" 12 | 13 | S = "${WORKDIR}/trunk/avrdude" 14 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/edbg/edbg_0.1.0.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "edbg: Simple utility for programming Atmel MCUs through EDBG interface" 2 | HOMEPAGE = "https://github.com/ataradov/edbg" 3 | SECTION = "console" 4 | LICENSE = "BSD" 5 | LIC_FILES_CHKSUM = "file://git/edbg.h;md5=6394409c44d1ac9a3928fb6996e4b8b3" 6 | 7 | SRC_URI = "git://github.com/ataradov/edbg.git;protocol=https" 8 | SRCREV = "80c50d03aac831f87f513a5d5455df1286bcb540" 9 | 10 | DEPENDS = "udev" 11 | 12 | S = "${WORKDIR}" 13 | 14 | SRCS = "${S}/git/dap.c \ 15 | ${S}/git/edbg.c \ 16 | ${S}/git/target.c \ 17 | ${S}/git/target_atmel_cm0p.c \ 18 | ${S}/git/target_atmel_cm3.c \ 19 | ${S}/git/target_atmel_cm4.c \ 20 | ${S}/git/target_atmel_cm7.c \ 21 | ${S}/git/dbg_lin.c" 22 | 23 | LIBS += "-ludev" 24 | 25 | CFLAGS += "-W -Wall -Wextra -O2 -std=gnu11" 26 | 27 | do_compile() { 28 | ${CC} ${CFLAGS} ${SRCS} ${LIBS} -o ${S}/git/edbg 29 | } 30 | 31 | do_install() { 32 | install -d ${D}${bindir} 33 | install -m 755 ${S}/git/edbg ${D}${bindir} 34 | } 35 | 36 | INSANE_SKIP_${PN} = "ldflags" 37 | INSANE_SKIP_${PN}-dev = "ldflags" 38 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/jimtcl/jimtcl-git.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "Jim is an opensource small-footprint implementation of the Tcl programming language" 2 | HOMEPAGE = "http://jim.tcl.tk" 3 | LICENSE = "BSD" 4 | LIC_FILES_CHKSUM = "file://LICENSE;md5=670d6aae00a2c7a4da40f70b78bdf992" 5 | 6 | ## SRCREV = ${AUTOREV} 7 | ## 8 | ## We use a fixed SRCREV to allow offline bitbake 9 | ## SRCREV == 35eff1766cc2dd2528f70349ab5522247ed0b40c 10 | ## corresponds to git rev on 2013-03-16 22:02 11 | ## please keep in sync with the openocd package. 12 | ## 13 | 14 | SRCREV="35eff1766cc2dd2528f70349ab5522247ed0b40c" 15 | 16 | PV = "gitr${SRCPV}" 17 | PR = "r4" 18 | 19 | PACKAGES = "${PN} ${PN}-dbg ${PN}-dev" 20 | 21 | inherit autotools 22 | 23 | SRC_URI = "git://github.com/msteveb/jimtcl.git;protocol=git;branch=master" 24 | S = "${WORKDIR}/git" 25 | 26 | CONFIGUREOPTS = "" 27 | 28 | do_configure() { 29 | oe_runconf 30 | } 31 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/jimtcl/jimtcl_0.74.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "Jim is an opensource small-footprint implementation of the Tcl programming language" 2 | HOMEPAGE = "http://jim.tcl.tk" 3 | LICENSE = "FreeBSD" 4 | LIC_FILES_CHKSUM = "file://LICENSE;md5=670d6aae00a2c7a4da40f70b78bdf992" 5 | 6 | ## 7 | ## HIKOB Note 8 | ## 9 | ## We use a fixed SRCREV in the GIT repo as jimtcl does 10 | ## not release tarballs. 11 | ## please keep in sync with the openocd package. 12 | ## 13 | ## SRCREV == 7c126ab08220024b7dfe293045e6ee4d0bb3ca95 14 | ## 15 | 16 | SRCREV="7c126ab08220024b7dfe293045e6ee4d0bb3ca95" 17 | 18 | ## PV = "0.74" 19 | PR = "r6" 20 | 21 | PACKAGES = "${PN} ${PN}-dbg ${PN}-dev" 22 | 23 | FILES_${PN}-dev += "/usr/include" 24 | FILES_${PN}-dev += "/usr/lib" 25 | FILES_${PN}-dev += "/usr/doc" 26 | 27 | inherit autotools 28 | 29 | SRC_URI = "git://github.com/msteveb/jimtcl.git;protocol=git;branch=master" 30 | S = "${WORKDIR}/git" 31 | 32 | CONFIGUREOPTS = "" 33 | 34 | EXTRA_OECONF = " --prefix=/usr " 35 | 36 | do_configure() { 37 | oe_runconf 38 | } 39 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/jimtcl/jimtcl_0.76.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "Jim is an opensource small-footprint implementation of the Tcl programming language" 2 | HOMEPAGE = "http://jim.tcl.tk" 3 | LICENSE = "FreeBSD" 4 | LIC_FILES_CHKSUM = "file://LICENSE;md5=d69300147248518155ea330e78019033" 5 | 6 | ## 7 | ## HIKOB Note 8 | ## 9 | ## We use a fixed SRCREV in the GIT repo as jimtcl does 10 | ## not release tarballs. 11 | ## please keep in sync with the openocd package. 12 | ## 13 | ## SRCREV == 51f65c6d38fbf86e1f0b036ad336761fd2ab7fa0 14 | ## 15 | 16 | SRCREV="51f65c6d38fbf86e1f0b036ad336761fd2ab7fa0" 17 | 18 | PR = "r0" 19 | 20 | PACKAGES = "${PN} ${PN}-dbg ${PN}-dev ${PN}-staticdev" 21 | 22 | FILES_${PN}-dev += "/usr/include" 23 | FILES_${PN}-dev += "/usr/lib/jim" 24 | FILES_${PN}-dev += "/usr/doc" 25 | FILES_${PN}-staticdev += "/usr/lib/libjim.a" 26 | 27 | inherit autotools 28 | DISABLE_STATIC = "" 29 | 30 | SRC_URI = "git://github.com/msteveb/jimtcl.git;protocol=git;branch=master" 31 | S = "${WORKDIR}/git" 32 | 33 | CONFIGUREOPTS = "" 34 | 35 | EXTRA_OECONF = " --prefix=/usr " 36 | 37 | do_configure() { 38 | oe_runconf 39 | } 40 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/openjdk/files/openjdk8-enable-hotSpot-builds-on-5.x-linux-kernels.patch: -------------------------------------------------------------------------------- 1 | diff --git hotspot/make/linux/Makefile hotspot/make/linux/Makefile 2 | --- hotspot/make/linux/Makefile 3 | +++ hotspot/make/linux/Makefile 4 | @@ -233,7 +233,7 @@ 5 | # Solaris 2.5.1, 2.6). 6 | # Disable this check by setting DISABLE_HOTSPOT_OS_VERSION_CHECK=ok. 7 | 8 | -SUPPORTED_OS_VERSION = 2.4% 2.5% 2.6% 3% 4% 9 | +SUPPORTED_OS_VERSION = 2.4% 2.5% 2.6% 3% 4% 5% 10 | OS_VERSION := $(shell uname -r) 11 | EMPTY_IF_NOT_SUPPORTED = $(filter $(SUPPORTED_OS_VERSION),$(OS_VERSION)) 12 | 13 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/openjdk/openjdk-8-native_%.bbappend: -------------------------------------------------------------------------------- 1 | FILESEXTRAPATHS_prepend := "${THISDIR}/files:" 2 | PATCHES_URI_append += "file://openjdk8-enable-hotSpot-builds-on-5.x-linux-kernels.patch;apply=no" 3 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/openjdk/openjdk-8_%.bbappend: -------------------------------------------------------------------------------- 1 | FILESEXTRAPATHS_prepend := "${THISDIR}/files:" 2 | PATCHES_URI_append += "file://openjdk8-enable-hotSpot-builds-on-5.x-linux-kernels.patch;apply=no" 3 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/openjdk/openjre-8_%.bbappend: -------------------------------------------------------------------------------- 1 | FILESEXTRAPATHS_prepend := "${THISDIR}/files:" 2 | PATCHES_URI_append += "file://openjdk8-enable-hotSpot-builds-on-5.x-linux-kernels.patch;apply=no" 3 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/openocd/files/0001-static-library.patch: -------------------------------------------------------------------------------- 1 | diff --git a/src/Makefile.am b/src/Makefile.am 2 | index 07981aa..1d9559c 100644 3 | --- a/src/Makefile.am 4 | +++ b/src/Makefile.am 5 | @@ -35,7 +35,7 @@ endif 6 | %C%_libopenocd_la_CPPFLAGS += $(AM_CPPFLAGS) $(CPPFLAGS) 7 | 8 | # the library search path. 9 | -%C%_libopenocd_la_LDFLAGS = $(all_libraries) 10 | +%C%_libopenocd_la_LDFLAGS = -static $(all_libraries) 11 | 12 | if IS_MINGW 13 | MINGWLDADD = -lws2_32 14 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/openocd/files/openocd-link-static.patch: -------------------------------------------------------------------------------- 1 | diff --git a/src/Makefile.am b/src/Makefile.am 2 | index c78e81c..3aca8a4 100644 3 | --- a/src/Makefile.am 4 | +++ b/src/Makefile.am 5 | @@ -55,7 +55,7 @@ endif 6 | libopenocd_la_CPPFLAGS += $(AM_CPPFLAGS) $(CPPFLAGS) 7 | 8 | # the library search path. 9 | -libopenocd_la_LDFLAGS = $(all_libraries) 10 | +libopenocd_la_LDFLAGS = -static $(all_libraries) 11 | 12 | if IS_MINGW 13 | MINGWLDADD = -lws2_32 14 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/openocd/files/remove-raggedright.patch: -------------------------------------------------------------------------------- 1 | From 287f0ee8ea4f4b5e66bea0db62c6f169e5dd97bb Mon Sep 17 00:00:00 2001 2 | From: =?UTF-8?q?Ga=C3=ABtan=20Harter?= 3 | Date: Mon, 3 Apr 2017 16:40:40 +0200 4 | Subject: [PATCH] Remove raggedright, not supported on debian wheezy 5 | 6 | --- 7 | doc/openocd.texi | 2 -- 8 | 1 file changed, 2 deletions(-) 9 | 10 | diff --git a/doc/openocd.texi b/doc/openocd.texi 11 | index 511bc6c..da3a109 100644 12 | --- a/doc/openocd.texi 13 | +++ b/doc/openocd.texi 14 | @@ -8460,11 +8460,9 @@ Cyg_Thread::thread_list, Cyg_Scheduler_Base::current_thread. 15 | @item ThreadX symbols 16 | _tx_thread_current_ptr, _tx_thread_created_ptr, _tx_thread_created_count. 17 | @item FreeRTOS symbols 18 | -@raggedright 19 | pxCurrentTCB, pxReadyTasksLists, xDelayedTaskList1, xDelayedTaskList2, 20 | pxDelayedTaskList, pxOverflowDelayedTaskList, xPendingReadyList, 21 | uxCurrentNumberOfTasks, uxTopUsedPriority. 22 | -@end raggedright 23 | @item linux symbols 24 | init_task. 25 | @item ChibiOS symbols 26 | -- 27 | 1.9.1 28 | 29 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/openocd/openocd-git.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "Free and Open On-Chip Debugging, In-System Programming and Boundary-Scan Testing" 2 | HOMEPAGE = "http://openocd.berlios.de/" 3 | SECTION = "utils" 4 | LICENSE = "GPLv2" 5 | LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263" 6 | 7 | PR = "r1" 8 | 9 | DEPENDS = "" 10 | DEPENDS += "libftdi" 11 | DEPENDS += "libusb1" 12 | DEPENDS += "hidapi" 13 | DEPENDS += "texinfo-native" 14 | 15 | PV = "gitr${SRCPV}" 16 | 17 | SRC_URI = " \ 18 | git://repo.or.cz/openocd.git;protocol=http;name=openocd \ 19 | git://repo.or.cz/r/git2cl.git;protocol=http;destsuffix=tools/git2cl;name=git2cl \ 20 | git://repo.or.cz/r/jimtcl.git;protocol=http;destsuffix=git/jimtcl;name=jimtcl \ 21 | git://repo.or.cz/r/libjaylink.git;protocol=http;destsuffix=git/src/jtag/drivers/libjaylink;name=libjaylink \ 22 | file://0001-static-library.patch \ 23 | " 24 | 25 | SRCREV_FORMAT = "openocd" 26 | SRCREV_openocd = "7c88e76a76588fa0e3ab645adfc46e8baff6a3e4" 27 | SRCREV_git2cl = "8373c9f74993e218a08819cbcdbab3f3564bbeba" 28 | SRCREV_jimtcl = "0aa0fb4e3a38d38a49de9eb585d93d63a370dcf6" 29 | SRCREV_libjaylink = "dce11b89e85179a92a0fe3a90d2693ca891ed646" 30 | 31 | S = "${WORKDIR}/git" 32 | 33 | ## ################################################## 34 | ## ################################################## 35 | 36 | PACKAGES = "${PN}-dbg ${PN}" 37 | 38 | FILES_${PN}-dbg += "/opt/openocd-dev/.debug" 39 | FILES_${PN} += "/opt/openocd-dev" 40 | 41 | # inherit autotools 42 | # Don't use out of tree build 43 | inherit autotools-brokensep pkgconfig gettext 44 | 45 | EXTRA_OECONF = "" 46 | EXTRA_OECONF += " --disable-werror " 47 | 48 | # samr21 49 | EXTRA_OECONF += " --enable-cmsis-dap --enable-hidapi-libusb " 50 | EXTRA_OECONF += " --enable-maintainer-mode " 51 | 52 | # nrf52dk 53 | EXTRA_OECONF += " --enable-jlink " 54 | 55 | PARAMS_BUILD = " --enable-largefile --disable-nls --enable-ipv6 --with-sysroot=${STAGING_DIR_TARGET} --with-libtool-sysroot=${STAGING_DIR_TARGET} " 56 | 57 | PARAMS_CROSS = " --build=${BUILD_SYS} --host=${HOST_SYS} --target=${TARGET_SYS} " 58 | PARAMS_CROSS += " --libdir=${STAGING_DIR_TARGET}/lib " 59 | PARAMS_INST = " --prefix=/opt/openocd-dev " 60 | 61 | do_configure() { 62 | # Build jimtcl in a separate package !!!!!!! got segfault when not doing it 63 | # So nosubmodule 64 | ./bootstrap nosubmodule 65 | ## oe_runconf does *not* work and must not be used here 66 | ./configure ${PARAMS_INST} ${PARAMS_CROSS} ${PARAMS_BUILD} ${EXTRA_OECONF} 67 | #oe_runconf ${PARAMS_INST} ${PARAMS_CROSS} ${PARAMS_BUILD} ${EXTRA_OECONF} 68 | } 69 | 70 | ## ################################################## 71 | ## ################################################## 72 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/openocd/openocd-ti.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "TI's fork of OpenOCD Free and Open On-Chip Debugging, In-System Programming and Boundary-Scan Testing" 2 | HOMEPAGE = "git://git.ti.com/sdo-emu/openocd.git" 3 | SECTION = "utils" 4 | LICENSE = "GPLv2" 5 | LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263" 6 | 7 | PR = "r1" 8 | 9 | DEPENDS = "" 10 | DEPENDS += "libusb1" 11 | DEPENDS += "jimtcl" 12 | DEPENDS += "hidapi" 13 | DEPENDS += "texinfo-native" 14 | 15 | ## ################################################## 16 | ## ################################################## 17 | 18 | # Use the master merge from branch develop dated September 21 2018 19 | SRCREV = "4765fd4c864c47d48754350c196bd5c5ce9c5ed9" 20 | 21 | SRC_URI = "git://git.ti.com/sdo-emu/openocd.git;protocol=git" 22 | 23 | S = "${WORKDIR}/git/openocd" 24 | 25 | ## ################################################## 26 | ## ################################################## 27 | 28 | PACKAGES = "${PN}-dbg ${PN}" 29 | 30 | FILES_${PN}-dbg += "/opt/openocd-ti/.debug" 31 | FILES_${PN} += "/opt/openocd-ti" 32 | 33 | # inherit autotools 34 | # Don't use out of tree build 35 | inherit autotools-brokensep pkgconfig 36 | 37 | EXTRA_OECONF = "" 38 | EXTRA_OECONF += " --disable-werror " 39 | 40 | # samr21 41 | EXTRA_OECONF += " --enable-cmsis-dap --enable-hidapi-libusb " 42 | EXTRA_OECONF += " --enable-maintainer-mode " 43 | 44 | # disable libjaylink (no submodule) 45 | EXTRA_OECONF += " --disable-internal-libjaylink " 46 | 47 | PARAMS_BUILD = " --enable-largefile --disable-nls --enable-ipv6 --with-sysroot=${STAGING_DIR_TARGET} --with-libtool-sysroot=${STAGING_DIR_TARGET} " 48 | PARAMS_BUILD += " --disable-internal-jimtcl --disable-ftdi " 49 | 50 | PARAMS_CROSS = " --build=${BUILD_SYS} --host=${HOST_SYS} --target=${TARGET_SYS} " 51 | PARAMS_CROSS += " --libdir=${STAGING_DIR_TARGET}/lib " 52 | PARAMS_INST = " --prefix=/opt/openocd-ti " 53 | 54 | do_configure() { 55 | autoreconf -f -i 56 | ./configure ${PARAMS_INST} ${PARAMS_CROSS} ${PARAMS_BUILD} ${EXTRA_OECONF} 57 | } 58 | 59 | ## ################################################## 60 | ## ################################################## 61 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/openocd/openocd_0.10.0.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "Free and Open On-Chip Debugging, In-System Programming and Boundary-Scan Testing" 2 | HOMEPAGE = "http://openocd.berlios.de/" 3 | SECTION = "utils" 4 | LICENSE = "GPLv2" 5 | LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263" 6 | 7 | PR = "r1" 8 | 9 | DEPENDS = "" 10 | DEPENDS += "libftdi" 11 | DEPENDS += "libusb1" 12 | DEPENDS += "libjaylink" 13 | DEPENDS += "jimtcl" 14 | DEPENDS += "hidapi" 15 | DEPENDS += "texinfo-native" 16 | 17 | ## ################################################## 18 | ## ################################################## 19 | 20 | # Use git version 0.10.0: issues when using source code 21 | SRCREV = "646566e006acd58fb9ac405511d3ecca79f26d55" 22 | 23 | SRC_URI = "git://github.com/ntfreak/openocd.git;protocol=https" 24 | SRC_URI += "file://0001-static-library.patch" 25 | 26 | S = "${WORKDIR}/git" 27 | 28 | ## ################################################## 29 | ## ################################################## 30 | 31 | PACKAGES = "${PN}-dbg ${PN}" 32 | 33 | FILES_${PN}-dbg += "/usr/local/bin/.debug" 34 | FILES_${PN} += "/usr/local" 35 | 36 | # inherit autotools 37 | # Don't use out of tree build 38 | inherit autotools-brokensep pkgconfig 39 | 40 | EXTRA_OECONF = "" 41 | EXTRA_OECONF += " --disable-werror " 42 | 43 | # samr21 44 | EXTRA_OECONF += " --enable-cmsis-dap --enable-hidapi-libusb " 45 | EXTRA_OECONF += " --enable-maintainer-mode " 46 | 47 | # nrf52dk 48 | EXTRA_OECONF += " --enable-jlink " 49 | 50 | # disable libjaylink (no submodule) 51 | EXTRA_OECONF += " --disable-internal-libjaylink " 52 | 53 | PARAMS_BUILD = " --enable-largefile --disable-nls --enable-ipv6 --with-sysroot=${STAGING_DIR_TARGET} --with-libtool-sysroot=${STAGING_DIR_TARGET} " 54 | PARAMS_BUILD += " --disable-internal-jimtcl " 55 | 56 | PARAMS_CROSS = " --build=${BUILD_SYS} --host=${HOST_SYS} --target=${TARGET_SYS} " 57 | PARAMS_CROSS += " --libdir=${STAGING_DIR_TARGET}/lib " 58 | PARAMS_INST = " --prefix=/usr/local " 59 | 60 | ## --enable-ipv6 61 | ## --libdir=${STAGING_DIR_TARGET}/lib 62 | ## 63 | ## export BUILD_SYS=x86_64-linux 64 | ## export HOST_SYS=arm-oe-linux-gnueabi 65 | ## export TARGET_SYS=arm-oe-linux-gnueabi 66 | ## export STAGING_DIR_TARGET=/home/volume6/dev.oe/openembedded-core/build.gw/tmp-eglibc/sysroots/var-som-am35 67 | ## 68 | ## ./configure --build=x86_64-linux --host=arm-oe-linux-gnueabi --target=arm-oe-linux-gnueabi \ 69 | ## --libdir=/home/volume6/dev.oe/openembedded-core/build.gw/tmp-eglibc/sysroots/var-som-am35/lib \ 70 | ## --enable-largefile --disable-nls \ 71 | ## --with-sysroot=/home/volume6/dev.oe/openembedded-core/build.gw/tmp-eglibc/sysroots/var-som-am35 \ 72 | ## --with-libtool-sysroot=/home/volume6/dev.oe/openembedded-core/build.gw/tmp-eglibc/sysroots/var-som-am35 \ 73 | ## --enable-ft2232_libftdi --disable-ftdi2232 --disable-ftd2xx --disable-werror --disable-internal-jimtcl 74 | 75 | do_configure() { 76 | # Build jimtcl in a separate package !!!!!!! got segfault when not doing it 77 | # So nosubmodule 78 | ./bootstrap nosubmodule 79 | ## oe_runconf does *not* work and must not be used here 80 | ./configure ${PARAMS_INST} ${PARAMS_CROSS} ${PARAMS_BUILD} ${EXTRA_OECONF} 81 | #oe_runconf ./configure ${PARAMS_CROSS} ${PARAMS_BUILD} ${EXTRA_OECONF} 82 | } 83 | 84 | ## ################################################## 85 | ## ################################################## 86 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/openocd/openocd_0.11.0.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "Free and Open On-Chip Debugging, In-System Programming and Boundary-Scan Testing" 2 | HOMEPAGE = "http://openocd.berlios.de/" 3 | SECTION = "utils" 4 | LICENSE = "GPLv2" 5 | LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263" 6 | 7 | PR = "r1" 8 | 9 | DEPENDS = "" 10 | DEPENDS += "libftdi" 11 | DEPENDS += "libusb1" 12 | DEPENDS += "hidapi" 13 | DEPENDS += "texinfo-native" 14 | 15 | ## ################################################## 16 | ## ################################################## 17 | 18 | # Use git version 0.11.0: issues when using source code 19 | SRCREV = "f342aac0845a69d591ad39a025d74e9c765f6420" 20 | 21 | SRC_URI = " \ 22 | git://repo.or.cz/openocd.git;protocol=http;name=openocd \ 23 | git://repo.or.cz/r/jimtcl.git;protocol=http;destsuffix=git/jimtcl;name=jimtcl \ 24 | git://repo.or.cz/r/libjaylink.git;protocol=http;destsuffix=git/src/jtag/drivers/libjaylink;name=libjaylink \ 25 | file://0001-static-library.patch \ 26 | " 27 | 28 | SRCREV_jimtcl = "0aa0fb4e3a38d38a49de9eb585d93d63a370dcf6" 29 | SRCREV_libjaylink = "9aa7a5957c07bb6e862fc1a6d3153d109c7407e4" 30 | 31 | S = "${WORKDIR}/git" 32 | 33 | ## ################################################## 34 | ## ################################################## 35 | 36 | PACKAGES = "${PN}-dbg ${PN}" 37 | 38 | FILES_${PN}-dbg += "/usr/local/bin/.debug" 39 | FILES_${PN} += "/usr/local" 40 | 41 | # inherit autotools 42 | # Don't use out of tree build 43 | inherit autotools-brokensep pkgconfig gettext 44 | 45 | EXTRA_OECONF = "" 46 | EXTRA_OECONF += " --disable-werror " 47 | 48 | # samr21 49 | EXTRA_OECONF += " --enable-cmsis-dap --enable-hidapi-libusb " 50 | EXTRA_OECONF += " --enable-maintainer-mode " 51 | 52 | # nrf52dk 53 | EXTRA_OECONF += " --enable-jlink " 54 | 55 | PARAMS_BUILD = " --enable-largefile --disable-nls --enable-ipv6 --with-sysroot=${STAGING_DIR_TARGET} --with-libtool-sysroot=${STAGING_DIR_TARGET} " 56 | 57 | PARAMS_CROSS = " --build=${BUILD_SYS} --host=${HOST_SYS} --target=${TARGET_SYS} " 58 | PARAMS_CROSS += " --libdir=${STAGING_DIR_TARGET}/lib " 59 | PARAMS_INST = " --prefix=/usr/local " 60 | 61 | do_configure() { 62 | # nosubmodule 63 | ./bootstrap nosubmodule 64 | ./configure ${PARAMS_INST} ${PARAMS_CROSS} ${PARAMS_BUILD} ${EXTRA_OECONF} 65 | } 66 | 67 | ## ################################################## 68 | ## ################################################## 69 | 70 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/openocd/openocd_0.7.0.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "Free and Open On-Chip Debugging, In-System Programming and Boundary-Scan Testing" 2 | HOMEPAGE = "http://openocd.berlios.de/" 3 | SECTION = "utils" 4 | LICENSE = "GPLv2" 5 | LIC_FILES_CHKSUM = "file://COPYING;md5=52aad3ae14f33671f4d848e9579f7870" 6 | 7 | PR = "r6" 8 | 9 | DEPENDS = "libftdi libusb libusb1 jimtcl" 10 | DEPENDS += "texinfo-native" 11 | 12 | ## ################################################## 13 | ## ################################################## 14 | 15 | SRC_URI = "${SOURCEFORGE_MIRROR}/openocd/${PV}/openocd-${PV}.tar.bz2;name=tarball" 16 | SRC_URI[tarball.md5sum] = "8977a26a4e3a529e1c4fcc0df587a6a4" 17 | SRC_URI[tarball.sha256sum] = "52237b786530c8460b221556c26fa4779f668b7dcb83ff14b8c5eb2050f38e63" 18 | 19 | ## SRC_URI = "http://ftp.fr.debian.org/debian/pool/main/o/openocd/openocd_0.7.0.orig.tar.gz;name=debtar" 20 | ## SRC_URI[debtar.md5sum] = "53ecbb5151df59541b6251335a440766" 21 | ## SRC_URI[debtar.sha256sum] = "3d653f594743248f0da3fedb40a03e19637e2ac972f5108eb298b7fd5f53d360" 22 | 23 | SRC_URI += "file://openocd-link-static.patch" 24 | 25 | S = "${WORKDIR}/openocd-${PV}" 26 | 27 | ## ################################################## 28 | ## ################################################## 29 | 30 | PACKAGES = "${PN}-dbg ${PN}" 31 | 32 | FILES_${PN}-dbg += "/usr/local/bin/.debug" 33 | FILES_${PN} += "/usr/local" 34 | 35 | inherit autotools 36 | 37 | EXTRA_OECONF = " --enable-ft2232_libftdi --disable-ftdi2232 --disable-ftd2xx --disable-werror " 38 | 39 | PARAMS_BUILD=" --enable-largefile --disable-nls --with-sysroot=${STAGING_DIR_TARGET} --with-libtool-sysroot=${STAGING_DIR_TARGET} " 40 | PARAMS_CROSS=" --build=${BUILD_SYS} --host=${HOST_SYS} --target=${TARGET_SYS} " 41 | PARAMS_INST=" --prefix=/usr/local " 42 | 43 | ## --enable-ipv6 44 | ## --libdir=${STAGING_DIR_TARGET}/lib 45 | ## 46 | ## export BUILD_SYS=x86_64-linux 47 | ## export HOST_SYS=arm-oe-linux-gnueabi 48 | ## export TARGET_SYS=arm-oe-linux-gnueabi 49 | ## export STAGING_DIR_TARGET=/home/volume6/dev.oe/openembedded-core/build.gw/tmp-eglibc/sysroots/var-som-am35 50 | ## 51 | ## ./configure --build=x86_64-linux --host=arm-oe-linux-gnueabi --target=arm-oe-linux-gnueabi \ 52 | ## --libdir=/home/volume6/dev.oe/openembedded-core/build.gw/tmp-eglibc/sysroots/var-som-am35/lib \ 53 | ## --enable-largefile --disable-nls \ 54 | ## --with-sysroot=/home/volume6/dev.oe/openembedded-core/build.gw/tmp-eglibc/sysroots/var-som-am35 \ 55 | ## --with-libtool-sysroot=/home/volume6/dev.oe/openembedded-core/build.gw/tmp-eglibc/sysroots/var-som-am35 \ 56 | ## --enable-ft2232_libftdi --disable-ftdi2232 --disable-ftd2xx --disable-werror --disable-internal-jimtcl 57 | 58 | do_configure() { 59 | ## touch jimtcl/configure 60 | ## oe_runconf does *not* work and must not be used here 61 | ./configure ${PARAMS_CROSS} ${PARAMS_BUILD} ${EXTRA_OECONF} 62 | } 63 | 64 | ## ################################################## 65 | ## ################################################## 66 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/openocd/openocd_0.9.0.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "Free and Open On-Chip Debugging, In-System Programming and Boundary-Scan Testing" 2 | HOMEPAGE = "http://openocd.berlios.de/" 3 | SECTION = "utils" 4 | LICENSE = "GPLv2" 5 | LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263" 6 | 7 | PR = "r1" 8 | 9 | DEPENDS = "" 10 | DEPENDS += "libftdi" 11 | DEPENDS += "libusb1" 12 | DEPENDS += "jimtcl" 13 | DEPENDS += "hidapi" 14 | DEPENDS += "texinfo-native" 15 | 16 | ## ################################################## 17 | ## ################################################## 18 | 19 | # Use git version 0.9.0: issues when using source code 20 | SRCREV = "7b8b2f944322161334e21f30709504e4d42da18e" 21 | 22 | SRC_URI = "git://github.com/ntfreak/openocd.git;protocol=https" 23 | SRC_URI += "file://openocd-link-static.patch" 24 | SRC_URI += "file://remove-raggedright.patch" 25 | 26 | S = "${WORKDIR}/git" 27 | 28 | ## ################################################## 29 | ## ################################################## 30 | 31 | PACKAGES = "${PN}-dbg ${PN}" 32 | 33 | FILES_${PN}-dbg += "/usr/local/bin/.debug" 34 | FILES_${PN} += "/usr/local" 35 | 36 | # inherit autotools 37 | # Don't use out of tree build 38 | inherit autotools-brokensep pkgconfig 39 | 40 | EXTRA_OECONF = "" 41 | EXTRA_OECONF += " --disable-werror " 42 | 43 | # FTDI for m3 nodes old 'ft2232' 44 | EXTRA_OECONF += " --enable-legacy-ft2232_libftdi --disable-ftdi2232 --disable-ftd2xx " 45 | # Newer ftdi interface too 46 | EXTRA_OECONF += " --enable-ftdi " 47 | 48 | # samr21 49 | EXTRA_OECONF += " --enable-cmsis-dap --enable-hidapi-libusb " 50 | EXTRA_OECONF += " --enable-maintainer-mode " 51 | 52 | 53 | PARAMS_BUILD = " --enable-largefile --disable-nls --enable-ipv6 --with-sysroot=${STAGING_DIR_TARGET} --with-libtool-sysroot=${STAGING_DIR_TARGET} " 54 | PARAMS_BUILD += " --disable-internal-jimtcl " 55 | 56 | PARAMS_CROSS = " --build=${BUILD_SYS} --host=${HOST_SYS} --target=${TARGET_SYS} " 57 | PARAMS_CROSS += " --libdir=${STAGING_DIR_TARGET}/lib " 58 | PARAMS_INST = " --prefix=/usr/local " 59 | 60 | ## --enable-ipv6 61 | ## --libdir=${STAGING_DIR_TARGET}/lib 62 | ## 63 | ## export BUILD_SYS=x86_64-linux 64 | ## export HOST_SYS=arm-oe-linux-gnueabi 65 | ## export TARGET_SYS=arm-oe-linux-gnueabi 66 | ## export STAGING_DIR_TARGET=/home/volume6/dev.oe/openembedded-core/build.gw/tmp-eglibc/sysroots/var-som-am35 67 | ## 68 | ## ./configure --build=x86_64-linux --host=arm-oe-linux-gnueabi --target=arm-oe-linux-gnueabi \ 69 | ## --libdir=/home/volume6/dev.oe/openembedded-core/build.gw/tmp-eglibc/sysroots/var-som-am35/lib \ 70 | ## --enable-largefile --disable-nls \ 71 | ## --with-sysroot=/home/volume6/dev.oe/openembedded-core/build.gw/tmp-eglibc/sysroots/var-som-am35 \ 72 | ## --with-libtool-sysroot=/home/volume6/dev.oe/openembedded-core/build.gw/tmp-eglibc/sysroots/var-som-am35 \ 73 | ## --enable-ft2232_libftdi --disable-ftdi2232 --disable-ftd2xx --disable-werror --disable-internal-jimtcl 74 | 75 | do_configure() { 76 | # Build jimtcl in a separate package !!!!!!! got segfault when not doing it 77 | # So nosubmodule 78 | ./bootstrap nosubmodule 79 | ## oe_runconf does *not* work and must not be used here 80 | ./configure ${PARAMS_CROSS} ${PARAMS_BUILD} ${EXTRA_OECONF} 81 | #oe_runconf ./configure ${PARAMS_CROSS} ${PARAMS_BUILD} ${EXTRA_OECONF} 82 | } 83 | 84 | ## ################################################## 85 | ## ################################################## 86 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/python/python3-beautifulsoup4_4.6.0.bb: -------------------------------------------------------------------------------- 1 | ## -*-conf-*- 2 | DESCRIPTION = "Screen-scraping library" 3 | HOMEPAGE = "https://pypi.python.org/pypi/beautifulsoup4" 4 | SECTION = "devel/python" 5 | LICENSE = "MIT" 6 | LIC_FILES_CHKSUM = "file://COPYING.txt;md5=f2d38d8a40bf73fd4b3d16ca2e5882d1" 7 | 8 | PR = "r0" 9 | 10 | SRC_URI[md5sum] = "c17714d0f91a23b708a592cb3c697728" 11 | SRC_URI[sha256sum] = "808b6ac932dccb0a4126558f7dfdcf41710dd44a4ef497a0bb59a77f9f078e89" 12 | 13 | inherit pypi setuptools3 14 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/python/python3-bottle_0.12.18.bb: -------------------------------------------------------------------------------- 1 | ## -*-conf-*- 2 | DESCRIPTION = "Fast and simple WSGI-framework for small web-applications" 3 | HOMEPAGE = "https://pypi.python.org/pypi/bottle/" 4 | SECTION = "devel/python" 5 | LICENSE = "MIT" 6 | LIC_FILES_CHKSUM = "file://README.rst;md5=1f9017c97709920b7382f39fb402466f" 7 | 8 | SRC_URI[md5sum] = "a00b7e9a1ab3be7c19c1235fea2ccb40" 9 | SRC_URI[sha256sum] = "0819b74b145a7def225c0e83b16a4d5711fde751cd92bae467a69efce720f69e" 10 | 11 | PYPI_PACKAGE = "bottle" 12 | 13 | inherit pypi setuptools3 14 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/python/python3-cbor_1.0.0.bb: -------------------------------------------------------------------------------- 1 | SUMMARY = "An implementation of RFC 7049 - Concise Binary Object Representation (CBOR)" 2 | HOMEPAGE = "https://github.com/brianolson/cbor_py" 3 | LICENSE = "Apache-2.0" 4 | LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/Apache-2.0;md5=89aea4e17d99a7cacdbeed46a0096b10" 5 | 6 | SRC_URI[md5sum] = "22b03b59784fd78cb6c27aa498af0db6" 7 | SRC_URI[sha256sum] = "13225a262ddf5615cbd9fd55a76a0d53069d18b07d2e9f19c39e6acb8609bbb6" 8 | 9 | PYPI_PACKAGE = "cbor" 10 | 11 | inherit pypi setuptools3 12 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/python/python3-cc2538-bsl_2.1.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "A script that communicates with the boot loader of the TI CC2538 and other SoCs (System on Chips)." 2 | HOMEPAGE = "https://github.com/JelmerT/cc2538-bsl" 3 | SECTION = "console" 4 | LICENSE = "BSD" 5 | LIC_FILES_CHKSUM = "file://cc2538-bsl.py;md5=fd7e87c62fec34c3f872ee3fc0a46d81" 6 | 7 | PR = "r1" 8 | 9 | SRCNAME = "cc2538-bsl" 10 | SRC_URI = "https://github.com/JelmerT/${SRCNAME}/archive/${PV}.tar.gz" 11 | 12 | SRC_URI[md5sum] = "ad7b1e48b4cac832b0a8045cd4d6dd2d" 13 | SRC_URI[sha256sum] = "30f2d5a200ffecd549e05311e94681514ff6e251aeee8e87b88c0ca9d219aad0" 14 | 15 | S = "${WORKDIR}/${SRCNAME}-${PV}" 16 | 17 | do_install(){ 18 | install -d ${D}${bindir} 19 | install -m 0755 ${S}/cc2538-bsl.py ${D}${bindir}/ 20 | } 21 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/python/python3-codecov_2.1.7.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "Hosted coverage reports for Github, Bitbucket and Gitlab" 2 | HOMEPAGE = "https://pypi.python.org/pypi/codecov/" 3 | SECTION = "devel/python" 4 | LICENSE = "Apache-2.0" 5 | LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/Apache-2.0;md5=89aea4e17d99a7cacdbeed46a0096b10" 6 | 7 | PYPI_PACKAGE = "codecov" 8 | 9 | SRC_URI[md5sum] = "ff791c7e7d9cdcff322a8e08e22b1904" 10 | SRC_URI[sha256sum] = "491938ad774ea94a963d5d16354c7299e90422a33a353ba0d38d0943ed1d5091" 11 | 12 | RDEPENDS_${PN}_class-target += " \ 13 | ${PYTHON_PN}-requests \ 14 | ${PYTHON_PN}-coverage \ 15 | " 16 | 17 | inherit pypi setuptools3 18 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/python/python3-distlib_0.3.1.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "Low-level components of distutils2/packaging" 2 | HOMEPAGE = "https://pypi.org/project/distlib/" 3 | SECTION = "packaging/python" 4 | LICENSE = "Python-2.0" 5 | LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=f6a11430d5cd6e2cd3832ee94f22ddfc" 6 | 7 | SRC_URI[md5sum] = "4baf787d8aceb260d6f77cb31bf27cf6" 8 | SRC_URI[sha256sum] = "edf6116872c863e1aa9d5bb7cb5e05a022c519a4594dc703843343a9ddd9bff1" 9 | 10 | PYPI_PACKAGE = "distlib" 11 | PYPI_PACKAGE_EXT = "zip" 12 | 13 | inherit pypi setuptools3 14 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/python/python3-filelock_3.0.10.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "A platform independent file lock." 2 | HOMEPAGE = "https://github.com/benediktschmitt/py-filelock" 3 | SECTION = "devel/python" 4 | LICENSE = "Unlicense" 5 | LIC_FILES_CHKSUM = "file://LICENSE.rst;md5=782ad7bbca1c0963a9aaf6bf97202d9b" 6 | 7 | PYPI_PACKAGE = "filelock" 8 | 9 | SRC_URI[sha256sum] = "d610c1bb404daf85976d7a82eb2ada120f04671007266b708606565dd03b5be6" 10 | 11 | inherit pypi setuptools3 12 | 13 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/python/python3-gcovr_4.2.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "A Python script for summarizing gcov data." 2 | SECTION = "devel/python" 3 | LICENSE = "BSD" 4 | LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/BSD;md5=3775480a712fc46a69647678acb234cb" 5 | 6 | PYPI_PACKAGE = "gcovr" 7 | 8 | SRC_URI[md5sum] = "83f75d78d59cbd8a34275a372a47f557" 9 | SRC_URI[sha256sum] = "5aae34dc81e51600cfecbbbce3c3a80ce3f7548bc0aa1faa4b74ecd18f6fca3f" 10 | 11 | inherit pypi setuptools3 12 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/python/python3-hkdf_git.bb: -------------------------------------------------------------------------------- 1 | SUMMARY = "HMAC-based Extract-and-Expand Key Derivation Function (HKDF)" 2 | HOMEPAGE = "https://github.com/casebeer/python-hkdf" 3 | LICENSE = "BSD-2-Clause" 4 | LIC_FILES_CHKSUM = "file://LICENSE;md5=f553aec9729c2f78a3dcc38d78a3cc80" 5 | 6 | inherit setuptools3 7 | 8 | PV = "git-src${SRCDATE}-r${SRCPV}" 9 | 10 | SRC_URI = "git://github.com/casebeer/python-hkdf.git;protocol=https" 11 | SRCREV = "${AUTOREV}" 12 | 13 | S = "${WORKDIR}/git/" 14 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/python/python3-intelhex_2.2.1.bb: -------------------------------------------------------------------------------- 1 | SUMMARY = "Python library for Intel HEX files manipulations" 2 | HOMEPAGE = "https://pypi.python.org/pypi/intelhex/" 3 | SECTION = "devel/python" 4 | LICENSE = "BSD-3-Clause" 5 | 6 | LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=4eba844696655c3eae07aca8e3a94772" 7 | 8 | SRC_URI[md5sum] = "9ce7402e0fd33249aef52cbf437b4ab7" 9 | SRC_URI[sha256sum] = "009d8511e0d50639230c39af9607deee771cf026f67ef7507a8c3fd4fa927832" 10 | 11 | inherit pypi setuptools3 12 | 13 | do_install_append() { 14 | # fix up commands that use exact #! for python 15 | for i in ${D}${bindir}/*; do 16 | sed -i 's@^#!/usr/bin/python@#!/usr/bin/env python3@' $i 17 | done 18 | } 19 | 20 | BBCLASSEXTEND = "native nativesdk" 21 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/python/python3-mccabe_0.2.1.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "McCabe checker, plugin for flake8" 2 | HOMEPAGE = "https://github.com/dreamhost/cliff" 3 | SECTION = "devel/python" 4 | LICENSE = "Apache-2.0" 5 | LIC_FILES_CHKSUM = "file://README.rst;md5=aa0383f6aee4f5c20084a97cd13164c4" 6 | 7 | SRC_URI[md5sum] = "5a3f3fa6a4bad126c88aaaa7dab682f5" 8 | SRC_URI[sha256sum] = "5a2a170e47de5593a6abfae1e9542bd2c3924ac62bbe4e6ed96c953c0352243a" 9 | 10 | RDEPENDS_${PN} += "${PYTHON_PN}-prettytable \ 11 | ${PYTHON_PN}-cmd2 \ 12 | ${PYTHON_PN}-pyparsing" 13 | 14 | inherit pypi setuptools3 15 | 16 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/python/python3-mock_4.0.2.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "A Python Mocking and Patching Library for Testing" 2 | HOMEPAGE = "https://pypi.python.org/pypi/mock" 3 | SECTION = "devel/python" 4 | LICENSE = "Apache-2.0" 5 | LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=de9dfbf780446b18aab11f00baaf5b7e" 6 | 7 | RDEPENDS_${PN} += "${PYTHON_PN}-prettytable \ 8 | ${PYTHON_PN}-cmd2 \ 9 | ${PYTHON_PN}-pyparsing \ 10 | ${PYTHON_PN}-mccabe \ 11 | ${PYTHON_PN}-pep8 \ 12 | ${PYTHON_PN}-pyflakes" 13 | 14 | PYPI_PACKAGE = "mock" 15 | 16 | inherit setuptools3 pypi 17 | 18 | SRC_URI[md5sum] = "6466619b89c2969dc57722ad73f85676" 19 | SRC_URI[sha256sum] = "dd33eb70232b6118298d516bbcecd26704689c386594f0f3c4f13867b2c56f72" 20 | 21 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/python/python3-paste_3.4.1.bb: -------------------------------------------------------------------------------- 1 | SUMMARY = "Tools for using a Web Server Gateway Interface stack" 2 | HOMEPAGE = "http://pythonpaste.org/" 3 | LICENSE = "MIT" 4 | 5 | LIC_FILES_CHKSUM = "file://docs/license.txt;md5=1798f29d55080c60365e6283cb49779c" 6 | 7 | SRC_URI[md5sum] = "1e60b2fbaf60da2d670468d9863427cb" 8 | SRC_URI[sha256sum] = "379c50d0a8016cc15b15d7f43445d8b9ac4b662943a0f6dcb8b08095deb158b3" 9 | 10 | PYPI_PACKAGE = "Paste" 11 | inherit pypi setuptools3 12 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/python/python3-pep8_1.7.1.bb: -------------------------------------------------------------------------------- 1 | SUMMARY = "Python style guide checker" 2 | SECTION = "devel/python" 3 | HOMEPAGE= "https://pypi.org/project/pep8/" 4 | LICENSE = "Apache-2.0" 5 | LIC_FILES_CHKSUM = "file://README.rst;md5=d8ebbbe831259ce010179d2f310b0f3e" 6 | 7 | PYPI_PACKAGE = "pep8" 8 | 9 | SRC_URI[md5sum] = "603821d06db945c71d811b5a8d78423c" 10 | SRC_URI[sha256sum] = "fe249b52e20498e59e0b5c5256aa52ee99fc295b26ec9eaa85776ffdb9fe6374" 11 | 12 | inherit pypi setuptools3 13 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/python/python3-pluggy_0.6.0.bb: -------------------------------------------------------------------------------- 1 | ## -*-conf-*- 2 | DESCRIPTION = "plugin and hook calling mechanisms for python" 3 | HOMEPAGE = "https://pypi.python.org/pypi/pluggy/" 4 | SECTION = "devel/python" 5 | LICENSE = "MIT" 6 | LIC_FILES_CHKSUM = "file://LICENSE;md5=338dad807ed9337bfaeb9979c3bfe20f" 7 | 8 | PR = "r0" 9 | 10 | SRC_URI[md5sum] = "ffdde7c3a5ba9a440404570366ffb6d5" 11 | SRC_URI[sha256sum] = "7f8ae7f5bdf75671a718d2daf0a64b7885f74510bcd98b1a0bb420eb9a9d0cff" 12 | 13 | inherit pypi setuptools3 14 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/python/python3-pydispatcher_2.0.5.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "Multi-producer-multi-consumer signal dispatching mechanism" 2 | SECTION = "devel/python" 3 | LICENSE = "BSD" 4 | LIC_FILES_CHKSUM = "file://license.txt;md5=09dffabd4d29ee02f66b0b7f808d57c2" 5 | 6 | PYPI_PACKAGE = "PyDispatcher" 7 | 8 | SRC_URI[md5sum] = "1b9c2ca33580c2770577add7130b0b28" 9 | SRC_URI[sha256sum] = "5570069e1b1769af1fe481de6dd1d3a388492acddd2cdad7a3bde145615d5caf" 10 | 11 | inherit pypi setuptools3 12 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/python/python3-pyelftools_0.26.bb: -------------------------------------------------------------------------------- 1 | SUMMARY = "Library for analyzing ELF files and DWARF debugging information" 2 | DESCRIPTION = "pyelftools is a pure-Python library for parsing and analyzing \ 3 | ELF files and DWARF debugging information" 4 | HOMEPAGE = "https://github.com/eliben/pyelftools" 5 | SECTION = "devel/python" 6 | LICENSE = "PD" 7 | LIC_FILES_CHKSUM = "file://LICENSE;md5=5ce2a2b07fca326bc7c146d10105ccfc" 8 | 9 | SRC_URI[md5sum] = "0ba0de4b47127249c4d632ae299cb0e8" 10 | SRC_URI[sha256sum] = "86ac6cee19f6c945e8dedf78c6ee74f1112bd14da5a658d8c9d4103aed5756a2" 11 | 12 | PYPI_PACKAGE = "pyelftools" 13 | 14 | inherit pypi setuptools3 15 | 16 | BBCLASSEXTEND = "native" 17 | 18 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/python/python3-pyocd_0.27.0.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "pyOCD, an Open Source python based library for programming and debugging ARM Cortex-M microcontrollers using CMSIS-DAP. " 2 | LICENSE = "Apache-2.0" 3 | LIC_FILES_CHKSUM = "file://LICENSE;md5=421492e27872cb498685e9d7649f63a2" 4 | HOMEPAGE = "https://github.com/mbedmicro/pyOCD" 5 | SUMMARY = "CMSIS-DAP debugger for Python" 6 | 7 | DEPENDS += "${PYTHON_PN}-setuptools-scm-git-archive-native" 8 | 9 | SRC_URI[md5sum] = "ed01d209bb06e908b8868ccf91b091a1" 10 | SRC_URI[sha256sum] = "a5fd9d3faa64397adc6426f8ddb771ab4cb31e7fcaacff9a352ea70615ef3e97" 11 | 12 | PYPI_PACKAGE = "pyocd" 13 | 14 | inherit pypi setuptools3 15 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/python/python3-pyserial/run-ptest: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | 4 | pytest -o log_cli=true -o log_cli_level=INFO | sed -e 's/\[...%\]//g'| sed -e 's/PASSED/PASS/g'| sed -e 's/FAILED/FAIL/g'|sed -e 's/SKIPPED/SKIP/g'| awk '{if ($NF=="PASS" || $NF=="FAIL" || $NF=="SKIP" || $NF=="XFAIL" || $NF=="XPASS"){printf "%s: %s\n", $NF, $0}else{print}}'| awk '{if ($NF=="PASS" || $NF=="FAIL" || $NF=="SKIP" || $NF=="XFAIL" || $NF=="XPASS") {$NF="";print $0}else{print}}' 5 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/python/python3-pyserial_3.4.bb: -------------------------------------------------------------------------------- 1 | SUMMARY = "Serial Port Support for Python" 2 | LICENSE = "BSD-3-Clause" 3 | LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=d476d94926db6e0008a5b3860d1f5c0d" 4 | 5 | SRC_URI[md5sum] = "ed6183b15519a0ae96675e9c3330c69b" 6 | SRC_URI[sha256sum] = "6e2d401fdee0eab996cf734e67773a0143b932772ca8b42451440cfed942c627" 7 | 8 | inherit pypi setuptools3 ptest 9 | 10 | PACKAGES =+ "${PN}-java ${PN}-osx ${PN}-win32 ${PN}-tools" 11 | 12 | FILES_${PN}-java = " \ 13 | ${PYTHON_SITEPACKAGES_DIR}/serial/*java* \ 14 | ${PYTHON_SITEPACKAGES_DIR}/serial/__pycache__/*java* \ 15 | " 16 | 17 | FILES_${PN}-osx = " \ 18 | ${PYTHON_SITEPACKAGES_DIR}/serial/tools/*osx* \ 19 | ${PYTHON_SITEPACKAGES_DIR}/serial/tools/__pycache__/*osx* \ 20 | " 21 | 22 | FILES_${PN}-win32 = " \ 23 | ${PYTHON_SITEPACKAGES_DIR}/serial/*serialcli* \ 24 | ${PYTHON_SITEPACKAGES_DIR}/serial/__pycache__/*serialcli* \ 25 | ${PYTHON_SITEPACKAGES_DIR}/serial/*win32* \ 26 | ${PYTHON_SITEPACKAGES_DIR}/serial/__pycache__/*win32* \ 27 | ${PYTHON_SITEPACKAGES_DIR}/serial/tools/miniterm* \ 28 | ${PYTHON_SITEPACKAGES_DIR}/serial/tools/__pycache__/miniterm* \ 29 | ${PYTHON_SITEPACKAGES_DIR}/serial/tools/*windows* \ 30 | ${PYTHON_SITEPACKAGES_DIR}/serial/tools/__pycache__/*windows* \ 31 | " 32 | 33 | RDEPENDS_${PN} = "\ 34 | ${PYTHON_PN}-fcntl \ 35 | ${PYTHON_PN}-io \ 36 | ${PYTHON_PN}-logging \ 37 | ${PYTHON_PN}-netclient \ 38 | ${PYTHON_PN}-numbers \ 39 | ${PYTHON_PN}-shell \ 40 | ${PYTHON_PN}-stringold \ 41 | ${PYTHON_PN}-threading \ 42 | " 43 | 44 | BBCLASSEXTEND = "native nativesdk" 45 | 46 | SRC_URI += " \ 47 | file://run-ptest \ 48 | " 49 | 50 | RDEPENDS_${PN}-ptest += " \ 51 | ${PYTHON_PN}-pytest \ 52 | " 53 | 54 | do_install_ptest() { 55 | install -d ${D}${PTEST_PATH}/test 56 | cp -rf ${S}/test/* ${D}${PTEST_PATH}/test/ 57 | } 58 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/python/python3-pytest-cov_2.10.0.bb: -------------------------------------------------------------------------------- 1 | ## -*-conf-*- 2 | DESCRIPTION = "pytest-cov: Pytest plugin for measuring coverage." 3 | HOMEPAGE = "https://pypi.python.org/pypi/pytest-cov/" 4 | SECTION = "devel/python" 5 | LICENSE = "MIT" 6 | LIC_FILES_CHKSUM = "file://LICENSE;md5=cbc4e25353c748c817db2daffe605e43" 7 | 8 | SRC_URI[md5sum] = "59f10b3749cfba88df81ecc02b7b4202" 9 | SRC_URI[sha256sum] = "1a629dc9f48e53512fcbfda6b07de490c374b0c83c55ff7a1720b3fccff0ac87" 10 | 11 | RDEPENDS_${PN} = "${PYTHON_PN}-pytest" 12 | 13 | inherit pypi setuptools3 14 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/python/python3-setuptools-scm-git-archive_1.0.bb: -------------------------------------------------------------------------------- 1 | SUMMARY = "setuptools_scm plugin for git archives" 2 | HOMEPAGE = "https://github.com/Changaco/setuptools_scm_git_archive/" 3 | AUTHOR = "Changaco" 4 | LICENSE = "MIT" 5 | LIC_FILES_CHKSUM = "file://LICENSE;md5=838c366f69b72c5df05c96dff79b35f2" 6 | 7 | PYPI_PACKAGE = "setuptools_scm_git_archive" 8 | 9 | DEPENDS += "\ 10 | ${PYTHON_PN}-setuptools-scm-native \ 11 | " 12 | 13 | RDEPENDS_${PN} += "\ 14 | ${PYTHON_PN}-setuptools-scm \ 15 | " 16 | 17 | DEPENDS += "${PYTHON_PN}-setuptools-scm-native" 18 | 19 | SRC_URI[md5sum] = "cb4ca99e97edea548117fe0d80cbd089" 20 | SRC_URI[sha256sum] = "52425f905518247c685fc64c5fdba6e1e74443c8562e141c8de56059be0e31da" 21 | 22 | BBCLASSEXTEND = "native" 23 | 24 | inherit pypi setuptools3 25 | 26 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/python/python3-testfixtures_6.14.1.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "A collection of helpers and mock objects for unit tests and doc tests." 2 | SECTION = "devel/python" 3 | LICENSE = "MIT" 4 | LIC_FILES_CHKSUM = "file://docs/license.txt;md5=b19f00294e65148c2779131bd7a10fd3" 5 | 6 | PYPI_PACKAGE = "testfixtures" 7 | 8 | SRC_URI[md5sum] = "d988e611192cb633d6a4dfe94af55dd7" 9 | SRC_URI[sha256sum] = "58d2b3146d93bc5ddb0cd24e0ccacb13e29bdb61e5c81235c58f7b8ee4470366" 10 | 11 | inherit pypi setuptools3 12 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/python/python3-toml_0.10.0.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "Python Library for Tom's Obvious, Minimal Language." 2 | HOMEPAGE = "https://github.com/uiri/toml" 3 | SECTION = "devel/python" 4 | LICENSE = "MIT" 5 | LIC_FILES_CHKSUM = "file://LICENSE;md5=6d6012eea477117abf51c31262a152f8" 6 | 7 | PYPI_PACKAGE = "toml" 8 | 9 | SRC_URI[sha256sum] = "229f81c57791a41d65e399fc06bf0848bab550a9dfd5ed66df18ce5f05e73d5c" 10 | 11 | inherit pypi setuptools3 12 | 13 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/python/python3-tox_3.6.0.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "virtualenv-based automation of test activities" 2 | HOMEPAGE = "http://tox.testrun.org" 3 | SECTION = "devel/python" 4 | LICENSE = "MIT" 5 | LIC_FILES_CHKSUM = "file://LICENSE;md5=f24505dfbdd8c22c61de6383f2e74bf9" 6 | 7 | PYPI_PACKAGE = "tox" 8 | 9 | SRC_URI[sha256sum] = "304177defdcb403d84aeb0400b1625b1e65a7fff19f0441329f9f76ebf67882f" 10 | 11 | inherit pypi setuptools3 12 | 13 | DEPENDS += "${PYTHON_PN}-setuptools-scm-native" 14 | 15 | RDEPENDS_${PN}_class-target += " \ 16 | python3-virtualenv \ 17 | python3-py \ 18 | python3-filelock \ 19 | python3-toml \ 20 | python3-pluggy \ 21 | " 22 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/python/python3-virtualenv_20.4.3.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "Virtual Python Environment builder" 2 | HOMEPAGE = "https://pypi.python.org/pypi/virtualenv" 3 | SECTION = "devel/python" 4 | LICENSE = "MIT" 5 | LIC_FILES_CHKSUM = "file://LICENSE;md5=0ce089158cf60a8ab6abb452b6405538" 6 | 7 | DEPENDS += "${PYTHON_PN}-setuptools-scm-git-archive-native" 8 | 9 | SRC_URI[md5sum] = "c4d8d3bfc3cac8ab091795473b601e50" 10 | SRC_URI[sha256sum] = "49ec4eb4c224c6f7dd81bb6d0a28a09ecae5894f4e593c89b0db0885f565a107" 11 | 12 | PYPI_PACKAGE = "virtualenv" 13 | 14 | inherit pypi setuptools3 15 | 16 | RDEPENDS_${PN}_class-target += " \ 17 | python3-distlib \ 18 | python3-appdirs \ 19 | " 20 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/python/python3-webob_1.8.2.bb: -------------------------------------------------------------------------------- 1 | ## -*-conf-*- 2 | DESCRIPTION = "WSGI request and response object" 3 | HOMEPAGE = "https://pypi.python.org/pypi/WebOb/" 4 | SECTION = "devel/python" 5 | LICENSE = "MIT" 6 | LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/MIT;md5=0835ade698e0bcf8506ecda2f7b4f302" 7 | 8 | PR = "r0" 9 | 10 | PYPI_PACKAGE = "WebOb" 11 | 12 | SRC_URI[md5sum] = "d04756e6683fedddba52eafbe9adf404" 13 | SRC_URI[sha256sum] = "1fe722f2ab857685fc96edec567dc40b1875b21219b3b348e58cd8c4d5ea7df3" 14 | 15 | inherit pypi setuptools3 16 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/python/python3-webtest_2.0.35.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "Helper to test WSGI applications" 2 | HOMEPAGE = "https://pypi.python.org/pypi/WebTest/" 3 | SECTION = "devel/python" 4 | LICENSE = "MIT" 5 | LIC_FILES_CHKSUM = "file://license.rst;md5=64f013a9d7a2a8ffc8d016a2d4214bcd" 6 | 7 | PYPI_PACKAGE = "WebTest" 8 | 9 | SRC_URI[md5sum] = "a5d027ffa0991fdf20e305c62bd37791" 10 | SRC_URI[sha256sum] = "aac168b5b2b4f200af4e35867cf316712210e3d5db81c1cbdff38722647bb087" 11 | 12 | inherit pypi setuptools3 13 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/python/python3_%.bbappend: -------------------------------------------------------------------------------- 1 | ALTERNATIVE_${PN}-dev += "python python-config" 2 | ALTERNATIVE_LINK_NAME[python] = "${bindir}/python" 3 | ALTERNATIVE_TARGET[python] = "${bindir}/python3" 4 | ALTERNATIVE_LINK_NAME[python-config] = "${bindir}/python-config" 5 | ALTERNATIVE_TARGET[python-config] = "${bindir}/python3-config" 6 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-devtools/segger-jlink/segger-jlink_760b.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "SEGGER J-Link Software and Documentation pack" 2 | LICENSE = "CLOSED" 3 | LIC_FILES_CHKSUM = "\ 4 | file://Doc/LicenseIncGUI.txt;md5=e4b273c1048dd2c3afe701297ce62697 \ 5 | " 6 | S = "${WORKDIR}/JLink_Linux_V${PV}_arm" 7 | PR = "r0" 8 | 9 | SRC_URI="https://www.segger.com/downloads/jlink/JLink_Linux_V${PV}_arm.tgz" 10 | BODY_DATA='accept_license_agreement=accepted&non_emb_ctr=confirmed&submit="Download software"' 11 | 12 | do_fetch () { 13 | /usr/bin/wget --post-data '${BODY_DATA}' ${SRC_URI} -O ${DL_DIR}/JLink_Linux_V${PV}_arm.tgz 14 | } 15 | 16 | inherit relative_symlinks 17 | 18 | do_install () { 19 | install -d ${D}/etc/udev/rules.d 20 | install -m 755 ${S}/99-jlink.rules ${D}/etc/udev/rules.d/ 21 | 22 | install -d ${D}/usr/local/share/JLink 23 | install -m 755 ${S}/JLinkExe ${D}/usr/local/share/JLink/JLinkExe 24 | install -m 755 ${S}/JLinkGDBServer ${D}/usr/local/share/JLink/JLinkGDBServer 25 | install -m 755 ${S}/libjlinkarm.so.7.60.2 ${D}/usr/local/share/JLink/libjlinkarm.so.7.60.2 26 | lnr ${D}/usr/local/share/JLink/libjlinkarm.so.7.60.2 ${D}/usr/local/share/JLink/libjlinkarm.so.7 27 | lnr ${D}/usr/local/share/JLink/libjlinkarm.so.7 ${D}/usr/local/share/JLink/libjlinkarm.so 28 | } 29 | 30 | INSANE_SKIP_${PN} = "already-stripped ldflags dev-so" 31 | 32 | FILES_${PN} += "/usr/local/share/JLink/JLinkExe " 33 | FILES_${PN} += "/usr/local/share/JLink/JLinkGDBServer " 34 | FILES_${PN} += "/usr/local/share/JLink/libjlinkarm.so.7.60.2 " 35 | FILES_${PN} += "/usr/local/share/JLink/libjlinkarm.so.7 " 36 | FILES_${PN} += "/usr/local/share/JLink/libjlinkarm.so " 37 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-extended/procps/procps/sysctl.conf: -------------------------------------------------------------------------------- 1 | # Uncomment the next line to enable packet forwarding for IPv4 2 | net.ipv4.ip_forward=1 3 | 4 | # Uncomment the next line to enable packet forwarding for IPv6 5 | # Enabling this option disables Stateless Address Autoconfiguration 6 | # based on Router Advertisements for this host 7 | net.ipv6.conf.all.forwarding=1 8 | 9 | # Dont' filter bridges for VMs networks 10 | net.bridge.bridge-nf-call-ip6tables = 0 11 | net.bridge.bridge-nf-call-iptables = 0 12 | net.bridge.bridge-nf-call-arptables = 0 13 | 14 | # Désactive autoconf IPv6 sur toutes les interfaces 15 | net.ipv6.conf.default.autoconf = 0 16 | net.ipv6.conf.default.accept_ra = 0 17 | net.ipv6.conf.default.accept_ra_defrtr = 0 18 | # unknown key 19 | # net.ipv6.conf.default.accept_ra_rtr_pref = 0 20 | net.ipv6.conf.default.accept_ra_pinfo = 0 21 | net.ipv6.conf.default.accept_source_route = 0 22 | net.ipv6.conf.default.accept_redirects = 0 23 | 24 | net.ipv6.conf.all.autoconf = 0 25 | net.ipv6.conf.all.accept_ra = 0 26 | net.ipv6.conf.all.accept_ra_defrtr = 0 27 | # unknown key 28 | # net.ipv6.conf.all.accept_ra_rtr_pref = 0 29 | net.ipv6.conf.all.accept_ra_pinfo = 0 30 | net.ipv6.conf.all.accept_source_route = 0 31 | net.ipv6.conf.all.accept_redirects = 0 32 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-extended/procps/procps_%.bbappend: -------------------------------------------------------------------------------- 1 | FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:" 2 | 3 | SRC_URI += "file://sysctl.conf" 4 | 5 | do_install_append() { 6 | install -d ${D}${sysconfdir} 7 | install -m 0644 ${WORKDIR}/sysctl.conf ${D}${sysconfdir}/sysctl.conf 8 | } 9 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-extended/sudo/sudo_1.8.%.bbappend: -------------------------------------------------------------------------------- 1 | # www-data user requires admin rights for controlling the USB ports 2 | # on the RPI3 gateway image 3 | do_install_append () { 4 | echo "www-data ALL= NOPASSWD: /usr/bin/ykushcmd" >> ${D}${sysconfdir}/sudoers.d/www-data 5 | echo "www-data ALL= NOPASSWD:SETENV: /opt/lora/start.sh" >> ${D}${sysconfdir}/sudoers.d/www-data 6 | echo "www-data ALL= NOPASSWD:SETENV: /usr/bin/python3" >> ${D}${sysconfdir}/sudoers.d/www-data 7 | echo "www-data ALL= NOPASSWD:SETENV: /usr/bin/uhubctl" >> ${D}${sysconfdir}/sudoers.d/www-data 8 | echo "www-data ALL= NOPASSWD:SETENV: /usr/bin/udevadm" >> ${D}${sysconfdir}/sudoers.d/www-data 9 | } 10 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-kernel/linux/files/0002-davinci_emac-allow-setting-the-mac-address-with-an-e.patch: -------------------------------------------------------------------------------- 1 | From 83298c0df10a55a5fc155860de8785a959e9026d Mon Sep 17 00:00:00 2001 2 | From: =?UTF-8?q?Ga=C3=ABtan=20Harter?= 3 | Date: Wed, 3 Feb 2021 15:53:20 +0100 4 | Subject: [PATCH 2/7] davinci_emac: allow setting the mac address with an 5 | 'eth=' boot parameter 6 | MIME-Version: 1.0 7 | Content-Type: text/plain; charset=UTF-8 8 | Content-Transfer-Encoding: 8bit 9 | 10 | This allows backward compatibility with u-boot passing the ethernet 11 | address through 'eth=' on the command line. 12 | 13 | Signed-off-by: Gaëtan Harter 14 | --- 15 | drivers/net/ethernet/ti/davinci_emac.c | 41 ++++++++++++++++++++++++++ 16 | 1 file changed, 41 insertions(+) 17 | 18 | diff --git a/drivers/net/ethernet/ti/davinci_emac.c b/drivers/net/ethernet/ti/davinci_emac.c 19 | index ae27be85e363..73d80dd57947 100644 20 | --- a/drivers/net/ethernet/ti/davinci_emac.c 21 | +++ b/drivers/net/ethernet/ti/davinci_emac.c 22 | @@ -1744,6 +1744,41 @@ davinci_emac_of_get_pdata(struct platform_device *pdev, struct emac_priv *priv) 23 | return pdata; 24 | } 25 | 26 | +/* Copied from arch/c6x/kernel/soc.c */ 27 | +static u8 cmdline_mac[6]; 28 | + 29 | +static int __init get_mac_addr_from_cmdline(char *str) 30 | +{ 31 | + int count, i, val; 32 | + 33 | + for (count = 0; count < 6 && *str; count++, str += 3) { 34 | + if (!isxdigit(str[0]) || !isxdigit(str[1])) 35 | + return 0; 36 | + if (str[2] != (count < 5 ? ':' : '\0')) 37 | + return 0; 38 | + 39 | + for (i = 0, val = 0; i < 2; i++) { 40 | + val = val << 4; 41 | + val |= isdigit(str[i]) ? 42 | + str[i] - '0' : toupper(str[i]) - 'A' + 10; 43 | + } 44 | + cmdline_mac[count] = val; 45 | + } 46 | + return 1; 47 | +} 48 | + 49 | +/* IoT-LAB Hack to get ethernet address from command line */ 50 | +__setup("eth=", get_mac_addr_from_cmdline); 51 | + 52 | +static int emac_mac_addr_from_cmdline(u8 *mac_addr) 53 | +{ 54 | + if (is_valid_ether_addr(cmdline_mac)) { 55 | + ether_addr_copy(mac_addr, cmdline_mac); 56 | + return 0; 57 | + } 58 | + return 1; 59 | +} 60 | + 61 | static int davinci_emac_try_get_mac(struct platform_device *pdev, 62 | int instance, u8 *mac_addr) 63 | { 64 | @@ -1897,6 +1932,12 @@ static int davinci_emac_probe(struct platform_device *pdev) 65 | if (!rc) 66 | ether_addr_copy(ndev->dev_addr, priv->mac_addr); 67 | 68 | + if (!emac_mac_addr_from_cmdline(priv->mac_addr)) { 69 | + ether_addr_copy(ndev->dev_addr, priv->mac_addr); 70 | + dev_info(&pdev->dev, "using command line MAC addr: %pM\n", 71 | + priv->mac_addr); 72 | + } 73 | + 74 | if (!is_valid_ether_addr(priv->mac_addr)) { 75 | /* Use random MAC if still none obtained. */ 76 | eth_hw_addr_random(ndev); 77 | -- 78 | 2.17.1 79 | 80 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-kernel/linux/files/defconfig: -------------------------------------------------------------------------------- 1 | CONFIG_LOCALVERSION="-iotlab" 2 | # CONFIG_LOCALVERSION_AUTO is not set 3 | CONFIG_DEFAULT_HOSTNAME="iotlab-board" 4 | CONFIG_SYSVIPC=y 5 | CONFIG_NO_HZ=y 6 | CONFIG_HIGH_RES_TIMERS=y 7 | CONFIG_BSD_PROCESS_ACCT=y 8 | CONFIG_IKCONFIG=y 9 | CONFIG_IKCONFIG_PROC=y 10 | CONFIG_LOG_BUF_SHIFT=14 11 | CONFIG_SYSFS_DEPRECATED=y 12 | CONFIG_SYSFS_DEPRECATED_V2=y 13 | CONFIG_BLK_DEV_INITRD=y 14 | # CONFIG_RD_BZIP2 is not set 15 | # CONFIG_RD_LZMA is not set 16 | # CONFIG_RD_XZ is not set 17 | # CONFIG_RD_LZO is not set 18 | # CONFIG_RD_LZ4 is not set 19 | CONFIG_CC_OPTIMIZE_FOR_SIZE=y 20 | CONFIG_KALLSYMS_ALL=y 21 | CONFIG_BPF_SYSCALL=y 22 | CONFIG_EMBEDDED=y 23 | CONFIG_SLAB=y 24 | CONFIG_OMAP_RESET_CLOCKS=y 25 | CONFIG_ARCH_OMAP3=y 26 | # CONFIG_SOC_OMAP3430 is not set 27 | # CONFIG_SOC_TI81XX is not set 28 | # CONFIG_MACH_OMAP3517EVM is not set 29 | # CONFIG_MACH_OMAP3_PANDORA is not set 30 | CONFIG_PL310_ERRATA_753970=y 31 | CONFIG_ARM_ERRATA_720789=y 32 | CONFIG_ARM_ERRATA_857271=y 33 | CONFIG_ARM_ERRATA_857272=y 34 | CONFIG_ARM_ERRATA_814220=y 35 | CONFIG_ARM_APPENDED_DTB=y 36 | CONFIG_ARM_ATAG_DTB_COMPAT=y 37 | CONFIG_ARM_ATAG_DTB_COMPAT_CMDLINE_EXTEND=y 38 | CONFIG_CPU_FREQ=y 39 | CONFIG_CPU_FREQ_DEFAULT_GOV_ONDEMAND=y 40 | CONFIG_CPU_FREQ_GOV_POWERSAVE=y 41 | # CONFIG_SUSPEND is not set 42 | # CONFIG_BLK_DEV_BSG is not set 43 | CONFIG_PARTITION_ADVANCED=y 44 | # CONFIG_EFI_PARTITION is not set 45 | CONFIG_CMDLINE_PARTITION=y 46 | # CONFIG_CORE_DUMP_DEFAULT_ELF_HEADERS is not set 47 | CONFIG_BINFMT_MISC=y 48 | CONFIG_NET=y 49 | CONFIG_PACKET=y 50 | CONFIG_UNIX=y 51 | CONFIG_NET_KEY=y 52 | CONFIG_INET=y 53 | CONFIG_IP_PNP=y 54 | CONFIG_IP_PNP_DHCP=y 55 | CONFIG_IP_PNP_BOOTP=y 56 | CONFIG_IP_PNP_RARP=y 57 | # CONFIG_IPV6_SIT is not set 58 | CONFIG_NETFILTER=y 59 | CONFIG_NF_CONNTRACK=y 60 | CONFIG_NF_CONNTRACK_EVENTS=y 61 | CONFIG_NF_CONNTRACK_TIMEOUT=y 62 | CONFIG_NF_CONNTRACK_TIMESTAMP=y 63 | # CONFIG_NF_CT_PROTO_DCCP is not set 64 | # CONFIG_NF_CT_PROTO_SCTP is not set 65 | # CONFIG_NF_CT_PROTO_UDPLITE is not set 66 | CONFIG_NF_TABLES=y 67 | CONFIG_NFT_CT=y 68 | CONFIG_NFT_LIMIT=y 69 | CONFIG_NFT_MASQ=y 70 | CONFIG_NFT_NAT=y 71 | CONFIG_NFT_REJECT=y 72 | CONFIG_NETFILTER_XT_TARGET_LOG=y 73 | CONFIG_NETFILTER_XT_MATCH_CONNTRACK=y 74 | CONFIG_NF_TABLES_IPV4=y 75 | CONFIG_NF_TABLES_ARP=y 76 | CONFIG_IP_NF_IPTABLES=y 77 | CONFIG_IP_NF_FILTER=y 78 | CONFIG_IP_NF_TARGET_REJECT=y 79 | CONFIG_IP_NF_NAT=y 80 | CONFIG_IP_NF_TARGET_MASQUERADE=y 81 | CONFIG_IP_NF_TARGET_REDIRECT=y 82 | CONFIG_IP_NF_MANGLE=y 83 | CONFIG_IP_NF_ARPTABLES=y 84 | CONFIG_IP_NF_ARPFILTER=y 85 | CONFIG_NF_TABLES_IPV6=y 86 | CONFIG_IP6_NF_IPTABLES=y 87 | CONFIG_IP6_NF_FILTER=y 88 | CONFIG_IP6_NF_TARGET_REJECT=y 89 | CONFIG_IP6_NF_MANGLE=y 90 | CONFIG_IP6_NF_NAT=y 91 | CONFIG_IP6_NF_TARGET_MASQUERADE=y 92 | CONFIG_BPFILTER=y 93 | CONFIG_CFG80211=y 94 | CONFIG_CFG80211_WEXT=y 95 | CONFIG_MAC80211=y 96 | CONFIG_UEVENT_HELPER=y 97 | CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" 98 | CONFIG_DEVTMPFS=y 99 | CONFIG_DEVTMPFS_MOUNT=y 100 | CONFIG_MTD=y 101 | CONFIG_MTD_CMDLINE_PARTS=y 102 | CONFIG_MTD_AFS_PARTS=y 103 | CONFIG_MTD_BLOCK=y 104 | CONFIG_MTD_RAW_NAND=y 105 | CONFIG_MTD_NAND_ECC_SW_BCH=y 106 | CONFIG_MTD_NAND_OMAP2=y 107 | CONFIG_MTD_NAND_OMAP_BCH=y 108 | CONFIG_MTD_UBI=y 109 | CONFIG_BLK_DEV_LOOP=y 110 | CONFIG_BLK_DEV_RAM=y 111 | CONFIG_BLK_DEV_RAM_SIZE=32768 112 | CONFIG_SCSI=y 113 | CONFIG_BLK_DEV_SD=y 114 | CONFIG_NETDEVICES=y 115 | CONFIG_TUN=y 116 | # CONFIG_NET_VENDOR_ALACRITECH is not set 117 | # CONFIG_NET_VENDOR_AMAZON is not set 118 | # CONFIG_NET_VENDOR_AQUANTIA is not set 119 | # CONFIG_NET_VENDOR_ARC is not set 120 | # CONFIG_NET_VENDOR_AURORA is not set 121 | # CONFIG_NET_VENDOR_BROADCOM is not set 122 | # CONFIG_NET_VENDOR_CADENCE is not set 123 | # CONFIG_NET_VENDOR_CAVIUM is not set 124 | # CONFIG_NET_VENDOR_CIRRUS is not set 125 | # CONFIG_NET_VENDOR_CORTINA is not set 126 | # CONFIG_NET_VENDOR_EZCHIP is not set 127 | # CONFIG_NET_VENDOR_FARADAY is not set 128 | # CONFIG_NET_VENDOR_GOOGLE is not set 129 | # CONFIG_NET_VENDOR_HISILICON is not set 130 | # CONFIG_NET_VENDOR_HUAWEI is not set 131 | # CONFIG_NET_VENDOR_INTEL is not set 132 | # CONFIG_NET_VENDOR_MARVELL is not set 133 | # CONFIG_NET_VENDOR_MELLANOX is not set 134 | # CONFIG_NET_VENDOR_MICREL is not set 135 | # CONFIG_NET_VENDOR_MICROCHIP is not set 136 | # CONFIG_NET_VENDOR_MICROSEMI is not set 137 | # CONFIG_NET_VENDOR_NATSEMI is not set 138 | # CONFIG_NET_VENDOR_NETRONOME is not set 139 | # CONFIG_NET_VENDOR_NI is not set 140 | # CONFIG_NET_VENDOR_PENSANDO is not set 141 | # CONFIG_NET_VENDOR_QUALCOMM is not set 142 | # CONFIG_NET_VENDOR_RENESAS is not set 143 | # CONFIG_NET_VENDOR_ROCKER is not set 144 | # CONFIG_NET_VENDOR_SAMSUNG is not set 145 | # CONFIG_NET_VENDOR_SEEQ is not set 146 | # CONFIG_NET_VENDOR_SOLARFLARE is not set 147 | # CONFIG_NET_VENDOR_SMSC is not set 148 | # CONFIG_NET_VENDOR_SOCIONEXT is not set 149 | # CONFIG_NET_VENDOR_STMICRO is not set 150 | # CONFIG_NET_VENDOR_SYNOPSYS is not set 151 | CONFIG_TI_DAVINCI_EMAC=y 152 | # CONFIG_NET_VENDOR_VIA is not set 153 | # CONFIG_NET_VENDOR_WIZNET is not set 154 | # CONFIG_NET_VENDOR_XILINX is not set 155 | CONFIG_MDIO_BITBANG=y 156 | CONFIG_MDIO_BUS_MUX_GPIO=y 157 | CONFIG_MDIO_BUS_MUX_MMIOREG=y 158 | CONFIG_MDIO_GPIO=y 159 | CONFIG_PPP=y 160 | CONFIG_PPP_BSDCOMP=y 161 | CONFIG_PPP_DEFLATE=y 162 | CONFIG_PPP_FILTER=y 163 | CONFIG_PPP_MULTILINK=y 164 | CONFIG_PPP_ASYNC=y 165 | CONFIG_PPP_SYNC_TTY=y 166 | CONFIG_USB_USBNET=y 167 | CONFIG_USB_NET_CDC_MBIM=y 168 | CONFIG_RTL8187=y 169 | # CONFIG_RTL_CARDS is not set 170 | # CONFIG_WLAN_VENDOR_QUANTENNA is not set 171 | # CONFIG_INPUT_KEYBOARD is not set 172 | # CONFIG_INPUT_MOUSE is not set 173 | # CONFIG_SERIO is not set 174 | CONFIG_SERIAL_8250=y 175 | CONFIG_SERIAL_8250_CONSOLE=y 176 | CONFIG_SERIAL_8250_NR_UARTS=32 177 | CONFIG_SERIAL_8250_EXTENDED=y 178 | CONFIG_SERIAL_8250_MANY_PORTS=y 179 | CONFIG_SERIAL_8250_SHARE_IRQ=y 180 | CONFIG_SERIAL_8250_DETECT_IRQ=y 181 | CONFIG_SERIAL_8250_RSA=y 182 | CONFIG_SERIAL_OMAP=y 183 | CONFIG_SERIAL_OMAP_CONSOLE=y 184 | CONFIG_I2C_CHARDEV=y 185 | CONFIG_PINCTRL_SINGLE=y 186 | CONFIG_DEBUG_GPIO=y 187 | CONFIG_GPIO_SYSFS=y 188 | CONFIG_GPIO_GENERIC_PLATFORM=y 189 | CONFIG_POWER_RESET=y 190 | CONFIG_POWER_RESET_RESTART=y 191 | # CONFIG_HWMON is not set 192 | CONFIG_WATCHDOG=y 193 | CONFIG_WATCHDOG_NOWAYOUT=y 194 | CONFIG_OMAP_WATCHDOG=y 195 | CONFIG_REGULATOR_DEBUG=y 196 | CONFIG_REGULATOR_TPS65023=y 197 | CONFIG_HID_BATTERY_STRENGTH=y 198 | CONFIG_HIDRAW=y 199 | CONFIG_UHID=y 200 | CONFIG_HID_PID=y 201 | CONFIG_USB_HIDDEV=y 202 | CONFIG_I2C_HID=y 203 | CONFIG_USB=y 204 | CONFIG_USB_ANNOUNCE_NEW_DEVICES=y 205 | CONFIG_USB_AUTOSUSPEND_DELAY=-1 206 | CONFIG_USB_EHCI_HCD=y 207 | CONFIG_USB_EHCI_ROOT_HUB_TT=y 208 | # CONFIG_USB_EHCI_TT_NEWSCHED is not set 209 | CONFIG_USB_ACM=y 210 | CONFIG_USB_STORAGE=y 211 | CONFIG_USB_SERIAL=y 212 | CONFIG_USB_SERIAL_GENERIC=y 213 | CONFIG_USB_SERIAL_CP210X=y 214 | CONFIG_USB_SERIAL_FTDI_SIO=y 215 | CONFIG_USB_SERIAL_PL2303=y 216 | CONFIG_USB_SERIAL_OPTION=y 217 | CONFIG_NOP_USB_XCEIV=y 218 | CONFIG_MMC=y 219 | CONFIG_MMC_OMAP_HS=y 220 | CONFIG_RTC_CLASS=y 221 | # CONFIG_RTC_NVMEM is not set 222 | CONFIG_RTC_DRV_DS1307=y 223 | CONFIG_DMADEVICES=y 224 | # CONFIG_TI_EDMA is not set 225 | CONFIG_OMAP_IOMMU=y 226 | # CONFIG_NVMEM is not set 227 | CONFIG_EXT2_FS=y 228 | CONFIG_EXT3_FS=y 229 | CONFIG_TMPFS=y 230 | CONFIG_TMPFS_POSIX_ACL=y 231 | CONFIG_JFFS2_FS=y 232 | CONFIG_JFFS2_FS_WBUF_VERIFY=y 233 | CONFIG_JFFS2_SUMMARY=y 234 | CONFIG_JFFS2_FS_XATTR=y 235 | CONFIG_JFFS2_COMPRESSION_OPTIONS=y 236 | CONFIG_JFFS2_LZO=y 237 | CONFIG_JFFS2_RUBIN=y 238 | CONFIG_NFS_FS=y 239 | CONFIG_NFS_V4=y 240 | CONFIG_ROOT_NFS=y 241 | CONFIG_NLS_CODEPAGE_437=y 242 | CONFIG_NLS_ISO8859_1=y 243 | CONFIG_CRYPTO_ECHAINIV=y 244 | CONFIG_CRYPTO_CBC=y 245 | CONFIG_CRYPTO_ECB=y 246 | CONFIG_CRYPTO_PCBC=y 247 | CONFIG_CRYPTO_MD5=y 248 | CONFIG_CRYPTO_DES=y 249 | CONFIG_CRYPTO_DEFLATE=y 250 | CONFIG_CRYPTO_LZO=y 251 | CONFIG_DEBUG_INFO=y 252 | CONFIG_DEBUG_FS=y 253 | CONFIG_DETECT_HUNG_TASK=y 254 | # CONFIG_SCHED_DEBUG is not set 255 | CONFIG_DEBUG_MUTEXES=y 256 | # CONFIG_DEBUG_BUGVERBOSE is not set 257 | CONFIG_DEBUG_LL=y 258 | CONFIG_DEBUG_OMAP3UART3=y 259 | CONFIG_DEBUG_UNCOMPRESS=y 260 | CONFIG_EARLY_PRINTK=y 261 | 262 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-kernel/linux/linux_5.4.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "Linux Kernel for var-som-am35 (TI AM3505) board" 2 | SECTION = "kernel" 3 | LIC_FILES_CHKSUM = "file://COPYING;md5=bbea815ee2795b2f4230826c0c6b8814" 4 | 5 | COMPATIBLE_MACHINE = "var-som-am35" 6 | 7 | PV = "${LINUX_VERSION}+git${SRCPV}" 8 | 9 | inherit kernel 10 | require recipes-kernel/linux/linux-yocto.inc 11 | 12 | BRANCH = "linux-5.4.y" 13 | 14 | SRC_URI = "git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git;nocheckout=1;branch=${BRANCH};name=machine" 15 | 16 | FILESEXTRAPATHS_prepend := "${THISDIR}/files:" 17 | 18 | SRC_URI += "file://0001-var-som-am35-add-device-tree.patch" 19 | SRC_URI += "file://0002-davinci_emac-allow-setting-the-mac-address-with-an-e.patch" 20 | SRC_URI += "file://defconfig" 21 | 22 | KCONFIG_MODE = "--alldefconfig" 23 | 24 | LINUX_VERSION ?= "5.4.114" 25 | LINUX_VERSION_EXTENSION_append = "-clochette" 26 | 27 | # Modify SRCREV to a different commit hash in a copy of this recipe to 28 | # build a different release of the Linux kernel. 29 | # tag: v5.4.114 de968c0c35d0cb90449f6984fab027879f9d7ceb 30 | SRCREV_machine="de968c0c35d0cb90449f6984fab027879f9d7ceb" 31 | 32 | DEPENDS += "u-boot-mkimage-native" 33 | 34 | do_deploy_append() { 35 | uboot-mkimage -A arm -O linux -T kernel -C none -a 80008000 -e 80008000 -n "${DISTRO_NAME}/${PV}/${MACHINE}" -d ${DEPLOYDIR}/${KERNEL_IMAGETYPE}-${MACHINE}-${MACHINE}.dtb.bin ${DEPLOYDIR}/uImage-${KERNEL_IMAGE_NAME}.bin 36 | ln -sf uImage-${KERNEL_IMAGE_NAME}.bin ${DEPLOYDIR}/uImage-${MACHINE}.bin 37 | ln -sf uImage-${KERNEL_IMAGE_NAME}.bin ${DEPLOYDIR}/uImage 38 | } 39 | 40 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/control-node-serial/control-node-serial_git.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "Control Node Serial Interface" 2 | LICENSE = "CECILL-2.0" 3 | LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/CECILL-2.0;md5=574109ac4bdff61f9c3e0de892ecbd19" 4 | 5 | DEPENDS = "oml2 oml2-native" 6 | 7 | SRC_URI = "git://github.com/iot-lab/control_node_serial.git;protocol=https" 8 | 9 | PR = "r4" 10 | PV = "git-src${SRCDATE}-r${SRCPV}" 11 | 12 | S = "${WORKDIR}/git/" 13 | SRCREV = "${AUTOREV}" 14 | 15 | do_install() { 16 | install -d ${D}${bindir} 17 | install -m 755 ${S}/control_node_serial_interface ${D}${bindir} 18 | } 19 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/flash-scripts/files/debug_a8_m3: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | /usr/bin/iotlab_debug 4 | exit $? 5 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/flash-scripts/files/flash_a8_m3: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | if [ $# != 1 ] 4 | then 5 | echo "Usage: $0 " >&2 6 | exit 1 7 | fi 8 | 9 | /usr/bin/iotlab_flash $1 10 | exit $? 11 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/flash-scripts/files/reset_a8_m3: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | /usr/bin/iotlab_reset 4 | exit $? 5 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/flash-scripts/flash-scripts-open-a8_0.1.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "IoT-LAB open A8 Linux node openocd scripts" 2 | LICENSE = "CECILL-2.0" 3 | LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/CECILL-2.0;md5=574109ac4bdff61f9c3e0de892ecbd19" 4 | 5 | S = "${WORKDIR}" 6 | 7 | PR = "r1" 8 | 9 | # package to ensure compatibility with old A8 open node image. Indeed now these scripts use generic programmer scripts on the gateway code 10 | 11 | RDEPENDS_${PN} = "openocd" 12 | RDEPENDS_${PN} += "bash" 13 | FILES_${PN} = "${bindir}/flash_a8_m3" 14 | FILES_${PN} += "${bindir}/reset_a8_m3" 15 | FILES_${PN} += "${bindir}/debug_a8_m3" 16 | 17 | SRC_URI = "\ 18 | file://flash_a8_m3 \ 19 | file://reset_a8_m3 \ 20 | file://debug_a8_m3 \ 21 | " 22 | 23 | do_install () { 24 | install -d ${D}${bindir} 25 | install -m 755 ${S}/flash_a8_m3 ${D}${bindir}/ 26 | install -m 755 ${S}/reset_a8_m3 ${D}${bindir}/ 27 | install -m 755 ${S}/debug_a8_m3 ${D}${bindir}/ 28 | } 29 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/ftdi-utils/ftdi-utils_1.1.0.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "IOT-LAB ftdi list and configuration" 2 | LICENSE = "CECILL-2.0" 3 | LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/CECILL-2.0;md5=574109ac4bdff61f9c3e0de892ecbd19" 4 | 5 | PACKAGES =+ "${PN}-list ${PN}-config" 6 | S = "${WORKDIR}" 7 | FILESEXTRAPATHS_prepend := "${THISDIR}/src:" 8 | 9 | # metapackage 10 | DEPENDS = "libftdi libusb1" 11 | 12 | RDEPENDS_${PN} += "${PN}-list ${PN}-config" 13 | ALLOW_EMPTY_${PN} = "1" 14 | 15 | inherit pkgconfig 16 | 17 | DESCRIPTION_${PN}-list = "IOT-LAB ftdi list" 18 | FILES_${PN}-list = "${bindir}/ftdi-devices-list" 19 | RDEPENDS_${PN}-list = "libftdi libusb1" 20 | 21 | DESCRIPTION_${PN}-config = "IOT-LAB ftdi eeprom config" 22 | FILES_${PN}-config = "${bindir}/ftdi-eeprom-config" 23 | RDEPENDS_${PN}-config = "libftdi libusb1" 24 | 25 | SRC_URI = "git://github.com/iot-lab/iot-lab-ftdi-utils.git;protocol=git;tag=${PV}" 26 | S = "${WORKDIR}/git/" 27 | 28 | 29 | do_compile () { 30 | export LDFLAGS="$(pkg-config --libs libftdi1) ${LDFLAGS}" 31 | export CFLAGS="$(pkg-config --cflags-only-I libftdi1) -DLIBFTDI1=1 ${CFLAGS}" 32 | 33 | oe_runmake 34 | } 35 | 36 | do_install () { 37 | install -d ${D}${bindir} 38 | install -m 755 ${S}/ftdi-devices-list ${D}${bindir}/ 39 | install -m 755 ${S}/ftdi-eeprom-config ${D}${bindir}/ 40 | } 41 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/ftdi-utils/src/.gitignore: -------------------------------------------------------------------------------- 1 | ftdi-devices-list 2 | ftdi-eeprom-config 3 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/gateway-code/files/start_dc_on: -------------------------------------------------------------------------------- 1 | #! /bin/sh 2 | { echo 'start dc'; sleep 1; } | control_node_serial_interface 3 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/gateway-code/files/stop_dc_on: -------------------------------------------------------------------------------- 1 | #! /bin/sh 2 | { echo 'stop dc'; sleep 1; } | control_node_serial_interface 3 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/gateway-code/gateway-code_git.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "Gateway Python Code" 2 | LICENSE = "CECILL-2.0" 3 | LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/CECILL-2.0;md5=574109ac4bdff61f9c3e0de892ecbd19" 4 | 5 | DEPENDS = "python3 oml2 oml2-native" 6 | 7 | SRC_URI = "git://github.com/iot-lab/iot-lab-gateway.git;protocol=https \ 8 | file://start_dc_on \ 9 | file://stop_dc_on" 10 | 11 | PR = "r4" 12 | PV = "git-src${SRCDATE}-r${SRCPV}" 13 | 14 | S = "${WORKDIR}/git/" 15 | SRCREV = "${AUTOREV}" 16 | # SRCREV = "2.10.0" 17 | 18 | # Add a package gateway-code-server with update-rc.d script & start|stop_dc_on scripts & post install dialout group 19 | # gateway: install gateway-code and gateway-code-server packages 20 | # Linux open node (eg. A8 and RPI3): install gateway-code package (udev rules and generic programmer) 21 | 22 | PACKAGES =+ "${PN}-server" 23 | 24 | WWW_DIR ?= "${localstatedir}/www" 25 | WWW_USER ?= "www-data" 26 | 27 | inherit update-rc.d setuptools3 useradd 28 | INITSCRIPT_PACKAGES = "${PN}-server" 29 | INITSCRIPT_NAME_${PN}-server = "gateway-server-daemon" 30 | # must start after gateway-server-network init.d script (S83/K17) which set virtual ip for open nodes 31 | INITSCRIPT_PARAMS_${PN}-server = "defaults 85 15" 32 | 33 | do_install_append () { 34 | install -d ${D}${sysconfdir}/udev/rules.d/ 35 | install -m 0644 ${S}/bin/rules.d/*.rules ${D}${sysconfdir}/udev/rules.d/ 36 | 37 | install -d ${D}${sysconfdir}/init.d/ 38 | install -m 0755 ${S}/bin/init_script/gateway-server-daemon ${D}${sysconfdir}/init.d/gateway-server-daemon 39 | 40 | install -d ${D}${bindir}/ 41 | install -m 0755 ${WORKDIR}/stop_dc_on ${D}${bindir}/ 42 | install -m 0755 ${WORKDIR}/start_dc_on ${D}${bindir}/ 43 | 44 | # create www-data home folder and .ssh folder 45 | # used to access A8 open nodes 46 | install -m 0755 -o ${WWW_USER} -g ${WWW_USER} -d ${D}${WWW_DIR}/ 47 | install -m 0755 -o ${WWW_USER} -g ${WWW_USER} -d ${D}${WWW_DIR}/.ssh 48 | } 49 | 50 | FILES_${PN} += "${libdir}/*" 51 | FILES_${PN} += "${sysconfdir}/udev/rules.d/*" 52 | FILES_${PN}-server += "${bindir}/start_dc_on" 53 | FILES_${PN}-server += "${bindir}/stop_dc_on" 54 | FILES_${PN}-server += "${sysconfdir}/init.d/gateway-server-daemon" 55 | 56 | RDEPENDS_${PN}-server = "bash" 57 | RDEPENDS_${PN} = "openocd socat oml2 control-node-serial" 58 | RDEPENDS_${PN} += "python3 python3-pyserial" 59 | RDEPENDS_${PN} += "python3-bottle python3-paste" 60 | RDEPENDS_${PN} += "python3-pyelftools" 61 | # for usermod on postinst 62 | RDEPENDS_${PN} += "shadow" 63 | RDEPENDS_${PN} += "openssh-ssh openssh-scp" 64 | 65 | # for development 66 | RDEPENDS_${PN} += "python3-gcovr" 67 | RDEPENDS_${PN} += "python3-coverage" 68 | RDEPENDS_${PN} += "python3-mock python3-pep8" 69 | RDEPENDS_${PN} += "python3-pylint" 70 | RDEPENDS_${PN} += "python3-tox (>= 3.4)" 71 | RDEPENDS_${PN} += "python3-testfixtures" 72 | RDEPENDS_${PN} += "python3-pytest" 73 | RDEPENDS_${PN} += "python3-pytest-cov" 74 | RDEPENDS_${PN} += "python3-webtest" 75 | RDEPENDS_${PN} += "python3-codecov" 76 | RDEPENDS_${PN} += "python3-beautifulsoup4" 77 | RDEPENDS_${PN} += "python3-webob" 78 | 79 | USERADD_PACKAGES = "${PN}" 80 | USERADD_PARAM_${PN} = "-u 33 -g 33 -d ${WWW_DIR} -r -M -s /bin/sh ${WWW_USER}" 81 | GROUPADD_PARAM_${PN} = "-g 33 ${WWW_USER}" 82 | 83 | pkg_postinst_${PN}-server () { 84 | # Add www-data to dialout group 85 | if test "x$D" != "x"; then 86 | OPT="--root $D" # Installing into a sysroot 87 | else 88 | OPT="" 89 | fi 90 | usermod $OPT -a -G dialout ${WWW_USER} 91 | } 92 | 93 | # Allow shipping arduino elf files 94 | INSANE_SKIP_${PN} = "arch" 95 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/jemalloc/jemalloc_4.0.4.bb: -------------------------------------------------------------------------------- 1 | SUMMARY = "A general purpose malloc(3) implementation that emphasizes fragmentation avoidance and scalable concurrency support." 2 | HOMEPAGE = "https://github.com/jemalloc/jemalloc" 3 | 4 | LICENSE = "BSD" 5 | LIC_FILES_CHKSUM = "file://COPYING;md5=5cff9c9987190d1c1ab7ba635c1d9f29" 6 | 7 | PV="4.0.4" 8 | SRC_URI = "https://github.com/jemalloc/jemalloc/releases/download/${PV}/jemalloc-${PV}.tar.bz2" 9 | SRC_URI[md5sum] = "687c5cc53b9a7ab711ccd680351ff988" 10 | SRC_URI[sha256sum] = "3fda8d8d7fcd041aa0bebbecd45c46b28873cf37bd36c56bf44961b36d0f42d0" 11 | 12 | inherit autotools 13 | 14 | FILES_${PN} = "/usr/lib/libjemalloc.so.2" 15 | 16 | FILES_${PN}-dev = "/usr/lib/libjemalloc.a \ 17 | /usr/lib/libjemalloc.so " 18 | 19 | PROVIDES="${PACKAGES}" 20 | 21 | do_configure (){ 22 | oe_runconf 23 | } 24 | 25 | do_compile (){ 26 | oe_runmake build_lib_shared 27 | } 28 | 29 | do_install() { 30 | oe_runmake DESTDIR=${D} install_lib_shared 31 | rm -fr ${D}/usr/src/debug/jemalloc 32 | } 33 | 34 | BBCLASSEXTEND = "lib_package" 35 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/libjaylink/libjaylink.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "Libjaylink: access to SEGGER J-Link devices" 2 | SECTION = "libs" 3 | DEPENDS += "libusb" 4 | LICENSE = "GPL-2.0" 5 | LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263" 6 | 7 | SRCREV = "8645845c1abebd004e991ba9a7f808f4fd0c608b" 8 | SRC_URI = "git://github.com/syntacore/libjaylink;protocol=https" 9 | 10 | S = "${WORKDIR}/git" 11 | 12 | inherit autotools pkgconfig 13 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/lora-gateway-bridge/lora-gateway-bridge/lora-gateway-bridge.init: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | DESC="LoRa Gateway Bridge" 4 | NAME=lora-gateway-bridge 5 | DAEMON=/opt/$NAME/$NAME 6 | PID_FILE=/var/run/$NAME.pid 7 | CONFIG_FILE=/var/config/$NAME/$NAME.toml 8 | 9 | 10 | function do_start { 11 | start-stop-daemon \ 12 | --start \ 13 | --background \ 14 | --make-pidfile --pidfile "$PID_FILE" \ 15 | --exec $DAEMON -- --config $CONFIG_FILE 16 | } 17 | 18 | function do_stop { 19 | start-stop-daemon \ 20 | --stop \ 21 | --retry=TERM/30/KILL/5 \ 22 | --pidfile "$PID_FILE" \ 23 | --exec "$DAEMON" 24 | retval="$?" 25 | sleep 1 26 | return "$retval" 27 | } 28 | 29 | case "$1" in 30 | start) 31 | echo "Starting $DESC" 32 | do_start 33 | ;; 34 | stop) 35 | echo "Stopping $DESC" 36 | do_stop 37 | ;; 38 | restart) 39 | echo "Restarting $DESC" 40 | do_stop 41 | case "$?" in 42 | 0|1) 43 | do_start 44 | ;; 45 | esac 46 | ;; 47 | *) 48 | echo "Usage: $NAME {start|stop|restart}" >&2 49 | exit 3 50 | ;; 51 | esac 52 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/lora-gateway-bridge/lora-gateway-bridge/lora-gateway-bridge.toml: -------------------------------------------------------------------------------- 1 | [general] 2 | # debug=5, info=4, warning=3, error=2, fatal=1, panic=0 3 | log_level = 4 4 | 5 | 6 | # Configuration which relates to the packet-forwarder. 7 | [packet_forwarder] 8 | # ip:port to bind the UDP listener to 9 | # 10 | # Example: 0.0.0.0:1700 to listen on port 1700 for all network interfaces. 11 | # This is the listeren to which the packet-forwarder forwards its data 12 | # so make sure the 'serv_port_up' and 'serv_port_down' from your 13 | # packet-forwarder matches this port. 14 | udp_bind = "0.0.0.0:1700" 15 | 16 | # Skip the CRC status-check of received packets 17 | # 18 | # This is only has effect when the packet-forwarder is configured to forward 19 | # LoRa frames with CRC errors. 20 | skip_crc_check = false 21 | 22 | 23 | # # Managed packet-forwarder configuration. 24 | # # 25 | # # By configuring one or multiple managed packet-forwarder sections, the 26 | # # LoRa Gateway Bridge updates the configuration when the backend receives 27 | # # a configuration change, after which it will restart the packet-forwarder. 28 | # [[packet_forwarder.configuration]] 29 | # # Gateway MAC. 30 | # # 31 | # # The LoRa Gateway Bridge will only apply the configuration updates for this 32 | # # gateway MAC. 33 | # mac="0102030405060708" 34 | 35 | # # Base configuration file. 36 | # # 37 | # # This file will be used as base-configuration and will not be overwritten on 38 | # # a configuration update. This file needs to exist and contains the base 39 | # # configuration and vendor specific 40 | # base_file="/var/config/lora-packet-forwarder-ap1/global_conf.json" 41 | 42 | # # Output configuration file. 43 | # # 44 | # # This will be the final configuration for the packet-forwarder, containing 45 | # # a merged version of the base configuration + the requested configuration 46 | # # update. 47 | # # Warning: this file will be overwritten on a configuration update! 48 | # output_file="/var/config/lora-packet-forwarder-ap1/local_conf.json" 49 | 50 | # # Restart command. 51 | # # 52 | # # This command is issued by the LoRa Gateway Bridge on a configuration 53 | # # change. Make sure the LoRa Gateway Bridge process has sufficient 54 | # # permissions to execute this command. 55 | # restart_command="/etc/init.d/lora-packet-forwarder-ap1 restart" 56 | 57 | 58 | # Configuration for the MQTT backend. 59 | [backend.mqtt] 60 | # MQTT topic templates for the different MQTT topics. 61 | # 62 | # The meaning of these topics are documented at: 63 | # https://docs.loraserver.io/lora-gateway-bridge/use/data/ 64 | # 65 | # The default values match the default expected configuration of the 66 | # LoRa Server MQTT backend. Therefore only change these values when 67 | # absolutely needed. 68 | # Use "{{ .MAC }}" as an substitution for the LoRa gateway MAC. 69 | # 70 | # Note that some authentication types might overwrite these templates (e.g. 71 | # in case of GCP Cloud IoT Core)! 72 | uplink_topic_template="gateway/{{ .MAC }}/rx" 73 | downlink_topic_template="gateway/{{ .MAC }}/tx" 74 | stats_topic_template="gateway/{{ .MAC }}/stats" 75 | ack_topic_template="gateway/{{ .MAC }}/ack" 76 | config_topic_template="gateway/{{ .MAC }}/config" 77 | 78 | # Payload marshaler. 79 | # 80 | # This defines how the MQTT payloads are encoded. Valid options are: 81 | # * v2_json: The default LoRa Gateway Bridge v2 encoding (will be deprecated and removed in LoRa Gateway Bridge v3) 82 | # * protobuf: Protobuf encoding (this will become the LoRa Gateway Bridge v3 default) 83 | # * json: JSON encoding (easier for debugging, but less compact than 'protobuf') 84 | marshaler="v2_json" 85 | 86 | # MQTT authentication. 87 | [backend.mqtt.auth] 88 | # Type defines the MQTT authentication type to use. 89 | # 90 | # Set this to the name of one of the sections below. 91 | # Note: when the 'v2_json marhaler' is configured, the generic backend will 92 | # always be used. 93 | type="generic" 94 | 95 | # Generic MQTT authentication. 96 | [backend.mqtt.auth.generic] 97 | # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) 98 | server="tcp://127.0.0.1:1883" 99 | 100 | # Connect with the given username (optional) 101 | username="" 102 | 103 | # Connect with the given password (optional) 104 | password="" 105 | 106 | # Quality of service level 107 | # 108 | # 0: at most once 109 | # 1: at least once 110 | # 2: exactly once 111 | # 112 | # Note: an increase of this value will decrease the performance. 113 | # For more information: https://www.hivemq.com/blog/mqtt-essentials-part-6-mqtt-quality-of-service-levels 114 | qos=0 115 | 116 | # Clean session 117 | # 118 | # Set the "clean session" flag in the connect message when this client 119 | # connects to an MQTT broker. By setting this flag you are indicating 120 | # that no messages saved by the broker for this client should be delivered. 121 | clean_session=true 122 | 123 | # Client ID 124 | # 125 | # Set the client id to be used by this client when connecting to the MQTT 126 | # broker. A client id must be no longer than 23 characters. When left blank, 127 | # a random id will be generated. This requires clean_session=true. 128 | client_id="" 129 | 130 | # CA certificate file (optional) 131 | # 132 | # Use this when setting up a secure connection (when server uses ssl://...) 133 | # but the certificate used by the server is not trusted by any CA certificate 134 | # on the server (e.g. when self generated). 135 | ca_cert="" 136 | 137 | # mqtt TLS certificate file (optional) 138 | tls_cert="" 139 | 140 | # mqtt TLS key file (optional) 141 | tls_key="" 142 | 143 | # Maximum interval that will be waited between reconnection attempts when connection is lost. 144 | # Valid units are 'ms', 's', 'm', 'h'. Note that these values can be combined, e.g. '24h30m15s'. 145 | max_reconnect_interval="10m0s" 146 | 147 | 148 | # Metrics configuration. 149 | [metrics] 150 | 151 | # Metrics stored in Prometheus. 152 | # 153 | # These metrics expose information about the state of the LoRa Gateway Bridge 154 | # instance like number of messages processed, number of function calls, etc. 155 | [metrics.prometheus] 156 | # Expose Prometheus metrics endpoint. 157 | endpoint_enabled=false 158 | 159 | # The ip:port to bind the Prometheus metrics server to for serving the 160 | # metrics endpoint. 161 | bind="" 162 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/lora-gateway-bridge/lora-gateway-bridge_2.6.0.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "LoRa Gateway Bridge" 2 | HOMEPAGE = "https://www.loraserver.io/" 3 | PRIORITY = "optional" 4 | LICENSE = "MIT" 5 | LIC_FILES_CHKSUM = "file://LICENSE;md5=5301050fd7cd58850085239d559297be" 6 | SRC_URI = "https://artifacts.loraserver.io/downloads/lora-gateway-bridge/lora-gateway-bridge_${PV}_linux_armv5.tar.gz \ 7 | file://lora-gateway-bridge.toml \ 8 | " 9 | SRC_URI[md5sum] = "e7700cd481eb1c6545ae5b4bf51379cd" 10 | SRC_URI[sha256sum] = "4ebe707b634087951f6f99a6e1a3ffe65ff1f8bcd43ebf66e83776d3c6f5248d" 11 | PR = "r1" 12 | 13 | LORA_GATEWAY_BRIDGE_DIR = "/opt/lora-gateway-bridge" 14 | 15 | INSANE_SKIP_${PN} = "ldflags" 16 | INHIBIT_PACKAGE_DEBUG_SPLIT = "1" 17 | INHIBIT_PACKAGE_STRIP = "1" 18 | 19 | S = "${WORKDIR}" 20 | 21 | do_install() { 22 | install -d ${D}${LORA_GATEWAY_BRIDGE_DIR} 23 | install -m 755 lora-gateway-bridge ${D}${LORA_GATEWAY_BRIDGE_DIR}/ 24 | 25 | install -d ${D}/var/config/lora-gateway-bridge 26 | install -m 0644 ${WORKDIR}/lora-gateway-bridge.toml ${D}/opt/lora-gateway-bridge/lora-gateway-bridge.toml 27 | } 28 | 29 | FILES_${PN} += "${LORA_GATEWAY_BRIDGE_DIR}" 30 | FILES_${PN}-dbg += "${LORA_GATEWAY_BRIDGE_DIR}/.debug" 31 | 32 | CONFFILES_${PN} += "/var/config/lora-gateway-bridge/lora-gateway-bridge.toml" 33 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/lora-gateway/lora-gateway/library.cfg: -------------------------------------------------------------------------------- 1 | # That file will be included in the Makefile files that have hardware dependencies 2 | 3 | ### Debug options ### 4 | # Set the DEBUG_* to 1 to activate debug mode in individual modules. 5 | # Warning: that makes the module *very verbose*, do not use for production 6 | 7 | DEBUG_AUX= 0 8 | DEBUG_SPI= 0 9 | DEBUG_REG= 0 10 | DEBUG_HAL= 1 11 | DEBUG_LBT= 0 12 | DEBUG_GPS= 0 13 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/lora-gateway/lora-gateway/lora-gateway-add-fpga-version-28-31-33.patch: -------------------------------------------------------------------------------- 1 | diff --git a/libloragw/src/loragw_reg.c b/libloragw/src/loragw_reg.c 2 | index 7e396bc..478f46a 100644 3 | --- a/libloragw/src/loragw_reg.c 4 | +++ b/libloragw/src/loragw_reg.c 5 | @@ -48,7 +48,7 @@ Maintainer: Sylvain Miermont 6 | #define PAGE_ADDR 0x00 7 | #define PAGE_MASK 0x03 8 | 9 | -const uint8_t FPGA_VERSION[] = { 31, 33 }; /* several versions could be supported */ 10 | +const uint8_t FPGA_VERSION[] = { 28, 31, 33 }; /* several versions could be supported */ 11 | 12 | /* 13 | auto generated register mapping for C code : 11-Jul-2013 13:20:40 14 | @@ -415,6 +415,16 @@ bool check_fpga_version(uint8_t version) { 15 | return false; 16 | } 17 | 18 | +uint8_t read_fpga_version() { 19 | + uint8_t u = 0; 20 | + uint8_t spi_stat = lgw_spi_r(lgw_spi_target, LGW_SPI_MUX_MODE1, LGW_SPI_MUX_TARGET_FPGA, loregs[LGW_VERSION].addr, &u); 21 | + if (spi_stat != LGW_SPI_SUCCESS) { 22 | + DEBUG_MSG("ERROR READING VERSION REGISTER\n"); 23 | + return LGW_REG_ERROR; 24 | + } 25 | + return u; 26 | +} 27 | + 28 | /* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ */ 29 | 30 | int reg_w_align32(void *spi_target, uint8_t spi_mux_mode, uint8_t spi_mux_target, struct lgw_reg_s r, int32_t reg_value) { 31 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/lora-gateway/lora-gateway/lora-gateway-add-spi-path-function.patch: -------------------------------------------------------------------------------- 1 | diff --git a/libloragw/inc/loragw_spi.h b/libloragw/inc/loragw_spi.h 2 | index fef1f48..74ef251 100644 3 | --- a/libloragw/inc/loragw_spi.h 4 | +++ b/libloragw/inc/loragw_spi.h 5 | @@ -46,6 +46,14 @@ Maintainer: Sylvain Miermont 6 | /* -------------------------------------------------------------------------- */ 7 | /* --- PUBLIC FUNCTIONS PROTOTYPES ------------------------------------------ */ 8 | 9 | +/* set SPI device */ 10 | +/** 11 | +@brief LoRa concentrator SPI path configuration for spidev 12 | +@param path pointer to spidev device 13 | +@return LGW_SPI_SUCCESS if path is valid, LGW_SPI_ERROR if not 14 | +*/ 15 | +int lgw_spi_set_path(const char *path); 16 | + 17 | /** 18 | @brief LoRa concentrator SPI setup (configure I/O and peripherals) 19 | @param spi_target_ptr pointer on a generic pointer to SPI target (implementation dependant) 20 | diff --git a/libloragw/src/loragw_spi.native.c b/libloragw/src/loragw_spi.native.c 21 | index c01ed1c..3472133 100644 22 | --- a/libloragw/src/loragw_spi.native.c 23 | +++ b/libloragw/src/loragw_spi.native.c 24 | @@ -56,10 +56,24 @@ Maintainer: Sylvain Miermont 25 | #define SPI_SPEED 8000000 26 | #define SPI_DEV_PATH "/dev/spidev0.0" 27 | //#define SPI_DEV_PATH "/dev/spidev32766.0" 28 | +char* spi_dev_path = SPI_DEV_PATH; 29 | 30 | /* -------------------------------------------------------------------------- */ 31 | /* --- PUBLIC FUNCTIONS DEFINITION ------------------------------------------ */ 32 | 33 | +/* set SPI device */ 34 | +int lgw_spi_set_path(const char *path) { 35 | + if (path) { 36 | + spi_dev_path = path; 37 | + return LGW_SPI_SUCCESS; 38 | + } 39 | + else { 40 | + return LGW_SPI_ERROR; 41 | + } 42 | +} 43 | + 44 | + 45 | + 46 | /* SPI initialization and configuration */ 47 | int lgw_spi_open(void **spi_target_ptr) { 48 | int *spi_device = NULL; 49 | @@ -78,7 +92,7 @@ int lgw_spi_open(void **spi_target_ptr) { 50 | } 51 | 52 | /* open SPI device */ 53 | - dev = open(SPI_DEV_PATH, O_RDWR); 54 | + dev = open(spi_dev_path, O_RDWR); 55 | if (dev < 0) { 56 | DEBUG_PRINTF("ERROR: failed to open SPI device %s\n", SPI_DEV_PATH); 57 | return LGW_SPI_ERROR; 58 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/lora-gateway/lora-gateway/lora-gateway-v28-skip-IQ-invert.patch: -------------------------------------------------------------------------------- 1 | diff --git a/libloragw/src/loragw_fpga.c b/libloragw/src/loragw_fpga.c 2 | index fa83a2a..7e667e3 100644 3 | --- a/libloragw/src/loragw_fpga.c 4 | +++ b/libloragw/src/loragw_fpga.c 5 | @@ -144,11 +144,14 @@ int lgw_fpga_configure(uint32_t tx_notch_freq) { 6 | return LGW_REG_ERROR; 7 | } 8 | 9 | - /* Required for Semtech AP2 reference design */ 10 | - x = lgw_fpga_reg_w(LGW_FPGA_CTRL_INVERT_IQ, 1); 11 | - if (x != LGW_REG_SUCCESS) { 12 | - DEBUG_MSG("ERROR: Failed to configure FPGA polarity\n"); 13 | - return LGW_REG_ERROR; 14 | + 15 | + if (read_fpga_version() > 28) { 16 | + /* Required for Semtech AP2 reference design and AP1.5 > v28 */ 17 | + x = lgw_fpga_reg_w(LGW_FPGA_CTRL_INVERT_IQ, 1); 18 | + if (x != LGW_REG_SUCCESS) { 19 | + DEBUG_MSG("ERROR: Failed to configure FPGA polarity\n"); 20 | + return LGW_REG_ERROR; 21 | + } 22 | } 23 | 24 | /* Configure TX notch filter */ 25 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/lora-gateway/lora-gateway_5.0.1.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "Driver/HAL to build a gateway using a concentrator board based on Semtech SX1301" 2 | HOMEPAGE = "https://github.com/Lora-net/lora_gateway" 3 | PRIORITY = "optional" 4 | LICENSE = "BSD" 5 | LIC_FILES_CHKSUM = "file://LICENSE;md5=a2bdef95625509f821ba00460e3ae0eb" 6 | PR = "r2" 7 | 8 | SRC_URI = "git://github.com/Lora-net/lora_gateway.git;protocol=git \ 9 | file://library.cfg \ 10 | file://lora-gateway-add-fpga-version-28-31-33.patch \ 11 | file://lora-gateway-v28-skip-IQ-invert.patch \ 12 | file://lora-gateway-add-spi-path-function.patch \ 13 | " 14 | 15 | SRCREV = "a955619271b5d0a46d32e08150acfbc1eed183b7" 16 | 17 | S = "${WORKDIR}/git" 18 | CFLAGS += "-Iinc -I." 19 | 20 | do_configure_append() { 21 | cp ${WORKDIR}/library.cfg ${S}/libloragw/library.cfg 22 | } 23 | 24 | do_compile() { 25 | oe_runmake 26 | } 27 | 28 | do_install() { 29 | install -d ${D}${libdir}/lora 30 | install -d ${D}${includedir}/lora 31 | 32 | install -m 0644 libloragw/libloragw.a ${D}${libdir}/lora 33 | install -m 0644 libloragw/library.cfg ${D}${libdir}/lora 34 | install -m 0644 libloragw/inc/* ${D}${includedir}/lora 35 | 36 | install -d ${D}/opt/lora-gateway/gateway-utils 37 | install -m 0755 libloragw/test_* ${D}/opt/lora-gateway/gateway-utils/ 38 | install -m 0755 util_pkt_logger/util_pkt_logger ${D}/opt/lora-gateway/gateway-utils/ 39 | install -m 0755 util_spectral_scan/util_spectral_scan ${D}/opt/lora-gateway/gateway-utils/ 40 | install -m 0755 util_spi_stress/util_spi_stress ${D}/opt/lora-gateway/gateway-utils/ 41 | install -m 0755 util_tx_test/util_tx_test ${D}/opt/lora-gateway/gateway-utils/ 42 | install -m 0755 util_tx_continuous/util_tx_continuous ${D}/opt/lora-gateway/gateway-utils/ 43 | install -m 0755 util_lbt_test/util_lbt_test ${D}/opt/lora-gateway/gateway-utils/ 44 | } 45 | 46 | PACKAGES += "${PN}-utils ${PN}-utils-dbg" 47 | 48 | FILES_${PN}-staticdev = "${libdir}/lora" 49 | FILES_${PN}-utils = "/opt/lora-gateway/gateway-utils/*" 50 | FILES_${PN}-utils-dbg = "/opt/lora-gateway/gateway-utils/.debug" 51 | FILES_${PN}-dev = "${includedir}/lora ${libdir}/lora/library.cfg" 52 | 53 | INSANE_SKIP_${PN}-utils += "ldflags" 54 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/lora-packet-forwarder/lora-packet-forwarder/README.md: -------------------------------------------------------------------------------- 1 | 2 | 3 | (c) Senet, Inc 2016 4 | 5 | 6 | 7 | 3rd Party Licenses 8 | ------------------ 9 | 10 | This software incorporates the lora_gateway software which requires the 11 | following statement to be included in its distribution. 12 | 13 | Copyright (c) 2013, SEMTECH S.A. 14 | All rights reserved. 15 | 16 | Redistribution and use in source and binary forms, with or without 17 | modification, are permitted provided that the following conditions are met: 18 | * Redistributions of source code must retain the above copyright 19 | notice, this list of conditions and the following disclaimer. 20 | * Redistributions in binary form must reproduce the above copyright 21 | notice, this list of conditions and the following disclaimer in the 22 | documentation and/or other materials provided with the distribution. 23 | * Neither the name of the Semtech corporation nor the 24 | names of its contributors may be used to endorse or promote products 25 | derived from this software without specific prior written permission. 26 | 27 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 28 | ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 29 | WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 30 | DISCLAIMED. IN NO EVENT SHALL SEMTECH S.A. BE LIABLE FOR ANY 31 | DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES 32 | (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 33 | LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND 34 | ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 35 | (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS 36 | SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 37 | 38 | 39 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/lora-packet-forwarder/lora-packet-forwarder/global_conf.json: -------------------------------------------------------------------------------- 1 | { 2 | "SX1301_conf": { 3 | "lorawan_public": true, 4 | "clksrc": 1, /* radio_1 provides clock to concentrator */ 5 | "lbt_cfg": { 6 | "enable": false, 7 | "rssi_target": -80, /* dBm */ 8 | "chan_cfg":[ /* 8 channels maximum */ 9 | { "freq_hz": 867100000, "scan_time_us": 128 }, 10 | { "freq_hz": 867300000, "scan_time_us": 5000 }, 11 | { "freq_hz": 867500000, "scan_time_us": 128 }, 12 | { "freq_hz": 869525000, "scan_time_us": 128 } 13 | ], 14 | "sx127x_rssi_offset": -4 /* dB */ 15 | }, 16 | "antenna_gain": 0, /* antenna gain, in dBi */ 17 | "radio_0": { 18 | "enable": true, 19 | "type": "SX1257", 20 | "freq": 867500000, 21 | "rssi_offset": -166.0, 22 | "tx_enable": true, 23 | "tx_notch_freq": 129000, /* [126..250] KHz */ 24 | "tx_freq_min": 863000000, 25 | "tx_freq_max": 870000000 26 | }, 27 | "radio_1": { 28 | "enable": true, 29 | "type": "SX1257", 30 | "freq": 868500000, 31 | "rssi_offset": -166.0, 32 | "tx_enable": false 33 | }, 34 | "chan_multiSF_0": { 35 | /* Lora MAC channel, 125kHz, all SF, 868.1 MHz */ 36 | "enable": true, 37 | "radio": 1, 38 | "if": -400000 39 | }, 40 | "chan_multiSF_1": { 41 | /* Lora MAC channel, 125kHz, all SF, 868.3 MHz */ 42 | "enable": true, 43 | "radio": 1, 44 | "if": -200000 45 | }, 46 | "chan_multiSF_2": { 47 | /* Lora MAC channel, 125kHz, all SF, 868.5 MHz */ 48 | "enable": true, 49 | "radio": 1, 50 | "if": 0 51 | }, 52 | "chan_multiSF_3": { 53 | /* Lora MAC channel, 125kHz, all SF, 867.1 MHz */ 54 | "enable": true, 55 | "radio": 0, 56 | "if": -400000 57 | }, 58 | "chan_multiSF_4": { 59 | /* Lora MAC channel, 125kHz, all SF, 867.3 MHz */ 60 | "enable": true, 61 | "radio": 0, 62 | "if": -200000 63 | }, 64 | "chan_multiSF_5": { 65 | /* Lora MAC channel, 125kHz, all SF, 867.5 MHz */ 66 | "enable": true, 67 | "radio": 0, 68 | "if": 0 69 | }, 70 | "chan_multiSF_6": { 71 | /* Lora MAC channel, 125kHz, all SF, 867.7 MHz */ 72 | "enable": true, 73 | "radio": 0, 74 | "if": 200000 75 | }, 76 | "chan_multiSF_7": { 77 | /* Lora MAC channel, 125kHz, all SF, 867.9 MHz */ 78 | "enable": true, 79 | "radio": 0, 80 | "if": 400000 81 | }, 82 | "chan_Lora_std": { 83 | /* Lora MAC channel, 250kHz, SF7, 868.3 MHz */ 84 | "enable": true, 85 | "radio": 1, 86 | "if": -200000, 87 | "bandwidth": 250000, 88 | "spread_factor": 7 89 | }, 90 | "chan_FSK": { 91 | /* FSK 50kbps channel, 868.8 MHz */ 92 | "enable": true, 93 | "radio": 1, 94 | "if": 300000, 95 | "bandwidth": 125000, 96 | "datarate": 50000 97 | }, 98 | "tx_lut_0": { 99 | /* TX gain table, index 0 */ 100 | "pa_gain": 0, 101 | "mix_gain": 8, 102 | "rf_power": -6, 103 | "dig_gain": 0 104 | }, 105 | "tx_lut_1": { 106 | /* TX gain table, index 1 */ 107 | "pa_gain": 0, 108 | "mix_gain": 10, 109 | "rf_power": -3, 110 | "dig_gain": 0 111 | }, 112 | "tx_lut_2": { 113 | /* TX gain table, index 2 */ 114 | "pa_gain": 0, 115 | "mix_gain": 12, 116 | "rf_power": 0, 117 | "dig_gain": 0 118 | }, 119 | "tx_lut_3": { 120 | /* TX gain table, index 3 */ 121 | "pa_gain": 1, 122 | "mix_gain": 8, 123 | "rf_power": 3, 124 | "dig_gain": 0 125 | }, 126 | "tx_lut_4": { 127 | /* TX gain table, index 4 */ 128 | "pa_gain": 1, 129 | "mix_gain": 10, 130 | "rf_power": 6, 131 | "dig_gain": 0 132 | }, 133 | "tx_lut_5": { 134 | /* TX gain table, index 5 */ 135 | "pa_gain": 1, 136 | "mix_gain": 12, 137 | "rf_power": 10, 138 | "dig_gain": 0 139 | }, 140 | "tx_lut_6": { 141 | /* TX gain table, index 6 */ 142 | "pa_gain": 1, 143 | "mix_gain": 13, 144 | "rf_power": 11, 145 | "dig_gain": 0 146 | }, 147 | "tx_lut_7": { 148 | /* TX gain table, index 7 */ 149 | "pa_gain": 2, 150 | "mix_gain": 9, 151 | "rf_power": 12, 152 | "dig_gain": 0 153 | }, 154 | "tx_lut_8": { 155 | /* TX gain table, index 8 */ 156 | "pa_gain": 1, 157 | "mix_gain": 15, 158 | "rf_power": 13, 159 | "dig_gain": 0 160 | }, 161 | "tx_lut_9": { 162 | /* TX gain table, index 9 */ 163 | "pa_gain": 2, 164 | "mix_gain": 10, 165 | "rf_power": 14, 166 | "dig_gain": 0 167 | }, 168 | "tx_lut_10": { 169 | /* TX gain table, index 10 */ 170 | "pa_gain": 2, 171 | "mix_gain": 11, 172 | "rf_power": 16, 173 | "dig_gain": 0 174 | }, 175 | "tx_lut_11": { 176 | /* TX gain table, index 11 */ 177 | "pa_gain": 3, 178 | "mix_gain": 9, 179 | "rf_power": 20, 180 | "dig_gain": 0 181 | }, 182 | "tx_lut_12": { 183 | /* TX gain table, index 12 */ 184 | "pa_gain": 3, 185 | "mix_gain": 10, 186 | "rf_power": 23, 187 | "dig_gain": 0 188 | }, 189 | "tx_lut_13": { 190 | /* TX gain table, index 13 */ 191 | "pa_gain": 3, 192 | "mix_gain": 11, 193 | "rf_power": 25, 194 | "dig_gain": 0 195 | }, 196 | "tx_lut_14": { 197 | /* TX gain table, index 14 */ 198 | "pa_gain": 3, 199 | "mix_gain": 12, 200 | "rf_power": 26, 201 | "dig_gain": 0 202 | }, 203 | "tx_lut_15": { 204 | /* TX gain table, index 15 */ 205 | "pa_gain": 3, 206 | "mix_gain": 14, 207 | "rf_power": 27, 208 | "dig_gain": 0 209 | } 210 | }, 211 | 212 | "gateway_conf": { 213 | /* change with default server address/ports, or overwrite in local_conf.json */ 214 | "server_address": "localhost", 215 | "serv_port_up": 1680, 216 | "serv_port_down": 1680, 217 | /* adjust the following parameters for your network */ 218 | "keepalive_interval": 10, 219 | "stat_interval": 30, 220 | "push_timeout_ms": 100, 221 | /* forward only valid packets */ 222 | "forward_crc_valid": true, 223 | "forward_crc_error": false, 224 | "forward_crc_disabled": false 225 | } 226 | } 227 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/lora-packet-forwarder/lora-packet-forwarder/local_conf.json: -------------------------------------------------------------------------------- 1 | { 2 | "gateway_conf": { 3 | "gateway_ID": "AA555A0000000000", 4 | "server_address": "127.0.0.1", 5 | "serv_port_up": 1700, 6 | "serv_port_down": 1700 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/lora-packet-forwarder/lora-packet-forwarder/lora-packet-forwarder-add-no-header-option.patch: -------------------------------------------------------------------------------- 1 | diff --git a/lora_pkt_fwd/src/lora_pkt_fwd.c b/lora_pkt_fwd/src/lora_pkt_fwd.c 2 | index 31a3743..c15b191 100644 3 | --- a/lora_pkt_fwd/src/lora_pkt_fwd.c 4 | +++ b/lora_pkt_fwd/src/lora_pkt_fwd.c 5 | @@ -2143,6 +2143,12 @@ void thread_down(void) { 6 | txpkt.no_crc = (bool)json_value_get_boolean(val); 7 | } 8 | 9 | + /* Parse "No Header" flag (optional field) */ 10 | + val = json_object_get_value(txpk_obj,"nhdr"); 11 | + if (val != NULL) { 12 | + txpkt.no_header = (bool)json_value_get_boolean(val); 13 | + } 14 | + 15 | /* parse target frequency (mandatory) */ 16 | val = json_object_get_value(txpk_obj,"freq"); 17 | if (val == NULL) { 18 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/lora-packet-forwarder/lora-packet-forwarder/lora-packet-forwarder-add-spi-dev-path.patch: -------------------------------------------------------------------------------- 1 | diff --git a/lora_pkt_fwd/src/lora_pkt_fwd.c b/lora_pkt_fwd/src/lora_pkt_fwd.c 2 | index 31a3743..a8c8f01 100644 3 | --- a/lora_pkt_fwd/src/lora_pkt_fwd.c 4 | +++ b/lora_pkt_fwd/src/lora_pkt_fwd.c 5 | @@ -119,6 +119,7 @@ static bool fwd_nocrc_pkt = false; /* packets with NO PAYLOAD CRC are NOT forwar 6 | /* network configuration variables */ 7 | static uint64_t lgwm = 0; /* Lora gateway MAC address */ 8 | static char serv_addr[64] = STR(DEFAULT_SERVER); /* address of the server (host name or IPv4/IPv6) */ 9 | +static char spi_device_path[64] = {0} ; /* custom SPI device path */ 10 | static char serv_port_up[8] = STR(DEFAULT_PORT_UP); /* server port for upstream traffic */ 11 | static char serv_port_down[8] = STR(DEFAULT_PORT_DW); /* server port for downstream traffic */ 12 | static int keepalive_time = DEFAULT_KEEPALIVE; /* send a PULL_DATA request every X seconds, negative = disabled */ 13 | @@ -645,6 +646,13 @@ static int parse_gateway_configuration(const char * conf_file) { 14 | MSG("INFO: server hostname or IP address is configured to \"%s\"\n", serv_addr); 15 | } 16 | 17 | + /* spi device path (optional) */ 18 | + str = json_object_get_string(conf_obj, "spi_device"); 19 | + if (str != NULL) { 20 | + strncpy(spi_device_path, str, sizeof(spi_device_path)-1); 21 | + MSG("INFO: SPI device is configured to \"%s\"\n", spi_device_path); 22 | + } 23 | + 24 | /* get up and down ports (optional) */ 25 | val = json_object_get_value(conf_obj, "serv_port_up"); 26 | if (val != NULL) { 27 | @@ -1092,6 +1100,11 @@ int main(void) 28 | } 29 | freeaddrinfo(result); 30 | 31 | + /* set custom SPI device path if configured */ 32 | + if (strlen(spi_device_path) > 0) 33 | + lgw_spi_set_path(spi_device_path); 34 | + 35 | + 36 | /* starting the concentrator */ 37 | i = lgw_start(); 38 | if (i == LGW_HAL_SUCCESS) { 39 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/lora-packet-forwarder/lora-packet-forwarder/lora-packet-forwarder-custom-conf-dir.patch: -------------------------------------------------------------------------------- 1 | From 843d63c38e7be8bbb593c9ca6226c0cebd68a2fb Mon Sep 17 00:00:00 2001 2 | From: Alexandre Abadie 3 | Date: Sun, 10 Mar 2019 11:44:54 +0100 4 | Subject: [PATCH] packet_forwarder: allow getting local config from other 5 | directory 6 | 7 | --- 8 | lora_pkt_fwd/src/lora_pkt_fwd.c | 18 +++++++++++++++++- 9 | 1 file changed, 17 insertions(+), 1 deletion(-) 10 | 11 | diff --git a/lora_pkt_fwd/src/lora_pkt_fwd.c b/lora_pkt_fwd/src/lora_pkt_fwd.c 12 | index 801f28d..4e87469 100644 13 | --- a/lora_pkt_fwd/src/lora_pkt_fwd.c 14 | +++ b/lora_pkt_fwd/src/lora_pkt_fwd.c 15 | @@ -981,7 +981,20 @@ int main(void) 16 | 17 | /* configuration file related */ 18 | char *global_cfg_path= "global_conf.json"; /* contain global (typ. network-wide) configuration */ 19 | - char *local_cfg_path = "local_conf.json"; /* contain node specific configuration, overwrite global parameters for parameters that are defined in both */ 20 | + char *local_cfg_path; 21 | + char *local_cfg_filename = "local_conf.json"; 22 | + char *cfg_dir = getenv("CFG_DIR"); 23 | + if (cfg_dir != NULL) { 24 | + MSG("INFO: using custom local configuration dir %s\n", cfg_dir); 25 | + local_cfg_path = malloc(strlen(cfg_dir) + strlen(local_cfg_filename) + 2); 26 | + sprintf(local_cfg_path, "%s/%s", cfg_dir, local_cfg_filename); 27 | + } 28 | + else { 29 | + local_cfg_path = malloc(strlen(local_cfg_filename) + 1); 30 | + sprintf(local_cfg_path, "%s", local_cfg_filename); 31 | + } 32 | + MSG("INFO: using local configuration file %s\n", local_cfg_path); 33 | + 34 | char *debug_cfg_path = "debug_conf.json"; /* if present, all other configuration files are ignored */ 35 | 36 | /* threads */ 37 | @@ -1082,6 +1095,9 @@ int main(void) 38 | parse_SX1301_configuration(local_cfg_path); 39 | parse_gateway_configuration(local_cfg_path); 40 | } 41 | + else { 42 | + MSG("INFO: cannot find local configuration file %s\n", local_cfg_path); 43 | + } 44 | } else if (access(local_cfg_path, R_OK) == 0) { /* if there is only a local conf, parse it and that's all */ 45 | MSG("INFO: found local configuration file %s, parsing it\n", local_cfg_path); 46 | x = parse_SX1301_configuration(local_cfg_path); 47 | -- 48 | 2.19.1 49 | 50 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/lora-packet-forwarder/lora-packet-forwarder/lora-packet-forwarder-parse-config-params-when-radio-disabled.patch: -------------------------------------------------------------------------------- 1 | diff --git a/lora_pkt_fwd/src/lora_pkt_fwd.c b/lora_pkt_fwd/src/lora_pkt_fwd.c 2 | index 1c54d57..92f25e3 100644 3 | --- a/lora_pkt_fwd/src/lora_pkt_fwd.c 4 | +++ b/lora_pkt_fwd/src/lora_pkt_fwd.c 5 | @@ -471,7 +471,8 @@ static int parse_SX1301_configuration(const char * conf_file) { 6 | } 7 | if (rfconf.enable == false) { /* radio disabled, nothing else to parse */ 8 | MSG("INFO: radio %i disabled\n", i); 9 | - } else { /* radio enabled, will parse the other parameters */ 10 | + } 11 | +// } else { /* radio enabled, will parse the other parameters */ 12 | snprintf(param_name, sizeof param_name, "radio_%i.freq", i); 13 | rfconf.freq_hz = (uint32_t)json_object_dotget_number(conf_obj, param_name); 14 | snprintf(param_name, sizeof param_name, "radio_%i.rssi_offset", i); 15 | @@ -505,8 +506,8 @@ static int parse_SX1301_configuration(const char * conf_file) { 16 | } else { 17 | rfconf.tx_enable = false; 18 | } 19 | - MSG("INFO: radio %i enabled (type %s), center frequency %u, RSSI offset %f, tx enabled %d, tx_notch_freq %u\n", i, str, rfconf.freq_hz, rfconf.rssi_offset, rfconf.tx_enable, rfconf.tx_notch_freq); 20 | - } 21 | + MSG("INFO: radio %i %sabled (type %s), center frequency %u, RSSI offset %f, tx enabled %d, tx_notch_freq %u\n", i, (rfconf.enable?"en":"dis"), str, rfconf.freq_hz, rfconf.rssi_offset, rfconf.tx_enable, rfconf.tx_notch_freq); 22 | +// } 23 | /* all parameters parsed, submitting configuration to the HAL */ 24 | if (lgw_rxrf_setconf(i, rfconf) != LGW_HAL_SUCCESS) { 25 | MSG("ERROR: invalid configuration for radio %i\n", i); 26 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/lora-packet-forwarder/lora-packet-forwarder/lora-packet-forwarder-remove-jit-power-check.patch: -------------------------------------------------------------------------------- 1 | diff --git a/lora_pkt_fwd/src/lora_pkt_fwd.c b/lora_pkt_fwd/src/lora_pkt_fwd.c 2 | index 1c54d57..1e74d7f 100644 3 | --- a/lora_pkt_fwd/src/lora_pkt_fwd.c 4 | +++ b/lora_pkt_fwd/src/lora_pkt_fwd.c 5 | @@ -2360,19 +2360,6 @@ void thread_down(void) { 6 | jit_result = JIT_ERROR_TX_FREQ; 7 | MSG("ERROR: Packet REJECTED, unsupported frequency - %u (min:%u,max:%u)\n", txpkt.freq_hz, tx_freq_min[txpkt.rf_chain], tx_freq_max[txpkt.rf_chain]); 8 | } 9 | - if (jit_result == JIT_ERROR_OK) { 10 | - for (i=0; i /sys/class/gpio/export 6 | echo "out" > /sys/class/gpio/gpio$SX1301_RESET_BCM_PIN/direction 7 | echo "0" > /sys/class/gpio/gpio$SX1301_RESET_BCM_PIN/value 8 | sleep 0.2 9 | echo "1" > /sys/class/gpio/gpio$SX1301_RESET_BCM_PIN/value 10 | sleep 0.2 11 | echo "0" > /sys/class/gpio/gpio$SX1301_RESET_BCM_PIN/value 12 | sleep 0.2 13 | echo "$SX1301_RESET_BCM_PIN" > /sys/class/gpio/unexport 14 | 15 | # Fire up the forwarder. 16 | cd /opt/lora 17 | ./lora_pkt_fwd 18 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/lora-packet-forwarder/lora-packet-forwarder_4.0.1.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "LoRa Packet Forwarder" 2 | HOMEPAGE = "https://github.com/Lora-net/packet_forwarder" 3 | PRIORITY = "optional" 4 | SECTION = "console/utils" 5 | # Semtech license is a modified BSD-style license 6 | LICENSE = "Proprietary" 7 | LIC_FILES_CHKSUM = "file://LICENSE;md5=22af7693d7b76ef0fc76161c4be76c45" 8 | DEPENDS = "lora-gateway" 9 | RDEPENDS_${PN} += "bash" 10 | PR = "r12" 11 | 12 | SRCREV = "v${PV}" 13 | 14 | SRC_URI = "git://github.com/Lora-net/packet_forwarder.git;protocol=git \ 15 | file://global_conf.json \ 16 | file://local_conf.json \ 17 | file://start.sh \ 18 | file://lora-packet-forwarder-add-spi-dev-path.patch \ 19 | file://lora-packet-forwarder-remove-jit-power-check.patch \ 20 | file://lora-packet-forwarder-custom-conf-dir.patch \ 21 | " 22 | 23 | S = "${WORKDIR}/git" 24 | B = "${S}" 25 | 26 | LORA_DIR = "/opt/lora" 27 | 28 | export LGW_PATH = "${STAGING_LIBDIR}/lora" 29 | export LGW_INC = "${STAGING_INCDIR}/lora" 30 | 31 | CFLAGS += "-I${LGW_INC} -Iinc -I. -std=gnu11" 32 | 33 | do_compile() { 34 | oe_runmake 35 | } 36 | 37 | do_install() { 38 | install -d ${D}${LORA_DIR} 39 | install -m 755 lora_pkt_fwd/lora_pkt_fwd ${D}${LORA_DIR}/ 40 | install -m 755 ${WORKDIR}/global_conf.json ${D}${LORA_DIR}/ 41 | install -m 755 ${WORKDIR}/local_conf.json ${D}${LORA_DIR}/ 42 | install -m 755 ${WORKDIR}/start.sh ${D}${LORA_DIR}/ 43 | 44 | install -d ${D}${LORA_DIR}/forwarder-utils 45 | install -m 755 util_sink/util_sink ${D}${LORA_DIR}/forwarder-utils/ 46 | install -m 755 util_ack/util_ack ${D}${LORA_DIR}/forwarder-utils/ 47 | install -m 755 util_tx_test/util_tx_test ${D}${LORA_DIR}/forwarder-utils/ 48 | } 49 | 50 | FILES_${PN} += "${LORA_DIR}" 51 | FILES_${PN}-dbg += "${LORA_DIR}/.debug ${LORA_DIR}/forwarder-utils/.debug" 52 | 53 | # disable this on purpose for dev purposes 54 | do_rm_work() { 55 | echo "skipping" 56 | } 57 | 58 | INSANE_SKIP_${PN} += "ldflags" 59 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/mjpg-streamer/files/vchiq-udev-rule: -------------------------------------------------------------------------------- 1 | SUBSYSTEM=="vchiq",GROUP="video",MODE="0660" 2 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/mjpg-streamer/mjpg-streamer/0001-slightly-unbreak-raspi-cmake.patch: -------------------------------------------------------------------------------- 1 | From ce462835e1155b38ddad73790adbc289b91dd95e Mon Sep 17 00:00:00 2001 2 | From: Koen Kooi 3 | Date: Sun, 3 Dec 2017 09:21:38 +0100 4 | Subject: [PATCH] slightly unbreak raspi cmake 5 | 6 | Signed-off-by: Koen Kooi 7 | --- 8 | .../plugins/input_raspicam/CMakeLists.txt | 18 +++--------------- 9 | 1 file changed, 3 insertions(+), 15 deletions(-) 10 | 11 | diff --git a/mjpg-streamer-experimental/plugins/input_raspicam/CMakeLists.txt b/mjpg-streamer-experimental/plugins/input_raspicam/CMakeLists.txt 12 | index bb645b2..74347d4 100644 13 | --- a/mjpg-streamer-experimental/plugins/input_raspicam/CMakeLists.txt 14 | +++ b/mjpg-streamer-experimental/plugins/input_raspicam/CMakeLists.txt 15 | @@ -1,23 +1,11 @@ 16 | +check_include_files(interface/vcos/vcos.h HAS_RPI) 17 | 18 | -if (EXISTS /opt/vc/include) 19 | - set(HAS_RASPI ON) 20 | -else() 21 | - set(HAS_RASPI OFF) 22 | +if(HAS_RPI) 23 | + MJPG_STREAMER_PLUGIN_OPTION(input_raspicam "Raspberry Pi input camera plugin") 24 | endif() 25 | 26 | -MJPG_STREAMER_PLUGIN_OPTION(input_raspicam "Raspberry Pi input camera plugin" 27 | - ONLYIF HAS_RASPI) 28 | - 29 | if (PLUGIN_INPUT_RASPICAM) 30 | 31 | - include_directories(/opt/vc/include) 32 | - include_directories(/opt/vc/include/interface/vcos) 33 | - include_directories(/opt/vc/include/interface/vcos/pthreads) 34 | - include_directories(/opt/vc/include/interface/vmcs_host) 35 | - include_directories(/opt/vc/include/interface/vmcs_host/linux) 36 | - 37 | - link_directories(/opt/vc/lib) 38 | - 39 | MJPG_STREAMER_PLUGIN_COMPILE(input_raspicam input_raspicam.c) 40 | 41 | target_link_libraries(input_raspicam mmal_core mmal_util mmal_vc_client vcos bcm_host) 42 | -- 43 | 2.0.1 44 | 45 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/mjpg-streamer/mjpg-streamer_git.bb: -------------------------------------------------------------------------------- 1 | SUMMARY = "MJPG-streamer takes JPGs from Linux-UVC compatible webcams, filesystem or other input plugins and streams them as M-JPEG via HTTP to webbrowsers, VLC and other software. It is the successor of uvc-streamer, a Linux-UVC streaming application with Pan/Tilt" 2 | 3 | LICENSE = "GPLv2" 4 | LIC_FILES_CHKSUM = "file://LICENSE;md5=751419260aa954499f7abaabaa882bbe" 5 | 6 | PV = "0.4+git${SRCPV}" 7 | SRCREV = "8cc9d22c1e79905d529a248ccf05bbf0625e0bf3" 8 | SRC_URI = "git://github.com/jacksonliam/mjpg-streamer.git;protocol=https \ 9 | file://0001-slightly-unbreak-raspi-cmake.patch;striplevel=2 \ 10 | file://d0dcc2e0bbe84ef0937def2d7d226eee88150739.patch \ 11 | " 12 | 13 | PATCHTOOL = "git" 14 | 15 | DEPENDS = "libgphoto2 v4l-utils libsdl udev" 16 | 17 | # Add support for raspicam on rpi platforms 18 | DEPENDS_append_rpi = " ${@bb.utils.contains("MACHINE_FEATURES", "vc4graphics", "", "userland", d)}" 19 | # https://lists.yoctoproject.org/pipermail/yocto/2014-June/019933.html 20 | ASNEEDED_rpi = "" 21 | 22 | 23 | S = "${WORKDIR}/git/mjpg-streamer-experimental" 24 | 25 | inherit cmake 26 | 27 | OECMAKE_GENERATOR="Unix Makefiles" 28 | EXTRA_OECMAKE = "-DENABLE_HTTP_MANAGEMENT=ON" 29 | 30 | EXTRA_OECMAKE_append_rpi = " ${@bb.utils.contains("MACHINE_FEATURES", "vc4graphics", "-DHAS_RASPI=OFF", "-DHAS_RASPI=ON", d)}" 31 | 32 | SRC_URI += " \ 33 | file://vchiq-udev-rule \ 34 | " 35 | 36 | do_install() { 37 | oe_runmake install DESTDIR=${D} 38 | 39 | install -d ${D}${sysconfdir}/udev/rules.d/ 40 | install -m 0644 ${WORKDIR}/vchiq-udev-rule ${D}${sysconfdir}/udev/rules.d/10-vchiq-permissions.rules 41 | } 42 | 43 | pkg_postinst_${PN} () { 44 | # Add www-data to video group 45 | if test "x$D" != "x"; then 46 | OPT="--root $D" # Installing into a sysroot 47 | else 48 | OPT="" 49 | fi 50 | usermod $OPT -a -G video www-data 51 | } 52 | 53 | FILES_${PN} += "${libdir}/*.so" 54 | 55 | # And make it rpi specific due to depending on rpi binaries 56 | PACKAGE_ARCH_rpi = "${MACHINE_ARCH}" 57 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/pycom-utils/files/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/pycom-utils/files/pypic.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | 3 | # Copyright (c) 2016-2020, Pycom Limited. 4 | # 5 | # This software is licensed under the GNU GPL version 3 or any 6 | # later version, with permitted additional terms. For more information 7 | # see the Pycom Licence v1.0 document supplied with this file, or 8 | # available at https://www.pycom.io/opensource/licensing 9 | 10 | from __future__ import print_function 11 | 12 | import argparse 13 | import struct 14 | import sys 15 | import time 16 | 17 | import serial 18 | 19 | try: 20 | from local_settings import DEBUG 21 | except: 22 | DEBUG = False 23 | __version__ = '0.9.3' 24 | 25 | CMD_PEEK = (0x0) 26 | CMD_POKE = (0x01) 27 | CMD_MAGIC = (0x02) 28 | CMD_HW_VER = (0x10) 29 | CMD_FW_VER = (0x11) 30 | CMD_PROD_ID = (0x12) 31 | CMD_SETUP_SLEEP = (0x20) 32 | CMD_GO_SLEEP = (0x21) 33 | CMD_CALIBRATE = (0x22) 34 | CMD_BAUD_CHANGE = (0x30) 35 | CMD_DFU = (0x31) 36 | 37 | ANSELA_ADDR = (0x18C) 38 | ANSELB_ADDR = (0x18D) 39 | ANSELC_ADDR = (0x18E) 40 | 41 | ADCON0_ADDR = (0x9D) 42 | ADCON1_ADDR = (0x9E) 43 | 44 | IOCAP_ADDR = (0x391) 45 | IOCAN_ADDR = (0x392) 46 | 47 | _ADCON0_CHS_POSN = (0x02) 48 | _ADCON0_ADON_MASK = (0x01) 49 | _ADCON1_ADCS_POSN = (0x04) 50 | _ADCON0_GO_nDONE_MASK = (0x02) 51 | 52 | ADRESL_ADDR = (0x09B) 53 | ADRESH_ADDR = (0x09C) 54 | 55 | TRISA_ADDR = (0x08C) 56 | TRISC_ADDR = (0x08E) 57 | 58 | PORTA_ADDR = (0x00C) 59 | PORTC_ADDR = (0x00E) 60 | 61 | WPUA_ADDR = (0x20C) 62 | 63 | PCON_ADDR = (0x096) 64 | STATUS_ADDR = (0x083) 65 | 66 | 67 | # helper functions 68 | def eprint(*args, **kwargs): 69 | print(*args, file=sys.stderr, **kwargs) 70 | 71 | 72 | def log(*args): 73 | print(' '.join(str(a) for a in args)) 74 | 75 | 76 | def error(msg): 77 | eprint('error:', msg) 78 | 79 | 80 | def exit_with_error(code, msg): 81 | error(msg) 82 | sys.exit(code) 83 | 84 | 85 | def warn(msg): 86 | eprint('warning:', msg) 87 | 88 | 89 | def print_debug(msg): 90 | if DEBUG: 91 | eprint(msg) 92 | 93 | 94 | class Pypic: 95 | 96 | def __init__(self, port): 97 | # we need bytesize to be 5 bits in order for the PIC to process the commands 98 | try: 99 | self.serial = serial.Serial(port, baudrate=115200, bytesize=serial.FIVEBITS, timeout=0.25, exclusive=True) 100 | connected = True 101 | except Exception as e: 102 | connected = False 103 | print_debug("Not connecting in exclusive mode because: %s" % str(e)) 104 | if not connected: 105 | try: 106 | self.serial = serial.Serial(port, baudrate=115200, bytesize=serial.FIVEBITS, timeout=0.25) 107 | except Exception as e: 108 | raise e 109 | self.detected = False 110 | 111 | try: 112 | if self.read_fw_version() < 6: 113 | raise ValueError('PIC firmware out of date') 114 | else: 115 | self.detected = True 116 | except Exception: 117 | pass 118 | 119 | def _write(self, data, read=True, num_read_bytes=1): 120 | self.serial.write(data) 121 | if read: 122 | r_data = self.serial.read(2) 123 | if not r_data: 124 | raise Exception('Timeout while waiting for Rx data') 125 | if num_read_bytes == 2: 126 | (b1, b2) = struct.unpack('BB', r_data) 127 | return 256 * b2 + b1 128 | else: 129 | if sys.version_info[0] < 3: 130 | return struct.unpack('B', r_data[0])[0] 131 | else: 132 | return r_data[0] 133 | 134 | def _flush(self, num_read_bytes=10): 135 | r_data = self.serial.read(num_read_bytes) 136 | # print(r_data) 137 | return 138 | 139 | def _send_cmd(self, cmd, num_read_bytes=1): 140 | return self._write(bytearray([cmd]), True, num_read_bytes) 141 | 142 | def read_hw_version(self): 143 | return self._send_cmd(CMD_HW_VER, 2) 144 | 145 | def read_fw_version(self): 146 | return self._send_cmd(CMD_FW_VER, 2) 147 | 148 | def read_product_id(self): 149 | return self._send_cmd(CMD_PROD_ID, 2) 150 | 151 | def peek_memory(self, addr): 152 | return self._write(bytearray([CMD_PEEK, addr & 0xFF, (addr >> 8) & 0xFF])) 153 | 154 | def poke_memory(self, addr, value): 155 | self._write(bytearray([CMD_POKE, addr & 0xFF, (addr >> 8) & 0xFF, value & 0xFF]), False) 156 | 157 | def magic_write_read(self, addr, _and=0xFF, _or=0, _xor=0): 158 | return self._write(bytearray([CMD_MAGIC, addr & 0xFF, (addr >> 8) & 0xFF, _and & 0xFF, _or & 0xFF, _xor & 0xFF])) 159 | 160 | def magic_write(self, addr, _and=0xFF, _or=0, _xor=0): 161 | self._write(bytearray([CMD_MAGIC, addr & 0xFF, (addr >> 8) & 0xFF, _and & 0xFF, _or & 0xFF, _xor & 0xFF]), False) 162 | 163 | def toggle_bits_in_memory(self, addr, bits): 164 | self.magic_write(addr, _xor=bits) 165 | 166 | def mask_bits_in_memory(self, addr, mask): 167 | self.magic_write(addr, _and=mask) 168 | 169 | def set_bits_in_memory(self, addr, bits): 170 | self.magic_write(addr, _or=bits) 171 | 172 | def reset_pycom_module(self): 173 | # make RC5 an output 174 | self.mask_bits_in_memory(TRISC_ADDR, ~(1 << 5)) 175 | # drive RC5 low 176 | self.mask_bits_in_memory(PORTC_ADDR, ~(1 << 5)) 177 | time.sleep(0.2) 178 | # drive RC5 high 179 | self.set_bits_in_memory(PORTC_ADDR, 1 << 5) 180 | time.sleep(0.1) 181 | # make RC5 an input 182 | self.set_bits_in_memory(TRISC_ADDR, 1 << 5) 183 | 184 | def enter_pycom_programming_mode(self, reset=True): 185 | print_debug("Entering programming mode with reset={}".format(reset)) 186 | # make RA5 an output 187 | self.mask_bits_in_memory(TRISA_ADDR, ~(1 << 5)) 188 | # drive RA5 low 189 | self.mask_bits_in_memory(PORTA_ADDR, ~(1 << 5)) 190 | # make RC0 an output 191 | self.mask_bits_in_memory(TRISC_ADDR, ~(1 << 0)) 192 | # set RC0 low 193 | self.mask_bits_in_memory(PORTC_ADDR, ~(1 << 0)) 194 | # perform reset 195 | if reset: 196 | self.reset_pycom_module() 197 | # We should keep RC0 low at this point in case someone 198 | # presses the reset button before the firmware upgrade 199 | # as this is mandatory for the regular expansion board 200 | self._flush() 201 | 202 | def exit_pycom_programming_mode(self, reset=True): 203 | print_debug("Leaving programming mode with reset={}".format(reset)) 204 | # make RA5 an output 205 | self.mask_bits_in_memory(TRISA_ADDR, ~(1 << 5)) 206 | # drive RA5 high 207 | self.set_bits_in_memory(PORTA_ADDR, 1 << 5) 208 | # make RC0 an input 209 | # This will prevent issues with the RGB LED 210 | self.set_bits_in_memory(TRISC_ADDR, 1 << 0) 211 | if reset: 212 | self.reset_pycom_module() 213 | self._flush() 214 | 215 | def isdetected(self): 216 | return self.detected 217 | 218 | def close(self): 219 | self.serial.close() 220 | 221 | 222 | def main(args): 223 | parser = argparse.ArgumentParser(description='Sends internal commands to put the Pycom module in programming mode') 224 | parser.add_argument('-p', '--port', metavar='PORT', help='the serial port used to communicate with the PIC') 225 | parser.add_argument('--enter', action='store_true', help='enter programming mode') 226 | parser.add_argument('--exit', action='store_true', help='exit programming mode') 227 | parser.add_argument('--noreset', action='store_true', help='do not reset esp32') 228 | args = parser.parse_args() 229 | 230 | if not args.port: 231 | exit_with_error(1, 'no serial port specified') 232 | 233 | if (args.enter and args.exit) or (not args.enter and not args.exit): 234 | exit_with_error(1, 'invalid action requested') 235 | 236 | pic = Pypic(args.port) 237 | 238 | if pic.isdetected(): 239 | if args.enter: 240 | pic.enter_pycom_programming_mode(not args.noreset) 241 | elif args.exit: 242 | pic.exit_pycom_programming_mode(not args.noreset) 243 | 244 | # print debug info about current PIC product 245 | print_debug("read_product_id(): 0x%X" % pic.read_product_id()) 246 | print_debug("read_hw_version(): 0x%X" % pic.read_hw_version()) 247 | print_debug("read_fw_version(): 0x%X" % pic.read_fw_version()) 248 | 249 | pic.close() 250 | 251 | 252 | if __name__ == "__main__": 253 | sys.exit(main(sys.argv[1:])) 254 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/pycom-utils/pycom-utils_0.1.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "Pycom boards utils" 2 | LICENSE = "GPLv3" 3 | LIC_FILES_CHKSUM = "\ 4 | file://esptool.py;beginline=3;endline=17;md5=4fe73a184ae6e27d0205eb5cf10f31c6 \ 5 | file://pypic.py;beginline=3;endline=8;md5=bc5f48a766e0c608b725ffff65d5272d \ 6 | file://updater.py;beginline=3;endline=8;md5=bc5f48a766e0c608b725ffff65d5272d \ 7 | " 8 | 9 | S = "${WORKDIR}" 10 | 11 | PR = "r1" 12 | 13 | RDEPENDS_${PN} += "python3 python3-pyserial" 14 | 15 | SRC_URI = "\ 16 | file://__init__.py \ 17 | file://esptool.py \ 18 | file://pypic.py \ 19 | file://updater.py \ 20 | " 21 | 22 | do_install () { 23 | install -d ${D}/usr/local/share/pycom/eps32/tools/fw_updater 24 | install -m 755 ${S}/__init__.py ${D}/usr/local/share/pycom/eps32/tools/fw_updater/ 25 | install -m 755 ${S}/esptool.py ${D}/usr/local/share/pycom/eps32/tools/fw_updater/ 26 | install -m 755 ${S}/pypic.py ${D}/usr/local/share/pycom/eps32/tools/fw_updater/ 27 | install -m 755 ${S}/updater.py ${D}/usr/local/share/pycom/eps32/tools/fw_updater/ 28 | } 29 | 30 | FILES_${PN} += "/usr/local/share/pycom/eps32/tools/fw_updater/*.py" 31 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/rtl-sdr/files/0001-Do-not-store-build-system-CFLAGS-in-the-pkgconfig-fi.patch: -------------------------------------------------------------------------------- 1 | From db61c2ea6ddc0cf0ef04c79593e1a76174c93dd1 Mon Sep 17 00:00:00 2001 2 | From: Philip Balister 3 | Date: Fri, 12 Feb 2016 13:06:33 -0500 4 | Subject: [PATCH] Do not store build system CFLAGS in the pkgconfig file. 5 | 6 | Signed-off-by: Philip Balister 7 | --- 8 | librtlsdr.pc.in | 2 +- 9 | 1 file changed, 1 insertion(+), 1 deletion(-) 10 | 11 | diff --git a/librtlsdr.pc.in b/librtlsdr.pc.in 12 | index 5e55049..c879f68 100644 13 | --- a/librtlsdr.pc.in 14 | +++ b/librtlsdr.pc.in 15 | @@ -6,6 +6,6 @@ includedir=@includedir@ 16 | Name: RTL-SDR Library 17 | Description: C Utility Library 18 | Version: @VERSION@ 19 | -Cflags: -I${includedir}/ @RTLSDR_PC_CFLAGS@ 20 | +Cflags: -I${includedir}/ 21 | Libs: -L${libdir} -lrtlsdr -lusb-1.0 22 | Libs.private: @RTLSDR_PC_LIBS@ 23 | -- 24 | 2.5.0 25 | 26 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/rtl-sdr/rtl-sdr_git.bb: -------------------------------------------------------------------------------- 1 | SUMMARY = "Software to turn the RTL2832U into a SDR" 2 | HOMEPAGE = "http://sdr.osmocom.org/trac/wiki/rtl-sdr" 3 | 4 | LICENSE = "GPLv2" 5 | LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe" 6 | 7 | DEPENDS = "libusb1" 8 | 9 | PV = "0.5.3+git${SRCPV}" 10 | 11 | SRC_URI = "git://git.osmocom.org/rtl-sdr \ 12 | file://0001-Do-not-store-build-system-CFLAGS-in-the-pkgconfig-fi.patch \ 13 | " 14 | SRCREV = "e3c03f738f5aef4dc51e2b741fbdb542b9cc1bb1" 15 | 16 | S = "${WORKDIR}/git" 17 | 18 | inherit autotools pkgconfig 19 | 20 | EXTRA_OECONF = "--enable-driver-detach" 21 | 22 | do_install_append() { 23 | install -d ${D}${sysconfdir}/udev/rules.d 24 | install -m 0644 ${S}/rtl-sdr.rules ${D}${sysconfdir}/udev/rules.d 25 | } 26 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/uhubctl/uhubctl_git.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "uhubctl - USB hub per-port power control" 2 | HOMEPAGE = "https://github.com/mvp/uhubctl" 3 | LICENSE = "GPLv2" 4 | LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \ 5 | file://LICENSE;md5=1e7b16e6ef7cd15d58b0f1c58dbf9817" 6 | 7 | DEPENDS = "libusb1" 8 | RDEPENDS_${PN} = "libusb1" 9 | 10 | SRC_URI = "git://github.com/mvp/uhubctl.git" 11 | SRCREV = "${AUTOREV}" 12 | PV = "git" 13 | S = "${WORKDIR}/git" 14 | 15 | do_install_append () { 16 | install -d ${D}${bindir} 17 | install -Dm 0755 ${S}/uhubctl ${D}${bindir}/ 18 | } 19 | 20 | FILES_${PN} += "${bindir}/*" 21 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/ykush/ykush/fix_makefile.patch: -------------------------------------------------------------------------------- 1 | From b8e76c17ecf1dcf726cdd37146a1132adba986bb Mon Sep 17 00:00:00 2001 2 | From: Alexandre Abadie 3 | Date: Mon, 22 Oct 2018 13:53:14 +0200 4 | Subject: [PATCH] fix makefile 5 | 6 | --- 7 | Makefile | 2 +- 8 | 1 file changed, 1 insertion(+), 1 deletion(-) 9 | 10 | diff --git a/Makefile b/Makefile 11 | index 2f45e31..be3658e 100644 12 | --- a/Makefile 13 | +++ b/Makefile 14 | @@ -3,7 +3,7 @@ OBJS = $(addprefix ykushcmd/objs/, ykushcmd.o commandParser.o ykushxs.o yk_usb_d 15 | LIBS = -lhidapi-libusb -lusb-1.0 -ludev 16 | LOADPATHS = -L$(CUR_PATH)/ykushcmd/linux 17 | INCLUDEPATHS= -I$(CUR_PATH)/ykushcmd/linux -I$(CUR_PATH)/ykushcmd/ykushxs -I$(CUR_PATH)/ykushcmd/ykush -I$(CUR_PATH)/ykushcmd -I$(CUR_PATH)/ykushcmd/help -I$(CUR_PATH)/ykushcmd/ykush2 -I$(CUR_PATH)/ykushcmd/ykush3 18 | -CPP = g++ 19 | +CPP = $(CXX) 20 | 21 | ykushcmd : $(OBJS) 22 | $(CPP) $(LOADPATHS) -o bin/ykushcmd $(OBJS) $(LIBS) 23 | -- 24 | 2.17.1 25 | 26 | -------------------------------------------------------------------------------- /meta-iotlab/recipes-support/ykush/ykush_git.bb: -------------------------------------------------------------------------------- 1 | DESCRIPTION = "Control application for Yepkit YKUSH Switchable USB Hub board." 2 | HOMEPAGE = "https://github.com/Yepkit/ykush" 3 | LICENSE = "Apache-2.0" 4 | LIC_FILES_CHKSUM = "file://LICENSE.md;md5=4b29e96047e31a3c38509d2c49b768b3" 5 | 6 | DEPENDS += "libusb hidapi udev" 7 | RDEPENDS_${PN} += "hidapi libusb1 udev" 8 | 9 | SRC_URI = "git://github.com/Yepkit/ykush.git;protocol=https \ 10 | file://fix_makefile.patch" 11 | SRCREV = "30d490423782a1d5379d1691a2539fad6ff6046d" 12 | PV = "git" 13 | S = "${WORKDIR}/git" 14 | 15 | PATCHTOOL = "git" 16 | 17 | do_install() { 18 | install -d ${D}${bindir} 19 | install -m 755 ${S}/bin/ykushcmd ${D}${bindir} 20 | } 21 | 22 | INSANE_SKIP_${PN} = "ldflags" 23 | INSANE_SKIP_${PN}-dev = "ldflags" 24 | -------------------------------------------------------------------------------- /meta-iotlab/recipes.txt: -------------------------------------------------------------------------------- 1 | recipes-bsp - Anything with links to specific hardware or hardware configuration information 2 | recipes-connectivity - Libraries and applications related to communication with other devices 3 | recipes-core - What's needed to build a basic working Linux image including commonly used dependencies 4 | recipes-devtools - Tools primarily used by the build system (but can also be used on targets) 5 | recipes-extended - Applications which whith is not essential add features compared to the alternatives in core. 6 | recipes-kernel - The kernel and generic applications/libraries with strong kernel dependencies 7 | recipes-support - Recipes used by other recipes but that are not directly included in images 8 | --------------------------------------------------------------------------------