rxpoweredup
Version:
A Typescript RxJS-based library for controlling LEGO Powered UP hubs & peripherals.
23 lines (22 loc) • 2.91 kB
TypeScript
import { RawPortOutputCommandMessage } from '../../types';
import { MotorServoEndState, MotorUseProfile, PortOperationCompletionInformation, PortOperationStartupInformation } from '../../constants';
import { IMotorCommandsOutboundMessageFactory } from '../../features';
import { WriteDirectModeDataBuilder } from './write-direct-mode-data-builder';
export declare class PortOutputCommandOutboundMessageFactory implements IMotorCommandsOutboundMessageFactory {
private readonly writeDirectModeDataBuilder;
constructor(writeDirectModeDataBuilder: WriteDirectModeDataBuilder);
startPower(portId: number, power: number, powerModeId?: number, startupMode?: PortOperationStartupInformation, completionMode?: PortOperationCompletionInformation): RawPortOutputCommandMessage;
startSpeed(portId: number, speed: number, power?: number, profile?: MotorUseProfile, startupMode?: PortOperationStartupInformation, completionMode?: PortOperationCompletionInformation): RawPortOutputCommandMessage;
startRotationSynchronized(virtualPortId: number, speed1: number, speed2: number, power?: number, useProfile?: MotorUseProfile, startupMode?: PortOperationStartupInformation, completionMode?: PortOperationCompletionInformation): RawPortOutputCommandMessage;
goToAbsolutePosition(portId: number, absolutePosition: number, speed?: number, power?: number, endState?: MotorServoEndState, profile?: MotorUseProfile, startupMode?: PortOperationStartupInformation, completionMode?: PortOperationCompletionInformation): RawPortOutputCommandMessage;
startSpeedForDegrees(portId: number, degree: number, speed?: number, power?: number, endState?: MotorServoEndState, useProfile?: MotorUseProfile, startupMode?: PortOperationStartupInformation, completionMode?: PortOperationCompletionInformation): RawPortOutputCommandMessage;
goToAbsolutePositionSynchronized(virtualPortId: number, absolutePosition1: number, absolutePosition2: number, speed?: number, power?: number, endState?: MotorServoEndState, useProfile?: MotorUseProfile, startupMode?: PortOperationStartupInformation, completionMode?: PortOperationCompletionInformation): RawPortOutputCommandMessage;
presetEncoder(portId: number, absolutePosition: number, positionModeId: number): RawPortOutputCommandMessage;
setAccelerationTime(portId: number, timeMs: number, profileId?: number, startupMode?: PortOperationStartupInformation, completionMode?: PortOperationCompletionInformation): RawPortOutputCommandMessage;
setDecelerationTime(portId: number, timeMs: number, profileId?: number, startupMode?: PortOperationStartupInformation, completionMode?: PortOperationCompletionInformation): RawPortOutputCommandMessage;
private ensureAccDecTimeIsWithinLimits;
private ensureSpeedIsWithinLimits;
private ensurePowerIsWithinLimits;
private ensureLpfPowerIsWithinLimits;
private ensureAbsolutePositionIsWithinLimits;
}