Hikone is located in north-west Shiga Prefecture, a few miles south from Maibara.
Take the Hikari Shinkansen, get off at Maibara Station (about two hours from Tōkyō).Take the JR Biwako Line to Hikone (about 5 minutes).
Besides JR lines, you can take the Ōmi Railway, running on the same route, yet not included in your JR Pass.
From Nagoya you don’t have to take a Shinkansen train. Take a Tōkaidō Line’s train to Gifu or Ōgaki. At the final stop take the JR Biwako Line (in some cases you will find a direct train from Nagoya to Maibara).
Take the JR Biwako Line, you will reach Hikone in less than one hour.
From Hikone Station there is a 20 minutes walk to the castle.