Diesel engine maker Cummins has raised its earnings outlook due to a recovery in the heavy truck sector and other markets.