Past and future solar activity from cosmogenic radionuclides