Hey, I wrote a considerably large post on just this topic.
This should be all you need! If you have any other questions just ask though :)
Bismarck used anti-French sentiment in 1860s Germany to get them to join his federation, adding that he gave Bavaria a lot of autonomy.