Hi,
To convert default usb otg in i.MX8mn to normal usb host only on the board, I have done below changes,
$pwd
/home/sandeepraj/imx-yocto-bsp1/build-wayland/tmp/work-shared/imx8mnevk/kernel-source/arch/arm64/boot/dts/freescale
$vim imx8mn-ddr4-evk.dts
&usbotg1 {
picophy,pre-emp-curr-control = <3>;
picophy,dc-vol-level-adjust = <7>;
// dr_mode = "otg";
dr_mode = "host";
hnp-disable;
srp-disable;
adp-disable;
// usb-role-switch;
status = "okay";
/*
port {
usb1_drd_sw: endpoint {
remote-endpoint = <&typec1_dr_sw>;
};
};
*/
};
/*
ptn5110_1: tcpc@50 {
compatible = "nxp,ptn5110";
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_typec1>;
reg = <0x50>;
interrupt-parent = <&gpio2>;
interrupts = <11 8>;
status = "okay";
port {
typec1_dr_sw: endpoint {
remote-endpoint = <&usb1_drd_sw>;
};
};
typec1_con: connector {
compatible = "usb-c-connector";
label = "USB-C";
power-role = "dual";
data-role = "dual";
try-power-role = "sink";
source-pdos = <PDO_FIXED(5000, 3000, PDO_FIXED_USB_COMM)>;
sink-pdos = <PDO_FIXED(5000, 3000, PDO_FIXED_USB_COMM)
PDO_VAR(5000, 20000, 3000)>;
op-sink-microwatt = <15000000>;
self-powered;
};
};
*/
disable other serial drivers in usb support related serial or other to work.
In my case default serial driver did not work, so I enabled the required one.
After doing all these changes along with serial baudrate configuration from my application,
I could read my sensor data through the usb serial interface that is /dev/ttyUSB0.
Thank you NXP for the support over email communication.