_____ (___ ) | | _ | | ( )_| | `\___/'
_ __ | | / / | |/ / | \ | |\ \ \_| \_/
_ | | | | | | | |____ \_____/
#### ## ##### ## ## #####
_____ | _ | | | | | | | | | \ \_/ / \___/
IMPORTANT: enter the case-INsensitive alphabetic (no numbers) code AND WRITE SOME SHORT summary of changes (below) if you are saving changes. (not required for previewing changes). Wiki-spamming is not tolerated, will be removed, so it does NOT even show up in history. Spammers go away now. Visit Preferences to set your user name Summary of change: Map sampling 1ms (best) or 2ms (good too). map_processing() every event (best), or every rev (good too) * //sensor_filt[MAP] = 2 * map_samples_summ / map_samples_count; * void map_processing(void) * { ** uint16_t t16; ** uint32_t t32; ** t16 = div_65535_x(map_samples_count); ** t32 = mult16_16(map_samples_summ,t16); ** sensor_filt[MAP] = t32 >> 15; ** map_samples_summ = 0; ** map_samples_count = 0; * } * has about 3us execute CPU time So ADC sample rate 1ms, i made every 2nd ADC reading for MAP, (exept time while WBO sampling). And average readings for trigger to trigger period. For debug purposes i have two config constants: minimum samples for averaging (=10 for now) and trigger perionds (=1 for now) http://www.vems.hu/files/MembersPage/Andrey/MapFilter.JPG Optional: Add document to category: Wiki formatting: * is Bullet list ** Bullet list subentry ... '''Bold''', ---- is horizontal ruler, <code> preformatted text... </code> See wiki editing HELP for tables and other formatting tips and tricks.