#!/usr/bin/perl

sub GenSectors
{
	($center, $stepping, $width, $angle, $rotate, $channels, $start) = @_;
	printf("%2s %10s %10s %10s %10s\n", "CH", "Low", "Center", "High", "Bearing");
	for ($i = $start; $i < $channels + $start; $i++)
	{
		printf("%2s %10s %10s %10s %10s\n", $i, $center - ($width / 2), $center, $center + ($width / 2), $angle);
		$center += $stepping;
		$angle = ($angle + $rotate) % 360;
	}
}

print("\t10MHz guarded 20MHz channels\n");
GenSectors(5.915, -0.03, 0.02, 0, 120, 3, 1);

printf("\n");

print("\tUnguarded 20MHz 240 deg channels\n");
GenSectors(5.835, -0.02, 0.02, 240, 0, 9, 4);
