Compose a musical piece using the given motif and adhering to the outlined musical form.
X:1
L:1/8
M:2/4
K:D
['a2 ag/a/ bagf g2 gf/g/ agfe f2', 'f2 fe/f/ gfed cd e/g/e/c/'  
X:1
L:1/8
M:2/4
K:D
 a2 ag/a/ | bagf | g2 gf/g/ | agfe | f2 fe/f/ | gfed | cd e/g/e/c/ | d2 D2 :: f2 fe/f/ | gfed | 
 cd e/g/e/c/ | dA FD | f2 fe/f/ | gfed | cd e/g/e/c/ | d2 D2 :|  