??? 12/24/10 17:11 Read: times |
#180278 - nobody has suggested Responding to: ???'s previous message |
what I mean is when you have 64kbyte of program to play about with and compilers are so cheap(certainly for the AVR), it makes sense to use a compiler, in fact I have done some test's on the '51, I wrote my own bit banging routine for the MCP3302 12bit+sign adc, at the start of the routine I set a port pin low and at the end of the routine set the port pin high and then measure aquisition speed on a scope, I wrote the same code using my compiler, and although the asembler was faster it was very marginal, not much difference in speed.
1) nobody has suggested that it does not make sense to use a compiler 2) a thing as simple as what you mention is NOT a valid compiler/assembler speed comparison, any decent compiler can convert bit=1 to one assembler instruction. 3) complicated calculations withs multiple accesses (such as DSP) would give a valid compiler/assembler speed comparison Now the interesting thing is on the AVR, the integral 10bit adc can be made to free run and interrupt the processor when the conversion is finished, great idea because the processor is not tied up bit banging for a value, the problem is, I'm experiencing chronic chross talk between channels, when used in differential mode. 1) most, if not all integral adc can "free run " and give interrupts when completed 2) crosstalk is more likely to be a problem a) with integral adc (analog on a digital die) than on a separate ADC b) with your ameateurish flying lead prototypes Erik |