added support for requesting pcodes from client