progress in debug: fix LLF/llh mismatch, and length + add adapter test in test/