Source

servo / Servo / Axis.pm

Full commit
#!/usr/bin/perl
package Servo::Axis;
use warnings;
use strict;

sub new
{
	my $class = shift;
	my @args = (
		.min		= -800,
		.max		= +800,
		@_
	);

	bless {
		dev		=> $args{-dev},
		channel		=> $args{-channel},
		min		=> $args{-min},
		max		=> $args{-max},
	}, $class;
}

sub go
{
	my $self = shift;
	my $position = shift;

	$self->{dev}->position($self->{channel}, $position);
}


"0, but true";
__END__