I guess he used a trained neural Net, to balance the bot (let it stand up, walk etc)

Neural net data is very small, but can incorporate complex calculations.