As a result of the fact that duty is inherent, or something that one naturally acquires, duty typically has a positive connotation as a responsibility. For example, in Switzerland, adults must serve in the military for a few years, and this is their duties as citizens. An obligation typically has a negative connotation, and a person may acquire these in a workplace, personal life or religious practice. For example, a person may have the obligation of doing household chores each day.
Philosopher Immanuel Kant elaborated on what it means to be human, and he felt that a concept of duty is a huge part of it. Kant said that humans are separated from the animal kingdom because people feel a moral duty to do certain things that might not directly benefit themselves. They might feel morally responsible to serve their countries, for example, and decide to enroll in the military. This would be a duty that stems for a moral belief that a person should help her community and country.
In a recent analysis, social philosopher Frank Skillern analyzed the way in which morality, duty, obligation and law coincide. Skillern argues that some people may feel moral duties to obey the laws but not people feel this way. As a result, he explores whether or not humans have obligations to follow laws. In other words, if humans do not have a predisposition and innate moral impulse to follow the law, then they may still feel obligated to follow the law, as a result of their accountability to others and desire to not get thrown in jail. So, they may not feel that following the law is their duty, but they may feel that it is their obligation, such that they do not suffer consequences in society.
Whereas you can interpret "duty" and "obligation" as two different concepts, there is also a way to interpret these terms by relating the two. If duty is an innate responsibility that one inherits, then obligation can be said to be the way in which this responsibility is carried out. For example, a person might have a duty to be a good son to his father. Whereas this is his duty, he carries it out by listening to his father, loving his father and helping his father. These are his obligations. They are the way in which he deals with the responsibility that results from his duty.