I’m very interested in it too, since several drafts have been released recently!
Hi
There is a new CoAP implementation for Contiki that is intended to be included in the official repository.
At the moment it is available at:
https://github.com/mkovatsc/SmartAppContiki -> branch coap-07
The update to draft 07 is quite recent and I have to check whether the new rest-example runs out of the box…
Branch coap-06 should work.
Best regards
Matthias
Great work! Thanks!
------------------------------------------------------------------------------
Magic Quadrant for Content-Aware Data Loss Prevention
Research study explores the data loss prevention market. Includes in-depth
analysis on the changes within the DLP market, and the criteria used to
evaluate the strengths and weaknesses of these DLP solutions.
http://www.accelacomm.com/jaw/sfnl/114/51385063/
_______________________________________________
Contiki-developers mailing list
Contiki-d...@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/contiki-developers
------------------------------------------------------------------------------
BlackBerry® DevCon Americas, Oct. 18-20, San Francisco, CA
The must-attend event for mobile developers. Connect with experts.
Get tools for creating Super Apps. See the latest technologies.
Sessions, hands-on labs, demos & much more. Register early & save!
http://p.sf.net/sfu/rim-blackberry-1
-----Original Message-----
From: cyril auburtin
Sent: Tuesday, August 02, 2011 11:48 AM
To: Contiki developer mailing list
Subject: Re: [Contiki-developers] CoAP development road-map?
Hello
in https://github.com/mkovatsc/SmartAppContiki branch coap-06
I wanted to use the rest-server-exemple with minimal-net platform
but it doesn't build, in static-routing.c:
#if !defined (CONTIKI_TARGET_MINIMAL_NET) /* Any other targets will be added
here (&& ! defined (OTHER))*/
minimal-net isn't supported?
------------------------------------------------------------------------------
BlackBerry® DevCon Americas, Oct. 18-20, San Francisco, CA
The must-attend event for mobile developers. Connect with experts.
Get tools for creating Super Apps. See the latest technologies.
Sessions, hands-on labs, demos & much more. Register early & save!
http://p.sf.net/sfu/rim-blackberry-1
-----Original Message-----
From: cyril auburtin
Sent: Tuesday, August 02, 2011 11:57 AM
To: Contiki developer mailing list
Subject: Re: [Contiki-developers] CoAP development road-map?
in SmartAppContiki/examples/rest-example
make TARGET=minimal-net rest-server-example gives:
gcc -DRF_CHANNEL=21 -DIEEE802154_CONF_PANID=0xBEEF -DUIP_CONF_IPV6_RPL=1 -DPROJECT_CONF_H=\"project-conf.h\"
-ffunction-sections -DWITH_COAP=6 -DREST=coap_rest_implementation -DUIP_CONF_TCP=0
-DCONTIKI=1 -DCONTIKI_TARGET_MINIMAL_NET=1 -DUIP_CONF_IPV6=1 -Wall -g -I/usr/local/include
-O -I. -I../../platform/minimal-net/. -I../../cpu/native/. -I../../cpu/native/net
-I../../core/dev -I../../core/lib -I../../core/net -I../../core/net/mac -I../../core/net/rime
-I../../core/net/rpl -I../../core/sys -I../../core/cfs -I../../core/ctk -I../../core/lib/ctk
-I../../core/loader -I../../core/. -I../../apps/coap-06 -I../../apps/rest-engine
-MMD -c static-routing.c -o obj_minimal-net/static-routing.o
static-routing.c:24:21: fatal error: node-id.h: Aucun fichier ou dossier de
ce type
compilation terminated.
make: *** [obj_minimal-net/static-routing.o] Erreur 1
rm rest-server-example.co
Hello
in https://github.com/mkovatsc/SmartAppContiki branch coap-06
I wanted to use the rest-server-exemple with minimal-net platform
but it doesn't build, in static-routing.c:
#if !defined (CONTIKI_TARGET_MINIMAL_NET) /* Any other targets will be added
here (&& ! defined (OTHER))*/
minimal-net isn't supported?
Great work! Thanks!
Hi
Branch coap-06 should work.
Best regards
Matthias
Hi,
Regards,
Jonathan Chung
--
The information transmitted is intended for the person or entity to which it
is addressed and may contain confidential and/or privileged material. Any
review, retransmission, dissemination or other use of, or taking of any
action in reliance upon, this information by persons or entities other than
the intended recipient is prohibited. If you received this in error, please
contact the sender and delete the material from any computer.
Hi
minimal-net was working, it should only be an issue with the configuration (Makefile and project-conf.h).
I will have a look at it and fix it…
Ciao
Matthias
Okay, the basic fix is to remove static-routing.c from the source-files for minimal-net, as it is unused anyway:
ifneq ($(TARGET), minimal-net)
PROJECT_SOURCEFILES += static-routing.c
endif
I do, however, have a problem reaching the minimal-net server since the changes at the platform code with the new HARD_CODED_ADDRESS define…
minimal-net will take a hard coded address in either the
/platform/contiki-conf.h file or /platform/contiki-main.c
Read the comments there, basically
#define HARD_CODED_ADDRESS "fdfd::10" //assign prefix and ipv6 address
fdfd::ff:fe00:10
With rpl only the link-local part ::ff:fe00:10 is used as the prefix comes
from the border router.
Setting the :10, :20, etc for each build allows different instances.
Running on minimal-net you should be able to see the traffic with wireshark
to indicate why the server is not responding. I suspect the syn/ack
handshake is working but the GET is overflowing the uip buffer.
Are you using the right port number for coap?
-----Original Message-----
From: cyril auburtin
Sent: Wednesday, August 03, 2011 11:47 AM
To: Contiki developer mailing list
Subject: Re: [Contiki-developers] CoAP development road-map?
thanks matthias
I have tried with latest contiki code
to launch rest-server-exemple with minimal-net target
also launched
sudo route add -6 aaaa::/64 tap0
sudo ip -6 address add aaaa::1/64 dev tap0
sudo sysctl -w net.ipv6.conf.all.forwarding=1
sudo /etc/init.d/radvd stop
sudo /etc/init.d/radvd start
then with copper I am not able to do anything with the rest-server, it times
out
I don't know what to debug since I never enter in the handler of the server
-----Original Message-----
From: Kovatsch Matthias
Sent: Wednesday, August 03, 2011 11:53 AM
To: Contiki developer mailing list
Subject: Re: [Contiki-developers] CoAP development road-map?
Okay, the basic fix is to remove static-routing.c from the source-files for
minimal-net, as it is unused anyway:
ifneq ($(TARGET), minimal-net)
PROJECT_SOURCEFILES += static-routing.c
endif
I do, however, have a problem reaching the minimal-net server since the
changes at the platform code with the new HARD_CODED_ADDRESS define…
Okay, my fault, my routing was messed up. It is working now.
I am pushing the fix to SmartAppContiki…
Okay, just to be sure:
The master of SmartAppContiki is quite outdated, as I am working in branch coap-07.
If you use the coap-07 branch, the CoAP implementation is different from the official Contiki repository! The port, for instance, is now 5683 by default.
Your mail just came in ;)
As the name tells, coap-07 implements the current draft 07. The official one only provides a subset of draft 03.
#if !UIP_CONF_IPV6_RPL
uip_ipaddr_t ipaddr;
#ifdef HARD_CODED_ADDRESS
uiplib_ipaddrconv(HARD_CODED_ADDRESS, &ipaddr);
#else
uip_ip6addr(&ipaddr, 0xaaaa, 0, 0, 0, 0, 0, 0, 0);
#endif
if ((ipaddr.u16[0]!=0) || (ipaddr.u16[1]!=0) || (ipaddr.u16[2]!=0) ||
(ipaddr.u16[3]!=0)) {
#if UIP_CONF_ROUTER
uip_ds6_prefix_add(&ipaddr, UIP_DEFAULT_PREFIX_LEN, 0, 0, 0, 0);
#else /* UIP_CONF_ROUTER */
uip_ds6_prefix_add(&ipaddr, UIP_DEFAULT_PREFIX_LEN, 0);
#endif /* UIP_CONF_ROUTER */
#if !UIP_CONF_IPV6_RPL
uip_ds6_set_addr_iid(&ipaddr, &uip_lladdr);
uip_ds6_addr_add(&ipaddr, 0, ADDR_AUTOCONF);
#endif
}
#endif
HARD_CODED_PREFIX overwrites that at startup to make the tun0 or wpcap
ethernet macs consistent with the assigned ipv6 addresses. Perhaps
UIP_CONF_LL_802154 should have been used instead.
The aaaa:: prefix is in a lot of tutorials too, perhaps an unfortunate
choice because it triggers the 6LoWPAN stateful address compression. IMO it
is not kosher to assign a hard coded prefix to an ipv6 device, that should
be picked up through the interface.
Personally I use link-local fe80::whatever%usb0 for quick tests and fdfd::
when I go the trouble of setting up the interface for prefix advertising.
The non-SLIP Rpl border router is a special case that does not accept RA's
with prefix advertisement, so minimal-net needs that prefix hard coded. But
it could be set in the contiki-conf.h file as the default for all examples,
with the comment that leaving the prefix undefined until the interface
assigns one is the proper way (HARD_CODED_ADDRESS = ::a:b:c:d would give a
unique mac address with no prefix) and that specifying e.g. aaaa::a:b:c:d
would end up with two prefixes if another came through the interface.
It may be clearer to use something like UIP_CONF_IPV6_PREFIX = 0 by default
but settable to foo::/64 if that is really what you want, and
UIP_CONF_LL_802154 for lladdr=bar. That does have the effect of ending up
with the ipv6 address of foo:ff:fe:bar which is kind of inconvenient. foo:1,
foo2:2, foo:3 is easier to type.
Okay, there is a bug that only shows on minimal-net.
It works exactly once, then the automatic chunking into blocks messes up the byte offset.
I’ll fix that soon.
Thanks for triggering the good old minimal-net test! :)
Fixed.
If you still want to use CoAP-06, also use the coap-07 branch. It includes all three stages (03, 06, 07).
BTW: There is a new Copper version for 07, but I am still waiting for the Mozilla review so that it appears on the website…
The client example is just there to give an idea how to implement a client and is thought for Cooja. To have an “interactive client”, it is based on the sky platform and uses a button and an LED server-sided.
The printf is buggy for the timed request, which gets the /toggle resource every 10 seconds.
The printf is actually for the button-event request, which cycles between different resources.
Have a look at the code and use the API calls from coap-0x.h to implement a useful minimal-net client.
I will add another example that uses blocking requests (in terms of control flow) that also support transparent blockwise transfers at the client side.
Best regards
Matthias
I now have a similar problem testing minimal-net client/server under Linux.
The examples work on motes and in Cooja, but not for minimal-net. The problem is that the two minimal-net instances cannot reach each other. If I try ping6, only the instance started first is reachable.
I set the correct address for tap0, when adding routes I get error messages:
user@instant-contiki:~$ sudo ip -6 route add fdfd::/64 via fdfd::1
RTNETLINK answers: Invalid argument
user@instant-contiki:~$ sudo route -A inet6 add fdfd::/64 gw fdfd::1
SIOCADDRT: Invalid argument
Link-local addresses do not work, either.
Is there something special to do, so that all instances are actually on the same tap0 device?
Had anyone multiple instances of minimal-net nodes communicating with each other before?
Bye
Matthias
-----Original Message-----
From: Kovatsch Matthias
Sent: Thursday, August 25, 2011 12:50 PM
To: Contiki developer mailing list
Subject: Re: [Contiki-developers] CoAP development road-map?
I now have a similar problem testing minimal-net client/server under Linux.
The examples work on motes and in Cooja, but not for minimal-net. The problem is that the two minimal-net instances cannot reach
each other. If I try ping6, only the instance started first is reachable.
I set the correct address for tap0, when adding routes I get error messages:
user@instant-contiki:~$ sudo ip -6 route add fdfd::/64 via fdfd::1
RTNETLINK answers: Invalid argument
user@instant-contiki:~$ sudo route -A inet6 add fdfd::/64 gw fdfd::1
SIOCADDRT: Invalid argument
Link-local addresses do not work, either.
Is there something special to do, so that all instances are actually on the same tap0 device?
Had anyone multiple instances of minimal-net nodes communicating with each other before?
Bye
Matthias
------------------------------------------------------------------------------
EMC VNX: the world's simplest storage, starting under $10K
The only unified storage solution that offers unified management
Up to 160% more powerful than alternatives and 25% more efficient.
Guaranteed. http://p.sf.net/sfu/emc-vnx-dev2dev
------------------------------------------------------------------------------ EMC VNX: the world's simplest storage, starting under $10K The only unified storage solution that offers unified management Up to 160% more powerful than alternatives and 25% more efficient. Guaranteed. http://p.sf.net/sfu/emc-vnx-dev2dev_______________________________________________ Contiki-developers mailing list Contiki-d...@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/contiki-developers
Hm I don't have this file in cpu because I do not using git repository but svn :(
this is my tap
tapdev_init();
#if !UIP_CONF_IPV6
� tcpip_set_outputfunc(tapdev_output);
#else
� tcpip_set_outputfunc(tapdev_send);
#endif
� process_poll(&tapdev_process);
� PROCESS_WAIT_UNTIL(ev == PROCESS_EVENT_EXIT);
� tapdev_exit();
� PROCESS_END();
}
do you know what should I do? Please help :S
Date: Thu, 25 Aug 2011 22:22:15 +0200
From: hadri...@googlemail.com
To: contiki-d...@lists.sourceforge.net
Subject: Re: [Contiki-developers] CoAP development road-map?
Hi,
i think this is a problem in /cpu/native/tapdev6.c
In the init code the tap0 device is hardcoded. But if you use linux and tap0 is already used, you got another tap device. The following code (ifconfig device ect.) also use hardcoded tap0. As I already mentionend some weeks ago, it would be more robust to ask for tap0 while the linux systemcall.
For solving the problem with multiple minimal-net instances, the tapdev6 have to more flexible in the name of the tapdevice. Of course a short hack is to rename the hardcoded device names for every instance.
kind regards
PS: this is the fix for the system call
diff --git a/cpu/native/net/tapdev6.c b/cpu/native/net/tapdev6.c
index 6334bbe..4fc34c2 100644
--- a/cpu/native/net/tapdev6.c
+++ b/cpu/native/net/tapdev6.c
@@ -132,6 +132,7 @@ tapdev_init(void)
�� {
���� struct ifreq ifr;
���� memset(&ifr, 0, sizeof(ifr));
+��� strncpy(ifr.ifr_name,"tap0", sizeof(ifr.ifr_name) - 1);
���� ifr.ifr_flags = IFF_TAP|IFF_NO_PI;
���� if (ioctl(fd, TUNSETIFF, (void *) &ifr) < 0) {
������ perror(buf);
Am 25.08.2011 18:50, schrieb Kovatsch Matthias:
I now have a similar problem testing minimal-net client/server under Linux.
The examples work on motes and in Cooja, but not for minimal-net. The problem is that the two minimal-net instances cannot reach each other. If I try ping6, only the instance started first is reachable.
�
I set the correct address for tap0, when adding routes I get error messages:
user@instant-contiki:~$ sudo ip -6 route add fdfd::/64 via fdfd::1
RTNETLINK answers: Invalid argument
user@instant-contiki:~$ sudo route -A inet6 add fdfd::/64 gw fdfd::1
SIOCADDRT: Invalid argument
�
Link-local addresses do not work, either.
�
Is there something special to do, so that all instances are actually on the same tap0 device?
Had anyone multiple instances of minimal-net nodes communicating with each other before?
�
Bye
Matthias
�
�
From: Kovatsch Matthias [mailto:kova...@inf.ethz.ch]
Sent: Montag, 15. August 2011 05:48
To: Contiki developer mailing list
Subject: Re: [Contiki-developers] CoAP development road-map?
�
The client example is just there to give an idea how to implement a client and is thought for Cooja. To have an �interactive client�, it is based on the sky platform and uses a button and an LED server-sided.
The printf is buggy for the timed request, which gets the /toggle resource every 10 seconds.
The printf is actually for the button-event request, which cycles between different resources.
Have a look at the code and use the API calls from coap-0x.h to implement a useful minimal-net client.
I will add another example that uses blocking requests (in terms of control flow) that also support transparent blockwise transfers at the client side.
�
Best regards
Matthias
�
�
From: cyril auburtin [mailto:cyril.a...@inria.fr]
Sent: Thursday, August 11, 2011 12:22 PM
To: Contiki developer mailing list
Subject: Re: [Contiki-developers] CoAP development road-map?
�
coap-client is not working with minimal-net (https://github.com/mkovatsc/SmartAppContiki/tree/coap-07/examples/rest-example branch coap-07)
maybe due to recent changes
$ sudo ./coap-client-example.minimal-net
ifconfig tap0 up
IPV6 Addresss: [aaaa::ff:fe00:5]
IPV6 Addresss: [fe80::ff:fe00:5]
Sending to /.well-known/core
� GETting URL...
Sending to /.well-known/core
� GETting URL...
Sending to /.well-known/core
� GETting URL...
with a rest-server with :10 running, (and joinable with copper)
Hello
again with minimal-net, your corrections for rest-server made it work, with copper client
I have tried using coap-client-example.c, with
#define SERVER_NODE(ipaddr)�� uip_ip6addr(ipaddr, 0xaaaa, 0, 0, 0, 0, 0x00ff, 0xfe00, 0x0010) /* minimal-net */
coap-client is built with #define HARD_CODED_ADDRESS����� "aaaa::5"
and rest-server with #define HARD_CODED_ADDRESS����� "aaaa::10"
I activate radvd forwarding, copper is still able to communicate with rest-server but coap-client says continuously:
ifconfig tap0 up
IPV6 Addresss: [aaaa::ff:fe00:5]
IPV6 Addresss: [fe80::ff:fe00:5]
Sending to /.well-known/core
� GETting URL...
Sending to /.well-known/core
� GETting URL...
Sending to /.well-known/core
� GETting URL...
Sending to /.well-known/core
� GETting URL...
Sending to /.well-known/core
� GETting URL...
Sending to /.well-known/core
I have used post or put query method, on uri: coap://[aaaa::212:7402:2:202]:5683/leds?color=blue with payload 'mode=on'
but would it work with multiple variables in the uri, and if yes how to do it
thx
thanks it's working well
how is the leds ressource request supposed to be formed?
Okay, there is a bug that only shows on minimal-net.
It works exactly once, then the automatic chunking into blocks messes up the byte offset.
I�ll fix that soon.
�
Thanks for triggering the good old minimal-net test! :)
�
�
From: cyril auburtin [mailto:cyril.a...@inria.fr]
Sent: Mittwoch, 3. August 2011 18:39
To: Contiki developer mailing list
Subject: Re: [Contiki-developers] CoAP development road-map?
�
I am in coap-06 branch and copper 06
�still minimal-net, with your precedent fix
and coap://[aaaa::206:98ff:fe00:232]:5683/.well-known/core� GET:
=sending CoAP message===
�Type: Confirmable
�Code: GET
�Transaction ID: 28874
�Options:
� Uri: /.well-known/core [1 option]
�Payload:
�=======================
-sent UDP datagram------
�Length: 21
�-----------------------
-receiving UDP datagram-
�Length: 25
�-----------------------
=received CoAP message==
�Type: Acknowledgment
�Code: 4.02 Bad Option
�Transaction ID: 28874
�Options:
� Block2: 0 (128 B/block) [1 byte(s)]
�Payload:
Block out of scope
�=======================
INFO: discoverHandler()
hello is working
but discover doesn't work
I have this alert "ERROR: Main.discoverHandler [Content-Type is null, not 'application/link-format']"
Okay, just to be sure:
The master of SmartAppContiki is quite outdated, as I am working in branch coap-07.
If you use the coap-07 branch, the CoAP implementation is different from the official Contiki repository! The port, for instance, is now 5683 by default.
�
Your mail just came in ;)
�
As the name tells, coap-07 implements the current draft 07. The official one only provides a subset of draft 03.
�
�
From: cyril auburtin [mailto:cyril.a...@inria.fr]
Sent: Mittwoch, 3. August 2011 18:12
To: Contiki developer mailing list
Subject: Re: [Contiki-developers] CoAP development road-map?
�
thanks I will try minimal-net with a rest-server and a coap-client with different ipv6, and debug
yes I tried copper with [aaaa::206:98ff:fe00:232]:61616
Hi Cyril,
minimal-net will take a hard coded address in either the
/platform/contiki-conf.h file or /platform/contiki-main.c
Read the comments there, basically
#define HARD_CODED_ADDRESS � � �"fdfd::10" //assign prefix and ipv6 address
�
------------------------------------------------------------------------------
BlackBerry® DevCon Americas, Oct. 18-20, San Francisco, CA
The must-attend event for mobile developers. Connect with experts.
Get tools for creating Super Apps. See the latest technologies.
Sessions, hands-on labs, demos & much more. Register early & save!
http://p.sf.net/sfu/rim-blackberry-1
_______________________________________________
Contiki-developers mailing list
Contiki-d...@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/contiki-developers
�
------------------------------------------------------------------------------
BlackBerry® DevCon Americas, Oct. 18-20, San Francisco, CA
The must-attend event for mobile developers. Connect with experts.
Get tools for creating Super Apps. See the latest technologies.
Sessions, hands-on labs, demos & much more. Register early & save!
http://p.sf.net/sfu/rim-blackberry-1
_______________________________________________
Contiki-developers mailing list
Contiki-d...@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/contiki-developers
�
------------------------------------------------------------------------------
BlackBerry® DevCon Americas, Oct. 18-20, San Francisco, CA
The must-attend event for mobile developers. Connect with experts.
Get tools for creating Super Apps. See the latest technologies.
Sessions, hands-on labs, demos & much more. Register early & save!
http://p.sf.net/sfu/rim-blackberry-1
_______________________________________________
Contiki-developers mailing list
Contiki-d...@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/contiki-developers
�
------------------------------------------------------------------------------
BlackBerry® DevCon Americas, Oct. 18-20, San Francisco, CA
The must-attend event for mobile developers. Connect with experts.
Get tools for creating Super Apps. See the latest technologies.
Sessions, hands-on labs, demos & much more. Register early & save!
http://p.sf.net/sfu/rim-blackberry-1
_______________________________________________
Contiki-developers mailing list
Contiki-d...@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/contiki-developers
�
------------------------------------------------------------------------------
BlackBerry® DevCon Americas, Oct. 18-20, San Francisco, CA
The must-attend event for mobile developers. Connect with experts.
Get tools for creating Super Apps. See the latest technologies.
Sessions, hands-on labs, demos & much more. Register early & save!
http://p.sf.net/sfu/rim-blackberry-1
_______________________________________________
Contiki-developers mailing list
Contiki-d...@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/contiki-developers
�
------------------------------------------------------------------------------ EMC VNX: the world's simplest storage, starting under $10K The only unified storage solution that offers unified management Up to 160% more powerful than alternatives and 25% more efficient. Guaranteed. http://p.sf.net/sfu/emc-vnx-dev2dev _______________________________________________ Contiki-developers mailing list Contiki-d...@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/contiki-developers
------------------------------------------------------------------------------ EMC VNX: the world's simplest storage, starting under $10K The only unified storage solution that offers unified management Up to 160% more powerful than alternatives and 25% more efficient. Guaranteed. http://p.sf.net/sfu/emc-vnx-dev2dev
_______________________________________________ Contiki-developers mailing list Contiki-d...@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/contiki-developers
Bonjour Cyril,
As-tu trouvé un moyen d'utiliser CoAP sur la TARGET minimal-net? As-tu un tuto le décrivant?
Merci d'avance.
cordialement,
Mathieu
De : cyril auburtin [mailto:cyril.a...@inria.fr]
Envoyé : mercredi 3 août 2011 17:48
À : Contiki developer mailing list
Objet : Re: [Contiki-developers] CoAP development road-map?