: poniedziałek 20 paź 2014, 11:59
Soft samolotowy dla m328 ma wyłączone baro aby zmieściły się procedury GPS.pbrys pisze:PS. wario nabgpsie jest wyłączone
Forum modelarzy i pilotów FPV
https://rc-fpv.pl/
Soft samolotowy dla m328 ma wyłączone baro aby zmieściły się procedury GPS.pbrys pisze:PS. wario nabgpsie jest wyłączone
Zwracam honor - wszystko jest na swoim miejscu, ale dopiero wtedy gdy się zrobi tak jak napisał miśpbrys pisze:pokazuje i w ramce jest wysokość
Przetestowałem i działamiś pisze:Bo emulator remzibiego aby dobrze działał musi mieć w systemie windows ustawiony separator dziesiętny jako . (kropka) a nie przecinek jak to jest w standardzie dla polskich ustawień.
Kod: Zaznacz cały
#define POWERMETER_HARD
#define PSENSORNULL 0 /* (*) hard only: set to analogRead() value for zero current; for I=0A my sensor
gives 1/2 Vss; that is approx 2.49Volt; */
#define PINT2mA 132 /* (*) hard: one integer step on arduino analog translates to mA (example 4.9 / 37 * 1000) ;
soft: use fictional value, start with 100.
for hard and soft: larger PINT2mA will get you larger value for power (mAh equivalent) */
#define AMP_SCALE 1024 /* scaling the current ADC value to current outputed via MSP in 0.1A steps (1024 = 1:1 scale) */
no to pięknie , ja tu z płytką się napracowałem, pidatory wywaliłem, goldy dolutowałem a tu taka niespodziankamiś pisze:...
2 - Nie ma Trzeba dorobić.
...
Kod: Zaznacz cały
#if defined(RX_RSSI)
case 2:
{
static uint8_t ind = 0;
static uint16_t rvec[RSSI_SMOOTH], rsum;
int16_t r = analogRead(RX_RSSI_PIN);
#if RSSI_SMOOTH > 1
rsum += r;
rsum -= rvec[ind];
rvec[ind++] = r;
ind %= RSSI_SMOOTH;
r = rsum / RSSI_SMOOTH;
#endif
r -= ((RSSI_ZERO*1024L)/100L); // RSSI_ZERO, RSSI_SCALE in range 0..100
if((RSSI_ZERO < RSSI_SCALE && r < 0) || (RSSI_ZERO > RSSI_SCALE && r > 0)) r = 0;
analog.rssi = ((int32_t)r * 100L)/(((RSSI_SCALE-RSSI_ZERO)*1024L)/100L); // analog.rssi in range 0..100
break;
}
#endif
Kod: Zaznacz cały
#define RSSI_ZERO 0 // Setup with value show at transmitter OFF
#define RSSI_SCALE 100 // Setup with value show at transmitter ON
Chyba...pbrys pisze:PS. chyba przesadziłem z tym żądają