Brought sda and dbn closer to new design and got all unit tests working.