hi thanks for answers
i make some changes in circuit. you can see in attachment .but output data still is fixed.
what about my program?is it correct?