Check the crankshaft position sensor. The crankshaft position sensor is located below the water pump. The alternator bracket will be blocking it and will need to be removed so you can gain access to the sensor if you have to remove it. The connector should be accessable on the engine block so you can measure it without removing the alternator.
http://www.moranbahweather.com/toyot.../m_18_0006.pdf
The other sensor to check would be the camshaft position sensor. Camshaft position sensor resistance is 835-1400 ohms when engine is cold and 1060-1645 when engine is hot.