Hi
Not sure about your code. But when using Basic Stamp syntax for serial. You should place at the top of your code.

Code:
Include "modedefs.bas"
In the back of the Picbasic Pro manual there is a section on the differences between PBP and Basic Stamp.

Hopefully you can make it work.