A Boeing 767 had just departed from Sydney runway 16R when, at a height of about 100ft, the crew reported hearing a series of loud bangs and the right engine exhaust gas temperature indicator rose rapidly into the red range. The right thrust lever was retarded to idle, resulting in the temperature indications returning to normal. ATC had also observed a series of explosions from the right engine as the aircraft departed and had declared a local emergency. The crew requested a return to the field for a landing. Because of local weather conditions the aircraft was radar vectored for an ILS approach to runway 16R, where it landed without further incident. After vacating the runway the aircraft was stopped on the taxiway, and the right engine shut down, before being inspected by the waiting fire services. As there was no evidence of fire the aircraft was taxiied back to the terminal where the passengers disembarked normally. A ground inspection of the engine revealed no external damage, however, an internal boroscope inspection revealed extensive damage to blades of the thirteenth compressor stage. The engine was subsequently removed for further inspection, resulting in a replaceable 'phillips' bit from a screwdriver being found in the core of the engine. The operator reported that the incident occurred on the first flight after the aircraft had undergone an 'A' maintenance check. The 'phillips' bit had probably entered the engine through the variable bleed valves which are open when the engine is not operating. The operator is investigating ways to preclude foreign objects entering the engine in this manner during ground maintenance.