EmonTH working out of the box, then stopped.

Summary "emonTH suddenly, stopped transmitting temperature."

I took delivery of :

1 x Programmer - USB to serial UART

1 x RFM12Pi V2 Raspberry Pi Expansion board
(Frequency (RF): 433Mhz RFM12B (Worldwide))

1 x emonTH - Temperature & Humidity Node
(Case: emonTH Case, Sensor: DS18B20 - Temperature Only, Radio: 433Mhz RFM12B (Worldwide))

With RFM12 Pi running RFM12B Full demo (included kaku) and emonTH out of the box:

minicom -b 9600 -o -D /dev/ttyAMA0 works (shows k command)
    sees EmonTH (and something else - assumed to be local RF traffic / noise) I was getting:-

0 8 248 0 0 0 0 0 30 0 52 135 154 3 65 37 6 125 226 246
168 254 167 107 231 66 98 138 212 190 247 247 111 239 189 195 72 124 172 190 30 << assumed local RF
19 0 0 0 0 0 0 0 0 <<<<<<<<< toggle EmonTH Power
19 1 0 0 0 0 0 0 0
19 2 0 0 0 0 0 0 0
19 3 0 0 0 0 0 0 0
19 4 0 0 0 0 0 0 0
19 5 0 0 0 0 0 0 0
19 6 0 0 0 0 0 0 0
19 7 0 0 0 0 0 0 0
19 8 0 0 0 0 0 0 0
19 9 0 0 0 0 0 0 0
19 251 0 0 0 0 0 30 0 <<<< temp
185 123 239 208 31 171 53 208 152 127 85 104 208 251 124 25 26 237 236 71 154 0 << assumed local
19 247 0 0 0 0 0 30 0
187 238 197 125 128 237 146 199 94 196 187 196 142 150 154 200 177 235 189 2182
166 27 118 115 203 110 59 255 14 14 51 253 250 156 74 194 242 207 249 0 245 330
138 251 88 156 176 217 168 188 247 126 135 142 238 156 30 193 63 183 173 10 172 << assumed local
19 0 0 0 0 0 0 0 0 <<<<<<<<< toggle EmonTH Power
19 1 0 0 0 0 0 0 0
19 2 0 0 0 0 0 0 0
19 3 0 0 0 0 0 0 0
19 4 0 0 0 0 0 0 0
19 5 0 0 0 0 0 0 0
19 6 0 0 0 0 0 0 0
19 7 0 0 0 0 0 0 0
19 8 0 0 0 0 0 0 0
19 9 0 0 0 0 0 0 0
35 81 191 191 43 17 249 142 87 14 100 124 241 115 178 81 157 125 237 170 162 71
19 246 0 0 0 0 0 29 0 << temperature transmission
12 220 139 222 18 238 114 116 6 38 223 232 142 240 117 76 183 220 120 224 199 5
26 12 14 189 156 26 172 125 229 159 238 237 136 188 53 125 250 59 174 212 119 0

All reasonable.

Checked could be powered and power cycled with battery or USB to serial UART, seemed consistent.

I was just contemplating getting original source for emonTH and checking can re-program and repeat above .. AND.. the emonTH suddenly, stopped transmitting temperature.

The LED remained on. No power cycling by battery or UART would restart it (quick flash when transmitting?).

I have checked with "blink" (which blinks!) and some hacking to stop at various points in "emonTH_DHT22_DS18B20.ino"  but before going much further would like advice on other tests to perform to isolate fault - possibly hardware.. is it a candidate for return?

Richard

Schism's picture

Re: EmonTH working out of the box, then stopped.

It's not completely clear what's going wrong. If you load the stock emonTH sketch it should give one long LED pulse when you put the batteries in, then flash briefly every minute when it transmits.

Have you double checked that your Pi and emonTH sketch are using the same network group? That's all I can really think of.

Richard_Piercy's picture

Re: EmonTH working out of the box, then stopped.

Thanks for the prompt response.

Yes it did give one long pulse followed by a short pulse every minute, and send the serial data as previously described included by wireless, and send data to and respond to serial port THEN suddenly:

1.stopped wireless transmissions.

2. stopped sending or responding to serial traffic.

3. LED constantly on (suspect stopped at some point in sketch waiting for some faulty h/w?)

The eMonth can be programmed successfully with:

1. The simple "blink" test

2. emonTH_DS18B20_Test

The RF12demo fails in the same way as above.

I suspect a H/W fault on the RFu, are there other tests?

Richard

Richard_Piercy's picture

Re: EmonTH working out of the box, then stopped.

Decided to isolate what had gone wrong:

With all access to the RFu commented out in "emonTH_DHT22_DS18B20" the unit runs, sending temperature via the serial port, so the conclusion is something in the RFu is faulty and the software accessing it hangs, sounds like a return to me. (I have bought a second unit to support my development and that is fine - am about to reprogram it!)

the heavy handed commented out bits are:

/* rjp: initialisation commented out to isolate fault
  rf12_initialize(nodeID, RF_freq, networkGroup);                       // Initialize RFM12B
  Serial.println("RJP2:");  
 
  // Send RFM12B test sequence (for factory testing)
  for (int i=0; i<10; i++)                                          
  {
    emonth.temp=i;
    rf12_sendNow(0, &emonth, sizeof emonth);
    delay(100);
  }
  rf12_sendWait(2);
  emonth.temp=0;
  // end of factory test sequence
 
  rf12_sleep(RF12_SLEEP);
  */

and

/* rjp: initialisation commented out to isolate fault
  power_spi_enable(); 
  rf12_sleep(RF12_WAKEUP);
  rf12_sendNow(0, &emonth, sizeof emonth);
  // set the sync mode to 2 if the fuses are still the Arduino default
  // mode 3 (full powerdown) can only be used with 258 CK startup fuses
  rf12_sendWait(2);
  rf12_sleep(RF12_SLEEP);
  power_spi_disable();
  */

 

Comment viewing options

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