I spent the day down in Heidelberg and will probably write a couple of essays tomorrow (with pictures). I will offer some travel advice on the city and what to see.
1. Heidelberg is a town that you really need a three-day weekend to get the full experience and see what there is to see. Most is outdoors....so you'd be smart to do it between April and September. Because of the tourist-magnet.....it's best to go Monday through Friday.
2. Going by train. The station is almost in mid-town, and if you live in Stuttgart or Frankfurt.....it's basically a 90-minute train ride. The Heidelberg train-station is on Kurfursten-Anlage (head east on Kurfursten). Walking, it's a 12-minute walk till when you hit "3" going north, so take the left turn and head toward the river (five minutes and you are at the river and old town area). There is a IBIS hotel at the train-station, but you could do a lot better (particularly on the north side of the river....the Astoria). There's supposed to be a new renovated deal (Heidelberg Suites) on the waterfront of the northside, with a boat-restaurant.
3. Mark Twain's hotel is on the north side of the river and up by the dam (far east side of town). It's still there and probably worth seeing.
4. Hauptstrasse in the old town area is the tourist magnet area.....coffee shops, old buildings, etc. If you make that your reference point.....you will do well.
5. The tram at Burgweg strasse....is point where you pay 7-Euro for a round-trip ticket to the top of the hill, and the castle. Note that on weekends.....it's heavy with tourist traffic. The tram will drop you off about 300 feet from the castle. When you return to the tram point, you can go further up the hill and get off at a scenic point. There, a second tram (the 1873 tram) will take you to the very top. It's worth doing this but I should note that the very top point is a place where you'd get off....take a dozen pictures.....sip a beer or coffee....and get back on the old tram to return to the bottom of the hill. You can eat up four hours just on the castle, tram ride and coffee.
6. The castle itself is under some renovation and don't be expecting some four-star experience. It's worth the time to go up but I wouldn't expect to be there for more than two hours. The museum that you see....is the pharmacy science museum (not related to the castle), and it's probably not worth seeing unless you get all chocked up over aspirin.
7. At the far east side of town is Karlstor (interesting item to see) and the dam. Put aside an hour for the two.
8. A key factor to Heidelberg is walking. There is a all-day bus and U-Bahn ticket which might help to some degree. But I would have good shoes on and anticipate being exhausted by the end of the day.
9. Between architecture and scenes of the old town....you need to set aside an entire afternoon for just walking around. The 'Alte Brucke' (the old bridge) is a mandatory thing to walk over.
10. There are a lot of 'chicky-micky' cafes and restaurants in Heidelberg. There are places where tourists typically stop and they will serve an authentic regular dinner. It won't be special or taste that great, but it makes the tourists happy. Such a place exists in the basement of the castle itself. My advice is limit yourself and go outside of town to some of the finer places that the locals will visit.
Of the ten top places to go and visit as an American in Germany.....I put Heidelberg up near the top five. It's one of those places where you rough it for eight hours and have a great time seeing a fair part of the town, and a year later come back....to see what you missed. The one negative is finding parking and that's why I recommend the tour-bus route, or taking the train into town (remember if you live in the state of Baden-Wurttemberg, you can get the state ticket for five people and travel all day within B-W on that one ticket.....staying off the ICE trains of course).