Skip to content

Commit

Permalink
feat(device) detect new brand hoco: HI10
Browse files Browse the repository at this point in the history
feat(device) detect brand Hotwav: Note 12 EF
feat(device) detect brand Nothing: Phone 2a Plus (A142P)
feat(device) detect brand AGM: H Max
feat(device) detect brand HMD: Skyline
feat(device) detect brand iTel: P65 (P671LN), Vista Tab 30 (P10003L)
feat(device) detect brand Doogee: S200 X, S200
feat(device) detect brand Blackview: Shark 9
feat(device) detect brand TOSCIDO: T181
  • Loading branch information
sanchezzzhak committed Dec 20, 2024
1 parent 490ceb8 commit db4d122
Show file tree
Hide file tree
Showing 5 changed files with 227 additions and 10 deletions.
1 change: 1 addition & 0 deletions Parser/Device/AbstractDeviceParser.php
Original file line number Diff line number Diff line change
Expand Up @@ -790,6 +790,7 @@ abstract class AbstractDeviceParser extends AbstractParser
'HMD' => 'HMD',
'8W' => 'HKPro',
'HOF' => 'HOFER',
'HOC' => 'hoco',
'H1' => 'Hoffmann',
'HOM' => 'Homatics',
'H0' => 'Hometech',
Expand Down
18 changes: 18 additions & 0 deletions Tests/fixtures/phablet-1.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5616,3 +5616,21 @@
model: Redmi Note 14 5G
os_family: Android
browser_family: Chrome
-
user_agent: Mozilla/5.0 (Linux; arm_64; Android 14; Note 12 EF) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/128.0.6613.33 YaBrowser/24.10.6.33.00 SA/3 Mobile Safari/537.36
os:
name: Android
version: "14"
platform: ARM
client:
type: browser
name: Yandex Browser
version: 24.10.6.33.00
engine: Blink
engine_version: 128.0.6613.33
device:
type: phablet
brand: Hotwav
model: Note 12 EF
os_family: Android
browser_family: Unknown
126 changes: 126 additions & 0 deletions Tests/fixtures/smartphone-41.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4406,3 +4406,129 @@
model: Honor X60 Pro
os_family: Android
browser_family: Chrome
-
user_agent: Mozilla/5.0 (Linux; Android 14; A142P Build/UP1A.231005.007) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/130.0.6723.107 Mobile Safari/537.36 OPX/2.6
os:
name: Android
version: "14"
platform: ""
client:
type: browser
name: Opera GX
version: "2.6"
engine: Blink
engine_version: 130.0.6723.107
device:
type: smartphone
brand: Nothing
model: Phone 2a Plus
os_family: Android
browser_family: Opera
-
user_agent: Mozilla/5.0 (Linux; arm_64; Android 14; AGM_H_MAX) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/128.0.6613.551 YaApp_Android/24.101.1 YaSearchBrowser/24.101.1 BroPP/1.0 SA/3 Mobile Safari/537.36
os:
name: Android
version: "14"
platform: ARM
client:
type: browser
name: Yandex Browser
version: 24.101.1
engine: Blink
engine_version: 128.0.6613.551
device:
type: smartphone
brand: AGM
model: H Max
os_family: Android
browser_family: Unknown
-
user_agent: Mozilla/5.0 (Linux; arm_64; Android 14; itel P671LN) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/130.0.6723.279 YaBrowser/24.12.0.279.00 SA/3 Mobile Safari/537.36
os:
name: Android
version: "14"
platform: ARM
client:
type: browser
name: Yandex Browser
version: 24.12.0.279.00
engine: Blink
engine_version: 130.0.6723.279
device:
type: smartphone
brand: iTel
model: P65
os_family: Android
browser_family: Unknown
-
user_agent: Mozilla/5.0 (Linux; arm_64; Android 14; HMD Skyline) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/130.0.6723.1804 YaApp_Android/24.120.1 YaSearchBrowser/24.120.1 BroPP/1.0 SA/3 Mobile Safari/537.36
os:
name: Android
version: "14"
platform: ARM
client:
type: browser
name: Yandex Browser
version: 24.120.1
engine: Blink
engine_version: 130.0.6723.1804
device:
type: smartphone
brand: HMD
model: Skyline
os_family: Android
browser_family: Unknown
-
user_agent: Mozilla/5.0 (Linux; arm_64; Android 14; S200 X) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/128.0.6613.67 YaSearchBrowser/24.106 BroPP/1.0 YaSearchApp/24.106 webOmni SA/3 Mobile Safari/537.36
os:
name: Android
version: "14"
platform: ARM
client:
type: browser
name: Yandex Browser
version: "24.106"
engine: Blink
engine_version: 128.0.6613.67
device:
type: smartphone
brand: Doogee
model: S200 X
os_family: Android
browser_family: Unknown
-
user_agent: Mozilla/5.0 (Linux; arm_64; Android 14; S200) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/128.0.6613.106 YaBrowser/24.10.4.106.00 SA/3 Mobile Safari/537.36
os:
name: Android
version: "14"
platform: ARM
client:
type: browser
name: Yandex Browser
version: 24.10.4.106.00
engine: Blink
engine_version: 128.0.6613.106
device:
type: smartphone
brand: Doogee
model: S200
os_family: Android
browser_family: Unknown
-
user_agent: Mozilla/5.0 (Linux; arm_64; Android 14; SHARK 9) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/130.0.6723.282 YaBrowser/24.12.0.282.00 SA/3 Mobile Safari/537.36
os:
name: Android
version: "14"
platform: ARM
client:
type: browser
name: Yandex Browser
version: 24.12.0.282.00
engine: Blink
engine_version: 130.0.6723.282
device:
type: smartphone
brand: Blackview
model: Shark 9
os_family: Android
browser_family: Unknown
54 changes: 54 additions & 0 deletions Tests/fixtures/tablet-12.yml
Original file line number Diff line number Diff line change
Expand Up @@ -1313,3 +1313,57 @@
model: WO12
os_family: Android
browser_family: Unknown
-
user_agent: Mozilla/5.0 (Linux; arm_64; Android 14.0; T181-EEA) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/130.0.6723.264 YaBrowser/24.12.0.264.01 (beta) Safari/537.36
os:
name: Android
version: "14.0"
platform: ARM
client:
type: browser
name: Yandex Browser
version: 24.12.0.264.01 beta
engine: Blink
engine_version: 130.0.6723.264
device:
type: tablet
brand: TOSCIDO
model: T181
os_family: Android
browser_family: Unknown
-
user_agent: Mozilla/5.0 (Linux; arm_64; Android 14; itel P10003L) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/128.0.6613.36 YaBrowser/24.10.6.36.01 Safari/537.36
os:
name: Android
version: "14"
platform: ARM
client:
type: browser
name: Yandex Browser
version: 24.10.6.36.01
engine: Blink
engine_version: 128.0.6613.36
device:
type: tablet
brand: iTel
model: Vista Tab 30
os_family: Android
browser_family: Unknown
-
user_agent: Mozilla/5.0 (Linux; arm_64; Android 14; hoco_HI10) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/128.0.6613.67 YaSearchBrowser/24.106/apad BroPP/1.0 YaSearchApp/24.106/apad webOmni SA/3 Mobile Safari/537.36
os:
name: Android
version: "14"
platform: ARM
client:
type: browser
name: Yandex Browser
version: "24.106"
engine: Blink
engine_version: 128.0.6613.67
device:
type: tablet
brand: hoco
model: HI10
os_family: Android
browser_family: Unknown
38 changes: 28 additions & 10 deletions regexes/device/mobiles.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2318,6 +2318,8 @@ AGM:
model: '$1'
- regex: 'AGM A9(?:[);/ ]|$)'
model: 'A9'
- regex: 'AGM_H_MAX'
model: 'H Max'
- regex: 'AGM_H3(?:[);/ ]|$)'
model: 'H3'
- regex: 'AGM_H5_PRO(?:[);/ ]|$)'
Expand Down Expand Up @@ -4226,7 +4228,7 @@ Bluegood:

