[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Paparazzi-devel] current sensor problem

From: Eduardo lavratti
Subject: [Paparazzi-devel] current sensor problem
Date: Thu, 15 Nov 2012 16:43:28 +0000

Felix, i open an issue about current sensor some time ago.
today i make a comment to this issue with a solution.

here are the lines i put in electrical.c
this solve the overflow problem when i use ESC motor break.
after i put the bound to electrical.current the overflow not occured anymore.

#ifndef SITL
  electrical.current = MilliAmpereOfAdc((electrical_priv.current_adc_buf.sum/electrical_priv.current_adc_buf.av_nb_sample));
  if (electrical.current < -65000 ) electrical.current = -65000;
  if (electrical.current >  65000 ) electrical.current =  65000;

best regards.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]