# Otg issue in R17, host mode does not work

**URL:** <https://forum.legato.io/t/otg-issue-in-r17-host-mode-does-not-work/6589>\
**Category:** Uncategorized\
**Created:** [September 14, 2023, 9:15am UTC](https://forum.legato.io/t/otg-issue-in-r17-host-mode-does-not-work/6589 "2023-09-14T09:15:14Z")\
**Posts on this page:** 12\
**Page:** 1

<div class="post-metadata">

**Author:** ![MVAJGER](https://avatars.discourse-cdn.com/v4/letter/m/e0b2c6/32.png) [@MVAJGER](https://forum.legato.io/u/MVAJGER)\
**Post date:** [September 14, 2023, 9:15am UTC](https://forum.legato.io/t/otg-issue-in-r17-host-mode-does-not-work/6589/1 "2023-09-14T09:15:14Z")

</div>

Hi,

I have a few questions regarding OTG. I found an article on the forum stating that it doesn’t work with custom hardware

> **[R17, no eth0 in custom board](https://forum.sierrawireless.com/t/r17-no-eth0-in-custom-board/30210)**
>
> After upgrading my WP7607 module to R17, it boots normally in mangOH-Green, but when I put it in a custom board (R16.3 used to function with no issue) eth0 is not present, (ifconfig doesn’t list eth0). It seems like an issue with low power mode...

> **[OTG doesn't work as expected on Release 17](https://forum.sierrawireless.com/t/otg-doesnt-work-as-expected-on-release-17/30332/6)**
>
> No we’re using the USB+/- lines directly connected to the WP7607 module. the USB host connector works fine on both boards with R17.

We are facing the same issue here; we don’t have eth, and we also use LAN95XX. Is there any information available about this problem? Is there a solution for it, or will it be fixed at all? This is currently holding our project back.

Thank you for your responses!

---

<div class="post-metadata">

**Author:** ![jyijyi](https://sea1.discourse-cdn.com/flex019/user_avatar/forum.legato.io/jyijyi/32/822_2.png) [@jyijyi](https://forum.legato.io/u/jyijyi)\
**Post date:** [September 14, 2023, 9:33am UTC](https://forum.legato.io/t/otg-issue-in-r17-host-mode-does-not-work/6589/2 "2023-09-14T09:33:13Z")

</div>

this is regression on R17  
Even for USB thumb drive, it would not work with the USB OTG.  
As workaround, you might need to use R16 or route to USB host connector which is using HSIC bus.

---

<div class="post-metadata">

**Author:** ![MVAJGER](https://avatars.discourse-cdn.com/v4/letter/m/e0b2c6/32.png) [@MVAJGER](https://forum.legato.io/u/MVAJGER)\
**Post date:** [September 14, 2023, 9:40am UTC](https://forum.legato.io/t/otg-issue-in-r17-host-mode-does-not-work/6589/3 "2023-09-14T09:40:41Z")

</div>

We definitely need the 4.x kernel! We don’t have the option for an HSIC solution. Is there a way to configure the OTG USB to operate exclusively as a host?

---

<div class="post-metadata">

**Author:** ![jyijyi](https://sea1.discourse-cdn.com/flex019/user_avatar/forum.legato.io/jyijyi/32/822_2.png) [@jyijyi](https://forum.legato.io/u/jyijyi)\
**Post date:** [September 14, 2023, 10:04am UTC](https://forum.legato.io/t/otg-issue-in-r17-host-mode-does-not-work/6589/4 "2023-09-14T10:04:03Z")

</div>

Isn’t USB OTG always a host?  
currently i cannot find any workaround to use USB OTG on R17

---

<div class="post-metadata">

**Author:** ![jyijyi](https://sea1.discourse-cdn.com/flex019/user_avatar/forum.legato.io/jyijyi/32/822_2.png) [@jyijyi](https://forum.legato.io/u/jyijyi)\
**Post date:** [October 3, 2023, 7:59am UTC](https://forum.legato.io/t/otg-issue-in-r17-host-mode-does-not-work/6589/5 "2023-10-03T07:59:54Z")

</div>

We have test build of R17 which is for fixing USB OTG.  
I have tested with USB thumb drive, it is OK to read it:

> **[MOLWP9X07-1373\_testbuild\_yocto\_wp76xx.4k.cwe](https://drive.google.com/file/d/1cse9Kpy9LS7LovUqzL8XsZ0jAMjpacHp/view?usp=sharing)**
>
> Google Drive file.

---

<div class="post-metadata">

**Author:** ![MVAJGER](https://avatars.discourse-cdn.com/v4/letter/m/e0b2c6/32.png) [@MVAJGER](https://forum.legato.io/u/MVAJGER)\
**Post date:** [October 3, 2023, 8:11am UTC](https://forum.legato.io/t/otg-issue-in-r17-host-mode-does-not-work/6589/6 "2023-10-03T08:11:37Z")

</div>

Hello,

Could you please provide me with a patch or a diff for the changes you made to enable OTG functionality? We are working on a custom build and would like to test it with these changes. Thank you in advance.

Best regards,

---

<div class="post-metadata">

**Author:** ![jyijyi](https://sea1.discourse-cdn.com/flex019/user_avatar/forum.legato.io/jyijyi/32/822_2.png) [@jyijyi](https://forum.legato.io/u/jyijyi)\
**Post date:** [October 3, 2023, 8:17am UTC](https://forum.legato.io/t/otg-issue-in-r17-host-mode-does-not-work/6589/7 "2023-10-03T08:17:23Z")

</div>

we are still testing the patch, we will attach the patch here later

In parallel, please test this yocto image at your side

---

<div class="post-metadata">

**Author:** ![MVAJGER](https://avatars.discourse-cdn.com/v4/letter/m/e0b2c6/32.png) [@MVAJGER](https://forum.legato.io/u/MVAJGER)\
**Post date:** [October 3, 2023, 8:24am UTC](https://forum.legato.io/t/otg-issue-in-r17-host-mode-does-not-work/6589/8 "2023-10-03T08:24:52Z")

</div>

We would be glad to test it, provided that we have a clear understanding of the modifications made in the “swi” package. Unfortunately, the project is currently stalled due to this, and we would like to proceed once it’s resolved.

---

<div class="post-metadata">

**Author:** ![MVAJGER](https://avatars.discourse-cdn.com/v4/letter/m/e0b2c6/32.png) [@MVAJGER](https://forum.legato.io/u/MVAJGER)\
**Post date:** [October 3, 2023, 9:15am UTC](https://forum.legato.io/t/otg-issue-in-r17-host-mode-does-not-work/6589/9 "2023-10-03T09:15:38Z")

</div>

I have tested the image you provided on our custom device, OTG is functioning, and the Ethernet interface is up and running. I look forward to further information. Thank you!

---

<div class="post-metadata">

**Author:** ![jyijyi](https://sea1.discourse-cdn.com/flex019/user_avatar/forum.legato.io/jyijyi/32/822_2.png) [@jyijyi](https://forum.legato.io/u/jyijyi)\
**Post date:** [October 3, 2023, 9:55am UTC](https://forum.legato.io/t/otg-issue-in-r17-host-mode-does-not-work/6589/10 "2023-10-03T09:55:50Z")

</div>

see if this patch works for you to apply to yocto source of R17:  
[usb\_otg\_fix.patch.txt](https://forum.legato.io/uploads/short-url/es5ifwDRtW9oOhupwoeez7FiBxQ.txt) (1.1 KB)

---

<div class="post-metadata">

**Author:** ![MVAJGER](https://avatars.discourse-cdn.com/v4/letter/m/e0b2c6/32.png) [@MVAJGER](https://forum.legato.io/u/MVAJGER)\
**Post date:** [October 3, 2023, 10:06am UTC](https://forum.legato.io/t/otg-issue-in-r17-host-mode-does-not-work/6589/11 "2023-10-03T10:06:27Z")

</div>

Thank you for providing the changes! I will report the information after testing.

---

<div class="post-metadata">

**Author:** ![MVAJGER](https://avatars.discourse-cdn.com/v4/letter/m/e0b2c6/32.png) [@MVAJGER](https://forum.legato.io/u/MVAJGER)\
**Post date:** [October 3, 2023, 12:50pm UTC](https://forum.legato.io/t/otg-issue-in-r17-host-mode-does-not-work/6589/12 "2023-10-03T12:50:09Z")

</div>

Based on the results of the first round of tests, it works on our custom build. I’ll mark the comment as a solution if we find anything, I’ll inform you. Thanks for the patch!
