pretty much got 5966 working just need to do some more tests.