Implemented amdefine