Updated

updated calculation
messed up xml
getting closer on the two activity trigger