Re: Issue in OTA of zephyr OS over UART on Nordic nrf52840_pca10056 chip #ble #bluetoothmesh #nrf52840 #uart

Adam Podogrocki

Hi Mayank,

If you are using UART as a connection type, then please disable other communication channels like BT and shell - at least in my case with STM32 it helped.

I assume that flash partition layout corresponds to what you've wrote: "I have flashed MCUBOOT (0x0 to 0x8000) and smp_svr (0xC000 to 0x27000)." 
I assume that you have signed the 'smp_svr' binary.

On Wed, 6 Nov 2019 at 07:36, Mayank Patel <mayank7117@...> wrote:
Hi Adam,

Thanks for the quick reply.
I have flashed MCUBOOT (0x0 to 0x8000) and smp_svr (0xC000 to 0x27000).
The flag CONFIG_UART_MCUMGR_ON_DEV_NAME is defaults to 'UART_0'.

My DTS file has following configuration right now.
        chosen {
                zephyr,console = &uart0;
                zephyr,shell-uart = &uart0;
                zephyr,uart-mcumgr = &uart0;
                zephyr,bt-mon-uart = &uart0;
                zephyr,sram = &sram0;
                zephyr,flash = &flash0;
                zephyr,code-partition = &slot0_partition;

&uart0 {
        compatible = "nordic,nrf-uart";
        current-speed = <115200>;
        status = "ok";
        //For i.MX DCE configuration
        tx-pin = <8>;
        rx-pin = <4>;
        rts-pin = <26>;
        cts-pin = <6>;

Command used from imx6ul board running on yocto linux:
sudo mcumgr --conntype serial --connstring='dev=/dev/ttymxc0,baud=115200' echo hello

So, am i missing some configuration or do you see any other issue?

Mayank Patel
(M.Tech VLSI & Embedded system)
Ganpat University

On Tue, Nov 5, 2019 at 8:43 PM Adam Podogrocki <a.podogrocki@...> wrote:
Hi Mayank,

If you are sure the partition layout of flash memory is correct and you flashed MCUboot and SMP_SVR sample respectively, then please check if the CONFIG_UART_MCUMGR_ON_DEV_NAME is set correctly.


On Tue, 5 Nov 2019 at 15:15, Mayank <mayank7117@...> wrote:

I have nrf52840 on my custom board (Based on IMX6, Running Yocto linux) which is connected over UART.
I want to do an OTA of zephyr OS on that chip over serial/ble and for that i had already tried following things.
1) I have build smp_svr and flashed it to nrf52840 so that i can use 'mcumgr' command line tool for the flashing.
Referred to know how to use 'mcumgr'.

Now, when i use mcumgr to communicate 'hello' message over serial/UART, It shows error of connection timed out. (Also tried with -t switch, but no luck).
Command used are :
sudo mcumgr --conntype serial --connstring='dev=/dev/ttymxc0,baud=115200' echo hello
--> So it's not able to open the connection using mcumgr and not getting any reply (Getting timeout).

Join to automatically receive all group messages.