Programming Sub Keys (Grey) is done the same way except you turn the master key 4 times before you open and close the door 5 times. Then insert the sub key, turn to the "ON" position, and wait your minute. Finish by removing the key and opening and closing the door 1 time as before.
You can erase all the keys and start over by turning a working master key 6 times and then opening and closing the door 7 times. Then remove the key and reprogram again.
Remember : You only have a few seconds to perform each maneuver so don't waste time. You will know when you have done it right when you insert the blank key and the security light on the radio stops blinking. If it does not work, try completing the sequence faster, time yourself. And don't worry, if it doesn't work the first time, just do it again

**It is our understanding, according to the book, you can have 2 master keys and 1 sub key, however, we are aware of one gentleman who was able to program 4 masters and 2 subs. We currently have 3 masters and 1 sub.**
R 2002+
1.Make sure all doors and windows are closed.
2.Insert master key into the ignition cylinder.
3.Cycle the ignition cylinder from ON to OFF 5 times.
4.Open and close the driver side door 6 times.
5.Remove the master key and insert the new duplicate key.
6.DO NOT TURN THE IGNITION CYLINDER ON
7.The new key will be registered after 60 seconds.The THEFT light on the
dashboard will go out,indicating that programming has been completed.
"some 2002 will work using the 1998+ programming."
ou can program an additional key into the Avensis 1998 - 06/2000 by following this sequence:
Open driver's door and insert programmed black key into ignition. Close door.
1). Within 15 seconds
Switch ignition on and off 4 times.
Switch ignition on.
Open and close the driver's door.
2). Within 20 seconds
Open and close driver's door 5 times.
Remove key from ignition.
3). Within 10 seconds
Insert black key to be programmed into ignition.
Switch on and leave for 1 minute.
Remove key.
Repeat step 3 for further keys.
To exit programming open and close the driver's door.
If your key is grey in colour then it cann't be used to program additional keys. I can cut Toyota / Lexus keys at a very reasonable cost. Email me for details.
If you do not have a programmed black key for the vehicle I can recode the engine ECU. Again, email me for details. Please state model, year of manufacture and engine type (VVTI or not VVTI).
Regards.
There are four different programming commands when setting up or verifying your remote transmitter, they are:
A. Add mode, used to add a remote to your Prius that is not currently registered.
B. Rewrite mode, used to erase all previously registered remotes and allow you to begin again the programming process.
C. Confirmation mode, used to verify the number of remotes that are already programmed in your Prius.
D. Prohibit mode, to prohibit all remotes from operating the door locks.
All four modes start with these instructions:
1) Make sure that the key is not in the ignition, the doors are unlocked, and the driver's door is open.
2) Very quickly, without turning, insert and remove key from the ignition twice. (leave key out)
3) Close and open the driver door twice. (leave door in open position)
4) Again, insert key into the ignition and remove it. This time only once. (leave key out)
5) Close and open the driver door twice, then close the door.
6) Insert key into the ignition and leave it in the LOCK position.
A. Add mode:
A1) Turn the key to "ON" for 1 second, then turn back to "LOCK".
A2) Remove the key.
A3) You’ll hear the doors "LOCK" and 1 second later "UNLOCK" (just listen)
A4) On your remote, press the lock and unlock buttons simultaneously for 1 to 1½ seconds, then let go.
A5) On your remote, IMMEDIATELY press unlock by itself.
A6) You’ll get one of three responses:
R1) You’ll hear the doors "LOCK", then "UNLOCK" once. The remote is accepted. If you want to program another remote, immediately proceed to step A4 with your second remote, otherwise open the driver’s door and the remote is registered.
R2) You’ll hear the doors "LOCK", then "UNLOCK" twice. Either you didn’t use the same remote in steps A4 and A5(not likely), or this remote was already registered.
The timing was off when you pressed the LOCK and UNLOCK buttons simultaneously and then UNLOCK by itself. Immediately press the two buttons together and the unlock by itself again. Keep trying until you get the locks to signal once that you have been successful. Then if you have another remote to program, quickly press its' buttons as before, until you hear the locks signal once. When you are finished, open and close the driver door to lock in the programming.
R3) If no response, go back to step 1 near the beginning of these instructions.
B. Rewrite mode:
B1) Turn the key to "ON" for 1 second, turn back to "LOCK" for 1 second, then back to "ON" for 1 second, and finally back to "LOCK" for 1 second
B2) Remove the key.
B3) You’ll hear the doors "LOCK", 1 second later "UNLOCK", 1 sec., "LOCK", 1 sec. "UNLOCK". (just listen)
B4) On your remote, press the lock and unlock buttons simultaneously for 1 to 1½ seconds, then let go.
B5) On your remote, IMMEDIATELY press unlock by itself.
B6) You’ll get one of three responses:
R1) You’ll hear the doors "LOCK", then "UNLOCK" once. The remote is accepted. If you want to program another remote, immediately proceed to step B4, otherwise open the driver’s door and the remote is registered.
R2) You’ll hear the doors "LOCK", then "UNLOCK" twice. You didn’t use the same remote in steps B4 and B5(not likely).
R3) If no response, go back to step 1 near the beginning of these instructions.
C. Confirmation mode:
C1) Turn the key in 1 to "ON" and back to "LOCK" in one second intervals for a total of 3 times.
C2) Remove the key.
C3) You’ll hear the doors "LOCK" and "UNLOCK" in 2 second intervals. (just listen and count each set)
1 Set = You have 1 remote registered
2 Sets = You have 2 remotes registered
3 Sets = You have 3 remotes registered
4 Sets = You have 4 remotes registered
5 Sets = You do NOT have any remotes registered
D. Prohibit mode:
D1) Turn the key to "ON" and back to "LOCK" in one second intervals a total of 5 times.
D2) Remove the key.
D3) You’ll hear the doors "LOCK", 1 second later "UNLOCK" 5 times. (just listen and count each set)
D4) This will erase all previously registered remotes and cancel the wireless door lock function.