# Blackview
Blackview:
regex: 'Blackview|(BL8[08]00|BV([24-9]000|8[18]00|[468]900|(5[1589]|9[135689])00|6[12368]00|7100)(?:[ _](?:PRO))?|(?<!Titan )P10000(?:[ _](?:PRO))?|omega[ _]pro|Alife[ _][PS]1|N6000|Heatwave|DM550|BV9700Pro|BL9000 Pro|(?<!Lenovo[_ ])A[68]0(?:Pro)?\))|(?:SOLID 4 G2|A[86]0Plus|A80S|BL(?:6000|8800)Pro|R6 Lite|P2Lite|A8 MAX|A30-RU|A20Pro|Android 10(?:[\d.]*);(?: [\w-]+;)? Tab[89]|Android 10(?:[\d.]*);(?: [\w-]+;)? (?:A80)|Android 11(?:[\d.]*);(?: [\w-]+;)? (?:A95|A100|BL5000|Tab 12)|Android 1[12](?:[\d.]*);(?: [\w-]+;)? (?:A[79]0|A70 Pro|A55 Pro|Tab 1[01356]|Tab 6)|Android 13(?:[\d.]*);(?: [\w-]+;)? (?:A200 Pro|Tab [86]0|Tab 18|BL9000)|BV500|BV4800|BV[579]200|SOLID_4G1|BV5300(?: Pro)?|Tab [56]0 Kids|Active 8 Pro|Active 8|SHARK 8|Tab 8E|Tab (?:7|[57]0|8|1[01]) WiFi|COLOR 8|Tab 1[236] Pro|MEGA 1|WAVE 6C|WAVE 8C?|HERO 10|A52 Pro| E7s)(?:[);/ ]|$)'
regex: 'Blackview|(BL8[08]00|BV([24-9]000|8[18]00|[468]900|(5[1589]|9[135689])00|6[12368]00|7100)(?:[ _](?:PRO))?|(?<!Titan )P10000(?:[ _](?:PRO))?|omega[ _]pro|Alife[ _][PS]1|N6000|Heatwave|DM550|BV9700Pro|BL9000 Pro|(?<!Lenovo[_ ])A[68]0(?:Pro)?\))|(?:SOLID 4 G2|A[86]0Plus|A80S|BL(?:6000|8800)Pro|R6 Lite|P2Lite|A8 MAX|A30-RU|A20Pro|Android 10(?:[\d.]*);(?: [\w-]+;)? Tab[89]|Android 10(?:[\d.]*);(?: [\w-]+;)? (?:A80)|Android 11(?:[\d.]*);(?: [\w-]+;)? (?:A95|A100|BL5000|Tab 12)|Android 1[12](?:[\d.]*);(?: [\w-]+;)? (?:A[79]0|A70 Pro|A55 Pro|Tab 1[01356]|Tab 6)|Android 13(?:[\d.]*);(?: [\w-]+;)? (?:A200 Pro|Tab [86]0|Tab 18|BL9000)|BV500|BV4800|BV[579]200|SOLID_4G1|BV5300(?: Pro)?|Tab [56]0 Kids|Active 8 Pro|Active 8|SHARK [89]|Tab 8E|Tab (?:7|[57]0|8|1[01]) WiFi|COLOR 8|Tab 1[236] Pro|MEGA 1|WAVE 6C|WAVE 8C?|HERO 10|A52 Pro| E7s)(?:[);/ ]|$)'
device: 'smartphone'
models:
- regex: 'A([2678]0|5[25]) ?Pro(?:[);/ ]|$)'
Expand Down Expand Up @@ -4257,8 +4259,8 @@ Blackview:
model: '$1'
- regex: 'COLOR 8'
model: 'Color 8'
- regex: 'SHARK 8'
model: 'Shark 8'
- regex: 'SHARK ([89])'
model: 'Shark $1'
- regex: 'WAVE 6C'
model: 'Wave 6C'
- regex: 'WAVE 8'
Expand Down Expand Up @@ -4407,7 +4409,7 @@ Boway:

