Forward part tested and working

Forward part tested and working
Backward phase working, not fully tested.

Backward phase working, not fully tested.