Fixed some issues with converting between byte/int and enum