# HMD (hmd.com)
HMD:
regex: 'HMD (?:Pulse (?:Pro|Plus)|Pulse|Fusion)(?:[);/ ]|$)'
regex: 'HMD (?:Pulse (?:Pro|Plus)|Pulse|Fusion|Skyline)(?:[);/ ]|$)'
device: 'smartphone'
models:
- regex: 'Pulse Plus'
Expand All @@ -4418,6 +4420,8 @@ HMD:
model: 'Pulse'
- regex: 'Fusion'
model: 'Fusion'
- regex: 'Skyline'
model: 'Skyline'

# Brondi (https://www.brondi.it/)
Brondi:
Expand Down Expand Up @@ -7623,7 +7627,7 @@ DoCoMo:

# Doogee
Doogee:
regex: 'DOOGEE[/ _-]|Valencia2_Y100(?:_?(?:pro|plus))?|Y100_Plus|X5max(?:[_ ]PRO)?|Shoot_[12]|x5_doogee|(KISSME|BIGBOY|COLLO[23]?|DAGGER|DISCOVERY2?|FIND|HOTWIND|LATTE|MAX|MINT|MOON|PIXELS|RAINBOX|TURBO|VALENCIA|VOYAGER2?|TITANS2?)[ -_](DG[0-9]+C?)(?:[);/ ]|$)|(?:BL12000|BL5500[_ ]Lite| Y6C|X9 Mini|LEO_DG280|Y9Plus|Y8 Plus|Hitman_DG850|S(?:4[01]|[568]8|9[05678]|59|61|8[69])Pro|X9[567]Pro|S[478]0Lite|S88Plus|BL[579]000|N[24]0Pro| S118|(?<!Lenovo )S90C|Ibiza_F2|S55_Lite|T5_Lite|S60 ?Lite|Iron-bone DG750|X10S|X[569]0L|MIX2|Y6 Max|Y6_Piano(?:_black)?|S100Pro|X[679]pro|V20Pro|S96GT|android 10(?:[\d.]*);(?: [\w-]+;)? (?:S59|S35|X95i?|X93|N30)|android 12(?:[\d.]*);(?: [\w-]+;)? (?:S98|S61|S89|V Max|S100|V30T?|S51)|V Max Plus|Y7Plus|S35T|V31GT|Smini|T[23]0Ultra|T10E|[TV]20S|V30Pro|android 14(?:[\d.]*);(?: [\w-]+;)? (?:N55)|android 13(?:[\d.]*);(?: [\w-]+;)? (?:R[12]0)|Android 9(?:[\d.]*);(?: [\w-]+;)? (?:N100|N20|Y8|S95)|S41T|N50S|D60 Pro|DK10|Turbo_mini_F1|Y100X|T30Pro|T10S|T10Plus|T20Mini|S41 Max|S41 Plus|N55 Pro|N55 Plus|S punk|S cyber|Blade10(?: Ultra|Pro)?|V Max Pro)(?:[);/ ]|$)'
regex: 'DOOGEE[/ _-]|Valencia2_Y100(?:_?(?:pro|plus))?|Y100_Plus|X5max(?:[_ ]PRO)?|Shoot_[12]|x5_doogee|(KISSME|BIGBOY|COLLO[23]?|DAGGER|DISCOVERY2?|FIND|HOTWIND|LATTE|MAX|MINT|MOON|PIXELS|RAINBOX|TURBO|VALENCIA|VOYAGER2?|TITANS2?)[ -_](DG[0-9]+C?)(?:[);/ ]|$)|(?:BL12000|BL5500[_ ]Lite| Y6C|X9 Mini|LEO_DG280|Y9Plus|Y8 Plus|Hitman_DG850|S(?:4[01]|[568]8|9[05678]|59|61|8[69])Pro|X9[567]Pro|S[478]0Lite|S88Plus|BL[579]000|N[24]0Pro| S118|(?<!Lenovo )S90C|Ibiza_F2|S55_Lite|T5_Lite|S60 ?Lite|Iron-bone DG750|X10S|X[569]0L|MIX2|Y6 Max|Y6_Piano(?:_black)?|S100Pro|X[679]pro|V20Pro|S96GT|android 10(?:[\d.]*);(?: [\w-]+;)? (?:S59|S35|X95i?|X93|N30)|android 12(?:[\d.]*);(?: [\w-]+;)? (?:S98|S61|S89|V Max|S100|V30T?|S51)|V Max Plus|Y7Plus|S35T|V31GT|Smini|T[23]0Ultra|T10E|[TV]20S|V30Pro|android 14(?:[\d.]*);(?: [\w-]+;)? (?:N55)|android 13(?:[\d.]*);(?: [\w-]+;)? (?:R[12]0)|Android 9(?:[\d.]*);(?: [\w-]+;)? (?:N100|N20|Y8|S95)|S41T|N50S|D60 Pro|DK10|Turbo_mini_F1|Y100X|T30Pro|T10S|T10Plus|T20Mini|S41 Max|S41 Plus|N55 Pro|N55 Plus|S punk|S cyber|Blade10(?: Ultra|Pro)?|V Max Pro|S200|S200 X)(?:[);/ ]|$)'
device: 'smartphone'
models:
- regex: 'T30Pro(?:[);/ ]|$)'
Expand Down Expand Up @@ -7680,7 +7684,7 @@ Doogee:
model: 'Leo $1'
- regex: 'Iron-bone (DG750)'
model: 'Iron Bone $1'
- regex: '(X95i?|BL[579]000|S90C|X10S|X[569]0L|X93|V30T?|V31GT|V20S|DK10)(?:[);/ ]|$)'
- regex: '(X95i?|BL[579]000|S90C|X10S|X[569]0L|X93|V30T?|V31GT|V20S|DK10|S200 X|S200)(?:[);/ ]|$)'
model: '$1'
- regex: 'X(9[567])Pro'
model: 'X$1 Pro'
Expand Down Expand Up @@ -13904,6 +13908,9 @@ iTel:
- regex: 'itel W7002'
device: 'tablet'
model: 'PrimeTab 1'
- regex: 'P10003L'
device: 'tablet'
model: 'Vista Tab 30'
- regex: 'itel it170([23])'
device: 'tablet'
model: 'iNote Prime $1'
Expand Down Expand Up @@ -33992,7 +33999,7 @@ Sunstech:

