The transmission control module and engine control module are located in the passenger rear of the engine compartment, behind a cover panel in the firewall. BMW have several bulletins about driveability issues relating to the control module. It is best to have a repair shop with BMW knowledge look at the car unless there is some specific reason (jump started the car the car wrong or module filed with water) you know the module is bad.
RepairPal Certified shops can diagnose and repair your 1996 BMW 318ti. They provide transparent pricing with a minimum 12-month or 12,000-mile warranty on repairs and services.