I set up XFCE with the slim display manager.FollowingTouching wood it seems the problem is fixed now.Also, xfce4-goodies was already installedI looked at the .xcfe logs but they did not mention the keyboard or mouse.Hi Zoltan,Thanks for all your suggestions
http://tutorialforlinux.com/2017/01/18/how-to-switch-from- gnomegnome3-to-xfce-desktop- on-debian-8-jessie That made the keyboard and mouse work again -- I think something had gone wrong in the lightdm configuration.After that I removed and re-installed lightdm and can now start that again with mouse and keyboard as well.Not sure what was wrong which is a bit of a shame.Good to have it working again though...