A few minor changes to previous code. Added a new command to get ID of
held item.