Proving emonTx is functioning after build

My objective is to prove that the emonTx with RF board is functioning correctly before I move forward

I have very carefully built my emonTx, following to the letter on a clean build WinXP laptop with OEM.org FTDI adapter & cable the instructions here using the 'blink' test programme:  http://arduino.cc/en/Guide/windows

I have a blue LED lit solid on the FTDI board but didn't see any Tx/Rx LEDs light when uploading to the board

I appreciate that I'm probably not going to see the emonTx LED blink because it's on a different pin but I do get 'Done uploading' in the bottom panel of the Arduino IDE.  I realise also that I can probably change the int led = # to get the emonTx LED to blink but haven't the confidence to do that yet ahead of ensuring that it is at least working.

Does that mean that it's accepted the sketch?

I couldn't find anywhere here or generally how to remove that or any other sketch ahead of loading the emonTx software.

I believe I am practically competent with electronics (broadcast, amateur radio, IT etc.) but have minimal knowledge of programming but willing and hoping to learn from this and other projects.  My main aim is great energy monitoring - and control for my business building and home.

In anticipation thank you for your help.

Thank you.

Steve

Dan Woodie's picture

Re: Proving emonTx is functioning after build

Steve,

I found it confusing that the FTDI can attach to the board two ways (the connection is not keyed or labeled). I initially started with the FTDI very bright blue LED facing the board and it would not work. By reversing it on the header so it faces the LED away from the board it works. For even more confusion, the NanodeRF is the opposite (face the LED towards the board). Have you verified that the header is attached the right way?

Dan

Robert Wall's picture

Re: Proving emonTx is functioning after build

Welcome, Steve,

The "Blink" test program in the Arduino library won't do anything. The LED on the emonTx is on a different output, as you say. If you look at the pinout picture of the emonTx, you can see that if you change

int led = 13;

to

int led = 9;

(that's DIO9 in the picture Digital In/Out 9) it will happen (hopefully!). Try it. I don't see how you can harm anything.

didn't see any Tx/Rx LEDs light when uploading to the board  There aren't any! There might have been if you were using a serial port, but not the USB port.

Does that mean that it's accepted the sketch? Yes. You don't need to "remove" a sketch. Uploading a sketch will overwrite the old one.

Learning software.

My bible for C is of course "Kernigan & Ritchie" http://www.amazon.co.uk/C-Programming-Language-2nd/dp/0131103628/ref=sr_.... This is the standard text book. 

The normal place I point people at who want to move up to C++ is http://www.relisoft.com/book/index.htm  and that assumes you know C. Because the Arduino environment normally uses a very small subset of the language, neither are the best place for a beginner to start, nor are many of the other on-line tutorials. I'd still suggest you have both of those, and maybe Bruce Eckel's "Thinking in C++" http://www.planetpdf.com/developer/article.asp?ContentID=6634 available for reference.

However, there is this: http://www.me.umn.edu/courses/me2011/arduino/arduinoGuide.pdf which does look to be a good starting place for a beginner. It does not go as far as classes and methods that are used here, though.

I'd say get stuck in and do some hands-on learning. If you're afraid of asking embarrassing questions in the forum, PM me.

stevenma's picture

Re: Proving emonTx is functioning after build

OK thank you Dan and Robert,

Excellent, the green emonTx is now flashing!  So far, so good.  I probably could have found the pin 9 reference but I'm at work (own business) and meant to be getting on with other things :) - although this is hopefully the start of having an energy, weather, status dashboard for our business centre.

I'll move forward now on to the next steps.

Thank you again for the help and extra info.

Regards,

Steve

Robert Wall's picture

Re: Proving emonTx is functioning after build

Dan:

(the connection is not keyed or labeled)  Not quite true: Not keyed, yes, but the pins on the shop FTDI at least are each labelled. GND is one end, RTS the other, and GND is labelled on the emonTx, on the GLCD and on the NanodeRF.

It's not outstandingly obvious, especially on the emonTx, so I've put a blob of white paint on the connector housings of everything to make it easier.

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.