I wonder if this is some interaction between the USB console and NxTerm?  Both are rather special cases.  Have you tried NxTerm with a serial console.  There are quite a few examples that worked in the past:

$ find boards -name defconfig | xargs grep CONFIG_NXTERM=y
boards/arm/lpc17xx_40xx/open1788/configs/knxterm/defconfig:CONFIG_NXTERM=y
boards/arm/lpc54xx/lpcxpresso-lpc54628/configs/nxwm/defconfig:CONFIG_NXTERM=y
boards/arm/lpc54xx/lpcxpresso-lpc54628/configs/twm4nx1/defconfig:CONFIG_NXTERM=y
boards/arm/lpc54xx/lpcxpresso-lpc54628/configs/twm4nx2/defconfig:CONFIG_NXTERM=y
boards/arm/sam34/sam3u-ek/configs/nxwm/defconfig:CONFIG_NXTERM=y
boards/arm/sam34/sam4e-ek/configs/nxwm/defconfig:CONFIG_NXTERM=y
boards/arm/sama5/sama5d3x-ek/configs/nxwm/defconfig:CONFIG_NXTERM=y
boards/arm/sama5/sama5d4-ek/configs/nxwm/defconfig:CONFIG_NXTERM=y
boards/arm/samv7/same70-xplained/configs/twm4nx/defconfig:CONFIG_NXTERM=y
boards/arm/samv7/samv71-xult/configs/nxwm/defconfig:CONFIG_NXTERM=y
boards/arm/samv7/samv71-xult/configs/vnxwm/defconfig:CONFIG_NXTERM=y
boards/arm/stm32/mikroe-stm32f4/configs/fulldemo/defconfig:CONFIG_NXTERM=y
boards/arm/stm32/shenzhou/configs/nxwm/defconfig:CONFIG_NXTERM=y
boards/arm/stm32/stm3210e-eval/configs/nxterm/defconfig:CONFIG_NXTERM=y
boards/arm/stm32/stm3220g-eval/configs/nxwm/defconfig:CONFIG_NXTERM=y
boards/arm/stm32/stm3240g-eval/configs/nxterm/defconfig:CONFIG_NXTERM=y
boards/arm/stm32/stm3240g-eval/configs/nxwm/defconfig:CONFIG_NXTERM=y
boards/arm/stm32/stm32f429i-disco/configs/nxwm/defconfig:CONFIG_NXTERM=y
boards/arm/stm32f7/stm32f746g-disco/configs/nxterm/defconfig:CONFIG_NXTERM=y
boards/sim/sim/sim/configs/nxwm/defconfig:CONFIG_NXTERM=y

But there is no working example that uses both NxTERM with a USB console:

$ find boards -name defconfig | xargs grep -l CONFIG_NXTERM=y | xargs grep CONFIG_NSH_USBCONSOLE=y

On 9/27/2022 4:26 AM, Jernej Turnsek wrote:
Hi,

I have enabled nxterm functionality on my board with a 400x240 display and
I am using an USB console. When starting nxterm example in nsh, I am seeing
the nxterm booting and setting the display, but when it should redirect
stdout to nxterm, it doesn't. I am still in USB console. Looking the code I
see that nsh_consolemain function is called from nsh_usbconsole.c, because
of USB console set in KConfig. Later it is calling nsh_configstdio which
duplicates stdio again and I think this is the reason for nxterm stdout not
working. How can I get around this problem?

Thanks,
Jernej


Reply via email to