Skip to content

Commit

Permalink
[lghombot] Cleaned up strings and translations.
Browse files Browse the repository at this point in the history
Signed-off-by: Fredrik Ahlström <[email protected]> (github: FluBBaOfWard)
  • Loading branch information
FluBBaOfWard committed Sep 11, 2018
1 parent 12cba7f commit a9d6be0
Show file tree
Hide file tree
Showing 6 changed files with 164 additions and 37 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
# FIXME: please substitute the xx_XX with a proper locale, ie. de_DE

# binding
binding.lghombot.name = LG HomBot Binding
binding.lghombot.description = The LG-HomBot binding allows control and supervision of your HomBot.

# thing types
thing-type.lghombot.LGHomBot.label = LG-HomBot
thing-type.lghombot.LGHomBot.description = HomBot vacuum robot

# thing type configuration
thing-type.config.lghombot.LGHomBot.ipAddress.label = Network Address
thing-type.config.lghombot.LGHomBot.ipAddress.description = The IP or host name of the HomBot.
thing-type.config.lghombot.LGHomBot.port.label = Port
thing-type.config.lghombot.LGHomBot.port.description = Port of the HomBot to control.
thing-type.config.lghombot.LGHomBot.pollingPeriod.label = Polling Period
thing-type.config.lghombot.LGHomBot.pollingPeriod.description = Time between polls in seconds.

# channel types
channel-type.lghombot.stateType.label = State
channel-type.lghombot.stateType.description = Current state.
channel-type.lghombot.stateType.state.option.UNKNOWN = Unknown
channel-type.lghombot.stateType.state.option.WORKING = Cleaning
channel-type.lghombot.stateType.state.option.BACKMOVING = Backmoving
channel-type.lghombot.stateType.state.option.BACKMOVING_INIT = Backmoving init
channel-type.lghombot.stateType.state.option.BACKMOVING_JOY = Backmoving joy
channel-type.lghombot.stateType.state.option.PAUSE = Paused
channel-type.lghombot.stateType.state.option.STANDBY = Standby
channel-type.lghombot.stateType.state.option.HOMING = Homing
channel-type.lghombot.stateType.state.option.DOCKING = Docking
channel-type.lghombot.stateType.state.option.CHARGING = Charging
channel-type.lghombot.stateType.state.option.DIAGNOSIS = Running diagnosis
channel-type.lghombot.stateType.state.option.RESERVATION = Changing settings
channel-type.lghombot.stateType.state.option.ERROR = Error

channel-type.lghombot.batteryType.label = Battery
channel-type.lghombot.batteryType.description = Current battery charge

channel-type.lghombot.cpuLoadType.label = CPU Load
channel-type.lghombot.cpuLoadType.description = Current CPU load
channel-type.lghombot.srvMemType.label = Used Memory
channel-type.lghombot.srvMemType.description = Memory used by webserver on HomBot.
channel-type.lghombot.startType.label = Clean
channel-type.lghombot.startType.description = Start cleaning.
channel-type.lghombot.homeType.label = Home
channel-type.lghombot.homeType.description = Return home.
channel-type.lghombot.stopType.label = Pause
channel-type.lghombot.stopType.description = Pause the HomBot.
channel-type.lghombot.turboType.label = Turbo
channel-type.lghombot.turboType.description = Turbo mode ON, OFF.
channel-type.lghombot.repeatType.label = Repeat
channel-type.lghombot.repeatType.description = Repeat cleaning ON, OFF.

channel-type.lghombot.modeType.label = Mode
channel-type.lghombot.modeType.description = Cleaning mode.
channel-type.lghombot.modeType.state.option.ZZ = Zigzag mode
channel-type.lghombot.modeType.state.option.SB = Cell by cell mode
channel-type.lghombot.modeType.state.option.SPOT = Spiral spot mode
channel-type.lghombot.modeType.state.option.MACRO_SECTOR = My space mode

channel-type.lghombot.nicknameType.label = Nickname
channel-type.lghombot.nicknameType.description = Nickname of the HomBot.
channel-type.lghombot.cameraType.label = Camera
channel-type.lghombot.cameraType.description = Image feed from the top camera.
channel-type.lghombot.mapType.label = Map
channel-type.lghombot.mapType.description = Map of last cleaned area.
channel-type.lghombot.moveType.label = Move
channel-type.lghombot.moveType.description = Move direction.
channel-type.lghombot.lastCleanType.label = Last Clean
channel-type.lghombot.lastCleanType.description = Last time the HomBot cleaned.
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
# FIXME: please substitute the xx_XX with a proper locale, ie. de_DE

# binding
binding.lghombot.name = LG HomBot Binding
binding.lghombot.description = LG-HomBot binding tillåter kontrol och övervakning av din HomBot.

# thing types
thing-type.lghombot.LGHomBot.label = LG-HomBot
thing-type.lghombot.LGHomBot.description = HomBot Robotdamsugare

