* RTNet - vnic0 question
@ 2019-08-21 14:20 Laurentiu-Cristian Duca
2019-08-21 16:59 ` Jan Kiszka
0 siblings, 1 reply; 10+ messages in thread
From: Laurentiu-Cristian Duca @ 2019-08-21 14:20 UTC (permalink / raw)
To: xenomai
Hello rtnet community,
I successfully tested the examples rtt-sender and rtt-responder
within a rtnet made from one beaglebone black and one qemu-x86_64-8139too,
with tdma and also with nomac.
I have noted that the presence of vnic0 as an up and fully
configured interface is mandatory,
even if rteth0 is up and fully configured.
Otherwise the rtt-sender announces "sendto failed: Network is unreachable".
Could anybody tell me why is this happening?
I have also noted that if I disable vnic0 (ifconfig vnic0 down),
rtping works if rteth0 is up and fully configured.
Why does not work rtt-sender in this case?
Could it be a problem with rtnet drivers?
Thank you and best regards,
L-C. Duca
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: RTNet - vnic0 question
2019-08-21 14:20 RTNet - vnic0 question Laurentiu-Cristian Duca
@ 2019-08-21 16:59 ` Jan Kiszka
2019-08-22 7:39 ` Laurentiu-Cristian Duca
0 siblings, 1 reply; 10+ messages in thread
From: Jan Kiszka @ 2019-08-21 16:59 UTC (permalink / raw)
To: Laurentiu-Cristian Duca, xenomai
On 21.08.19 16:20, Laurentiu-Cristian Duca via Xenomai wrote:
> Hello rtnet community,
>
> I successfully tested the examples rtt-sender and rtt-responder
> within a rtnet made from one beaglebone black and one qemu-x86_64-8139too,
> with tdma and also with nomac.
Are we talking about some legacy Xenomai or even RTnet version? Or where did you
get the examples from? They are not part of RTnet in Xenomai 3.
>
> I have noted that the presence of vnic0 as an up and fully
> configured interface is mandatory,
> even if rteth0 is up and fully configured.
> Otherwise the rtt-sender announces "sendto failed: Network is unreachable".
> Could anybody tell me why is this happening?
>
> I have also noted that if I disable vnic0 (ifconfig vnic0 down),
> rtping works if rteth0 is up and fully configured.
> Why does not work rtt-sender in this case?
> Could it be a problem with rtnet drivers?
I bet your examples are falling back to normal network here, and that is
provided between your test nodes via the vnics. This leads to my first question:
Where did you pick the examples up, how did you build them etc.? Also, did you
make sure that rtudp was loaded?
Jan
--
Siemens AG, Corporate Technology, CT RDA IOT SES-DE
Corporate Competence Center Embedded Linux
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: RTNet - vnic0 question
2019-08-21 16:59 ` Jan Kiszka
@ 2019-08-22 7:39 ` Laurentiu-Cristian Duca
2019-08-22 7:54 ` Laurentiu-Cristian Duca
0 siblings, 1 reply; 10+ messages in thread
From: Laurentiu-Cristian Duca @ 2019-08-22 7:39 UTC (permalink / raw)
To: Jan Kiszka; +Cc: xenomai
Hello Jan and friends
Thank you for your fast answer. Please find below the details.
On 8/21/19, Jan Kiszka <jan.kiszka@siemens.com> wrote:
> On 21.08.19 16:20, Laurentiu-Cristian Duca via Xenomai wrote:
>> Hello rtnet community,
>>
>> I successfully tested the examples rtt-sender and rtt-responder
>> within a rtnet made from one beaglebone black and one
>> qemu-x86_64-8139too,
>> with tdma and also with nomac.
>
> Are we talking about some legacy Xenomai or even RTnet version? Or where did
> you
> get the examples from? They are not part of RTnet in Xenomai 3.
>
I got the examples from rtnet-0.9.13. I know they are quite old, but
I needed a start point.
Are these obsolete? Do you have any examples for Xenomai 3?
rtnet-0.9.13/examples/xenomai/posix/rtt-sender.c
rtnet-0.9.13/examples/xenomai/posix/rtt-responder.c
>>
>> I have noted that the presence of vnic0 as an up and fully
>> configured interface is mandatory,
>> even if rteth0 is up and fully configured.
>> Otherwise the rtt-sender announces "sendto failed: Network is
>> unreachable".
>> Could anybody tell me why is this happening?
>>
>> I have also noted that if I disable vnic0 (ifconfig vnic0 down),
>> rtping works if rteth0 is up and fully configured.
>> Why does not work rtt-sender in this case?
>> Could it be a problem with rtnet drivers?
>
> I bet your examples are falling back to normal network here, and that is
> provided between your test nodes via the vnics. This leads to my first
> question:
> Where did you pick the examples up, how did you build them etc.? Also, did
> you
> make sure that rtudp was loaded?
I am 100% sure that rtudp was loaded. The modules were loaded by a script:
modprobe rt_smsc && modprobe rt_davinci_mdio && modprobe rt_ticpsw
modprobe rtipv4 && modprobe rtpacket && modprobe rtudp
modprobe rtmac
modprobe nomac
#modprobe tdma
I used robertcnelson Xenomai 3.0.9 patch for beaglebone black linux
4.14.108. It's on github.
I have also copied the rtnet header files to xenomai-userspace
include. The files compile without warnings.
The makefile is:
# Tested with linaro toolchain
(gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf)
CC = arm-linux-gnueabihf-gcc
XENO_INSTALL = /home/laur/lucru/raspberry-pi/robertcnelson/ti-linux-kernel-dev/ignore/xenomai-userspace
RTNET_INSTALL = /home/laur/lucru/raspberry-pi/robertcnelson/rtnet-hiddeate2m
#XENO_CONFIG :=
/home/laur/lucru/raspberry-pi/robertcnelson/ti-linux-kernel-dev/ignore/xenomai-userspace/usr/xenomai/bin/xeno-config
#/usr/xenomai/bin/xeno-config
#CFLAGS := $(shell $(XENO_CONFIG) --posix --alchemy --cflags)
#LDFLAGS := $(shell $(XENO_CONFIG) --posix --alchemy --ldflags)
LIBCFLAGS = -Wall -I$(XENO_INSTALL)/usr/xenomai/include/cobalt
LIBCFLAGS += -I$(XENO_INSTALL)/usr/xenomai/include
CFLAGS = -Wall -I$(XENO_INSTALL)/usr/xenomai/include/cobalt
CFLAGS += -I$(XENO_INSTALL)/usr/xenomai/include/alchemy
-I$(XENO_INSTALL)/usr/xenomai/include
CFLAGS += -march=armv7-a -mfpu=vfpv4 -D_GNU_SOURCE -D_REENTRANT
-D__COBALT__ -D__COBALT_WRAP_
CFLAGS += -I$(RTNET_INSTALL)/stack/include
LFLAGS = -lalchemy -lcopperplate
$(XENO_INSTALL)/usr/xenomai/lib/xenomai/bootstrap.o
LFLAGS += -Wl,--wrap=main -Wl,--wrap=malloc -Wl,--wrap=free
#-Wl,--dynamic-list=$(XENO_INSTALL)/usr/xenomai/lib/dynlist.ld
LFLAGS += -L$(XENO_INSTALL)/usr/xenomai/lib -lcobalt -lpthread -lrt
LFLAGS += -march=armv7-a -mfpu=vfpv4 -Llib
all: rtt-sender rtt-responder
rtt-sender: rtt-sender.o
$(CC) -o rtt-sender rtt-sender.o $(LFLAGS)
rtt-sender.o: rtt-sender.c
$(CC) -c -o rtt-sender.o rtt-sender.c $(CFLAGS) $(LIBCFLAGS)
(same for rtt-responder)
Kind regards,
L-C.
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: RTNet - vnic0 question
2019-08-22 7:39 ` Laurentiu-Cristian Duca
@ 2019-08-22 7:54 ` Laurentiu-Cristian Duca
2019-08-22 11:21 ` Laurentiu-Cristian Duca
0 siblings, 1 reply; 10+ messages in thread
From: Laurentiu-Cristian Duca @ 2019-08-22 7:54 UTC (permalink / raw)
To: Jan Kiszka; +Cc: xenomai
The rt drivers for bbb are taken from:
https://github.com/G-Ray/xenomai-boneblack-rtnet-drivers
and I am not 100% sure that they are working correctly.
On 8/22/19, Laurentiu-Cristian Duca <laurentiu.duca@gmail.com> wrote:
> Hello Jan and friends
>
> Thank you for your fast answer. Please find below the details.
>
> On 8/21/19, Jan Kiszka <jan.kiszka@siemens.com> wrote:
>> On 21.08.19 16:20, Laurentiu-Cristian Duca via Xenomai wrote:
>>> Hello rtnet community,
>>>
>>> I successfully tested the examples rtt-sender and rtt-responder
>>> within a rtnet made from one beaglebone black and one
>>> qemu-x86_64-8139too,
>>> with tdma and also with nomac.
>>
>> Are we talking about some legacy Xenomai or even RTnet version? Or where
>> did
>> you
>> get the examples from? They are not part of RTnet in Xenomai 3.
>>
> I got the examples from rtnet-0.9.13. I know they are quite old, but
> I needed a start point.
> Are these obsolete? Do you have any examples for Xenomai 3?
> rtnet-0.9.13/examples/xenomai/posix/rtt-sender.c
> rtnet-0.9.13/examples/xenomai/posix/rtt-responder.c
>
>>>
>>> I have noted that the presence of vnic0 as an up and fully
>>> configured interface is mandatory,
>>> even if rteth0 is up and fully configured.
>>> Otherwise the rtt-sender announces "sendto failed: Network is
>>> unreachable".
>>> Could anybody tell me why is this happening?
>>>
>>> I have also noted that if I disable vnic0 (ifconfig vnic0 down),
>>> rtping works if rteth0 is up and fully configured.
>>> Why does not work rtt-sender in this case?
>>> Could it be a problem with rtnet drivers?
>>
>> I bet your examples are falling back to normal network here, and that is
>> provided between your test nodes via the vnics. This leads to my first
>> question:
>> Where did you pick the examples up, how did you build them etc.? Also,
>> did
>> you
>> make sure that rtudp was loaded?
>
> I am 100% sure that rtudp was loaded. The modules were loaded by a
> script:
> modprobe rt_smsc && modprobe rt_davinci_mdio && modprobe rt_ticpsw
> modprobe rtipv4 && modprobe rtpacket && modprobe rtudp
> modprobe rtmac
> modprobe nomac
> #modprobe tdma
>
> I used robertcnelson Xenomai 3.0.9 patch for beaglebone black linux
> 4.14.108. It's on github.
> I have also copied the rtnet header files to xenomai-userspace
> include. The files compile without warnings.
> The makefile is:
> # Tested with linaro toolchain
> (gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf)
> CC = arm-linux-gnueabihf-gcc
> XENO_INSTALL =
> /home/laur/lucru/raspberry-pi/robertcnelson/ti-linux-kernel-dev/ignore/xenomai-userspace
> RTNET_INSTALL =
> /home/laur/lucru/raspberry-pi/robertcnelson/rtnet-hiddeate2m
>
> #XENO_CONFIG :=
> /home/laur/lucru/raspberry-pi/robertcnelson/ti-linux-kernel-dev/ignore/xenomai-userspace/usr/xenomai/bin/xeno-config
> #/usr/xenomai/bin/xeno-config
> #CFLAGS := $(shell $(XENO_CONFIG) --posix --alchemy --cflags)
> #LDFLAGS := $(shell $(XENO_CONFIG) --posix --alchemy --ldflags)
>
> LIBCFLAGS = -Wall -I$(XENO_INSTALL)/usr/xenomai/include/cobalt
> LIBCFLAGS += -I$(XENO_INSTALL)/usr/xenomai/include
>
> CFLAGS = -Wall -I$(XENO_INSTALL)/usr/xenomai/include/cobalt
> CFLAGS += -I$(XENO_INSTALL)/usr/xenomai/include/alchemy
> -I$(XENO_INSTALL)/usr/xenomai/include
> CFLAGS += -march=armv7-a -mfpu=vfpv4 -D_GNU_SOURCE -D_REENTRANT
> -D__COBALT__ -D__COBALT_WRAP_
> CFLAGS += -I$(RTNET_INSTALL)/stack/include
>
> LFLAGS = -lalchemy -lcopperplate
> $(XENO_INSTALL)/usr/xenomai/lib/xenomai/bootstrap.o
> LFLAGS += -Wl,--wrap=main -Wl,--wrap=malloc -Wl,--wrap=free
> #-Wl,--dynamic-list=$(XENO_INSTALL)/usr/xenomai/lib/dynlist.ld
> LFLAGS += -L$(XENO_INSTALL)/usr/xenomai/lib -lcobalt -lpthread -lrt
> LFLAGS += -march=armv7-a -mfpu=vfpv4 -Llib
>
> all: rtt-sender rtt-responder
> rtt-sender: rtt-sender.o
> $(CC) -o rtt-sender rtt-sender.o $(LFLAGS)
> rtt-sender.o: rtt-sender.c
> $(CC) -c -o rtt-sender.o rtt-sender.c $(CFLAGS) $(LIBCFLAGS)
> (same for rtt-responder)
>
>
> Kind regards,
> L-C.
>
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: RTNet - vnic0 question
2019-08-22 7:54 ` Laurentiu-Cristian Duca
@ 2019-08-22 11:21 ` Laurentiu-Cristian Duca
2019-08-22 12:10 ` Per Oberg
0 siblings, 1 reply; 10+ messages in thread
From: Laurentiu-Cristian Duca @ 2019-08-22 11:21 UTC (permalink / raw)
To: Jan Kiszka; +Cc: xenomai
Hi,
I have made a test between two qemu-x86_64-rt_8139too with different
mac and IP addresses,
one is master one is slave. In each of them I do:
/usr/xenomai/sbin/rtnet start
Then the applications rtt-sender and rtt-responder (taken from rtnet
0.9.13 release) work,
but if I turn off vnic0, then rtt-sender reports error: "sendto
failed: Network is unreachable",
even if rteth0 is up and fully configured.
Do you have any simple apps that work on rtnet?
Thank you,
Kind regards
On 8/22/19, Laurentiu-Cristian Duca <laurentiu.duca@gmail.com> wrote:
> The rt drivers for bbb are taken from:
> https://github.com/G-Ray/xenomai-boneblack-rtnet-drivers
> and I am not 100% sure that they are working correctly.
>
> On 8/22/19, Laurentiu-Cristian Duca <laurentiu.duca@gmail.com> wrote:
>> Hello Jan and friends
>>
>> Thank you for your fast answer. Please find below the details.
>>
>> On 8/21/19, Jan Kiszka <jan.kiszka@siemens.com> wrote:
>>> On 21.08.19 16:20, Laurentiu-Cristian Duca via Xenomai wrote:
>>>> Hello rtnet community,
>>>>
>>>> I successfully tested the examples rtt-sender and rtt-responder
>>>> within a rtnet made from one beaglebone black and one
>>>> qemu-x86_64-8139too,
>>>> with tdma and also with nomac.
>>>
>>> Are we talking about some legacy Xenomai or even RTnet version? Or where
>>> did
>>> you
>>> get the examples from? They are not part of RTnet in Xenomai 3.
>>>
>> I got the examples from rtnet-0.9.13. I know they are quite old, but
>> I needed a start point.
>> Are these obsolete? Do you have any examples for Xenomai 3?
>> rtnet-0.9.13/examples/xenomai/posix/rtt-sender.c
>> rtnet-0.9.13/examples/xenomai/posix/rtt-responder.c
>>
>>>>
>>>> I have noted that the presence of vnic0 as an up and fully
>>>> configured interface is mandatory,
>>>> even if rteth0 is up and fully configured.
>>>> Otherwise the rtt-sender announces "sendto failed: Network is
>>>> unreachable".
>>>> Could anybody tell me why is this happening?
>>>>
>>>> I have also noted that if I disable vnic0 (ifconfig vnic0 down),
>>>> rtping works if rteth0 is up and fully configured.
>>>> Why does not work rtt-sender in this case?
>>>> Could it be a problem with rtnet drivers?
>>>
>>> I bet your examples are falling back to normal network here, and that is
>>> provided between your test nodes via the vnics. This leads to my first
>>> question:
>>> Where did you pick the examples up, how did you build them etc.? Also,
>>> did
>>> you
>>> make sure that rtudp was loaded?
>>
>> I am 100% sure that rtudp was loaded. The modules were loaded by a
>> script:
>> modprobe rt_smsc && modprobe rt_davinci_mdio && modprobe rt_ticpsw
>> modprobe rtipv4 && modprobe rtpacket && modprobe rtudp
>> modprobe rtmac
>> modprobe nomac
>> #modprobe tdma
>>
>> I used robertcnelson Xenomai 3.0.9 patch for beaglebone black linux
>> 4.14.108. It's on github.
>> I have also copied the rtnet header files to xenomai-userspace
>> include. The files compile without warnings.
>> The makefile is:
>> # Tested with linaro toolchain
>> (gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf)
>> CC = arm-linux-gnueabihf-gcc
>> XENO_INSTALL =
>> /home/laur/lucru/raspberry-pi/robertcnelson/ti-linux-kernel-dev/ignore/xenomai-userspace
>> RTNET_INSTALL =
>> /home/laur/lucru/raspberry-pi/robertcnelson/rtnet-hiddeate2m
>>
>> #XENO_CONFIG :=
>> /home/laur/lucru/raspberry-pi/robertcnelson/ti-linux-kernel-dev/ignore/xenomai-userspace/usr/xenomai/bin/xeno-config
>> #/usr/xenomai/bin/xeno-config
>> #CFLAGS := $(shell $(XENO_CONFIG) --posix --alchemy --cflags)
>> #LDFLAGS := $(shell $(XENO_CONFIG) --posix --alchemy --ldflags)
>>
>> LIBCFLAGS = -Wall -I$(XENO_INSTALL)/usr/xenomai/include/cobalt
>> LIBCFLAGS += -I$(XENO_INSTALL)/usr/xenomai/include
>>
>> CFLAGS = -Wall -I$(XENO_INSTALL)/usr/xenomai/include/cobalt
>> CFLAGS += -I$(XENO_INSTALL)/usr/xenomai/include/alchemy
>> -I$(XENO_INSTALL)/usr/xenomai/include
>> CFLAGS += -march=armv7-a -mfpu=vfpv4 -D_GNU_SOURCE -D_REENTRANT
>> -D__COBALT__ -D__COBALT_WRAP_
>> CFLAGS += -I$(RTNET_INSTALL)/stack/include
>>
>> LFLAGS = -lalchemy -lcopperplate
>> $(XENO_INSTALL)/usr/xenomai/lib/xenomai/bootstrap.o
>> LFLAGS += -Wl,--wrap=main -Wl,--wrap=malloc -Wl,--wrap=free
>> #-Wl,--dynamic-list=$(XENO_INSTALL)/usr/xenomai/lib/dynlist.ld
>> LFLAGS += -L$(XENO_INSTALL)/usr/xenomai/lib -lcobalt -lpthread -lrt
>> LFLAGS += -march=armv7-a -mfpu=vfpv4 -Llib
>>
>> all: rtt-sender rtt-responder
>> rtt-sender: rtt-sender.o
>> $(CC) -o rtt-sender rtt-sender.o $(LFLAGS)
>> rtt-sender.o: rtt-sender.c
>> $(CC) -c -o rtt-sender.o rtt-sender.c $(CFLAGS) $(LIBCFLAGS)
>> (same for rtt-responder)
>>
>>
>> Kind regards,
>> L-C.
>>
>
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: RTNet - vnic0 question
2019-08-22 11:21 ` Laurentiu-Cristian Duca
@ 2019-08-22 12:10 ` Per Oberg
2019-08-22 14:27 ` Laurentiu-Cristian Duca
0 siblings, 1 reply; 10+ messages in thread
From: Per Oberg @ 2019-08-22 12:10 UTC (permalink / raw)
To: Laurentiu-Cristian Duca; +Cc: xenomai
----- Den 22 aug 2019, på kl 13:21, xenomai xenomai@xenomai.org skrev:
> Hi,
> I have made a test between two qemu-x86_64-rt_8139too with different
> mac and IP addresses,
> one is master one is slave. In each of them I do:
> /usr/xenomai/sbin/rtnet start
> Then the applications rtt-sender and rtt-responder (taken from rtnet
> 0.9.13 release) work,
> but if I turn off vnic0, then rtt-sender reports error: "sendto
> failed: Network is unreachable",
> even if rteth0 is up and fully configured.
> Do you have any simple apps that work on rtnet?
You have :
rtping
rtifconfig
rtroute
Perhaps these can be of assistance?
> Thank you,
> Kind regards
> On 8/22/19, Laurentiu-Cristian Duca <laurentiu.duca@gmail.com> wrote:
> > The rt drivers for bbb are taken from:
> > https://github.com/G-Ray/xenomai-boneblack-rtnet-drivers
> > and I am not 100% sure that they are working correctly.
> > On 8/22/19, Laurentiu-Cristian Duca <laurentiu.duca@gmail.com> wrote:
> >> Hello Jan and friends
> >> Thank you for your fast answer. Please find below the details.
> >> On 8/21/19, Jan Kiszka <jan.kiszka@siemens.com> wrote:
> >>> On 21.08.19 16:20, Laurentiu-Cristian Duca via Xenomai wrote:
> >>>> Hello rtnet community,
> >>>> I successfully tested the examples rtt-sender and rtt-responder
> >>>> within a rtnet made from one beaglebone black and one
> >>>> qemu-x86_64-8139too,
> >>>> with tdma and also with nomac.
> >>> Are we talking about some legacy Xenomai or even RTnet version? Or where
> >>> did
> >>> you
> >>> get the examples from? They are not part of RTnet in Xenomai 3.
> >> I got the examples from rtnet-0.9.13. I know they are quite old, but
> >> I needed a start point.
> >> Are these obsolete? Do you have any examples for Xenomai 3?
> >> rtnet-0.9.13/examples/xenomai/posix/rtt-sender.c
> >> rtnet-0.9.13/examples/xenomai/posix/rtt-responder.c
> >>>> I have noted that the presence of vnic0 as an up and fully
> >>>> configured interface is mandatory,
> >>>> even if rteth0 is up and fully configured.
> >>>> Otherwise the rtt-sender announces "sendto failed: Network is
> >>>> unreachable".
> >>>> Could anybody tell me why is this happening?
> >>>> I have also noted that if I disable vnic0 (ifconfig vnic0 down),
> >>>> rtping works if rteth0 is up and fully configured.
> >>>> Why does not work rtt-sender in this case?
> >>>> Could it be a problem with rtnet drivers?
> >>> I bet your examples are falling back to normal network here, and that is
> >>> provided between your test nodes via the vnics. This leads to my first
> >>> question:
> >>> Where did you pick the examples up, how did you build them etc.? Also,
> >>> did
> >>> you
> >>> make sure that rtudp was loaded?
> >> I am 100% sure that rtudp was loaded. The modules were loaded by a
> >> script:
> >> modprobe rt_smsc && modprobe rt_davinci_mdio && modprobe rt_ticpsw
> >> modprobe rtipv4 && modprobe rtpacket && modprobe rtudp
> >> modprobe rtmac
> >> modprobe nomac
> >> #modprobe tdma
> >> I used robertcnelson Xenomai 3.0.9 patch for beaglebone black linux
> >> 4.14.108. It's on github.
> >> I have also copied the rtnet header files to xenomai-userspace
> >> include. The files compile without warnings.
> >> The makefile is:
> >> # Tested with linaro toolchain
> >> (gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf)
> >> CC = arm-linux-gnueabihf-gcc
> >> XENO_INSTALL =
> >> /home/laur/lucru/raspberry-pi/robertcnelson/ti-linux-kernel-dev/ignore/xenomai-userspace
> >> RTNET_INSTALL =
> >> /home/laur/lucru/raspberry-pi/robertcnelson/rtnet-hiddeate2m
> >> #XENO_CONFIG :=
> >> /home/laur/lucru/raspberry-pi/robertcnelson/ti-linux-kernel-dev/ignore/xenomai-userspace/usr/xenomai/bin/xeno-config
> >> #/usr/xenomai/bin/xeno-config
> >> #CFLAGS := $(shell $(XENO_CONFIG) --posix --alchemy --cflags)
> >> #LDFLAGS := $(shell $(XENO_CONFIG) --posix --alchemy --ldflags)
> >> LIBCFLAGS = -Wall -I$(XENO_INSTALL)/usr/xenomai/include/cobalt
> >> LIBCFLAGS += -I$(XENO_INSTALL)/usr/xenomai/include
> >> CFLAGS = -Wall -I$(XENO_INSTALL)/usr/xenomai/include/cobalt
> >> CFLAGS += -I$(XENO_INSTALL)/usr/xenomai/include/alchemy
> >> -I$(XENO_INSTALL)/usr/xenomai/include
> >> CFLAGS += -march=armv7-a -mfpu=vfpv4 -D_GNU_SOURCE -D_REENTRANT
> >> -D__COBALT__ -D__COBALT_WRAP_
> >> CFLAGS += -I$(RTNET_INSTALL)/stack/include
> >> LFLAGS = -lalchemy -lcopperplate
> >> $(XENO_INSTALL)/usr/xenomai/lib/xenomai/bootstrap.o
> >> LFLAGS += -Wl,--wrap=main -Wl,--wrap=malloc -Wl,--wrap=free
> >> #-Wl,--dynamic-list=$(XENO_INSTALL)/usr/xenomai/lib/dynlist.ld
> >> LFLAGS += -L$(XENO_INSTALL)/usr/xenomai/lib -lcobalt -lpthread -lrt
> >> LFLAGS += -march=armv7-a -mfpu=vfpv4 -Llib
> >> all: rtt-sender rtt-responder
> >> rtt-sender: rtt-sender.o
> >> $(CC) -o rtt-sender rtt-sender.o $(LFLAGS)
> >> rtt-sender.o: rtt-sender.c
> >> $(CC) -c -o rtt-sender.o rtt-sender.c $(CFLAGS) $(LIBCFLAGS)
> >> (same for rtt-responder)
> >> Kind regards,
> >> L-C.
Per Öberg
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: RTNet - vnic0 question
2019-08-22 12:10 ` Per Oberg
@ 2019-08-22 14:27 ` Laurentiu-Cristian Duca
2019-08-22 14:38 ` Jan Kiszka
2019-08-22 14:47 ` Per Oberg
0 siblings, 2 replies; 10+ messages in thread
From: Laurentiu-Cristian Duca @ 2019-08-22 14:27 UTC (permalink / raw)
To: Per Oberg; +Cc: xenomai
Hi,
I have used rtifconfig, rtroute and rtping and I mentioned that worked,
I have written that rtt-sender and rtt-responder which use posix skin
worked only on vnic0 and not on rteth0.
I have ported frag-ip.c (from rtnet 0.9.13 to xenomai 3)
which uses alchemy instead of posix and it works on rteth0 link
between two qemu-x86_64-rt_8139too virtual machines,
but do not work on bbb (I think the drivers I use have problems on bbb).
Thx
On 8/22/19, Per Oberg <pero@wolfram.com> wrote:
>
>
> ----- Den 22 aug 2019, på kl 13:21, xenomai xenomai@xenomai.org skrev:
>
>> Hi,
>
>> I have made a test between two qemu-x86_64-rt_8139too with different
>> mac and IP addresses,
>> one is master one is slave. In each of them I do:
>> /usr/xenomai/sbin/rtnet start
>> Then the applications rtt-sender and rtt-responder (taken from rtnet
>> 0.9.13 release) work,
>> but if I turn off vnic0, then rtt-sender reports error: "sendto
>> failed: Network is unreachable",
>> even if rteth0 is up and fully configured.
>> Do you have any simple apps that work on rtnet?
>
> You have :
> rtping
> rtifconfig
> rtroute
>
> Perhaps these can be of assistance?
>
>> Thank you,
>> Kind regards
>
>> On 8/22/19, Laurentiu-Cristian Duca <laurentiu.duca@gmail.com> wrote:
>> > The rt drivers for bbb are taken from:
>> > https://github.com/G-Ray/xenomai-boneblack-rtnet-drivers
>> > and I am not 100% sure that they are working correctly.
>
>> > On 8/22/19, Laurentiu-Cristian Duca <laurentiu.duca@gmail.com> wrote:
>> >> Hello Jan and friends
>
>> >> Thank you for your fast answer. Please find below the details.
>
>> >> On 8/21/19, Jan Kiszka <jan.kiszka@siemens.com> wrote:
>> >>> On 21.08.19 16:20, Laurentiu-Cristian Duca via Xenomai wrote:
>> >>>> Hello rtnet community,
>
>> >>>> I successfully tested the examples rtt-sender and rtt-responder
>> >>>> within a rtnet made from one beaglebone black and one
>> >>>> qemu-x86_64-8139too,
>> >>>> with tdma and also with nomac.
>
>> >>> Are we talking about some legacy Xenomai or even RTnet version? Or
>> >>> where
>> >>> did
>> >>> you
>> >>> get the examples from? They are not part of RTnet in Xenomai 3.
>
>> >> I got the examples from rtnet-0.9.13. I know they are quite old, but
>> >> I needed a start point.
>> >> Are these obsolete? Do you have any examples for Xenomai 3?
>> >> rtnet-0.9.13/examples/xenomai/posix/rtt-sender.c
>> >> rtnet-0.9.13/examples/xenomai/posix/rtt-responder.c
>
>
>> >>>> I have noted that the presence of vnic0 as an up and fully
>> >>>> configured interface is mandatory,
>> >>>> even if rteth0 is up and fully configured.
>> >>>> Otherwise the rtt-sender announces "sendto failed: Network is
>> >>>> unreachable".
>> >>>> Could anybody tell me why is this happening?
>
>> >>>> I have also noted that if I disable vnic0 (ifconfig vnic0 down),
>> >>>> rtping works if rteth0 is up and fully configured.
>> >>>> Why does not work rtt-sender in this case?
>> >>>> Could it be a problem with rtnet drivers?
>
>> >>> I bet your examples are falling back to normal network here, and that
>> >>> is
>> >>> provided between your test nodes via the vnics. This leads to my
>> >>> first
>> >>> question:
>> >>> Where did you pick the examples up, how did you build them etc.?
>> >>> Also,
>> >>> did
>> >>> you
>> >>> make sure that rtudp was loaded?
>
>> >> I am 100% sure that rtudp was loaded. The modules were loaded by a
>> >> script:
>> >> modprobe rt_smsc && modprobe rt_davinci_mdio && modprobe rt_ticpsw
>> >> modprobe rtipv4 && modprobe rtpacket && modprobe rtudp
>> >> modprobe rtmac
>> >> modprobe nomac
>> >> #modprobe tdma
>
>> >> I used robertcnelson Xenomai 3.0.9 patch for beaglebone black linux
>> >> 4.14.108. It's on github.
>> >> I have also copied the rtnet header files to xenomai-userspace
>> >> include. The files compile without warnings.
>> >> The makefile is:
>> >> # Tested with linaro toolchain
>> >> (gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf)
>> >> CC = arm-linux-gnueabihf-gcc
>> >> XENO_INSTALL =
>> >> /home/laur/lucru/raspberry-pi/robertcnelson/ti-linux-kernel-dev/ignore/xenomai-userspace
>> >> RTNET_INSTALL =
>> >> /home/laur/lucru/raspberry-pi/robertcnelson/rtnet-hiddeate2m
>
>> >> #XENO_CONFIG :=
>> >> /home/laur/lucru/raspberry-pi/robertcnelson/ti-linux-kernel-dev/ignore/xenomai-userspace/usr/xenomai/bin/xeno-config
>> >> #/usr/xenomai/bin/xeno-config
>> >> #CFLAGS := $(shell $(XENO_CONFIG) --posix --alchemy --cflags)
>> >> #LDFLAGS := $(shell $(XENO_CONFIG) --posix --alchemy --ldflags)
>
>> >> LIBCFLAGS = -Wall -I$(XENO_INSTALL)/usr/xenomai/include/cobalt
>> >> LIBCFLAGS += -I$(XENO_INSTALL)/usr/xenomai/include
>
>> >> CFLAGS = -Wall -I$(XENO_INSTALL)/usr/xenomai/include/cobalt
>> >> CFLAGS += -I$(XENO_INSTALL)/usr/xenomai/include/alchemy
>> >> -I$(XENO_INSTALL)/usr/xenomai/include
>> >> CFLAGS += -march=armv7-a -mfpu=vfpv4 -D_GNU_SOURCE -D_REENTRANT
>> >> -D__COBALT__ -D__COBALT_WRAP_
>> >> CFLAGS += -I$(RTNET_INSTALL)/stack/include
>
>> >> LFLAGS = -lalchemy -lcopperplate
>> >> $(XENO_INSTALL)/usr/xenomai/lib/xenomai/bootstrap.o
>> >> LFLAGS += -Wl,--wrap=main -Wl,--wrap=malloc -Wl,--wrap=free
>> >> #-Wl,--dynamic-list=$(XENO_INSTALL)/usr/xenomai/lib/dynlist.ld
>> >> LFLAGS += -L$(XENO_INSTALL)/usr/xenomai/lib -lcobalt -lpthread -lrt
>> >> LFLAGS += -march=armv7-a -mfpu=vfpv4 -Llib
>
>> >> all: rtt-sender rtt-responder
>> >> rtt-sender: rtt-sender.o
>> >> $(CC) -o rtt-sender rtt-sender.o $(LFLAGS)
>> >> rtt-sender.o: rtt-sender.c
>> >> $(CC) -c -o rtt-sender.o rtt-sender.c $(CFLAGS) $(LIBCFLAGS)
>> >> (same for rtt-responder)
>
>
>> >> Kind regards,
>> >> L-C.
>
>
> Per Öberg
>
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: RTNet - vnic0 question
2019-08-22 14:27 ` Laurentiu-Cristian Duca
@ 2019-08-22 14:38 ` Jan Kiszka
2019-08-27 13:53 ` Laurentiu-Cristian Duca
2019-08-22 14:47 ` Per Oberg
1 sibling, 1 reply; 10+ messages in thread
From: Jan Kiszka @ 2019-08-22 14:38 UTC (permalink / raw)
To: Laurentiu-Cristian Duca, Per Oberg; +Cc: xenomai
On 22.08.19 16:27, Laurentiu-Cristian Duca via Xenomai wrote:
> Hi,
>
> I have used rtifconfig, rtroute and rtping and I mentioned that worked,
> I have written that rtt-sender and rtt-responder which use posix skin
> worked only on vnic0 and not on rteth0.
>
> I have ported frag-ip.c (from rtnet 0.9.13 to xenomai 3)
> which uses alchemy instead of posix and it works on rteth0 link
> between two qemu-x86_64-rt_8139too virtual machines,
> but do not work on bbb (I think the drivers I use have problems on bbb).
I still suspect your ported rtt-sender/responder have some binding issue to
RTnet so that UDP sockets fall back to plan Linux. You can check that by running
"netstat -lun" while the two are active. If someone listens on a suspicious
port, you have the prove.
Looking at your makefile...
>
> Thx
>
> On 8/22/19, Per Oberg <pero@wolfram.com> wrote:
>>
>>
>> ----- Den 22 aug 2019, på kl 13:21, xenomai xenomai@xenomai.org skrev:
>>
>>> Hi,
>>
>>> I have made a test between two qemu-x86_64-rt_8139too with different
>>> mac and IP addresses,
>>> one is master one is slave. In each of them I do:
>>> /usr/xenomai/sbin/rtnet start
>>> Then the applications rtt-sender and rtt-responder (taken from rtnet
>>> 0.9.13 release) work,
>>> but if I turn off vnic0, then rtt-sender reports error: "sendto
>>> failed: Network is unreachable",
>>> even if rteth0 is up and fully configured.
>>> Do you have any simple apps that work on rtnet?
>>
>> You have :
>> rtping
>> rtifconfig
>> rtroute
>>
>> Perhaps these can be of assistance?
>>
>>> Thank you,
>>> Kind regards
>>
>>> On 8/22/19, Laurentiu-Cristian Duca <laurentiu.duca@gmail.com> wrote:
>>>> The rt drivers for bbb are taken from:
>>>> https://github.com/G-Ray/xenomai-boneblack-rtnet-drivers
>>>> and I am not 100% sure that they are working correctly.
>>
>>>> On 8/22/19, Laurentiu-Cristian Duca <laurentiu.duca@gmail.com> wrote:
>>>>> Hello Jan and friends
>>
>>>>> Thank you for your fast answer. Please find below the details.
>>
>>>>> On 8/21/19, Jan Kiszka <jan.kiszka@siemens.com> wrote:
>>>>>> On 21.08.19 16:20, Laurentiu-Cristian Duca via Xenomai wrote:
>>>>>>> Hello rtnet community,
>>
>>>>>>> I successfully tested the examples rtt-sender and rtt-responder
>>>>>>> within a rtnet made from one beaglebone black and one
>>>>>>> qemu-x86_64-8139too,
>>>>>>> with tdma and also with nomac.
>>
>>>>>> Are we talking about some legacy Xenomai or even RTnet version? Or
>>>>>> where
>>>>>> did
>>>>>> you
>>>>>> get the examples from? They are not part of RTnet in Xenomai 3.
>>
>>>>> I got the examples from rtnet-0.9.13. I know they are quite old, but
>>>>> I needed a start point.
>>>>> Are these obsolete? Do you have any examples for Xenomai 3?
>>>>> rtnet-0.9.13/examples/xenomai/posix/rtt-sender.c
>>>>> rtnet-0.9.13/examples/xenomai/posix/rtt-responder.c
>>
>>
>>>>>>> I have noted that the presence of vnic0 as an up and fully
>>>>>>> configured interface is mandatory,
>>>>>>> even if rteth0 is up and fully configured.
>>>>>>> Otherwise the rtt-sender announces "sendto failed: Network is
>>>>>>> unreachable".
>>>>>>> Could anybody tell me why is this happening?
>>
>>>>>>> I have also noted that if I disable vnic0 (ifconfig vnic0 down),
>>>>>>> rtping works if rteth0 is up and fully configured.
>>>>>>> Why does not work rtt-sender in this case?
>>>>>>> Could it be a problem with rtnet drivers?
>>
>>>>>> I bet your examples are falling back to normal network here, and that
>>>>>> is
>>>>>> provided between your test nodes via the vnics. This leads to my
>>>>>> first
>>>>>> question:
>>>>>> Where did you pick the examples up, how did you build them etc.?
>>>>>> Also,
>>>>>> did
>>>>>> you
>>>>>> make sure that rtudp was loaded?
>>
>>>>> I am 100% sure that rtudp was loaded. The modules were loaded by a
>>>>> script:
>>>>> modprobe rt_smsc && modprobe rt_davinci_mdio && modprobe rt_ticpsw
>>>>> modprobe rtipv4 && modprobe rtpacket && modprobe rtudp
>>>>> modprobe rtmac
>>>>> modprobe nomac
>>>>> #modprobe tdma
>>
>>>>> I used robertcnelson Xenomai 3.0.9 patch for beaglebone black linux
>>>>> 4.14.108. It's on github.
>>>>> I have also copied the rtnet header files to xenomai-userspace
>>>>> include. The files compile without warnings.
>>>>> The makefile is:
>>>>> # Tested with linaro toolchain
>>>>> (gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf)
>>>>> CC = arm-linux-gnueabihf-gcc
>>>>> XENO_INSTALL =
>>>>> /home/laur/lucru/raspberry-pi/robertcnelson/ti-linux-kernel-dev/ignore/xenomai-userspace
>>>>> RTNET_INSTALL =
>>>>> /home/laur/lucru/raspberry-pi/robertcnelson/rtnet-hiddeate2m
>>
>>>>> #XENO_CONFIG :=
>>>>> /home/laur/lucru/raspberry-pi/robertcnelson/ti-linux-kernel-dev/ignore/xenomai-userspace/usr/xenomai/bin/xeno-config
>>>>> #/usr/xenomai/bin/xeno-config
>>>>> #CFLAGS := $(shell $(XENO_CONFIG) --posix --alchemy --cflags)
>>>>> #LDFLAGS := $(shell $(XENO_CONFIG) --posix --alchemy --ldflags)
The interesting parts are commented out. For POSIX, you simply want
xeno-config --skin posix --cflags / --ldflags
Nothing self-written.
Jan
>>
>>>>> LIBCFLAGS = -Wall -I$(XENO_INSTALL)/usr/xenomai/include/cobalt
>>>>> LIBCFLAGS += -I$(XENO_INSTALL)/usr/xenomai/include
>>
>>>>> CFLAGS = -Wall -I$(XENO_INSTALL)/usr/xenomai/include/cobalt
>>>>> CFLAGS += -I$(XENO_INSTALL)/usr/xenomai/include/alchemy
>>>>> -I$(XENO_INSTALL)/usr/xenomai/include
>>>>> CFLAGS += -march=armv7-a -mfpu=vfpv4 -D_GNU_SOURCE -D_REENTRANT
>>>>> -D__COBALT__ -D__COBALT_WRAP_
>>>>> CFLAGS += -I$(RTNET_INSTALL)/stack/include
>>
>>>>> LFLAGS = -lalchemy -lcopperplate
>>>>> $(XENO_INSTALL)/usr/xenomai/lib/xenomai/bootstrap.o
>>>>> LFLAGS += -Wl,--wrap=main -Wl,--wrap=malloc -Wl,--wrap=free
>>>>> #-Wl,--dynamic-list=$(XENO_INSTALL)/usr/xenomai/lib/dynlist.ld
>>>>> LFLAGS += -L$(XENO_INSTALL)/usr/xenomai/lib -lcobalt -lpthread -lrt
>>>>> LFLAGS += -march=armv7-a -mfpu=vfpv4 -Llib
>>
>>>>> all: rtt-sender rtt-responder
>>>>> rtt-sender: rtt-sender.o
>>>>> $(CC) -o rtt-sender rtt-sender.o $(LFLAGS)
>>>>> rtt-sender.o: rtt-sender.c
>>>>> $(CC) -c -o rtt-sender.o rtt-sender.c $(CFLAGS) $(LIBCFLAGS)
>>>>> (same for rtt-responder)
>>
>>
>>>>> Kind regards,
>>>>> L-C.
>>
>>
>> Per Öberg
>>
>
--
Siemens AG, Corporate Technology, CT RDA IOT SES-DE
Corporate Competence Center Embedded Linux
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: RTNet - vnic0 question
2019-08-22 14:27 ` Laurentiu-Cristian Duca
2019-08-22 14:38 ` Jan Kiszka
@ 2019-08-22 14:47 ` Per Oberg
1 sibling, 0 replies; 10+ messages in thread
From: Per Oberg @ 2019-08-22 14:47 UTC (permalink / raw)
To: Laurentiu-Cristian Duca; +Cc: xenomai
----- Den 22 aug 2019, på kl 16:27, Laurentiu-Cristian Duca laurentiu.duca@gmail.com skrev:
> Hi,
> I have used rtifconfig, rtroute and rtping and I mentioned that worked,
> I have written that rtt-sender and rtt-responder which use posix skin
> worked only on vnic0 and not on rteth0.
> I have ported frag-ip.c (from rtnet 0.9.13 to xenomai 3)
> which uses alchemy instead of posix and it works on rteth0 link
> between two qemu-x86_64-rt_8139too virtual machines,
> but do not work on bbb (I think the drivers I use have problems on bbb).
Sorry for the blunt answer. I obviously didn't read enough of the discussion and I didn't provide a good explanation of my thoughts.
My thoughts were basically these:
What I have found myself is that the routing table for rteth0 needed external poking (using ping from other source) to be set up properly, and "Network unreachable" seems to me like a failure in lookup. Perhaps when using virtual devices there are some messages sent in the virtual environment that pokes it for you?
You write that you had it working and already tried rtping, so maybe it's already taken care of. But otherwise it would have been a good idea trying rtroute and see if there is a valid mac-address in the table.
> Thx
> On 8/22/19, Per Oberg <pero@wolfram.com> wrote:
> > ----- Den 22 aug 2019, på kl 13:21, xenomai xenomai@xenomai.org skrev:
> >> Hi,
> >> I have made a test between two qemu-x86_64-rt_8139too with different
> >> mac and IP addresses,
> >> one is master one is slave. In each of them I do:
> >> /usr/xenomai/sbin/rtnet start
> >> Then the applications rtt-sender and rtt-responder (taken from rtnet
> >> 0.9.13 release) work,
> >> but if I turn off vnic0, then rtt-sender reports error: "sendto
> >> failed: Network is unreachable",
> >> even if rteth0 is up and fully configured.
> >> Do you have any simple apps that work on rtnet?
> > You have :
> > rtping
> > rtifconfig
> > rtroute
> > Perhaps these can be of assistance?
> >> Thank you,
> >> Kind regards
> >> On 8/22/19, Laurentiu-Cristian Duca <laurentiu.duca@gmail.com> wrote:
> >> > The rt drivers for bbb are taken from:
> >> > https://github.com/G-Ray/xenomai-boneblack-rtnet-drivers
> >> > and I am not 100% sure that they are working correctly.
> >> > On 8/22/19, Laurentiu-Cristian Duca <laurentiu.duca@gmail.com> wrote:
> >> >> Hello Jan and friends
> >> >> Thank you for your fast answer. Please find below the details.
> >> >> On 8/21/19, Jan Kiszka <jan.kiszka@siemens.com> wrote:
> >> >>> On 21.08.19 16:20, Laurentiu-Cristian Duca via Xenomai wrote:
> >> >>>> Hello rtnet community,
> >> >>>> I successfully tested the examples rtt-sender and rtt-responder
> >> >>>> within a rtnet made from one beaglebone black and one
> >> >>>> qemu-x86_64-8139too,
> >> >>>> with tdma and also with nomac.
> >> >>> Are we talking about some legacy Xenomai or even RTnet version? Or
> >> >>> where
> >> >>> did
> >> >>> you
> >> >>> get the examples from? They are not part of RTnet in Xenomai 3.
> >> >> I got the examples from rtnet-0.9.13. I know they are quite old, but
> >> >> I needed a start point.
> >> >> Are these obsolete? Do you have any examples for Xenomai 3?
> >> >> rtnet-0.9.13/examples/xenomai/posix/rtt-sender.c
> >> >> rtnet-0.9.13/examples/xenomai/posix/rtt-responder.c
> >> >>>> I have noted that the presence of vnic0 as an up and fully
> >> >>>> configured interface is mandatory,
> >> >>>> even if rteth0 is up and fully configured.
> >> >>>> Otherwise the rtt-sender announces "sendto failed: Network is
> >> >>>> unreachable".
> >> >>>> Could anybody tell me why is this happening?
> >> >>>> I have also noted that if I disable vnic0 (ifconfig vnic0 down),
> >> >>>> rtping works if rteth0 is up and fully configured.
> >> >>>> Why does not work rtt-sender in this case?
> >> >>>> Could it be a problem with rtnet drivers?
> >> >>> I bet your examples are falling back to normal network here, and that
> >> >>> is
> >> >>> provided between your test nodes via the vnics. This leads to my
> >> >>> first
> >> >>> question:
> >> >>> Where did you pick the examples up, how did you build them etc.?
> >> >>> Also,
> >> >>> did
> >> >>> you
> >> >>> make sure that rtudp was loaded?
> >> >> I am 100% sure that rtudp was loaded. The modules were loaded by a
> >> >> script:
> >> >> modprobe rt_smsc && modprobe rt_davinci_mdio && modprobe rt_ticpsw
> >> >> modprobe rtipv4 && modprobe rtpacket && modprobe rtudp
> >> >> modprobe rtmac
> >> >> modprobe nomac
> >> >> #modprobe tdma
> >> >> I used robertcnelson Xenomai 3.0.9 patch for beaglebone black linux
> >> >> 4.14.108. It's on github.
> >> >> I have also copied the rtnet header files to xenomai-userspace
> >> >> include. The files compile without warnings.
> >> >> The makefile is:
> >> >> # Tested with linaro toolchain
> >> >> (gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf)
> >> >> CC = arm-linux-gnueabihf-gcc
> >> >> XENO_INSTALL =
> >> >> /home/laur/lucru/raspberry-pi/robertcnelson/ti-linux-kernel-dev/ignore/xenomai-userspace
> >> >> RTNET_INSTALL =
> >> >> /home/laur/lucru/raspberry-pi/robertcnelson/rtnet-hiddeate2m
> >> >> #XENO_CONFIG :=
> >> >> /home/laur/lucru/raspberry-pi/robertcnelson/ti-linux-kernel-dev/ignore/xenomai-userspace/usr/xenomai/bin/xeno-config
> >> >> #/usr/xenomai/bin/xeno-config
> >> >> #CFLAGS := $(shell $(XENO_CONFIG) --posix --alchemy --cflags)
> >> >> #LDFLAGS := $(shell $(XENO_CONFIG) --posix --alchemy --ldflags)
> >> >> LIBCFLAGS = -Wall -I$(XENO_INSTALL)/usr/xenomai/include/cobalt
> >> >> LIBCFLAGS += -I$(XENO_INSTALL)/usr/xenomai/include
> >> >> CFLAGS = -Wall -I$(XENO_INSTALL)/usr/xenomai/include/cobalt
> >> >> CFLAGS += -I$(XENO_INSTALL)/usr/xenomai/include/alchemy
> >> >> -I$(XENO_INSTALL)/usr/xenomai/include
> >> >> CFLAGS += -march=armv7-a -mfpu=vfpv4 -D_GNU_SOURCE -D_REENTRANT
> >> >> -D__COBALT__ -D__COBALT_WRAP_
> >> >> CFLAGS += -I$(RTNET_INSTALL)/stack/include
> >> >> LFLAGS = -lalchemy -lcopperplate
> >> >> $(XENO_INSTALL)/usr/xenomai/lib/xenomai/bootstrap.o
> >> >> LFLAGS += -Wl,--wrap=main -Wl,--wrap=malloc -Wl,--wrap=free
> >> >> #-Wl,--dynamic-list=$(XENO_INSTALL)/usr/xenomai/lib/dynlist.ld
> >> >> LFLAGS += -L$(XENO_INSTALL)/usr/xenomai/lib -lcobalt -lpthread -lrt
> >> >> LFLAGS += -march=armv7-a -mfpu=vfpv4 -Llib
> >> >> all: rtt-sender rtt-responder
> >> >> rtt-sender: rtt-sender.o
> >> >> $(CC) -o rtt-sender rtt-sender.o $(LFLAGS)
> >> >> rtt-sender.o: rtt-sender.c
> >> >> $(CC) -c -o rtt-sender.o rtt-sender.c $(CFLAGS) $(LIBCFLAGS)
> >> >> (same for rtt-responder)
> >> >> Kind regards,
> >> >> L-C.
> > Per Öberg
Per Öberg
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: RTNet - vnic0 question
2019-08-22 14:38 ` Jan Kiszka
@ 2019-08-27 13:53 ` Laurentiu-Cristian Duca
0 siblings, 0 replies; 10+ messages in thread
From: Laurentiu-Cristian Duca @ 2019-08-27 13:53 UTC (permalink / raw)
To: Jan Kiszka; +Cc: Per Oberg, xenomai
Success
I had to run on target xeno-config and paste the output to my makefile,
because I was doing cross-compile for bbb on a x86_64 host.
So, the tests are:
frag-ip between bbb and qemu-x86-64-rt_8139too which use alchemy: success
rtt-sender/rtt-responder which use posix skin: success.
However the ping fails
even if vnic0 is fully configured just as rteth0 for which rtping succeds.
Thank you all
On 8/22/19, Jan Kiszka <jan.kiszka@siemens.com> wrote:
> On 22.08.19 16:27, Laurentiu-Cristian Duca via Xenomai wrote:
>> Hi,
>>
>> I have used rtifconfig, rtroute and rtping and I mentioned that worked,
>> I have written that rtt-sender and rtt-responder which use posix skin
>> worked only on vnic0 and not on rteth0.
>>
>> I have ported frag-ip.c (from rtnet 0.9.13 to xenomai 3)
>> which uses alchemy instead of posix and it works on rteth0 link
>> between two qemu-x86_64-rt_8139too virtual machines,
>> but do not work on bbb (I think the drivers I use have problems on bbb).
>
> I still suspect your ported rtt-sender/responder have some binding issue to
>
> RTnet so that UDP sockets fall back to plan Linux. You can check that by
> running
> "netstat -lun" while the two are active. If someone listens on a suspicious
>
> port, you have the prove.
>
> Looking at your makefile...
>
>>
>> Thx
>>
>> On 8/22/19, Per Oberg <pero@wolfram.com> wrote:
>>>
>>>
>>> ----- Den 22 aug 2019, på kl 13:21, xenomai xenomai@xenomai.org skrev:
>>>
>>>> Hi,
>>>
>>>> I have made a test between two qemu-x86_64-rt_8139too with different
>>>> mac and IP addresses,
>>>> one is master one is slave. In each of them I do:
>>>> /usr/xenomai/sbin/rtnet start
>>>> Then the applications rtt-sender and rtt-responder (taken from rtnet
>>>> 0.9.13 release) work,
>>>> but if I turn off vnic0, then rtt-sender reports error: "sendto
>>>> failed: Network is unreachable",
>>>> even if rteth0 is up and fully configured.
>>>> Do you have any simple apps that work on rtnet?
>>>
>>> You have :
>>> rtping
>>> rtifconfig
>>> rtroute
>>>
>>> Perhaps these can be of assistance?
>>>
>>>> Thank you,
>>>> Kind regards
>>>
>>>> On 8/22/19, Laurentiu-Cristian Duca <laurentiu.duca@gmail.com> wrote:
>>>>> The rt drivers for bbb are taken from:
>>>>> https://github.com/G-Ray/xenomai-boneblack-rtnet-drivers
>>>>> and I am not 100% sure that they are working correctly.
>>>
>>>>> On 8/22/19, Laurentiu-Cristian Duca <laurentiu.duca@gmail.com> wrote:
>>>>>> Hello Jan and friends
>>>
>>>>>> Thank you for your fast answer. Please find below the details.
>>>
>>>>>> On 8/21/19, Jan Kiszka <jan.kiszka@siemens.com> wrote:
>>>>>>> On 21.08.19 16:20, Laurentiu-Cristian Duca via Xenomai wrote:
>>>>>>>> Hello rtnet community,
>>>
>>>>>>>> I successfully tested the examples rtt-sender and rtt-responder
>>>>>>>> within a rtnet made from one beaglebone black and one
>>>>>>>> qemu-x86_64-8139too,
>>>>>>>> with tdma and also with nomac.
>>>
>>>>>>> Are we talking about some legacy Xenomai or even RTnet version? Or
>>>>>>> where
>>>>>>> did
>>>>>>> you
>>>>>>> get the examples from? They are not part of RTnet in Xenomai 3.
>>>
>>>>>> I got the examples from rtnet-0.9.13. I know they are quite old, but
>>>>>> I needed a start point.
>>>>>> Are these obsolete? Do you have any examples for Xenomai 3?
>>>>>> rtnet-0.9.13/examples/xenomai/posix/rtt-sender.c
>>>>>> rtnet-0.9.13/examples/xenomai/posix/rtt-responder.c
>>>
>>>
>>>>>>>> I have noted that the presence of vnic0 as an up and fully
>>>>>>>> configured interface is mandatory,
>>>>>>>> even if rteth0 is up and fully configured.
>>>>>>>> Otherwise the rtt-sender announces "sendto failed: Network is
>>>>>>>> unreachable".
>>>>>>>> Could anybody tell me why is this happening?
>>>
>>>>>>>> I have also noted that if I disable vnic0 (ifconfig vnic0 down),
>>>>>>>> rtping works if rteth0 is up and fully configured.
>>>>>>>> Why does not work rtt-sender in this case?
>>>>>>>> Could it be a problem with rtnet drivers?
>>>
>>>>>>> I bet your examples are falling back to normal network here, and
>>>>>>> that
>>>>>>> is
>>>>>>> provided between your test nodes via the vnics. This leads to my
>>>>>>> first
>>>>>>> question:
>>>>>>> Where did you pick the examples up, how did you build them etc.?
>>>>>>> Also,
>>>>>>> did
>>>>>>> you
>>>>>>> make sure that rtudp was loaded?
>>>
>>>>>> I am 100% sure that rtudp was loaded. The modules were loaded by a
>>>>>> script:
>>>>>> modprobe rt_smsc && modprobe rt_davinci_mdio && modprobe rt_ticpsw
>>>>>> modprobe rtipv4 && modprobe rtpacket && modprobe rtudp
>>>>>> modprobe rtmac
>>>>>> modprobe nomac
>>>>>> #modprobe tdma
>>>
>>>>>> I used robertcnelson Xenomai 3.0.9 patch for beaglebone black linux
>>>>>> 4.14.108. It's on github.
>>>>>> I have also copied the rtnet header files to xenomai-userspace
>>>>>> include. The files compile without warnings.
>>>>>> The makefile is:
>>>>>> # Tested with linaro toolchain
>>>>>> (gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf)
>>>>>> CC = arm-linux-gnueabihf-gcc
>>>>>> XENO_INSTALL =
>>>>>> /home/laur/lucru/raspberry-pi/robertcnelson/ti-linux-kernel-dev/ignore/xenomai-userspace
>>>>>> RTNET_INSTALL =
>>>>>> /home/laur/lucru/raspberry-pi/robertcnelson/rtnet-hiddeate2m
>>>
>>>>>> #XENO_CONFIG :=
>>>>>> /home/laur/lucru/raspberry-pi/robertcnelson/ti-linux-kernel-dev/ignore/xenomai-userspace/usr/xenomai/bin/xeno-config
>>>>>> #/usr/xenomai/bin/xeno-config
>>>>>> #CFLAGS := $(shell $(XENO_CONFIG) --posix --alchemy --cflags)
>>>>>> #LDFLAGS := $(shell $(XENO_CONFIG) --posix --alchemy --ldflags)
>
> The interesting parts are commented out. For POSIX, you simply want
>
> xeno-config --skin posix --cflags / --ldflags
>
> Nothing self-written.
>
> Jan
>
>>>
>>>>>> LIBCFLAGS = -Wall -I$(XENO_INSTALL)/usr/xenomai/include/cobalt
>>>>>> LIBCFLAGS += -I$(XENO_INSTALL)/usr/xenomai/include
>>>
>>>>>> CFLAGS = -Wall -I$(XENO_INSTALL)/usr/xenomai/include/cobalt
>>>>>> CFLAGS += -I$(XENO_INSTALL)/usr/xenomai/include/alchemy
>>>>>> -I$(XENO_INSTALL)/usr/xenomai/include
>>>>>> CFLAGS += -march=armv7-a -mfpu=vfpv4 -D_GNU_SOURCE -D_REENTRANT
>>>>>> -D__COBALT__ -D__COBALT_WRAP_
>>>>>> CFLAGS += -I$(RTNET_INSTALL)/stack/include
>>>
>>>>>> LFLAGS = -lalchemy -lcopperplate
>>>>>> $(XENO_INSTALL)/usr/xenomai/lib/xenomai/bootstrap.o
>>>>>> LFLAGS += -Wl,--wrap=main -Wl,--wrap=malloc -Wl,--wrap=free
>>>>>> #-Wl,--dynamic-list=$(XENO_INSTALL)/usr/xenomai/lib/dynlist.ld
>>>>>> LFLAGS += -L$(XENO_INSTALL)/usr/xenomai/lib -lcobalt -lpthread -lrt
>>>>>> LFLAGS += -march=armv7-a -mfpu=vfpv4 -Llib
>>>
>>>>>> all: rtt-sender rtt-responder
>>>>>> rtt-sender: rtt-sender.o
>>>>>> $(CC) -o rtt-sender rtt-sender.o $(LFLAGS)
>>>>>> rtt-sender.o: rtt-sender.c
>>>>>> $(CC) -c -o rtt-sender.o rtt-sender.c $(CFLAGS) $(LIBCFLAGS)
>>>>>> (same for rtt-responder)
>>>
>>>
>>>>>> Kind regards,
>>>>>> L-C.
>>>
>>>
>>> Per Öberg
>>>
>>
>
> --
> Siemens AG, Corporate Technology, CT RDA IOT SES-DE
> Corporate Competence Center Embedded Linux
>
^ permalink raw reply [flat|nested] 10+ messages in thread
end of thread, other threads:[~2019-08-27 13:53 UTC | newest]
Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-08-21 14:20 RTNet - vnic0 question Laurentiu-Cristian Duca
2019-08-21 16:59 ` Jan Kiszka
2019-08-22 7:39 ` Laurentiu-Cristian Duca
2019-08-22 7:54 ` Laurentiu-Cristian Duca
2019-08-22 11:21 ` Laurentiu-Cristian Duca
2019-08-22 12:10 ` Per Oberg
2019-08-22 14:27 ` Laurentiu-Cristian Duca
2019-08-22 14:38 ` Jan Kiszka
2019-08-27 13:53 ` Laurentiu-Cristian Duca
2019-08-22 14:47 ` Per Oberg
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.