Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[DNM] Add TMGIndustries maker #1189

Open
wants to merge 4 commits into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions src/makers/TMGIndustries/antennas.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
import { MakerAntenna } from '../antennaMakerTypes'

const TMG_INDUSTRIES_US = {
name: 'TMG Industries Hotspot (US 915)',
gain: 1.2,
} as MakerAntenna

const TMG_INDUSTRIES_EU = {
name: 'TMG Industries (EU 868)',
gain: 2.3,
} as MakerAntenna

export default { TMG_INDUSTRIES_US, TMG_INDUSTRIES_EU }
690 changes: 690 additions & 0 deletions src/makers/TMGIndustries/hotspot.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
52 changes: 52 additions & 0 deletions src/makers/TMGIndustries/hotspots.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
import HotspotIcon from './hotspot.svg'
import { MakerHotspot } from '../hotspotMakerTypes'
import ANTENNAS from './antennas'

const TMGIndustriesHotspotBLE = {
name: 'TMG industries hotspot',
icon: HotspotIcon,
onboardType: 'BLE',
translations: {
en: {
diagnostic:
'<b><white>Diagnostic support allows TMG Industries Maker to identify issues with your Hotspot in a secure way.</white></b>\n\nTMG Industries Maker will never have access to private keys and will only ever be able to access your Hotspot and not any other devices on your Network.\n\nIf you would like to opt-out of diagnostic support please email <purple><b>support@tmgindustries.ca</b></purple> from the email used to purchase the Hotspot.',
power: [
'Attach the antenna and plug in the provided power adapter.',
'Your Hotspot will boot up, and its light will become Green when ready.',
],
bluetooth: [
'Press the black button on your Hotspot. Its light should turn blue.',
"Ensure your phone's bluetooth is on before proceeding",
],
},
ja: {
diagnostic:
'<b><white>診断サポートにより、TMG IndustriesMakerは安全な方法でホットな問題を特定できます。</white></b> \n\nTMG Industries Makerは秘密鍵にアクセスできなくなり、常にホットスポットにのみアクセスでき、ネットワーク上の他のデバイスにはアクセスできなくなります。 \n\n診断サポートをオプトアウトする場合は、ホットスポットの購入に使用したメールを<purple><b>support@tmgindustries.ca</b></purple>に送信してください。',
power: [
'アンテナを取り付け、付属の電源アダプターを差し込みます。',
'ホットスポットが起動し、準備ができるとライトが緑色になります。'
],
bluetooth:[
'ホットスポットの黒いボタンを押します。 そのライトは青に変わるはずです。',
'続行する前に、スマートフォンのBluetoothがオンになっていることを確認してください'
]
},
ko: {
diagnostic: '<b><white>진단 지원을 통해 TMG Industries Maker는 핫스팟 문제를 안전한 방식으로 식별할 수 있습니다.</white></b>\n\nTMG Industries Maker는 개인 키에 액세스할 수 없으며 앞으로도 그럴 것입니다. 핫스팟에 액세스할 수 있으며 네트워크의 다른 장치에는 액세스할 수 없습니다.\n\n진단 지원을 거부하려면 <purple><b>support@tmgindustries.ca</b></purple>으로 이메일을 보내주십시오. Hotspot 구매에 사용한 이메일',
power: [
'안테나를 연결하고 제공된 전원 어댑터를 연결하세요.',
'핫스팟이 부팅되고 준비가 되면 표시등이 녹색으로 바뀝니다.',
],
bluetooth: [
'핫스팟의 검은색 버튼을 누르십시오. 그 빛은 파란색으로 변해야 합니다.',
"계속하기 전에 휴대전화의 블루투스가 켜져 있는지 확인하십시오",
]
},
},
antenna: {
us: ANTENNAS.TMG_INDUSTRIES_US,
default: ANTENNAS.TMG_INDUSTRIES_EU,
},
} as MakerHotspot

export default { TMGIndustriesHotspotBLE }
9 changes: 9 additions & 0 deletions src/makers/TMGIndustries/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
import antennas from './antennas'
import hotspots from './hotspots'

export default {
antennas,
hotspots,
id: 99999, // TODO: Get maker id from onboarding server
supportEmail: 'support@tmgindustries.ca',
}
4 changes: 4 additions & 0 deletions src/makers/index.ts
Original file line number Diff line number Diff line change
@@ -22,6 +22,7 @@ import hummingbird from './hummingbird'
import merryIoT from './merryIoT'
import milesight from './milesight'
import deepernetwork from './deepernetwork'
import tmgindustries from './TMGIndustries'
import { LangType, supportedLangs } from '../utils/i18n/i18nTypes'
import { HotspotMakerLangField } from './hotspotMakerTypes'

@@ -48,6 +49,7 @@ export const Makers: Record<string, { id: number; supportEmail: string }> = {
merryIoT,
milesight,
deepernetwork,
tmgindustries,
}

export const AntennaModels = {
@@ -75,6 +77,7 @@ export const AntennaModels = {
...merryIoT.antennas,
...milesight.antennas,
...deepernetwork.antennas,
...tmgindustries.antennas,
}

export const HotspotMakerModels = {
@@ -100,6 +103,7 @@ export const HotspotMakerModels = {
...merryIoT.hotspots,
...milesight.hotspots,
...deepernetwork.hotspots,
...tmgindustries.hotspots,
}

export type HotspotType = keyof typeof HotspotMakerModels