# thing type configuration
thing-type.config.lghombot.LGHomBot.ipAddress.label = Nätverksdress
thing-type.config.lghombot.LGHomBot.ipAddress.description = IP Adress eller namn på HomBot.
thing-type.config.lghombot.LGHomBot.port.label = Port
thing-type.config.lghombot.LGHomBot.port.description = Nätverksport på HomBot.
thing-type.config.lghombot.LGHomBot.pollingPeriod.label = Pollningsperiod
thing-type.config.lghombot.LGHomBot.pollingPeriod.description = Tid mellan pollningar i sekunder.

# channel types
channel-type.lghombot.stateType.label = Status
channel-type.lghombot.stateType.description = Nuvarande status.
channel-type.lghombot.stateType.state.option.UNKNOWN = Okänd
channel-type.lghombot.stateType.state.option.WORKING = Städar
channel-type.lghombot.stateType.state.option.BACKMOVING = Backar
channel-type.lghombot.stateType.state.option.BACKMOVING_INIT = Startar backning
channel-type.lghombot.stateType.state.option.BACKMOVING_JOY = Backar ur
channel-type.lghombot.stateType.state.option.PAUSE = Pausad
channel-type.lghombot.stateType.state.option.STANDBY = Väntar
channel-type.lghombot.stateType.state.option.HOMING = Åker hemåt
channel-type.lghombot.stateType.state.option.DOCKING = Dockar
channel-type.lghombot.stateType.state.option.CHARGING = Laddar
channel-type.lghombot.stateType.state.option.DIAGNOSIS = Kör diagnos
channel-type.lghombot.stateType.state.option.RESERVATION = Gör inställning
channel-type.lghombot.stateType.state.option.ERROR = Fel

channel-type.lghombot.batteryType.label = Batteri
channel-type.lghombot.batteryType.description = Nuvarande batteriladdning.

channel-type.lghombot.cpuLoadType.label = CPU belastning
channel-type.lghombot.cpuLoadType.description = Nuvarande CPU belastning.
channel-type.lghombot.srvMemType.label = Använt minne
channel-type.lghombot.srvMemType.description = Minne använt av webserver på HomBot.
channel-type.lghombot.startType.label = Städa
channel-type.lghombot.startType.description = Börja städa.
channel-type.lghombot.homeType.label = Hemåt
channel-type.lghombot.homeType.description = Återvänd hem.
channel-type.lghombot.stopType.label = Paus
channel-type.lghombot.stopType.description = Pausa HomBot.
channel-type.lghombot.turboType.label = Turbo
channel-type.lghombot.turboType.description = Turbo läge AV, PÅ.
channel-type.lghombot.repeatType.label = Återupprepa
channel-type.lghombot.repeatType.description = Återupprepande städning AV, PÅ.

channel-type.lghombot.modeType.label = Städläge
channel-type.lghombot.modeType.description = Städläge.
channel-type.lghombot.modeType.state.option.ZZ = Sicksack läge
channel-type.lghombot.modeType.state.option.SB = Cell vid cell läge
channel-type.lghombot.modeType.state.option.SPOT = Punktspiral läge
channel-type.lghombot.modeType.state.option.MACRO_SECTOR = Mitt utrymme läge

channel-type.lghombot.nicknameType.label = Smeknamn
channel-type.lghombot.nicknameType.description = Smeknamn på HomBot.
channel-type.lghombot.cameraType.label = Kamera
channel-type.lghombot.cameraType.description = Bild från toppkameran.
channel-type.lghombot.mapType.label = Karta
channel-type.lghombot.mapType.description = Karta över senaste städade arean.
channel-type.lghombot.moveType.label = Styr
channel-type.lghombot.moveType.description = Styr riktning.
channel-type.lghombot.lastCleanType.label = Senaste städning
channel-type.lghombot.lastCleanType.description = Senaste tillfälle som HomBot städade.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

<thing-type id="LGHomBot">
<label>LG-HomBot</label>
<description>LG-HomBot Vacuum robot</description>
<description>HomBot vacuum robot.</description>
<category>CleaningRobot</category>

<channels>
Expand All @@ -29,18 +29,19 @@

<properties>
<property name="vendor">LG</property>
<property name="modelId">HomBot</property>
</properties>
<representation-property>deviceId</representation-property>

