Content update

This commit is contained in:
Johannes Findeisen 2021-02-21 07:50:36 +01:00
commit 6508c44984
2 changed files with 20 additions and 2 deletions

View file

@ -60,10 +60,17 @@ array(3) {
}
```
### scard_connect($context, "OMNIKEY CardMan 5x21 00 00");
### scard_connect($context, "OMNIKEY CardMan 5x21 00 00" [, int $protocol]);
Connects to a card. Returns the $connection to a reader or FALSE.
Where optional $protocol is:
* 1 = T=0
* 2 = T=1
Default $protocol is T=1.
### scard_reconnect($connection);
Returns the $connection to a reader or FALSE.

View file

@ -39,7 +39,7 @@ echo "\n";
# Connect to the card
echo ">> Connect to Card\n";
$connection = scard_connect($context, $reader);
$connection = scard_connect($context, $reader, 1);
var_dump($connection);
$errno = scard_last_errno();
@ -73,6 +73,17 @@ $errstr = scard_errstr($errno);
var_dump($errstr);
echo "\n";
# Show Status
echo ">> Show Status\n";
$status = scard_status($connection);
var_dump($status);
$errno = scard_last_errno();
var_dump($errno);
$errstr = scard_errstr($errno);
var_dump($errstr);
echo "\n";
# Release the PC/SC context
echo ">> Release Context\n";
scard_release_context($context);