fix and modify
working on interrupt
add reg id