# Hotwav (www.hotwav.com)
Hotwav:
regex: '(?:Venus[_ ](?:X[12]|X1[0245679]|R8 PLUS|R[236-9]|R1[028]|X16-1)|Cosmos[ _](?:V8_lite|V19_Plus|V2[0-3]|U2?|V1[359]|V[45689]|V8-2)|Pearl K[123]|Magic Q8|Magic 5 Plus|Magic (?:[89]|1[13])|Hot[_ ]6|Symbol (?:M1|X|Max|R60|Pro|S4)|Symbol|Cyber (?:[78X]|1[35])|Cyber (?:9|13|X) Pro|Cosmos|W10 Pro|TAB R[57]|TAB R6 (?:Pro|Ultra)|T5 Pro| M5i|Hyper 7 Pro)(?:[);/ ]|$)|(?:Android 8(?:[\d.]*);(?: [\w-]+;)? M5 Plus|Android 12(?:[\d.]*);(?: [\w-]+;)? W10|Android 13(?:[\d.]*);(?: [\w-]+;)? (?:T7(?: Pro)?|T5 Max))(?: Build|[;)])'
regex: '(?:Venus[_ ](?:X[12]|X1[0245679]|R8 PLUS|R[236-9]|R1[028]|X16-1)|Cosmos[ _](?:V8_lite|V19_Plus|V2[0-3]|U2?|V1[359]|V[45689]|V8-2)|Pearl K[123]|Magic Q8|Magic 5 Plus|Magic (?:[89]|1[13])|Hot[_ ]6|Symbol (?:M1|X|Max|R60|Pro|S4)|Symbol|Note 12 EF|Cyber (?:[78X]|1[35])|Cyber (?:9|13|X) Pro|Cosmos|W10 Pro|TAB R[57]|TAB R6 (?:Pro|Ultra)|T5 Pro| M5i|Hyper 7 Pro)(?:[);/ ]|$)|(?:Android 8(?:[\d.]*);(?: [\w-]+;)? M5 Plus|Android 12(?:[\d.]*);(?: [\w-]+;)? W10|Android 13(?:[\d.]*);(?: [\w-]+;)? (?:T7(?: Pro)?|T5 Max))(?: Build|[;)])'
device: 'smartphone'
models:
# explicit smartphone models
Expand Down Expand Up @@ -34032,6 +34039,9 @@ Hotwav:
- regex: 'Symbol R60'
device: 'phablet'
model: 'Symbol R60'
- regex: 'Note 12 EF'
device: 'phablet'
model: 'Note 12 EF'
# explicit tablet models
- regex: 'TAB R6 Pro'
device: 'tablet'
Expand Down Expand Up @@ -38797,10 +38807,10 @@ Ookee:

