encode note