fix ammeter RAPI bugs