iobroker.mg-saic 0.1.2 → 0.1.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -25,14 +25,16 @@ For manufacturer information, see [MG Motor](https://www.mgmotor.eu/) and [SAIC
25
25
  1. Install the adapter and create an instance in ioBroker Admin.
26
26
  2. Select the account region and login type (email or phone number).
27
27
  3. Enter the account's email address or phone number and password. For phone login, also enter the phone country calling code.
28
- 4. Set the status polling interval >60 seconds. The default is 1800 seconds.
28
+ 4. Set the status polling interval to 60 seconds or more. The default is 1800 seconds.
29
29
  5. Save the settings and start the instance. Vehicles available to the account appear under `vehicles.<VIN>`.
30
+ Existing vehicle object IDs are reused if the cloud API changes the VIN casing. Device labels use the localized generic vehicle name; the VIN, brand, model, and other available vehicle metadata are provided as read-only states.
30
31
 
31
32
  ## Features
32
33
 
33
34
  - Connects ioBroker to the iSmart cloud service and retrieves vehicle status.
34
35
  - Provides remote controls for supported vehicle functions.
35
36
  - Supports climate, heating, and charging features where available for the vehicle.
37
+ - Omits unrecognized free-form charging text while retaining numeric measurements and validated charging-point identifiers.
36
38
 
37
39
  ## Installation
38
40
 
@@ -43,6 +45,14 @@ The adapter is published on npm and available from ioBroker's Latest adapter rep
43
45
  [![Donate](https://camo.githubusercontent.com/ef8c60305542390406855547e32850909812a73c4abada236de22a6dc88b313f/68747470733a2f2f7777772e70617970616c6f626a656374732e636f6d2f64655f44452f44452f692f62746e2f62746e5f646f6e61746543435f4c472e676966)](https://www.paypal.com/donate/?hosted_button_id=3RJQGSJNRSHUJ)
44
46
 
45
47
  ## Changelog
48
+ ### 0.1.4 (2026-11-11)
49
+
50
+ - (Voodoo2man) Corrected command-response validation, status values, charging-field handling, vehicle ID reuse, and cloud polling intervals; removed the non-informative vehicle name state.
51
+
52
+ ### 0.1.3 (2026-11-08)
53
+
54
+ - (Voodoo2man) Retry startup initialization after temporary cloud login and vehicle-list outages with bounded backoff, prevent false setting writes from triggering remote setting actions, and add the missing region labels in the Admin UI.
55
+
46
56
  ### 0.1.2 (2026-11-08)
47
57
 
48
58
  - (Voodoo2man) Prevented unsafe or case-colliding API fields and vehicle IDs from creating duplicate datapoints, kept status IDs stable across field-casing changes, scheduled polling after each completed cycle while honoring queued manual refreshes, and removed an unused cloud-backend translation.
@@ -60,19 +70,6 @@ The adapter is published on npm and available from ioBroker's Latest adapter rep
60
70
  - (Voodoo2man) Applied confirmed profile-specific charging conversions.
61
71
  - (Voodoo2man) Calculated available battery energy from battery level and usable capacity.
62
72
 
63
- ### 0.0.4 (2026-10-24)
64
-
65
- - (Voodoo2man) Corrected GPS coordinates.
66
- - (Voodoo2man) Fixed incorrect datapoint values.
67
- - (Voodoo2man) Removed duplicate and irrelevant datapoints.
68
- - (Voodoo2man) Set min version of admin to 8.2.0, js-controller 7.2.2, node.js 24
69
-
70
- ### 0.0.3 (2026-10-21)
71
-
72
- - (Voodoo2man) Improved release automation, updated Node.js release checks, and removed unpublished version metadata.
73
- - (Voodoo2man) Added charging data
74
- - (Voodoo2man) Fixed vehicle datapoint units and roles
75
-
76
73
  Older changelog entries are available in [CHANGELOG_OLD.md](CHANGELOG_OLD.md).
77
74
 
78
75
  ## License
@@ -6,6 +6,12 @@
6
6
  "To avoid possible session interference with the mobile app, use a separate iSmart account for ioBroker where possible. Share the vehicle with that account and grant the permissions needed for your intended use.": "Um mögliche Konflikte mit der mobilen App zu vermeiden, verwenden Sie nach Möglichkeit ein separates iSmart-Konto für ioBroker. Teilen Sie das Fahrzeug mit diesem Konto und erteilen Sie die für die gewünschte Nutzung erforderlichen Berechtigungen.",
7
7
  "Region": "Region",
8
8
  "European Union": "Europäische Union",
9
+ "China": "China",
10
+ "Australia": "Australien",
11
+ "Brazil": "Brasilien",
12
+ "Israel": "Israel",
13
+ "Turkey": "Türkei",
14
+ "Thailand": "Thailand",
9
15
  "Rest of World": "Rest der Welt",
10
16
  "Login type": "Anmeldetyp",
11
17
  "Email": "E-Mail",
@@ -6,6 +6,12 @@
6
6
  "To avoid possible session interference with the mobile app, use a separate iSmart account for ioBroker where possible. Share the vehicle with that account and grant the permissions needed for your intended use.": "To avoid possible session interference with the mobile app, use a separate iSmart account for ioBroker where possible. Share the vehicle with that account and grant the permissions needed for your intended use.",
7
7
  "Region": "Region",
8
8
  "European Union": "European Union",
9
+ "China": "China",
10
+ "Australia": "Australia",
11
+ "Brazil": "Brazil",
12
+ "Israel": "Israel",
13
+ "Turkey": "Turkey",
14
+ "Thailand": "Thailand",
9
15
  "Rest of World": "Rest of World",
10
16
  "Login type": "Login type",
11
17
  "Email": "Email",
@@ -6,6 +6,12 @@
6
6
  "To avoid possible session interference with the mobile app, use a separate iSmart account for ioBroker where possible. Share the vehicle with that account and grant the permissions needed for your intended use.": "Para evitar posibles interferencias de sesión con la aplicación móvil, utiliza una cuenta iSmart independiente para ioBroker siempre que sea posible. Comparte el vehículo con esa cuenta y concede los permisos necesarios para el uso previsto.",
7
7
  "Region": "Región",
8
8
  "European Union": "Unión Europea",
9
+ "China": "China",
10
+ "Australia": "Australia",
11
+ "Brazil": "Brasil",
12
+ "Israel": "Israel",
13
+ "Turkey": "Turquía",
14
+ "Thailand": "Tailandia",
9
15
  "Rest of World": "Resto del mundo",
10
16
  "Login type": "Tipo de inicio de sesión",
11
17
  "Email": "Correo electrónico",
@@ -6,6 +6,12 @@
6
6
  "To avoid possible session interference with the mobile app, use a separate iSmart account for ioBroker where possible. Share the vehicle with that account and grant the permissions needed for your intended use.": "Pour éviter toute interférence de session avec l'application mobile, utilisez si possible un compte iSmart distinct pour ioBroker. Partagez le véhicule avec ce compte et accordez les autorisations nécessaires à l'utilisation souhaitée.",
7
7
  "Region": "Région",
8
8
  "European Union": "Union européenne",
9
+ "China": "Chine",
10
+ "Australia": "Australie",
11
+ "Brazil": "Brésil",
12
+ "Israel": "Israël",
13
+ "Turkey": "Turquie",
14
+ "Thailand": "Thaïlande",
9
15
  "Rest of World": "Reste du monde",
10
16
  "Login type": "Type de connexion",
11
17
  "Email": "E-mail",
@@ -6,6 +6,12 @@
6
6
  "To avoid possible session interference with the mobile app, use a separate iSmart account for ioBroker where possible. Share the vehicle with that account and grant the permissions needed for your intended use.": "Per evitare possibili interferenze di sessione con l'app mobile, utilizza, se possibile, un account iSmart separato per ioBroker. Condividi il veicolo con quell'account e concedi le autorizzazioni necessarie per l'uso previsto.",
7
7
  "Region": "Regione",
8
8
  "European Union": "Unione europea",
9
+ "China": "Cina",
10
+ "Australia": "Australia",
11
+ "Brazil": "Brasile",
12
+ "Israel": "Israele",
13
+ "Turkey": "Turchia",
14
+ "Thailand": "Thailandia",
9
15
  "Rest of World": "Resto del mondo",
10
16
  "Login type": "Tipo di accesso",
11
17
  "Email": "E-mail",
@@ -6,6 +6,12 @@
6
6
  "To avoid possible session interference with the mobile app, use a separate iSmart account for ioBroker where possible. Share the vehicle with that account and grant the permissions needed for your intended use.": "Gebruik waar mogelijk een apart iSmart-account voor ioBroker om mogelijke sessieproblemen met de mobiele app te voorkomen. Deel het voertuig met dat account en verleen de benodigde rechten voor het beoogde gebruik.",
7
7
  "Region": "Regio",
8
8
  "European Union": "Europese Unie",
9
+ "China": "China",
10
+ "Australia": "Australië",
11
+ "Brazil": "Brazilië",
12
+ "Israel": "Israël",
13
+ "Turkey": "Turkije",
14
+ "Thailand": "Thailand",
9
15
  "Rest of World": "Rest van de wereld",
10
16
  "Login type": "Aanmeldtype",
11
17
  "Email": "E-mailadres",
@@ -6,6 +6,12 @@
6
6
  "To avoid possible session interference with the mobile app, use a separate iSmart account for ioBroker where possible. Share the vehicle with that account and grant the permissions needed for your intended use.": "Aby uniknąć możliwych konfliktów sesji z aplikacją mobilną, w miarę możliwości użyj osobnego konta iSmart dla ioBroker. Udostępnij temu kontu pojazd i nadaj uprawnienia wymagane do planowanego użycia.",
7
7
  "Region": "Region",
8
8
  "European Union": "Unia Europejska",
9
+ "China": "Chiny",
10
+ "Australia": "Australia",
11
+ "Brazil": "Brazylia",
12
+ "Israel": "Izrael",
13
+ "Turkey": "Turcja",
14
+ "Thailand": "Tajlandia",
9
15
  "Rest of World": "Reszta świata",
10
16
  "Login type": "Typ logowania",
11
17
  "Email": "E-mail",
@@ -6,6 +6,12 @@
6
6
  "To avoid possible session interference with the mobile app, use a separate iSmart account for ioBroker where possible. Share the vehicle with that account and grant the permissions needed for your intended use.": "Para evitar possíveis interferências de sessão com a aplicação móvel, utilize, sempre que possível, uma conta iSmart separada para o ioBroker. Partilhe o veículo com essa conta e conceda as permissões necessárias para a utilização pretendida.",
7
7
  "Region": "Região",
8
8
  "European Union": "União Europeia",
9
+ "China": "China",
10
+ "Australia": "Austrália",
11
+ "Brazil": "Brasil",
12
+ "Israel": "Israel",
13
+ "Turkey": "Turquia",
14
+ "Thailand": "Tailândia",
9
15
  "Rest of World": "Resto do mundo",
10
16
  "Login type": "Tipo de início de sessão",
11
17
  "Email": "E-mail",
@@ -6,6 +6,12 @@
6
6
  "To avoid possible session interference with the mobile app, use a separate iSmart account for ioBroker where possible. Share the vehicle with that account and grant the permissions needed for your intended use.": "Чтобы избежать возможных конфликтов сеанса с мобильным приложением, по возможности используйте отдельную учетную запись iSmart для ioBroker. Предоставьте этой учетной записи доступ к автомобилю и необходимые для использования разрешения.",
7
7
  "Region": "Регион",
8
8
  "European Union": "Европейский союз",
9
+ "China": "Китай",
10
+ "Australia": "Австралия",
11
+ "Brazil": "Бразилия",
12
+ "Israel": "Израиль",
13
+ "Turkey": "Турция",
14
+ "Thailand": "Таиланд",
9
15
  "Rest of World": "Остальной мир",
10
16
  "Login type": "Тип входа",
11
17
  "Email": "Электронная почта",
@@ -6,6 +6,12 @@
6
6
  "To avoid possible session interference with the mobile app, use a separate iSmart account for ioBroker where possible. Share the vehicle with that account and grant the permissions needed for your intended use.": "Щоб уникнути можливих конфліктів сеансів із мобільним застосунком, за можливості використовуйте окремий обліковий запис iSmart для ioBroker. Надайте йому доступ до автомобіля та необхідні для використання дозволи.",
7
7
  "Region": "Регіон",
8
8
  "European Union": "Європейський Союз",
9
+ "China": "Китай",
10
+ "Australia": "Австралія",
11
+ "Brazil": "Бразилія",
12
+ "Israel": "Ізраїль",
13
+ "Turkey": "Туреччина",
14
+ "Thailand": "Таїланд",
9
15
  "Rest of World": "Решта світу",
10
16
  "Login type": "Тип входу",
11
17
  "Email": "Електронна пошта",
@@ -6,6 +6,12 @@
6
6
  "To avoid possible session interference with the mobile app, use a separate iSmart account for ioBroker where possible. Share the vehicle with that account and grant the permissions needed for your intended use.": "为避免与手机应用的会话发生冲突,请尽可能为 ioBroker 使用单独的 iSmart 账户。将车辆共享给该账户,并授予预期用途所需的权限。",
7
7
  "Region": "地区",
8
8
  "European Union": "欧盟",
9
+ "China": "中国",
10
+ "Australia": "澳大利亚",
11
+ "Brazil": "巴西",
12
+ "Israel": "以色列",
13
+ "Turkey": "土耳其",
14
+ "Thailand": "泰国",
9
15
  "Rest of World": "其他地区",
10
16
  "Login type": "登录类型",
11
17
  "Email": "电子邮箱",
@@ -0,0 +1,37 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __export = (target, all) => {
7
+ for (var name in all)
8
+ __defProp(target, name, { get: all[name], enumerable: true });
9
+ };
10
+ var __copyProps = (to, from, except, desc) => {
11
+ if (from && typeof from === "object" || typeof from === "function") {
12
+ for (let key of __getOwnPropNames(from))
13
+ if (!__hasOwnProp.call(to, key) && key !== except)
14
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
15
+ }
16
+ return to;
17
+ };
18
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
+ var initialization_retry_exports = {};
20
+ __export(initialization_retry_exports, {
21
+ calculateInitializationRetryDelayMs: () => calculateInitializationRetryDelayMs
22
+ });
23
+ module.exports = __toCommonJS(initialization_retry_exports);
24
+ const INITIALIZATION_RETRY_DELAY_MS = 6e4;
25
+ const MAX_INITIALIZATION_RETRY_DELAY_MS = 5 * INITIALIZATION_RETRY_DELAY_MS;
26
+ function calculateInitializationRetryDelayMs(retryCount) {
27
+ const attempts = Math.max(1, retryCount);
28
+ if (attempts <= 3) {
29
+ return INITIALIZATION_RETRY_DELAY_MS * attempts;
30
+ }
31
+ return MAX_INITIALIZATION_RETRY_DELAY_MS;
32
+ }
33
+ // Annotate the CommonJS export names for ESM import in node:
34
+ 0 && (module.exports = {
35
+ calculateInitializationRetryDelayMs
36
+ });
37
+ //# sourceMappingURL=initialization-retry.js.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../src/initialization-retry.ts"],
4
+ "sourcesContent": ["const INITIALIZATION_RETRY_DELAY_MS = 60_000;\nconst MAX_INITIALIZATION_RETRY_DELAY_MS = 5 * INITIALIZATION_RETRY_DELAY_MS;\n\n/**\n * Returns the bounded delay before retrying initialization.\n *\n * @param retryCount Number of initialization failures.\n * @returns Retry delay in milliseconds.\n */\nexport function calculateInitializationRetryDelayMs(retryCount: number): number {\n\tconst attempts = Math.max(1, retryCount);\n\tif (attempts <= 3) {\n\t\treturn INITIALIZATION_RETRY_DELAY_MS * attempts;\n\t}\n\treturn MAX_INITIALIZATION_RETRY_DELAY_MS;\n}\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,MAAM,gCAAgC;AACtC,MAAM,oCAAoC,IAAI;AAQvC,SAAS,oCAAoC,YAA4B;AAC/E,QAAM,WAAW,KAAK,IAAI,GAAG,UAAU;AACvC,MAAI,YAAY,GAAG;AAClB,WAAO,gCAAgC;AAAA,EACxC;AACA,SAAO;AACR;",
6
+ "names": []
7
+ }