From: Tim L. <tl...@ve...> - 2003-04-26 15:39:54
|
Roger, I agree with you that a delay in setbaudrate might be necessary, and it would be preferable to doing retries. Unfortunately, I can't get the serial communications to fail at the moment. This is with no delay after the baud rate change, and no retries in the routines. Usually, it would fail about 1 of 5 times of GetPhoneData. I guess I'll wait for the weather to change, and try again. However, the open comm port started to fail (on both attempts). I added 'time.sleep(1)' before the 2nd attempt to open, and that seemed to fix that. Tim > I am working on adding the code. The two attempts to open comm port > are in CVS now. > > I've got a theory that the other problems are caused by the host > computer > changing baud rate too quickly. However I never get comms failures > myself > so I can't test it. > > Could you please 'import time' at the top of commport.py and > then at the end of setbaudrate add 'time.sleep(1)' > NB this needs to be against the CVS source, not your new routines. > > Please tell me if this makes any difference. I would prefer it over > the solution of sending stuff up to twice since that could fail in > other ways (eg if the command being sent is to delete a file but the > first worked but we fudged dealing with the response then we would > send a second command and get a file not existing error). > > Roger > > > ------------------------------------------------------- > This sf.net email is sponsored by:ThinkGeek > Welcome to geek heaven. > http://thinkgeek.com/sf > _______________________________________________ > Bitpim-devel mailing list > Bit...@li... > https://lists.sourceforge.net/lists/listinfo/bitpim-devel > |