update main programme