codegeneration first working version i think!