Fixed small bug in hardware library