Problems downloading to Picaxe

Innes

Member
I am having problems downloading to some new picaxes. I think I have exhausted virtually all possibilities, so I thought I'd explain the problem together with what I have tried with the hope that someone can spot something obvious - or maybe not so obvious...

I have three picaxe 18X chips and one picaxe 18 (which came on the 18pin standard project board (CHI030).

When I started experimenting (I'm new to picaxe last week!), I was using the 18 on the project board and downloading without any problems - I think I had one memory verification error in the many (hundreds?) of downloads that I did. This is still the case, so I'm happy with 18.

I then put an 18x on the project board and that was also OK, but I was having maybe 5% memory verification errors on download.

I then built a breadboard circuit (including download components) for further experimentation and the above results were pretty similar - say 99%+ success for the 18 and 95% success for the 18x.

I then tried a different (brand new straight out of anti-static container) 18x on my breadboard and was getting more like 99% <i>failure </i> on downloading the software, making it unusable. The same is happening with a 3rd brand new 18x which I put onto the CHI030 project board.

To summarise:

18 - download success 99%+ of the time
18x(1st) - download success 95% of the time
18x(2nd) - fails download 99%
18x(3rd) - fails download 99%

Notes:

I have tested the above on both the CHI030 project board and my own breadboard circuit and the results are repeatable.

I am using a USB to Serial adaptor provided by Tech-Supplies. I have tested using the download cable supplied with the project board and also with my own home-made download cable with no difference in results.

I have tested using 3x1.5V batteries (brand new and also replace during testing). I have also tested with a 4.5V bench PSU and a home-made 5V regulated supply (based on 7805 regaultor).

I can't think of anything else to try, and am now coming to the point where I think the 18x chips are at fault. Unfortunately, my experience of picaxe is very limited, so I have no idea if these download problems are normal or not.

Finally, it's worth mentioning that I wear an anti-static wrist-strip whilst exeriementing!

I'd really appreciate comments or assistance as frustration is prevailing.

Thanks in advance.
 

manuka

Senior Member
First - welcome! 2nd- top marks on your VERY lucid insights. Don't we wish all Forum cries for help were so well outlined...

18Xs are usually bullet proof, so unless you've got a rare bad batch (unlikely given Rev.Ed's QC I personally noted on a recent Bath visit) it still must be something trivial. Can you perhaps take a pix of your layout &amp; upload (perhaps to free host), as the Forum's collective wisdom may then immediately spot an &quot;Aha&quot;.

You can always cut your teeth on the 08M, perhaps in a layout like =&gt; <A href='http://www.picaxe.orcon.net.nz/bread08.jpg' Target=_Blank>External Web Link</a>
 

hippy

Technical Support
Staff member
Not sure what the problem is. If the results are repeatable it does look like the problem is specific to the chips rather than to the hardware they are used in.

The other possibility could be that the two which are being stubborn are executing some code which makes them resistant to downloading. You can try holding them in Reset until the download splash screen says &quot;Connecting to hardware...&quot;, and if that doesn't help, turn the power off until that point, to see if it helps.

The only other thought is, what voltage the USB to Serial converter puts out. It could be for those particular awkward chips that whatever gets through the 22K on download is marginal, but then you also said you'd tried your own lead. Is this from a laptop or from a desktop PC ?
 

Technical

Technical Support
Staff member
The chip cannot be at fault if it downloads at all, if faulty it would never download! The fact that you can download sometimes means the fault is elsewhere.

A common fault is a missing pull up resistor on the reset pin.

If not this, it is almost certainly a power supply or decoupling issue. The 18X is more voltage intolerant than the 18 (which will work at 6V), however it should download almost always at either 4.5V from 3xAA cells or 5V regulated.

What happens when you use the hard-reset procedure (see manual). Does your program contain blocking commands such as serin?

Where is your power supply connected on the CHI030?
 

Innes

Member
Thank you for you responses. Some great suggestions there, and no doubt ones that will come in useful <i>when </i> I experience further problems in the future!

The problem is one that was such a pain to confirm that I didn't want to try it until I had some other suggestions...

Hippy wins first prize for suggesting the USB to Serial adaptor! Yes, I had tried my own lead, but it was still connected via the USB adaptor into my <i>laptop </i> ! I don't have a desktop PC in my workshop, so I had to get the picaxe kit into my office, install the picaxe editor, configure the serial port and... success; the download has worked every time so far.

This now leaves me with the problem of getting a PC into the workshop. I have all the bits but it's somewhat annoying to have to build a PC just to do fairly infrequent serial downloads! Does anyone have any suggestions as to what could be done with USB adaptor (or other areas of the circuit) to resolve this problem which I assume is a power issue.

Are Rev-Ed/Tech-Supplies aware that the USB adaptor may not work 100% with some laptops? Having said that, it might just be my laptop (Acer 1350) asI only have a sample of one!

Thanks again; I'll keep you updated if I experience further problems. Time to build that workshop PC.
 

Technical

Technical Support
Staff member
We have sold tens of thousands of the USB adapters and not aware of any major issues, so sounds like it a USB power supply issue with your laptop. Some laptops do power down the USB port when in sleep mode, try removing and reinserting the adapter in this situation. Also make sure the adapter is directly in the laptop, not in a USB hub.
 

thelabwiz

Senior Member
USB -&gt; Serial adapters that use the Prolific converter chips seem to work better than some of the others (whether interfacing to the PICAXE or to Palm PDAs).
I've had no problems with the 08M or 18A (haven't tried an 18X yet) using a Prolific-based USB-&gt;serial adapter on a Compaq Presario 900 series laptop.

