Skip to content

Journal de travail MC

Michael Caraccio edited this page Dec 6, 2015 · 4 revisions

16.11.2015

Avancement : installation d'instant Contiki en VM pour facilement compiler et envoyé les builds sur USB : http://www.contiki-os.org/start.html

Installer le border-router sur la Z1 : http://zolertia.sourceforge.net/wiki/index.php/Mainpage:Contiki_apps

J'ai peut-être trouvé quelque chose d'intéressant : https://github.com/contiki-os/contiki/tree/master/examples/cc26xx/cc26xx-web-demo

Cela permet de convertir le sensortag en border-router (on ne veut pas ca, mais bon). Et donc de la faire communiquer en IPv6 avec 6lowpan des nodes. M

Autre document sympa pour comprendre les bases du sujet :

17.11.2015 - 05.12.2015

Links

Main - SensorTag2015

[http://processors.wiki.ti.com/index.php/SensorTag2015]

CC2650 SensorTag User's Guide

  • Firmware Upgrade [http://processors.wiki.ti.com/index.php/CC2650_SensorTag_User's_Guide]

Prerecquis

Instant Contiki

  • Téléchargement de la VM sur leur site puis conversion de la VM avec Parallels Desktop. (installation des drivers, etc)
  • Mettre à jour le dossier git “Contiki” :
git submodule sync && git submodule update --init
git pull

Reception de la carte et premier test

Hello world

  1. Allumer VM
  2. Connection USB de la carte
  3. Suivre le tuto :

Compilation du Hello World

git clone https://github.com/contiki-os/contiki.git
cd contiki/examples/hello-world
make TARGET=z1 hello-world
make TARGET=z1 savetarget
sudo make hello-world.upload
make login

Si erreur lors d’un sudo make TARGET=z1 hello-worldmake: msp430-gcc: Command not found Il faut installer :

sudo apt-get install gcc-msp430

sensortag

  1. prendre git avec recursion
  2. lancer make board=sensortag truc

DOSSIER REC

sudo make TARGET=z1 savetarget
sudo make clean
sudo make border-router.upload && sudo make z1-reset && sudo make connect-router

sensortag demo

j'ai changé dans projet-conf.h le channel de 25 à 26

sudo make clean
sudo make TARGET=srf06-cc26xx BOARD=sensortag/cc2650 cc26xx-demo.bin CPU_FAMILY=cc26xx

sensortag web-demo

sudo make TARGET=srf06-cc26xx BOARD=sensortag/cc2650 cc26xx-web-demo.bin CPU_FAMILY=cc26xx

Zolertia z1

  1. se rendre dans le dossier ipv6 -> border router
  2. Installer le paquet suivant : sudo apt-get install gcc-msp430
  3. Save target make TARGET=z1 savetarget
  4. Compile and send to device sudo make border-router.upload
  5. Connect to device sudo make z1-reset && make connect-router

Executer CCS en root:

sudo /opt/ti/ccsv6/eclipse/ccstudio

Si erreur :

make: msp430-gcc: Command not found
make: msp430-gcc: Command not found
  CC        slip-bridge.c
make: msp430-gcc: Command not found
make: *** [obj_z1/slip-bridge.o] Error 127

Installer le paquet :

sudo make clean
sudo apt-get install gcc-msp430

Installation de Code Composer

  1. Download latest version here http://processors.wiki.ti.com/index.php/Download_CCS
tar -xvf CCS_web_linux.tar.gz
  1. Installation de quelques dépendances http://processors.wiki.ti.com/index.php/Linux_Host_Support_CCSv6 unzip CCS_Web_linux.gz

Update XDS100

  1. Download and install "XDS Emulation Software Package" processors.wiki.ti.com/.../XDS_Emulation_Software_Package
  2. Disconnect the sensor tag from DevPack
  3. Attach DevPack to USB
  4. go to c:\ti\ccs_base\common\uscif\xds110 and open ReadMe.txt:

quote:

"Run the following two commands from this directory:

xdsdfu -m
xdsdfu -f firmware.bin -r

You may need to pause after the first command to give the OS time to recognize that the XDS110 has reconfigured as a different USB device.

Once the second command completes, the firmware is updated, and the debug probe should be ready to use." Lien : [https://e2e.ti.com/support/wireless_connectivity/f/538/t/435274]

Démarrer uniflash

sudo /opt/ti/uniflash_3.4/eclipse/uniflash

cd /opt/ti/uniflash_3.4
sudo ./opt/ti/uniflash_3.4/uniflash.sh -verbose 1 -ccxml /home/user/Documents/sensortagconf.ccxml -program /home/user/contiki/examples/cc26xx/cc26xx-demo.elf

devenir root:

sudo /bin/bash

Si erreur suite lors du make hello-world.upload

user@instant-contiki:~/contiki/examples/hello-world$ make hello-world.upload
using saved target 'z1'
msp430-objcopy hello-world.z1 -O ihex hello-world.ihex
cp hello-world.ihex tmpimage.ihex
/dev/ttyUSB0
make z1-reset z1-upload
using saved target 'z1'
make[1]: Entering directory `/home/user/contiki/examples/hello-world'
make -k -j 20 z1-reset-sequence
using saved target 'z1'
make[2]: Entering directory `/home/user/contiki/examples/hello-world'
../../tools/z1/z1-bsl-nopic --z1 -c /dev/ttyUSB0 -r
MSP430 Bootstrap Loader Version: 1.39-goodfet-8
Use -h for help
Use --fromweb to upgrade a GoodFET.
MSP430 Bootstrap Loader Version: 1.39-goodfet-8
Use -h for help
Use --fromweb to upgrade a GoodFET.
Traceback (most recent call last):
  File "../../tools/z1/z1-bsl-nopic", line 1940, in <module>
    main(0);
  File "../../tools/z1/z1-bsl-nopic", line 1848, in main
    bsl.comInit(comPort)                            #init port
  File "../../tools/z1/z1-bsl-nopic", line 323, in comInit
    timeout = self.timeout
  File "/usr/lib/python2.7/dist-packages/serial/serialutil.py", line 261, in __init__
    self.open()
  File "/usr/lib/python2.7/dist-packages/serial/serialposix.py", line 278, in open
    raise SerialException("could not open port %s: %s" % (self._port, msg))
serial.serialutil.SerialException: could not open port /dev/ttyUSB0: [Errno 13] Permission denied: '/dev/ttyUSB0'
make[2]: *** [z1-r.-dev-ttyUSB0] Error 1
make[2]: Target `z1-reset-sequence' not remade because of errors.
make[2]: Leaving directory `/home/user/contiki/examples/hello-world'
make[1]: *** [z1-reset] Error 2
make[1]: Leaving directory `/home/user/contiki/examples/hello-world'
make: *** [hello-world.upload] Error 2
rm hello-world.ihex

Solution : faire la commande en sudo

Clone this wiki locally