Fixed errors in HardwareBase and created an example for class usage