I've gone cheapo and replaced the downstream O2 sensor with another OEM Toyota sensor with identical color coded wires. I believe the sensors are Denso 2344623 and the wires are white, blue, black and black. The two blacks are both ground wires, one for the sensor and one for the heating circuit. Based on very inclemet weather, I snipped the wires from underneath the doner car and moved on to a drier environment. For replacing the stolen sensor, I simply butt spliced the wires underneath my 2003 without any further analysis and, therefore, I had a 50/50 chance on getting the blacks the same as original. All seems to have worked out okay. Does anyone know if the black ground wires are interchangeable or should each one be aligned with its original white or blue wire? Thanks in advance for you help, Larry BTW, I will post a writeup for my experience adapting a Gen2 aftermarket cat converter to a Gen1 as soon as I get a few hundred miles on it. It worked out pretty slick.
Looking in my 2001 wiring diagram (more info), the downstream sensor (bank 1 sensor 2) has four wires to its connector H9 (under the carpet in the passenger compartment). I don't know about the colors of the wires on the sensor itself; what the diagram shows are the colors in the car's wiring harness up to that connector, black for 12 volts from the battery, green with yellow stripe for control of the heater (the ECM switches HT1B to ground), yellow for the sensor output, and brown for the isolated sensor ground and cable shield. Toyota typically uses white with black stripe wires for general-purpose grounding, and brown wires (as here) for the isolated grounding needed to keep sensitive sensor inputs noise-free. As you can see, this brown ground circuit is nowhere mingled with the car's general white/black ground system or the body ground; it is shared only by the downstream O2 sensor and its wire shield, and the shield of the upstream sensor, and is grounded through E11 of the ECM itself. (At the upstream sensor's pin 4, you can see another brown wire go off the page; that is a similar isolated ground circuit that serves the rest of the sensitive engine sensors and is grounded through ECM terminal E2.) Upshot: I would go back and make sure to get those connections right, which might mean tugging up the carpet at the passenger floor so you can see the connector in question. That's important both because the sensor has a dedicated isolated ground, and because the heater doesn't really have a 'ground' connection; it's powered between the battery and a switched ground controlled by the ECM. Mixing up those connections would not do what you want. If you already snipped the original connector off the sensor, you don't have the pin numbers to go by, and you may have to use an ohmmeter and work from the test procedures in the repair manual to make sure you've identified which two wires are the heater and which are the sensor and its ground.