Calculation help for dissolved CO2


I have been searching all over and keep seeing the Henry's Law but I cant seem to get a formula together for what I am looking for.
I want to know how many grams of CO2 are in the soda based on the temperature of the soda and the pressure of the headspace (at equilibrium when no more CO2 is being absorbed into the solution). I then can use this for other formulations of interest, like how much I have actually used from the tank, the volume in the bottle as (3, 4, 4.5 ect).
I dont know if it is as simple as a I expect it should be, but if someone has the long hand down I could plug in the numbers that would be of great help. Also if they could explain the steps involved (or what each number represents)
I have created an excel formula, but that only worked if the temp was at 20C, not a variable temperature.
