i see a couple of things. it is really a simple fix if your handy with 2ools
first thing. undo all that crap pull it out.
now you can work.
where it comes out of the wall. I cant see it, but. do you have 1.5'' of pipe showing ?
just pipe, no fittings. if you do. cut the pvc with a hack saw or what ever aw you have
NOTE...IMPORTANT...you need a minimum of 1'' of pipe to glue a new fitting to...
it can not be any shorter.
aftr you have cut the pipe, glue a 1.5'' pvc coupling on the pipe.
you can build from here
hold a 22.5 degree {{{
ftg x hub ]]] pvc fitting in line with the coupling and the sink drain .
http://screencast.com/t/VvEqgy5j
measure the pipe length you need from coupling to 22.5 degree fitting.
cut and install pipe glue pipe into coupling, 22 onto pipe, glue a 1.5'' trap adapter on the 22.
slide ptrap into trap adapter...i think you have it from there
while your up under the sink.
look at that white dishwasher drain hose.
get a wire, string, damn bread tie..whatever
tie that hose up so that it goes up to the bottom of cabinet then down to the disposal
this might be where your smell is coming from. tie the hose up will stop it