Hi, I have a firmware for a 8051 based device that works flawlessly with the real hardware. However, when I'm debugging it I have lots of problems with the serial port simulation and I'm often losing characters in the messages. I ruled out the cable as the problem and also the software I'm using to send the messages (the exact same that works fine when interfacing with the real device. Can you give me any pointers to what the problem might be? I'm using this INI file for the communication:
MODE COM3 19200,0,8,1 ASSIGN COM3 < S0IN > S0OUT S0TIME=1
My device communicates using 19200bps, 8 data bits, no parity and 1 stop bits.
Any help will be greatly appreciated
I just gave up on simulation and use the target instead. Does your 8051 have on-chip debug?
If not, For the purpose of this exercise, could you switch (temporarily) to an 8051 that does have on-chip debug?
can you adjust your sending device to put a (small) delay between characters?
can you put something between the device and the PC to buffer the data and add such an inter-character delay?
Uhm, I tried on-chip debug and it works horribly. Often when debugging the code if I try to use breakpoints the code just goes to invalid positions. The manual says that could happen sometimes, but my experience is that it happens so often that the board is just an expensive paperweight. I think I'll try with the option: can you adjust your sending device to put a (small) delay between characters? It appears to be the most feasible option for me.
Thanks a lot for the pointers Neil!
I have a firmware for a 8051 based device then Uhm, I tried on-chip debug and it works horribly.
WHICH DERIVATIVE ARE YOU USING
these days "a 8051 based device" does not say anything
Erik
Heh, no secrecy, it's a Dallas DS5250-F
I don't even bother to mention it because with all those ridiculous NDAs no one really can discuss much about it. Usually when I ask about it all I get is "Oh, the NDAs".
Are they "Non-Debug Arrangements" ?
;-)