Cannot get anything from USB to UART programmer

Firstly, got to say I feel there is a serious lack of documentation about using the USB to UART programmer. That aside, I’ve reached the point of binning the whole emon system because after a week of evenings I cannot get the UART programmer to work.I suspect is it a duff board, so I’m hoping someone can confirm what I’m thinking.

Firstly, I have an emonPi and 3 emonTx boards. The emonPi is working and I have one of the emonTx boards connected to it, so from this perspective (I haven’t really configured anything yet, no point if I cannot get all 3 boards talking to the Pi).

So I need to set the node ID on one of the boards at least via the programmer.

I’ve spent a fair bit of time reading as much info as I can find, and no matter what I do, I get no output at all from the board. I have tested this on 2 PCs that I know are good, as they both talk to other serial devices over the USB ports.

I’ve installed the Windows 10 drivers for the UART board.
I’ve installed the Arduino IDE

When I first tried to get the UART board to talk to the PC, the blue light came on, on the board, but there was no serial port being created on the PC, nor was there the usual “bing” to indicate something had been plugged in. After 2 evenings, I tried a different USB extension cable to the one supplied, and suddenly there was my serial port in device manager. Upon checking it was a new port (Not Com3/4/5) that has not been used by any other USB to Serial driver, so from that perspective all should be good.
Now plugging the UART board into the cable gets the Windows “bing” to say a device is connected.

Next another “beef”. There is no diagram I can find to say which way up the UART board is supposed to be plugged into the emonTx. I’ve tried it both ways up and I get nothing.

The instructions state to not plug in any power source to the emonTx when the UART board is connected… How does it boot then? I have tried without, and then with a mini USB power soirce BTW.

I’ve used serial since about 1980, so I think I know my way around it. But using PuTTY, Reflection and the Arduino IDE, I cannot get any response at all when the UART board is connected to the emonTx. Nothing, Zero, Zilch… and YES, I have messed with the baud rate and the NL/CR settings and still I get nothing at all.

The UART board looks somewhat worse for wear though, nothing a clean and tidy as the photo of a board in the “shop”.

Am I doing something wrong or is the board as dead as the USB cable that came with it?

Answers on a (electronic) postcard please, because I’m tearing my hair out and I didn’t have too much to begin with!

Did you find the Wiki emonTx3 User Guide — OpenEnergyMonitor 0.0.1 documentation?

Most common error when using the emonTX is that the TX and RX lines are labeled the wrong way round (when compared to convention). The programmer from the shop just plugs in. @Robert.Wall will tell you exactly but IIRC you connect tx-tx and rx-rx.

I’ve had loads of issues in the past with the Windows drivers for the programmer.

It takes it’s power from the programmer.

[edit]

Was this supplied for the programmer (there is an option on that page) or the one to power the EmonPi? It is possible the EmonPi cable is power only. @glyn.hudson or @TrystanLea could say.

As Brian says, you don’t need any extension between the programmer and the emonTx. It plugs in, LED down, so that the “GND” connection is nearest the RJ45 socket and the antenna.
The answer to

is “GND” is marked both on the programmer and on the emonTx pcb. None of my emonTx’s are in cases, so I don’t know whether the front panel is marked to show the orientation. but now I’ve found a case, in fact I see the acrylic panel is engraved “GND” at that end.
If you do find you need a ribbon cable extension, then the pins connect 1-1 with no crossovers.

Where did you get the programmer and cable from?

