My serial interrupt routine collects all the data from the serial buffer (Controller) successfully, the data sent from the controller never exceed more than 2000 bytes.
The problem is when the controller sends large no. of bytes for eg 400 bytes, the array "RecBuffer" holds all the bytes successfully but when i look at the array RecBUffer after the interrupt routine or at the end in the interrupt routine as i posted below, The data inside the array is different, what manipulation do i need to make in order to make the content remain the same until its is over wriiten.
This above case is not the same for fewer bytes sent, the content is not altered.
i work on dos, compiler turbo c
#define ETX 3
unsigned char RecBuffer;
unsigned short count;
void interrupt (*oldport1isr)();
void interrupt PORT1INT() /* Interrupt Service Routine (ISR) for PORT1 */
unsigned int c;
c = inportb(PORT1 + 5);
if (c & 1)
RecBuffer[count] = inportb(PORT1);
printf("RecBUffer=%x ",RecBUffer);// to look at the array content at the end of data collection
} while (c & 1);
many thanks for any help