AppleScript control Sound Preference Input in OSX 10.3.4

I can get to the sound preference:
tell application “System Preferences”
set current pane to pane “”
end tell
But I can’t figure out how to go to “Input” so I can switch between a USB headset and speakers on the optical digital-in port.
Also is there a way that the script would simply toggle between:
Name “Plantronics Headset” - Port "USB
Name “Digital In” - port - Optical digital-in port

I am a newbie - thanks for any help