File tree Expand file tree Collapse file tree
htdocs/luci-static/resources/view/modem Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ LUCI_DESCRIPTION:=LuCI JS interface to define the available modems. The list of
1212MAINTAINER: =Rafał Wabik <4Rafal@gmail.com>
1313LUCI_DEPENDS: =
1414LUCI_PKGARCH: =all
15- PKG_VERSION: =1.0.4-20230711
15+ PKG_VERSION: =1.0.5-20231008
1616
1717define Package/luci-app-modemdefine/conffiles
1818/etc/config/modemdefine
Original file line number Diff line number Diff line change @@ -54,12 +54,20 @@ return view.extend({
5454 let product = '' ;
5555 let serialnumber = '' ;
5656 let driver = '' ;
57+ let bus = '' ;
5758
5859 for ( const line of lines ) {
5960 if ( line . includes ( 'Driver=hub' ) || line . includes ( 'Driver=usb-storage' ) || line . includes ( 'Driver=usblp' ) ) {
6061 driver = line . split ( 'Driver=' ) [ 1 ] . trim ( ) ;
6162 break ;
6263 }
64+
65+ if ( line . includes ( 'Spd=' ) ) {
66+ const match = line . match ( / S p d = ( [ ^ ] + ) / ) ;
67+ if ( match && match [ 1 ] ) {
68+ bus = match [ 1 ] . trim ( ) ;
69+ }
70+ }
6371
6472 if ( line . includes ( 'Vendor=' ) ) {
6573 const match = line . match ( / V e n d o r = ( [ ^ ] + ) / ) ;
@@ -103,7 +111,8 @@ return view.extend({
103111 Product : product ,
104112 Vendor : vendor ,
105113 ProdID : pid ,
106- SerialNumber : serialnumber
114+ Bus_speed : bus ,
115+ Serial_Number : serialnumber
107116 } ;
108117 results . push ( result ) ;
109118 }
You can’t perform that action at this time.
0 commit comments