Communications error on emonpi1

After looking at the troubleshooting guide it appears that I am not receiving data from the RFM2Pi adapter as I am not seeing any messages about frames being received in the log. It appears to have stopped working after a software update (os software and emoncms update) in late June, however I am just noticing this now.

The system has been running for a few years with software updates along the way.

I am running version low-write 11.6.2

Here is the relevant lines in /var/log/emoncms/emoncms.log

2024-07-16 22:08:13,142 INFO MainThread Creating EmonHubJeeInterfacer ‘RFM2Pi’
2024-07-16 22:08:13,144 DEBUG MainThread Opening serial port: /dev/ttyAMA0 @ 38400 bits/s
2024-07-16 22:08:15,147 WARNING MainThread Device communication error - check settings
2024-07-16 22:08:15,149 INFO MainThread Setting RFM2Pi baseid: 5 (5i)
2024-07-16 22:08:16,151 INFO MainThread Setting RFM2Pi frequency: 433 (4b)
2024-07-16 22:08:17,152 INFO MainThread Setting RFM2Pi group: 210 (210g)
2024-07-16 22:08:18,155 INFO MainThread Setting RFM2Pi quiet: 1 (1q)
2024-07-16 22:08:19,157 INFO MainThread Setting RFM2Pi calibration: 110V (2p)
2024-07-16 22:08:20,159 DEBUG MainThread Setting RFM2Pi pubchannels: [‘ToEmonCMS’]
2024-07-16 22:08:20,160 DEBUG MainThread Setting RFM2Pi subchannels: [‘ToRFM12’]
2024-07-16 22:08:20,161 INFO MainThread Creating EmonHubMqttInterfacer ‘MQTT’

Can you offer any suggestions as to what I should look at next? I tried searching the code for the place that created the " communication error - check settings" but was unable to find it in github. I also validated that the serial port /dev/ttyAMA0 is still present.

Thanks,
Jason

This says it can’t get an answer when it tries to talk at 38400. Baud rates have changed over time - it’s worth trying 9600 or 57600 first, then everything in between up to 115200.

I tried 9600, 19200, 38400, 57600 and 115200 all with the same results

2024-07-17 14:55:25,230 DEBUG MainThread Opening serial port: /dev/ttyAMA0 @ 115200 bits/s
2024-07-17 14:55:27,233 WARNING MainThread Device communication error - check settings

Each time the line shows the selected data rate and the same communication error.

What does the interfacer at the start of your emonhub.conf file look like? This is my very old 868 MHz emonPi:

[interfacers]
### This interfacer manages the RFM12Pi/RFM69Pi/emonPi module
[[RFM2Pi]]
    Type = EmonHubJeeInterfacer
    [[[init_settings]]]
        com_port = /dev/ttyAMA0
        com_baud = 38400                        # 9600 for old RFM12Pi
    [[[runtimesettings]]]
        pubchannels = ToEmonCMS,
        subchannels = ToRFM12,

        group = 210
        frequency = 868
        baseid = 5                              # emonPi / emonBase nodeID
        calibration = 230V                      # (UK/EU: 230V, US: 110V)
        quiet = true                            # Disable quite mode (default enabled) to enable RF packet debugging, show packets which fail crc
        # interval =  300                         # Interval to transmit time to emonGLCD (seconds)

Thanks for the replay. here is the start of emonhub.conf

[interfacers]
### This interfacer manages the RFM12Pi/RFM69Pi/emonPi module
[[RFM2Pi]]
    Type = EmonHubJeeInterfacer
    [[[init_settings]]]
        com_port = /dev/ttyAMA0
        com_baud = 38400                        # 9600 for old RFM12Pi
    [[[runtimesettings]]]
        pubchannels = ToEmonCMS,
        subchannels = ToRFM12,

        group = 210
        frequency = 433
        baseid = 5                              # emonPi / emonBase nodeID
        calibration = 110V                      # (UK/EU: 230V, US: 110V)
        quiet = true                            # Disable quite mode (default enabled) to enable RF packet debugging, show packets which fail crc
        # interval =  0                         # Interval to transmit time to emonGLCD (seconds)

Also, this is a North American installation.

That should not make any difference.

It looks as if the sketch in the analogue front end of your emonPi might have had its comms protocol changed, but it should have responded to one of those baud rates.

I’m afraid I’ve run out of ideas, it has to be one for @TrystanLea.

Hello @Jason_Yates

I wonder if the software update in June included updating the firmware on the emonPi board?
It might be worth trying to update the firmware again, what emonSD image version are you running? (Search for emonpiRelease on the Admin > Info page)

You could try writing the emonPi firmware again via the Update tool here:

If you could copy the update log result here that would be great

@TrystanLea, That fixed the problem.

Thank you both for taking the time to help.