An schematic would be very useful. Also the max switching frequency of the L293D is 5kHz. Which frequency are you using?