Updated samples
changes to demo code