Like Glenn said, the variable $Function will get or the value "Master", or the value "Slave".
[Edit]
Why am I always so slow hitting that submit button
[/Edit]