comm.h and comm.c creation, some fixes