Last question first... The smog machine has a specific RPM requirement
during both the 15mph and 25mph portion of the smog test; so the smog
technician has to have your Toyota in which every gear suits the smog
machine's required engine RPMs. Typically during the 15mph portion the
transmission should be in 2nd gear, and during the 25mph portion the
transmission should be in 3rd gear.
As far as the high HC, changing the oxygen sensor may help lower it if the
HC fault was due to an air/fuel mixture problem. The O2 sensor controls fuel
delivery. If the CO amount your engine produced was not near the average
result indicated on your smog check report, it may have caused the high HC
fault. Since you mention having replaced the sparkplugs, distributor cap and
rotor recently, the high HC problem may be due to either too high or too low
CO... Though I can't confirm this without knowing the CO results.
You may want to consider using our online VIR diagnosis system and have one
of our smog technicians take a look at your Toyota's overall smog check
results. www.smogtips.com/smog_evaluations.cfm
The CAP program is always an excellent state assistance service to use. I'd
recommend getting a new smog test with the replaced O2 sensor and corrected
timing, and if your Toyota still fails the smog check, go ahead and apply
for CAP.