ACM1252U-Y3
– Reference Manual
Version 1.03
www.acs.com.hk
Page 42 of 92
www.acs.com
.hk
5.2.4.7.
Copy Value Block
This command is used to copy a value from a value block to another value block.
Copy Value Block APDU Format (7 bytes)
Where:
Source Block Number
1 byte. The value of the source value block will be copied to the
target value block.
Target Block Number
1 byte. The value block to be restored. The source and target
value blocks must be in the same sector.
Copy Value Block Response Format (2 bytes)
Response
Data Out
Result
SW1
SW2
Copy Value Block Response Codes
Results
SW1
SW2
Meaning
Success
90
00h
The operation was completed
successfully.
Error
63
00h
The operation failed.
Examples:
// Store a value
“1” into block
05h
APDU = {
FF D7
00
05
05
00
00 00 00 01h}
// Read the value block
05h
APDU = {
FF B1
00
05
04h}
// Copy the value from value block
05h
to value block
06h
APDU = {
FF D7
00
05
02
03
06h
}
// Increment the value block
05h
by “5”
APDU = {
FF D7
00
05
05
01
00 00 00 05h}
Command
Class
INS
P1
P2
Lc
Data In
Copy Value
Block
FFh
D7h
00h
Source
Block
Number
02h
03h
Target
Block
Number