Community
OpenEnergyMonitor

Community

Connecting RFM2Pi on Raspberry Pi 3 Model B?

Hi, I’m looking to migrate from an older Pi onto a new Pi which already has my currentcost envi connected to it. The current cost is using node-red to read and send the data to emoncms.
In a similar vein, I am looking at migrating the RFM2Pi onto the same platform, and remove the need to run oemgateway (or emonhub, I think).

I’ve not got any instructions to work, I understand ttyAMA0 is now being used by the bluetooth functionality. I think they are suggesting using ttyS0 or ttySerial0 or something.

I’d like to retain the bluetooth functionality and am using the WiFi to send the info.

Anyway, wonder if anyone has any suggestion?

Thanks

This is the only thing I can find. It doesn’t mean much to me, but it’s certainly discussing disabling the BT, which is fine.

http://raspberrypi.stackexchange.com/questions/45570/how-do-i-make-serial-work-on-the-raspberry-pi3

I tried the last suggestion of disabling the BT in “/boot/cmdline.txt”, but couldn’t see anything on /dev/ttyAMA0

Also the old instructions suggested editing /etc/inittab … but that file is empty nowadays.

Thanks

Hi Nick,

Good to hear from you. Hope you are well :slight_smile:

Correct, on the Pi3 by default AMA0 is used for BT. However to have a reliable serial connection to the RFM12Pi / RFM69Pi we have (on our latest pre-build SD card image) we have disabled the onboard BT and re-mapped AMA0 back to the GPIO UART ports to enable AMA0 to be used by the RFM12Pi.

See blog post: https://blog.openenergymonitor.org/2016/03/raspberry-pi-3/

I think the easiest way to migrate is:

  1. Use Pi3 with our emonSD-03-May16.img
  2. Your older RFM12Pi will work fine, you will just need to adjust the RFM12 baudrate in emonhub.conf to 9600. This can be done via the Emoncms web interface emonHub tab
  3. Use a USB BT adapter
  4. NodeRED is running as standard on the SD card image, (port 1880) you should just be able to import your CC nodered flow. See nodeRED config for login: https://guide.openenergymonitor.org/integrations/nodered

Alternatively if you fancied experimenting you could try and get the BT to work at the same time as the UART on the Pi3. We found using the software serial port unreliable. Would be nice if we could get a solution for this. However BT USB adaptors are cheap and easily available so it’s not a high priority for us right now. There might be some more info avaialble on this now. I was trying to make this work in the same week the Pi3 came out and we were kinda figuring stuff out on the fly.

From our blog post: https://blog.openenergymonitor.org/2016/03/raspberry-pi-3/

To disable onboard Pi3 Bluetooth and restore UART0/ttyAMA0 over GPIOs 14 & 15 modify:

`sudo nano /boot/config.txt`

Add to the end of the file

`dtoverlay=pi3-disable-bt`

We also need to run 

`sudo systemctl disable hciuart`

However if you use our pre-built SD card image as a starting point all this has been done, working and tested :-)

Hey Glyn, great to hear from you too!

I’m not the first to hit this issue then…

Might keep oemgateway running a little longer, until I decide on a replacement.

I know this is an old thread, just want to confirm if I install the RFM12Pi from my old Pi B+ into a newer PI 3 B+ for Pi 4, and using the latest emonSD image I should be golden ?