John
 

Innes

Member
I'll try the USB adaptor in a couple of my desktop machines. The laptop has been running off a mains adaptor and there are no power-saving settings currently activated. However, I do understand that it may simply be a quirk with my laptop USB ports. I'll let you know how the USB adaptor it gets on with my desktops.

Incidentally, I do appreciate the good technical support from the supplier; it's a rare thing these days.
 

Innes

Member
I've tried a few downloads using the USN to Serial adaptor on one of my desktops, and it is working perfectly.

It looks like it's my laptop's USB port that is causing the problem.

I am aware that 'Technical' suggested that I should not be using a USB hub (which I am currently not doing!), but I'm wondering if there is any chance that a <i>powered </i> USB hub might assist in resolving the problem, or is it likely to exacerbate it? I really could do with using the laptop in my workshop. I might have a powered hub lying around, so I might give it a try.
 

manuka

Senior Member
No problems here with the bullet proof Rev.Ed USB-D9 adapters either. USB ports are 5V at up to 500mA &amp; will shut down if overdrawn, so if a hub was in use I'd ponder you may be close to this limit.Running battery or mains? What brand laptop ? A picture via &quot;tinypic&quot; <A href='http://tinypic.com/' Target=_Blank>External Web Link</a> etc may help us.

Edited by - manuka on 05/09/2006 12:19:48
 

Technical

Technical Support
Staff member
A <b>powered </b> hub is worth a try if you have one lying around anyway. An unpowered hub, without anything else attached, should also work. The problems occur when the unpowered hub supplies a number of devices.

Also make sure you have the correct driver installed for the version of Windows you are using on the laptop. You can download the drivers from the software page of this site.

Edited by - Technical on 05/09/2006 12:30:16
 

Innes

Member
I think I may have already mentioned that the laptop is an Acer 1350 and that it is running off the mains. If I can find a powered hub lying around, I'll give it a go (this is highly likely considering the amount of old kit/junk I have in my workshop).

Failing that, I'll just have to build another PC for downloading.

Incidentally, I now have no doubts that the USB adaptor is definitely <i>not </i> at fault, as it is downloading to the picaxe perfectly on my desktop PCs. It looks like I have just been unlucky with my Acer 1350 laptop.
 

marcos.placona

Senior Member
I use a Compac laptop using the USB cable and and it downloads like a charm. If you power your laptop on the mains, do you notice any change?

Cheers
 

manuka

Senior Member
If this laptop is giving Picaxe USB-serial cable woes, then it's likely to be suspect on other USB applications too. In the past I've rustled up a simple USB cable hack allowing demand current &amp; terminal voltage to be checked with various loads. It's been particularly useful when comparing the transmitter drain on WiFi adapters.

But see if you can borrow something like this <A href='http://www.passmark.com/products/usb2loopback.htm ' Target=_Blank>External Web Link</a> for more professional tests. Naturally testing software abounds ( Google...), although loopback plugs may be needed too. This could make a good Picaxe project in fact (in spite of Picaxe MHz versus near GHz USB 2.0 ) - any thoughts? At least you'd not need to worry about yet another power supply.

Edited by - manuka on 06/09/2006 08:54:47
 

Innes

Member
Manuka, thanks for your reply. In this instance, it's not worth me spending any more time on the USB issue. I've set up an old (VERY old!) PC in my workshop which is just enough to run the Picaxe editor under Windows XP, and the download works fine using the built-in com ports. As it happens, we've just decided that my wife is going to 'inherit' my old Acer laptop, and it seems to work fine with the USB device we have use so far, e.g. mice, keyboards, Bluetooth dongles and USB memory sticks, so I'm happy enough. To be fair, the Acer laptop is over three years old now, and it's still works very well (although battery life is now poor).

It's handy to know about the USB loopback tester though; it may come in handy in the future.

Thanks to all for your input on this issue. The side-benefit of my laptop USB problem is that I now have a desktop PC in my workshop, which will no doubt come in handy for other projects.
 
Top