Dominevo
ReferenceDevice capabilities

ir-transmitter

ir-transmitter — emit a pulse train (infrared or RF) with settings.

ir-transmitter — emit a pulse train (infrared or RF) with settings. One cap for both media: everything medium-specific is a per-call setting, validated against what the transmitter declares in getInfo.

send refuses with a typed user error: ir-transmitter.offline (the transmitter cannot be reached) and ir-transmitter.too-long (more pulses than the transmitter's maxTimings). A setting the transmitter cannot apply is NOT a refusal: the train is sent and the key comes back in ignoredSettings. send takes exactly one of timings or native (a code in a format listed in getInfo.formats).

learn waits for the user to point a remote at the transmitter and refuses with ir-transmitter.learn-unsupported, ir-transmitter.learn-timeout or ir-transmitter.learn-undecodable.

At a glance

Capabilityir-transmitter
Provided byThe device's own driver provides it: each device registers its own provider.
Active providers per deviceone
Device typesgeneric
Sourcepackages/types/src/capabilities/ir-transmitter.cap.ts

Methods

Every method takes the device id (deviceId) to address the device; the input tables below list the other fields.

MethodKindRequired of a providerAccess
sendmutationyesprotected
learnmutationyesprotected
getInfoqueryyesprotected

send

mutation

Input

FieldTypeRequiredDescription
timingsnumber[]no
native{ format: "tuya"; code: string }no
settings{ carrierHz?: number; dutyCyclePercent?: number; repeat?: number; repeatDelayMs?: number }no

Output

FieldTypeRequiredDescription
oktrueyes
ignoredSettingsstring[]yesSettings the transmitter could not apply; the train was still sent.

learn

mutation

Input

FieldTypeRequiredDescription
timeoutMsnumberno (default 20000)

Output

FieldTypeRequiredDescription
native{ format: "tuya"; code: string } | nullyesThe code in the device's own format, when it reports one.
timingsnumber[]yes
carrierHznumber | nullyes

getInfo

query

Input

No fields besides deviceId.

Output

FieldTypeRequiredDescription
media("ir" | "rf")[]yes
settable("carrierHz" | "dutyCyclePercent" | "repeat" | "repeatDelayMs")[]yes
maxTimingsnumberyes
learnbooleanno (default false)The transmitter can learn a code (learn).
formats"tuya"[]no (default [])Native code formats the transmitter replays verbatim (send.native).

Runtime state

The state Dominevo keeps for each device with this capability, readable without calling the provider.

Last send and last learn, for the device card. Written by the provider on every attempt, including a typed refusal. A learn-unsupported refusal is not an attempt and is not written.

FieldTypeRequiredDescription
lastSend{ at: number; ok: boolean; error: string | null; medium: "ir" | "rf" } | nullyes
lastLearn{ at: number; ok: boolean; error: string | null } | nullyes
lastFetchedAtnumberyesMs epoch when the slice was last updated.