# TOSCIDO (www.toscido.com)
TOSCIDO:
regex: '(?:(?:T1[235]|T151|T2[1268]|P101)-EEA|W-?109)(?:[);/ ]|$)'
regex: '(?:(?:T1[235]|T151|T2[1268]|T181|P101)-EEA|W-?109)(?:[);/ ]|$)'
device: 'tablet'
models:
- regex: '(T1[235]|T151|T2[1268]|P101)-EEA(?:[);/ ]|$)'
- regex: '(T1[235]|T151|T2[1268]|P101|T181)-EEA(?:[);/ ]|$)'
model: '$1'
- regex: 'W-?109(?:[);/ ]|$)'
model: 'W109'
Expand Down Expand Up @@ -40115,13 +40125,15 @@ CMF:

# Nothing (https://nothing.tech/)
Nothing:
regex: '(?:A06[35]|AIN065|A142|Phone \(2a\))(?:[);/ ]|$)'
regex: '(?:A06[35]|AIN065|A142P?|Phone \(2a\))(?:[);/ ]|$)'
device: 'smartphone'
models:
- regex: 'A063|A015'
model: 'Phone 1'
- regex: 'A(?:IN)?065'
model: 'Phone 2'
- regex: 'A142P'
model: 'Phone 2a Plus'
- regex: 'A142|Phone \(2a\)'
model: 'Phone 2a'

