Custom Ethernet driver and IPv4
#ipv4
#ethernet
#networking
Maik Vermeulen
I am working to implement a driver for a SPI Ethernet controller. The code is being called at initialization, but I am stuck at testing the driver. I would like to use the Net Shell, so net ping xxx.xxx.xxx.xxx for example. Unfortunately, I notice that the code fails in net_icmpv4_send_echo_request() when checking iface->config.ip.ipv4. Do I need to take extra steps to use IPv4 over my custom ethernet driver, beside enabling the driver and net shell? I could image I would have to bind my ethernet interface to the network stack somewhere, but I haven't found exactly where.
|
||||||||||
|
||||||||||
Zephyr HCI Mesh Support
Vivek Rajpara <vivek.rajpara@...>
Hello,
We are looking for the solution where we need to use Meshctl on Linux host and control the Zephyr based BT with it, can you please let us know if this support is enabled in Zephyr or not? Looking forward to hearing from you as it is a crucial design factor for us. Below is our setup nrf52840(as BT HCI controller) + Arm processor with Linux (we are using bluez 5.50 meshctl tool) I can see BT_HCI_MESH_EXT config, but it can't be enabled from menuconfig, I tried to enable it in project configuration but still, I can't send any command from meshctl to zephyr yet. Thanks in advance.
This message contains confidential information and is for the intended recipients. If you are not intended recipients you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately by e-mail if you have received this e-mail by mistake and delete this e-mail from your system. E-mail transmission cannot be guaranteed to be secure or error-free as information could be intercepted, corrupted, lost, destroyed, arrive late or incomplete, or contain viruses. The sender or VOLANSYS (www.volansys.com) therefore does not accept liability for any errors or omissions in the contents of this message.
|
||||||||||
|
||||||||||
API meeting: agenda
Carles Cufi
Hi all,
Tomorrow's topics: - VIDEO/DISPLAY: add ELCDIF support and VIDEO/DISPLAY shim layer - PR https://github.com/zephyrproject-rtos/zephyr/pull/21009 - Add i2c_async for asynchronous transfers - PR https://github.com/zephyrproject-rtos/zephyr/pull/23371 Additional items in the "Triage" column in the GitHub project may be discussed if time permits. If you want an item included in the meeting, please add it to the GitHub project. Teams link: https://teams.microsoft.com/l/meetup-join/19%3ameeting_NWU2MjZlYWEtZDcwMi00MWQzLTgwMjEtNDdkYjQwMjBjMmFj%40thread.v2/0?context=%7b%22Tid%22%3a%22af0096d9-700c-411a-b795-b3dd7122bad2%22%2c%22Oid%22%3a%22841a7c92-7816-4faf-9887-5e334e88f6d8%22%7d https://github.com/zephyrproject-rtos/zephyr/wiki/Zephyr-Committee-and-Working-Group-Meetings#zephyr-api-discussion https://github.com/zephyrproject-rtos/zephyr/projects/18 https://docs.google.com/document/d/1lv-8B5QE2m4FjBcvfqAXFIgQfW5oz6306zJ7GIZIWCk/edit Regards, Carles
|
||||||||||
|
||||||||||
Hi all,
I would like to know the status of WINC1500 driver in zephyr. Is this fully tested? We are currently working on a product that uses Nordic's nRF52832 with WINC1500 over SPI. For our development setup, we are using nRF52-DK (PCA10040) board. We have connected WINC1500-XPRO board to nRF-DK on SPI_1 (P2/P8) and for the IRQ - P0.17. Here is our DTS overlay that we have placed for our setup as nrf52dk_nrf52832.overlay in samples/net/wifi/boards &spi1 {
compatible = "nordic,nrf-spi";
status = "okay";
cs-gpios = <&gpio0 3 0>;
sck-pin = <31>;
mosi-pin = <30>;
miso-pin = <29>;
winc1500@0 {
status = "okay";
compatible = "atmel,winc1500";
reg = <0x0>;
label = "winc1500";
spi-max-frequency = <4000000>;
irq-gpios = <&gpio0 17 1>;
reset-gpios = <&gpio0 4 1>;
enable-gpios = <&gpio0 28 0>;
};
};
And here is the nrf52dk_nrf52832.conf we have placed in samples/net/wifi/boards CONFIG_GPIO=y CONFIG_SPI=y CONFIG_SPI_1=y CONFIG_LEGACY_TIMEOUT_API=y CONFIG_WIFI_WINC1500=y CONFIG_WIFI_WINC1500_REGION_NORTH_AMERICA=y Here is the command line used for building this sample for this setup - rajas-imac:zephyr rdsingh$ west build -p auto -b smtio_nrf52 samples/net/wifi -- -G"Eclipse CDT4 - Ninja" rajas-imac:zephyr rdsingh$ west flash When we tried to run samples/net/wifi with this setup here are our observations - - WINC1500 driver still uses Legacy timeout API and requires CONFIG_LEGACY_TIMEOUT_API=y Once we fixed this, the driver initializes WINC1500 and reads the MAC address from it successfully. After this step, if fails to set the Region, Power level etc and hence fails all commands from the shell. We are not sure if this is an issue with the WINC1500 driver or with the nrfx_SPI drivers. Would love get some insight from someone who already have worked on this driver, if possible. We can commit some of our resources to get this driver fully debugged and working with the following boards - - nRF52-DK as described here and SAMD21-XPRO with WINC1500-XPRO connected on EXT1. We would love to contribute to this driver in terms of making it work. I see that there is a on going pull request that addresses Legacy timeout API fix in drivers/wifi/winc1500/wifi_winc1500.c but it fixes only one occurance!! We look forward to guidance and help here. regards, RDS
|
||||||||||
|
||||||||||
Re: Need help in configuring ip address from telnet or ssh
#nrf52840
Jukka Rissanen
Hi, there is net_if_ipv4_addr_add() function that can be used to add an IPv4 address to the network interface at runtime. Cheers, Jukka
On Thu, 2020-06-18 at 01:44 -0700, giriprasad@... wrote: Hi Team,
|
||||||||||
|
||||||||||
Need help in configuring ip address from telnet or ssh
#nrf52840
giriprasad@...
Hi Team,
Following is my requirement, please go through and please suggest a possible method for me. I had PCA10056(NRF52840) board with me. It will be having a default IPV4 address when the device gets booted. My requirement is that the user should be able to set the ip_address of his preference to the board at run time. He can use telnet or ssh or any other protocol with an ethernet interface. Please suggest the possible solution for this requirement. Thanks & Regards, Giri Prasad N.
|
||||||||||
|
||||||||||
Re: how to provide own out of tree implementation/replacement of existing driver
Jan Pohanka
'imply' would probably be a good idea here.
toggle quoted messageShow quoted text
By then I will live with custom patches to the main tree, thanks for support. st 17. 6. 2020 v 18:45 odesílatel Bolivar, Marti <Marti.Bolivar@nordicsemi.no> napsal:
|
||||||||||
|
||||||||||
Re: Seeed BLE Micro (nrf51822) hangs on k_msleep
Matias N.
Thanks, I opened the issue. Don't know how to assign the issue to you, though.
On Wed, Jun 17, 2020, at 02:01, Chettimada, Vinayak Kariappa wrote:
|
||||||||||
|
||||||||||
Re: how to provide own out of tree implementation/replacement of existing driver
Bolivar, Marti
Maybe we can work towards removing the 'select' statements in those
toggle quoted messageShow quoted text
cases and using 'imply' instead? https://github.com/torvalds/linux/commit/237e3ad0f195d8fd34f1299e45f04793832a16fc "Cufi, Carles" <Carles.Cufi@nordicsemi.no> writes:
Hi Jan,
|
||||||||||
|
||||||||||
Re: how to provide own out of tree implementation/replacement of existing driver
Carles Cufi
Hi Jan,
toggle quoted messageShow quoted text
This has been done in the past in the following way: https://github.com/zephyrproject-rtos/zephyr/blob/master/drivers/entropy/Kconfig.nrf5#L7 It's not ideal, but it's the only current solution I am aware of. Regards, Carles
-----Original Message-----
|
||||||||||
|
||||||||||
Re: how to provide own out of tree implementation/replacement of existing driver
Jan Pohanka
Hello,
toggle quoted messageShow quoted text
yes, but I'm afraid that this would work only in simplest cases eg. when an in-tree driver is not selected as dependency etc... út 16. 6. 2020 v 23:07 odesílatel Bolivar, Marti <Marti.Bolivar@nordicsemi.no> napsal:
|
||||||||||
|
||||||||||
Re: Seeed BLE Micro (nrf51822) hangs on k_msleep
Chettimada, Vinayak Kariappa
Hi Matias,
Please create a github issue detailing the steps to reproduce, please mention the diff/changes of the upstream master samples you are using. Also upload the “.config” file of your build. You can assign it to me, for starters.’
That said, be stuck at sleep/WFI indicates stopped 32KHz clock due to missing/damaged external crystal and misconfigure LFCLOCK source.
Regards, Vinayak
From: users@... <users@...>
On Behalf Of Matias N. via lists.zephyrproject.org
Sent: 16 June 2020 23:29 To: Vinayak Kariappa <vinayak.kariappa@...> Cc: users@... Subject: Re: [Zephyr-users] Seeed BLE Micro (nrf51822) hangs on k_msleep
Hi, sorry for the delay. I just tried your suggestion and it does not seem to make a difference. As I mentioned, on debugging it seems to be halted at the WFI instruction. From my understanding, there should be an interrupt firing via the RTC but this is not happening and the MCU does not get out of the WFI (I placed a breakpoint at the rtc1_nfr_isr) and it never reaches there.
I also tried to simply modify the in-tree board definition for BLE nano, changing the LED gpio pin and setting the appropriate UART pins for my board and then flashing the blinky sample. I got the same result of the LED staying fixed.
Furthermore, the board came with nordic's UART/BLE demonstration firmware and this works (I can bind from my phone) so I would rule out defective hardware.
I can't really understand what could be happening. Any idea on what I should try?
Best, Matias
On Wed, Jun 10, 2020, at 21:42, Vinayak Kariappa wrote:
|
||||||||||
|
||||||||||
Re: Seeed BLE Micro (nrf51822) hangs on k_msleep
Matias N.
Hi, sorry for the delay. I just tried your suggestion and it does not seem to make a difference. As I mentioned, on debugging it seems to be halted at the WFI instruction. From my understanding, there should be an interrupt firing via the RTC but this is not happening and the MCU does not get out of the WFI (I placed a breakpoint at the rtc1_nfr_isr) and it never reaches there. I also tried to simply modify the in-tree board definition for BLE nano, changing the LED gpio pin and setting the appropriate UART pins for my board and then flashing the blinky sample. I got the same result of the LED staying fixed. Furthermore, the board came with nordic's UART/BLE demonstration firmware and this works (I can bind from my phone) so I would rule out defective hardware. I can't really understand what could be happening. Any idea on what I should try? Best, Matias
On Wed, Jun 10, 2020, at 21:42, Vinayak Kariappa wrote:
|
||||||||||
|
||||||||||
Re: Git submodules with West
#west
Bolivar, Marti
Hi,
toggle quoted messageShow quoted text
Right now, the only way to handle submodules with west is the way you're currently doing it. If you are interested in submitting a PR with support, I think it'd make sense to add. The only wrinkle is that west "clones" repositories by combining git init + fetch + checkout instead of actually running git clone. "mike via lists.zephyrproject.org" <mike=rokkresearch.com@lists.zephyrproject.org> writes:
Hi,
|
||||||||||
|
||||||||||
Re: how to provide own out of tree implementation/replacement of existing driver
Bolivar, Marti
Hi,
toggle quoted messageShow quoted text
You should be able to just disable the in-tree driver using Kconfig and use your own out of tree driver. "Jan Pohanka via lists.zephyrproject.org" <xhpohanka=gmail.com@lists.zephyrproject.org> writes:
Hello,
|
||||||||||
|
||||||||||
how to provide own out of tree implementation/replacement of existing driver
Jan Pohanka
Hello,
I would like to use my own implementation of an existing driver. Is there any way to do that? I have found an amend feature in https://github.com/zephyrproject-rtos/zephyr/pull/19980 but I cannot make it work. If I understand correctly it is intended more to add some functionality than completely replace. In my use-case it would be probably easier to use out of tree implementation for some time than maintain patches for the main tree. In fact I need just to add support for new soc from the stm32 family that is not yet in existing drivers (clock, watchdog, ethernet, etc). Later when our code is polished, I will prepare pull-requests. best regards Jan
|
||||||||||
|
||||||||||
API meeting: agenda
Carles Cufi
Hi all,
Today's topics: - device struct and constness - Issue https://github.com/zephyrproject-rtos/zephyr/issues/22941 - PR https://github.com/zephyrproject-rtos/zephyr/pull/26127 - Extend the sensor API with function for getting the value of a sensor attribute - Issue https://github.com/zephyrproject-rtos/zephyr/issues/26167 - PR https://github.com/zephyrproject-rtos/zephyr/pull/26166 Additional items in the "Triage" column in the GitHub project may be discussed if time permits. If you want an item included in the meeting, please add it to the GitHub project. Teams link: https://teams.microsoft.com/l/meetup-join/19%3ameeting_NWU2MjZlYWEtZDcwMi00MWQzLTgwMjEtNDdkYjQwMjBjMmFj%40thread.v2/0?context=%7b%22Tid%22%3a%22af0096d9-700c-411a-b795-b3dd7122bad2%22%2c%22Oid%22%3a%22841a7c92-7816-4faf-9887-5e334e88f6d8%22%7d https://github.com/zephyrproject-rtos/zephyr/wiki/Zephyr-Committee-and-Working-Group-Meetings#zephyr-api-discussion https://github.com/zephyrproject-rtos/zephyr/projects/18 https://docs.google.com/document/d/1lv-8B5QE2m4FjBcvfqAXFIgQfW5oz6306zJ7GIZIWCk/edit Regards, Carles
|
||||||||||
|
||||||||||
Git submodules with West
#west
mike@...
Hi,
I have a Zephyr project set up as a manifest repository, and I'm trying to include a git repository that makes use of submodules. i.e., I would normally clone this repository with: git clone --recursiveIs there a way to specify this from west.yml? I was able to manually add the sub-module by specifying a new project containing the sub-module in west.yml, and using the 'path' specifier to put it underneath the top level git repo. But, I'm wondering if there's a way to do this without having to manually add all of the sub-modules to west.yml. Thanks in advance.
|
||||||||||
|
||||||||||
Re: BLE "Just-Works" configuration
Jeremy Herbert
I ended up resolving this, it was to do with the previous bond information being stored. The following two configs fixed it: CONFIG_BT_KEYS_OVERWRITE_OLDEST=y CONFIG_BT_SMP_ALLOW_UNAUTH_OVERWRITE=y Note that this is an insecure configuration, CONFIG_BT_SMP_ALLOW_UNAUTH_OVERWRITE allows a possible forced deauth and reauth MITM attack. But for testing it works fine. Thanks, Jeremy
On Sat, 13 Jun 2020 at 12:34, Jeremy Herbert via lists.zephyrproject.org <jeremy.006=gmail.com@...> wrote:
|
||||||||||
|
||||||||||
BLE "Just-Works" configuration
Jeremy Herbert
Hi, I'm trying to set up Zephyr as a BLE peripheral with an nrf52810. I have the peripheral_hids example running fine, including bonding with the passkey being printed out over printk. However, my actual end device doesn't have any input/output other than a few buttons, so I'd like to change this to use "Just-Works" pairing so it can at least bond and have encrypted communication but not have MITM protection (ie BT_SECURITY_L2). I can't seem to find much documentation on implementing this scenario using Zephyr, so I was wondering if there is an example available on exactly what to do for this type of pairing/bonding where no input/output is available? I did give it a try myself based on this example, but I am a bit stuck. I have tried setting the bt_conn_auth_cb members all to NULL, as well as changing the GATT entry permissions to BT_GATT_PERM_READ_ENCRYPT instead of BT_GATT_PERM_READ_AUTHEN (I also did the same for the BT_GATT_PERM_WRITE_AUTHEN). When connecting and bonding with an android device (I'm using the nRF connect app), it asks to pair, but then on continuing with this it fails. In the debug log from the device I can see (I removed the MAC address): Security failed: XX:XX:XX:XX:XX:XX (public) level 1 err 4 Disconnected from XX:XX:XX:XX:XX:XX (public) (reason 0x13) where error code 4 is BT_SMP_ERR_CONFIRM_FAILED. I also tried setting a pairing_confirm callback in the bt_conn_auth_cb struct which just confirms the connection by calling bt_conn_auth_pairing_confirm(), but it doesn't appear to make a difference. Any pointers would be appreciated. Thanks, Jeremy
|
||||||||||
|