I think thats a kodi issue tbh - if i recall correctly - they call it the ZERO buffer issue where the buffer runs out without refilling after about 15 min or so...I had that too.
You can try to apply the following AdvancedSettings.xml file to Kodi and tweak it to taste and see if that helps.
Code:
<advancedsettings>
<cache>
<buffermode>2</buffermode>
<memorysize>454033408</memorysize>
<readfactor>4</readfactor>
</cache>
</advancedsettings>
the memorysize node is your device's available free ram divided by 3 ( in bytes ).
If you make memorysize a value of 0 (zero ) - you effectively cache ahead on disk, which works brilliantly, but it could reduce the lifespan of your disk if it is a SSD - so it's apparently not recommended.
You can read more about it here :
kodi.wiki