Speeding up your AXE027 Download

administrator

Administrator
Staff member
On my 2 computers (XP Home and Win7/32), the Prolific is consistantly 3 times faster when programming 3725 bytes into 28x1s - 20 seconds vs 1minute+. Refer to separate thread.
We have had a few questions like this recently, so wanted to clarify how you can speed up the AXE027 PICAXE USB Cable download if desired.

The AXE027 cable uses the FTDI USB<>serial chipset, which is generally considered to be one of the best quality and most reliable USB chip/driver combinations available. We would very closely with FTDI to ensure the Windows drivers are the best possible.

The default FTDI driver setting includes a 16ms 'latency' on data transfer. The technical reasons behind latency are quite complicated, but latency is basically added to increase reliability of the USB<>serial conversion system, which obviously works, as the AXE027 is extremely reliable!

Latency does however slow down data transfer, making a PICAXE download slightly slower. Prolific drivers appear to use no latency at all, which is why they do a quicker download. (As a side note we also have an increasing number of reports of 'cheap' USB adapters that are supposed to use a Prolific chipset but actually have a fake chip inside, and hence do not work at all with the PICAXE system).

But the good news is that, if you want to, you can change the FTDI latency to anything between 1 and 255 ms (16 is the default) via the FTDI driver settings. By changing to 1ms you can at least halve your overall download time. But be aware this may reduce the reliability when transferring large amounts of data.

To adjust the AXE027 latency:
1) Right click over the 'AXE027 PICAXE USB' listing in Control Panel>Device Manager>Ports (COM & LPT).
2) Click Properties
3) Select the 'Port Settings' tab and click the 'Advanced' button
4) Change the Latency setting from 16 to the desired value (1ms is the fastest possible), then click OK

We welcome feedback as to how people get on with different latency settings on different versions of Windows.
 

westaust55

Moderator
Thanks for this information.
I will try out some alternate setting in the near future (once back home).
This will compliment the #nodata and #notable directives to speed up downloads for X1 and X2 parts.
 
Last edited:

inglewoodpete

Senior Member
Thanks for the feedback Technical.

Hopefully, over the next 2 weeks, I'll have plenty of opportunity to do some comparative testing. I'm flying to Beijing tonight for an exhibition of Silent Barrage, which has a network of 38 PICAXEs.
 

srnet

Senior Member
Is changing the latency safe ?

i.e. if it causes download errors or corruption of data, will these always be detected and reported ?
 

PieM

Senior Member
My test on windows seven: ( 900 bytes on 28X2 with no data and no table) 12 s before, and 6 s after with 2 ms latency.

Many thanks. I'll translate on French forum :)
 

geoff07

Senior Member
USB settings

If you need info about USB settings and how they can be adjusted even when the device is unplugged, this document http://www.syscompdesign.com/AppNotes/usb-com-port-debug.pdf gives some info especially about a useful environment variable.

My own problem, on a little xp netbook I'm setting up for use as a portable download machine, is that, having worked fine initially with the AXE027, it now believes that COM4 is assigned to the AXE027 even when it is unplugged, and won't recognise any replugs. So I'm looking for a way to safely clear the existing USB setting. Using the environment variable in this article I can at least see it. Any ideas on how to clear an XP USB assignment welcome.
 
Last edited:

Technical

Technical Support
Staff member
This is normal behaviour if you have the hidden/ghost USB devices visible by setting the environment variable.
Windows basically 'reserves' COM4 for the AXE027, even if it is not connected. This is why if you always plug the AXE027 into the same USB socket it will always come back with the same virtual COM port number (COM4 in your case).

To remove a driver right click over it in Device Manager and select uninstall.
 

geoff07

Senior Member
I was being a bit cautious about removing USB assignments because a lot of the innards in the box are USB and I didn't want to get to the point of having to reinstall. But all fine now, thanks.

As I typed this a little yellow window popped up in the corner saying 'auto-saved'. I wonder where to?

Latency adjustment:
Dell Mini 910, 1GB, XP SP3, AXE027
1532 byte download into 28x2, no-data, no-table
Latency 16mS: download time 26 seconds
Latency 2mS: download time 14 seconds, no errors
 

lazarus

New Member
Thanks!

1ms is indeed a lot faster. But my first tests show that the programmer does not always detect the picaxe at 1ms. This seems to go better with a more stable power supply (battery + cap).
 

westaust55

Moderator
Two part reason for this post:

1. Bump the thread since I feel the information is useful to many members.

2. Using Win XP SP3 and having taken a slightly conservative approach by change the latency setting from 16 to 8,
with for example a 3278 byte program into a 40X1 the improvement is down from 54 seconds to 30 seconds for program download.
So here I can confirm that even without being as radical as setting 1 msec latency, I have experienced no problems with downloads after several months.
 

RonCzap

Member
Two part reason for this post:

1. Bump the thread since I feel the information is useful to many members.

2. Using Win XP SP3 and having taken a slightly conservative approach by change the latency setting from 16 to 8,
with for example a 3278 byte program into a 40X1 the improvement is down from 54 seconds to 30 seconds for program download.
So here I can confirm that even without being as radical as setting 1 msec latency, I have experienced no problems with downloads after several months.
Is there any impact on the reliability when using the Serial Terminal at higher baud rates, e.g. #terminal 9600 or 19200 or 38400?
 

Goeytex

Senior Member
Using the FTDI Chip (AXE027) I have had no problems with the latency set to 4.
I have never had any problems with the FTDI /AXE027.

I also use a Silabs CP2102 based adapter and on occasion, (but very rarely) get
a memory verification error. (Always at byte 511 on a 08m2). It has no latency
adjustment capability in Windows.
 

hippy

Technical Support
Staff member
Is there any impact on the reliability when using the Serial Terminal at higher baud rates, e.g. #terminal 9600 or 19200 or 38400?
There generally shouldn't be and I've been using a "1" setting for latency for ages now and haven't noticed any issues in practice.

The latency issue is a bit like having a human chain throwing packages along the line and determines how long packages accumulate for before passing them on and can affect how the end of the line stacks those packages up. Depending on how quickly packages are being created ( text characters ) and how quickly the stacker receives them ( terminal display ) determines how evenly timed or in bursts those characters are shown but it's probably not even noticeable in practice.
 
Top