<config-description>
<parameter name="ipAddress" type="text" required="true">
<label>Network Address</label>
<description>The IP or host name of the HomBot</description>
<description>The IP or host name of the HomBot.</description>
<context>network-address</context>
</parameter>
<parameter name="port" type="integer" min="1000" max="65335">
<label>Port</label>
<description>Port of the HomBot to control</description>
<description>Port of the HomBot to control.</description>
<default>6260</default>
<advanced>true</advanced>
</parameter>
Expand All @@ -57,20 +58,20 @@
<channel-type id="stateType">
<item-type>String</item-type>
<label>State</label>
<description>Current state</description>
<description>Current state.</description>
<state pattern="%s" readOnly="true">
<options>
<option value="UNKNOWN">Unknown</option>
<option value="WORKING">Cleaning</option>
<option value="BACKMOVING">Backmoving</option>
<option value="BACKMOVING_INIT">Backmoving Init</option>
<option value="BACKMOVING_JOY">Backmoving Joy</option>
<option value="BACKMOVING_INIT">Backmoving init</option>
<option value="BACKMOVING_JOY">Backmoving joy</option>
<option value="PAUSE">Pause</option>
<option value="STANDBY">Standby</option>
<option value="HOMING">Homing</option>
<option value="DOCKING">Docking</option>
<option value="CHARGING">Charging</option>
<option value="DIAGNOSIS">Diagnosis running</option>
<option value="DIAGNOSIS">Running diagnosis</option>
<option value="RESERVATION">Changing settings</option>
<option value="ERROR">Error</option>
</options>
Expand All @@ -79,57 +80,57 @@
<channel-type id="batteryType">
<item-type>Number</item-type>
<label>Battery</label>
<description>Current battery charge</description>
<description>Current battery charge.</description>
<category>BatteryLevel</category>
<state pattern="%d%%" readOnly="true"/>
</channel-type>
<channel-type id="cpuLoadType" advanced="true">
<item-type>Number</item-type>
<label>CPU Load</label>
<description>Current CPU load</description>
<description>Current CPU load.</description>
<state pattern="%d%%" readOnly="true"/>
</channel-type>
<channel-type id="srvMemType" advanced="true">
<item-type>String</item-type>
<label>Used Memory</label>
<description>Memory used by webserver on HomBot</description>
<description>Memory used by webserver on HomBot.</description>
<state pattern="%s" readOnly="true"/>
</channel-type>
<channel-type id="startType">
<item-type>Switch</item-type>
<label>Clean</label>
<description>Start cleaning</description>
<description>Start cleaning.</description>
<tags>
<tag>Switchable</tag>
</tags>
</channel-type>
<channel-type id="homeType">
<item-type>Switch</item-type>
<label>Home</label>
<description>Return home</description>
<description>Return home.</description>
<tags>
<tag>Switchable</tag>
</tags>
</channel-type>
<channel-type id="pauseType" advanced="true">
<item-type>Switch</item-type>
<label>Pause</label>
<description>Pause cleaning</description>
<description>Pause the HomBot.</description>
</channel-type>
<channel-type id="turboType">
<item-type>Switch</item-type>
<label>Turbo</label>
<description>Turbo mode ON, OFF</description>
<description>Turbo mode ON, OFF.</description>
</channel-type>
<channel-type id="repeatType">
<item-type>Switch</item-type>
<label>Repeat</label>
<description>Repeat mode ON, OFF</description>
<description>Repeat cleaning ON, OFF.</description>
</channel-type>
<channel-type id="modeType">
<item-type>String</item-type>
<label>Mode</label>
<description>Cleaning mode</description>
<description>Cleaning mode.</description>
<state>
<options>
<option value="ZZ">Zigzag mode</option>
Expand All @@ -142,25 +143,25 @@
<channel-type id="nicknameType">
<item-type>String</item-type>
<label>Nickname</label>
<description>The nickname of the HomBot</description>
<description>Nickname of the HomBot.</description>
<state pattern="%s" readOnly="true"/>
</channel-type>
<channel-type id="cameraType">
<item-type>Image</item-type>
<label>Camera</label>
<description>Image feed from the top camera</description>
<description>Image feed from the top camera.</description>
<state readOnly="true"/>
</channel-type>
<channel-type id="mapType" advanced="true">
<item-type>Image</item-type>
<label>Map</label>
<description>Map of last cleaned area</description>
<description>Map of last cleaned area.</description>
<state readOnly="true"/>
</channel-type>
<channel-type id="moveType" advanced="true">
<item-type>String</item-type>
<label>Move</label>
<description>Move direction</description>
<description>Move direction.</description>
<state>
<options>
<option value="FORWARD">Forward</option>
Expand All @@ -177,8 +178,8 @@
</channel-type>
<channel-type id="lastCleanType">
<item-type>DateTime</item-type>
<label>Last clean</label>
<description>Last time the robot cleaned</description>
<label>Last Clean</label>
<description>Last time the HomBot cleaned.</description>
<state pattern="%1$tF %1$tR" readOnly="true" />
</channel-type>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -401,7 +401,7 @@ private void updateAllChannels() {
}

private void parseImage() {
if (!super.isLinked(CHANNEL_CAMERA)) {
if (!isLinked(CHANNEL_CAMERA)) {
return;
}
final int width = 320;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 +255,6 @@ private void messageReceive(String message, String ipAddress) {
Map<String, Object> properties = new HashMap<>(3);
properties.put(LGHomBotConfiguration.IP_ADDRESS, ipAddress);
properties.put(Thing.PROPERTY_FIRMWARE_VERSION, fwVersion);
properties.put(Thing.PROPERTY_MODEL_ID, model);
properties.put("server", srvVersion);
DiscoveryResult result = DiscoveryResultBuilder.create(uid).withProperties(properties)
.withLabel(model + " (" + nickName + ")").build();
Expand Down

0 comments on commit a9d6be0

Please sign in to comment.