CoO and Co3O4 nanoparticles with a tunable particle size