Just for fun, maybe try this:
Right click on the main computer's My Computer. Select properties. Select Hardware. Select Device Manager. Find your NIC card, click on Properites and select Power Management.
If there is a check next to:
Allow the computer to turn off this device to save power, uncheck it.
It may be that the ping "wakes up" the network card and allows the second attempt to connect.
Just a thought.
FYI: If using Vista, the path will be a little different, but it's the same idea.