Digitech XC4134 Serial to Ethernet

PiCaxeDB

New Member
Hi all
I could do with some advise on if it is possible to program a Picaxe 28X2 via this device .

-Link to Unit -
I have data coming from the Chip to the 'Serial Terminal' on the PC one great step for me.
If I can get the link to program as well would be fabiolus, I can't get it to work.
Any tips would be great.
 

AllyCat

Senior Member
Hi,

PICaxe programming is initiated by "Break Signalling" and sadly many "RS232" adapters (USB, Bluetooth, etc., and possibly your Ethernet device) do NOT support it. Unfortunately, the data sheets rarely specify if Break Signalling is (or isn't) supported, so you may need to do a practical test to find out. FWIW, I never got a (useful) reply from the "Technical Support" of a manufacturer of a similar Bluetooth device. :(

In principle, you only need a multimeter (or even a LED) to test if the Break Signal is passing through the system (from the PICaxe Editor).

Cheers, Alan.
 

inglewoodpete

Senior Member
The word "break" does not appear in the device's manual, so it could be a costly experiment if break signalling is not supported. I suggest you call Jaycar's support line and ask them. I have to say I have been under whealmed by their knowledge in the past :(.
 

PhilHornby

Senior Member
Any tips would be great.
There is a discussion here, of various possibilities - including my own thoughts on resurrecting the supplied "Serial over Ethernet (Program Picaxe connected to another computer over internet)" functionality.

Use of a Raspberry Pi as the go-between looks the most likely to succeed (to me). The initial discussion here seems to have a morphed into a workable solution, also documented here by forumite @SteveDee
 

hippy

Technical Support
Staff member
Use of a Raspberry Pi as the go-between looks the most likely to succeed (to me).
That would be my opinion as well, or something similar.

To have remote programming, so one can keep using Windows and PE6, there are three parts to the solution; something which runs under Windows and presents itself as a Virtual Serial Port which puts what is sent to it on ethernet, and returns what it receives back. Something on the other end which bridges the ethernet to a PICAXE chip. Plus of course a protocol so both sides can communicate what they need to.

It's the Virtual Serial Port for Windows which usually proves the biggest challenge. There are solutions but most are commercial or convoluted. The simplest would be two Pi, one at each end, and a separate connection between the two. The PC-side Pi could present itself as a USB Serial Port which avoids needing any additional Virtual Serial Port software.

But the real problem is how to power-cycle the PICAXE if one needs to perform a Hard Reset. That's going to require additional power-switching circuitry at the other end.

Years ago I did get remote programming working with an 18X which has a Reset pin but it wasn't that successful in practice. I never pursued it after that as not worth the effort involved.

For the OP; the best bet, as suggested, is to look at the output from your ethernet to 9-way module and run the PE6 Serial Cable Test. That should reveal whether it supports Break Signalling or not.
 

PiCaxeDB

New Member
Thanks everyone much appreciated.
Hippy I did the cable test and the "Break" does not come through.
Another Question?,
Using the old Picaxe serial cable 9-way ,connected to the AXE401 shield board, I connected the scope to pin 3 on the "9-way" and found it out puts -6v +6v. I'm worried this is not good for the picaxe28x2 chip.
Has not damaged the Picaxe yet but i'm not game to use it now I found that. get the -6v +6v when I send from the PC to AXE401.
In trying to solve the -6v I connect a diode from pin3 to ground, that took out the -6V and left the +6v sigional, but it's still above what I think is Ok.

I'm experimenting with an "USB RJ45 Extension" Link Here .
Same deal serial connection Ok but no program download. Tested indoors with 30m of Cat5e cable and program down load worked fine, Picaxe and PC are 30m apart. Off to get a Cat6 cable and see how it goes.
Using the link to trouble shoot and program my Sun tracking Sola panels details here "Link to Panels"
I'm able to do what I need with "USB RJ45" I just load the Updates to my laptop and go out and update
 

lbenson

Senior Member
Note that the standard interface, with 10K to 0V and 22K to the programming in pin, is designed to protect the PICAXE from the voltages from the original "RS232" serial voltages of +/- 25V or sometimes +/- 16V, so your +/- 6V should be fine if you have those resistors in place.
 

PiCaxeDB

New Member
Note that the standard interface, with 10K to 0V and 22K to the programming in pin, is designed to protect the PICAXE from the voltages from the original "RS232" serial voltages of +/- 25V or sometimes +/- 16V, so your +/- 6V should be fine if you have those resistors in place.
Thanks lbenson
 

hippy

Technical Support
Staff member
Using the old Picaxe serial cable 9-way ,connected to the AXE401 shield board, I connected the scope to pin 3 on the "9-way" and found it out puts -6v +6v. I'm worried this is not good for the picaxe28x2 chip.
As lbenson notes the PICAXE download circuit was designed for RS232 and should be fine so long as the 22K is in place.

+/-6V through 22K is only +/-270uA which is not enough to damage the silicon despite the voltage notionally being out of spec.

This is what I have used to block negative voltages but not sure how well it would work over the distances you have, whether the diode would be best at the home side or remote PICAXE side ...
Code:
             |\ |           ___
RS232 TX >---| >|-----.----|___|---> PICAXE Download Serial In
             |/ |    .|.    22K
            1N4148   | |
                     |_|10K
                      |
RS232 0V -------------^------------- PICAXE 0V
 

inglewoodpete

Senior Member
As lbenson notes the PICAXE download circuit was designed for RS232 and should be fine so long as the 22K is in place.

+/-6V through 22K is only +/-270uA which is not enough to damage the silicon despite the voltage notionally being out of spec.

This is what I have used to block negative voltages but not sure how well it would work over the distances you have, whether the diode would be best at the home side or remote PICAXE side ...
A series diode is unnecessary to protect against negative voltages on PIC input pins (with the exception of the pin used for Reset and Vpp). Each I/O pin has built-in protection diodes between the pin and Vss and Vdd. (Practically) any voltage can be connected to an input pin via a suitable series resistor. It is the current limitation of the diodes that determines the resistance required.

From what I've read in Microchip's documentation, the current limit of these protection diodes is around 20mA. Not that I'd be trying to pass that sort of current in or out of and input pin: currents of this order will impact the supply rails and consequently the stability of the PIC.

The inbuilt protection diodes protect both input and output pins. Just look at what happens when an unquenched inductive load (Eg a relay) is connected to a PIC: the protection diode/s do their job of preventing permanent damage but the PIC can reset/restart.
 

bpowell

Senior Member
If you're looking to reliably communicate with a PICAXE that is local to you (but a far distance from the PC) and you have ethernet cable out there already, look at 232/422 converters...I picked up a few from ebay for a few bucks, and they work great. I have a 20x2 about 80 meters from my PC, and I'm able to communicate with it, program it, etc. as if it were sitting next to me.

As hippy pointed out, there is no power-cycling capacity ... so I need to be careful to not "lock myself out" but worst-case, I trudge out tot he pump-house and power-cycle it ... haven't had to yet.

I've tested successful send/receive up to 78.600 baud (which is the fastest I can "sertxd" at 64Mhz ... time permitting, I'll probably throw a raw PIC out there that is programmed to send data at various baud rates up to 2Mb/s just to see how fast I *can* send data .... but my proof of concept PICAXE is working just great across these converters and CAT5e cable ... only needs 2 pair of wires!
 

hippy

Technical Support
Staff member
A series diode is unnecessary to protect against negative voltages on PIC input pins (with the exception of the pin used for Reset and Vpp). Each I/O pin has built-in protection diodes between the pin and Vss and Vdd.
Even the MCLR / Reset pin has a clamping diode to 0V / Vss, but best to check the data sheets.

The main reason I recall for actually blocking negative voltages is they may cause ADC readings to be offset upwards from 0V.
 
Top