OK… So about the only combination that it seems I did not try was the programmer board upside down, with no power to the emonTx, no extension cable (programmer plugged awkwardly but directly into a USB port) and the Arduino IDE (Reflection also works fine but so far no luck with PuTTY.
Now I just need to work out how to get the Pi to see the extra boards!
To be honest, a picture on the Wiki page showing the programmer connected would have been immensely useful, as although with the benefit of hindsight and your comments, the letters GND on both the programmer and the emonTx are difficult to see, especially if you’re older that 8 years old and even with 4 eyes, it’s not so easy to see the small print :slight_smile:
The USB extension cable is just that. It was a cable supplied in the same bag as the programmer (I bought everything from your shop BTW, for the very reason that I didn’t want to introduce potential 3rd party quality issues) with a male and a female USB A connector to simply extend the USB port away from the PC.

To prove that I did try everything I could to not ask the question above, this link is broken…
Github PDF: Configuration of RF Module & on-line calibration

So tonight I’ll try to get all 3 emonTx boards talking to the emonCMS system…

BTW, if I have 3 emonTx boards all connected to the same consumer unit, how closely can I stack them to each other? If I stack them on top of each other with 25mm standoffs for example, can you see that causing any problems with the sensors (although they are touching each other in the consumer unit anyway), but more importantly, is there likely to be any interference between the radio waves transmitting back to the Pi?

@Gwil - seems there might be an issue with the cable supplied. Could you possibly connect up the programmer to an EmonTX, take a photo and publish it to the shop page please - this has come up twice recently.

Was this link on the Wiki? Try GitHub - openenergymonitor/EmonTxV3CM: EmonTxV3 Continuous Monitoring Firmware (Default shipped EmonTxV3 firmware) and the file is listed there.

Stacking the boards near each other shouldn’t be an issue. What will likely be an issue is the
need for each antenna to be spaced a minimum distance from the other antennas.
That distance should be ¼-wavelength or more. (½-wavelength minimum would be better)
At 433 MHz, ¼ wave is approximately 173 mm. At 868 MHz it’s approximately 86 mm.

1 Like

Can you try that cable again, please? If it still doesn’t work, email [email protected] and refer to this thread.

The reason I asked is we know some “low-cost” programmers don’t actually work.

Assuming you have modern emonTx’s with the modern default sketch in each, they will come set up as Node 15. You must have unique node numbers in your system, else the data gets mixed up. You can change the second to be Node 16 via the DIP switch on the p.c.b. (Look at the Wiki, I haven’t even taken the protective film off mine!) or do as I do and set it via the Arduino IDE and the on-line configuration settings as it powers up. Then that should pop up in emonCMS on the inputs page as Node 16.

The third one is fractionally more complicated. You must change the NodeID programmatically (let’s say it becomes Node 17), and having done that, you then need to make a copy of the Node 16 definition in emonhub.conf (via your web browser: Emonhub → Edit config) and call it Node 17. (Just check that you don’t have another Node 17 in the cofig file.) When you do that, the data from that one should also pop up on the Inputs page.

C.t’s touching isn’t ideal, because the magnetic field in one could just induce a field in the second that shows up as a spurious current. It’s not a measurement I’ve tried to make - but I have put a current-carrying bundle of wires (equivalent to 100 A) next to and touching a c.t., but not through it, and it measured as 160 mA (about equivalent to a 40 W load on the intended circuit).

I went one better than a photo. I have a couple of male and female USB connectors with pins on the individual cables. Plugging the male into the female USB and putting a test meter across each pin combination, I got closed circuits on the red-to-red, the black-to-black, white-to-white & green-to-green. Every other combination was open circuit as you would expect. I then plugged the USB test rigs into each end of an Amazon basics USB extension cable and got the same result.
When I plugged in the extension cable supplied with the programming board I got open circuit on the red wire, so pin 1, which is supposed to be the +5V. So this is the problem.
I then plugged the programming board into the amazon cable (which I know works as I used it this morning successfully) and the blue LED came on. Using the cable supplied with the board, there was no blue LED.
Hope that helps

OK, that could be an issue. Especially as the fly leads on the CT sensors are not long enough to allow that degree of separation with 3 emonTx boards. If there is a problem, would using an extension for the antennas work? I’m not too familiar with radio (although it seems I am learning a lot!).

So you’re saying Pin 1 - Pin 1 (the +5V) in the Shop-supplied lead is open-circuit? Email the shop.

(Brian was suggesting to Gwil, who works for OEM/Megni, that a picture showing how to connect the programmer is necessary.)

Yes, pin 1 is open circuit.
And YES, a picture to show how to connect the programmer would have saved me some time because I would at least have known I had connected it correctly and the problem was elsewhere.

Email has been sent

1 Like

Short answer, yes.

This should give you an idea of what’s needed and an example of what one result looks like:
https://openenergymonitor.org/forum-archive/node/6238.html

Thanks Gents,

Help much appreciated.

All 3 emonTx boards configured and I have 11 inputs (10 x MCB and 1 x incoming feed) connected. The boards have been recognised by the emonCMS system and in theory, the inputs are being received

The 3 emonTx boards are definitely less than 173mm apart currently, although maybe 150mm. I’ll experiment with moving them closer because I’m keen to stack them together to save space.

Happy to close this thread now. I have other questions and will create new threads later in the week

1 Like