The present invention relates to a method for coating a surface of a substrate with a drug for sustained release: (i) providing a substrate with a surface to be coated, (ii) depositing at least one bilayer on at least a portion of said surface, wherein one layer of the bilayer comprises a polyelectrolyte and the other layer comprises a pharmaceutically active ingredient, and wherein the two layers of the bilayer are oppositely charged under conditions of the deposition and one layer of the bilayer has a substantially different net charge under physiological conditions. The invention also pertains to substrates with microscopic or macroscopic surfaces coated with the method according to the invention.