Expand Down Expand Up @@ -43218,6 +43230,12 @@ LUO:
device: 'tv'
model: '$1'

# hoco
hoco:
regex: 'hoco[_ -]?([^;/)]+)( Build|[;)])'
device: 'tablet'
model: '$1'

# Devices with undectable brand, but detectable model
Unknown:
regex: 'Plasma Mobile|WebTV/(\d+\.\d+)|TV Bro| BOX|BOX | BOX |roku|YouView|DirectFB|avdn/|wired|wireless|AndroidTV|cordova-amazon-fireos|wv-atv|SDSTB|SDOTT|(?:M10 Ultra|FO-R15|TVBOX|Smart[ _-]?TV|SmartATV|M8S\+ 4K|PCBox|rk(?:3128|322x|3368)(?:[_-]box)?|H10 PLAY|Smart AIO TV|TVBOX_L|L-BOX|TVBOX-5G|mips.+(?:Opera TV|wireless|wired)|smartbox|TV BOX|BOX TV|I12Pro Max|(?:audi_)?ks1280x480|AT&T TV|RealtekATV|AOSP on r33a0|tv001 on rtd289x|hx322x_box|X98_S500|8K3528-T|MX10|V88|H8S|X92|AI PONT|tv\.plus|WayDroid x86_64 Device|MediaBox|Cloud Phone|HK1RBOX-X4)(?:[);/ ]|$)'
Expand Down

0 comments on commit db4d122

Please sign in to comment.