#!/usr/bin/perl

$pwmval=$ARGV[0];

$pwmval2=$ARGV[1];

if (!($ARGV[0])) {die("must have at least 1 input arg. (the pwm value)")}

$commandstring = sprintf("echo -n -e \"\\%s\" > /dev/squarewave0",$pwmval);

print STDOUT "$commandstring\n";
system($commandstring);  # drives pwm

