Hi all,
I am trying to avoid closing and opening my serial port every time I want to flash the board. My goal is to have another UART output going to an FTDI breakout board and then into another USB port on my computer.

In the schematic of the nRF9160, it looks like there is another UART available on pins 23 and 24.
I have changed the overlay to include these two pins. Is this correct?

`/ {
aliases {
bootloader-led0 = &blue_led;
};
};

// Full speed ahead
&uart0 {
status = “okay”;
current-speed = <1000000>;
tx-pin = <6>;
rx-pin = <5>;
};

&uart1 {
status = “okay”;
current-speed = <115200>;
tx-pin = <24>;
rx-pin = <23>;
};
`
How would I redirect the printk outputs to this uart instead of the Silicon Labs USB to UART on the board?

    cchoi22915 it’s already defined. 🙂

    If you open circuitdojo_feather_nrf9160_common.dts you’ll see all the defaults. You can either use the command menu (CTRL + SHIFT +P) or open it manually zephyr/boards/arm/circuitdojo_feather_nrf9160/circuitdojo_feather_nrf9160_common.dts

    Second answer relates to the chosen keyword in your overlay.

    The default is:

    	chosen {
    		zephyr,console = &uart0;
    		zephyr,shell-uart = &uart0;
    		zephyr,uart-mcumgr = &uart0;
    	};

    You can change the console and shell to uart1 in your overlay.

    	chosen {
    		zephyr,console = &uart1;
    		zephyr,shell-uart = &uart1;
    		zephyr,uart-mcumgr = &uart0;
    	};

    I did a quick thing on the chosen keyword this past week: https://www.youtube.com/watch?v=uAG5EVSWGKs

      Okay thanks jaredwolff , I’ll watch the video! After looking at the .dts, it appears I actually need to utilize &uart2 as it utilizes pins 24 and 23.

      Terms and Conditions | Privacy Policy