My Sensors with Heltec V2



  • Hello MySensors,
    I have a problem.
    I buy two Heltec Lora V2 and I wanto to use the first as Gateway and the second as node.

    The gateway and relative node start (No FAIL detect) but, when the node try to send a msg the log print NO_REPY.

    Ho I can find an example?.

    Is possible to use Heltec as node and raspberry gateway with RFM95 ?.

    thanks to all

    Heltec V2 GATEWAY LOG
    1176 GWT:TIN:CONNECTING...
    1178 GWT:TIN:IP: 192.168.1.50
    1184 MCO:BGN:STP
    1187 MCO:BGN:INIT OK,TSP=1
    1191 TSM:READY:NWD REQ
    1195 RFM95:SWR:SEND,TO=255,SEQ=0,RETRY=0
    8201 ?TSF:MSG:SEND,0-0-255-255,s=255,c=3,t=20,pt=0,l=0,sg=0,ft=0,st=NACK:
    900050 TSF:SAN:OK

    Heltec V2 Node

    17 MCO:BGN:INIT NODE,CP=RLNNA---,FQ=16,REL=7,VER=2.3.2-beta
    27 TSM:INIT
    28 TSF:WUR:MS=0
    40 TSM:INIT:TSP OK
    41 TSM:INIT:STATID=1
    44 TSF:SID:OK,ID=1
    46 TSM:FPAR
    71 ?TSF:MSG:SEND,1-1-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK:
    2078 !TSM:FPAR:NO REPLY
    2080 TSM:FPAR
    2106 ?TSF:MSG:SEND,1-1-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK:
    4113 !TSM:FPAR:NO REPLY
    4115 TSM:FPAR
    4141 ?TSF:MSG:SEND,1-1-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK:


  • Mod

    Welcome to the forum @dimoia

    I'm not sure if anyone has tried it, but the setup you are describing should work.

    What spreading factor setting are you using for the lora modem? If you use the slow factors, you might need to adjust some timeouts. See https://github.com/mysensors/MySensors/issues/742

    Are the devices withn range from eachother? ( at least 5m, but not many hundred meters away?)

    Are you using the antenna that seems to be included in the kit? If not, what atenna are you using?



  • Hi Mikael,
    I executed the instructions you posted and I solved the problem.
    Thanks


  • Mod

    Great work @dimoia, thanks for reporting back



  • Hello @dimoia ,
    Trying to make a gateway and a node using the Heltec Lora Oled board, can you please post the settings you used to make it work with mysensors?
    Thank you



  • @mrussi
    Not sure if you still need this info, but I'll leave it here in case anyone else needs it. I couldn't find this either so i had to look at the heltec pinout diagram and compared to the ESP32 Library

    /*
     * The MySensors Arduino library handles the wireless radio link and protocol
     * between your home built sensors/actuators and HA controller of choice.
     * The sensors forms a self healing radio network with optional repeaters. Each
     * repeater and gateway builds a routing tables in EEPROM which keeps track of the
     * network topology allowing messages to be routed to nodes.
     *
     * Created by Henrik Ekblad <henrik.ekblad@mysensors.org>
     * Copyright (C) 2013-2018 Sensnology AB
     * Full contributor list: https://github.com/mysensors/MySensors/graphs/contributors
     *
     * Documentation: http://www.mysensors.org
     * Support Forum: http://forum.mysensors.org
     *
     * This program is free software; you can redistribute it and/or
     * modify it under the terms of the GNU General Public License
     * version 2 as published by the Free Software Foundation.
     *
     *******************************
     *
     * REVISION HISTORY
     * Version 1.0 - tekka
     *
     * DESCRIPTION
     * The ESP32 gateway sends data received from sensors to the WiFi link.
     * The gateway also accepts input on ethernet interface, which is then sent out to the radio network.
     *
     * Make sure to fill in your ssid and WiFi password below.
     */
    
    // Enable debug prints to serial monitor
    #define MY_DEBUG
    
    // Enables and select radio type (if attached)
    //#define MY_RADIO_RF24
    //#define MY_RADIO_RFM69
    #define MY_RADIO_RFM95
    #define MY_DEBUG_VERBOSE_RFM95
    #define MY_RFM95_RST_PIN 14
    #define MY_RFM95_CS_PIN 18
    #define MY_RFM95_IRQ_PIN 26
    #define MY_RFM95_IRQ_NUM MY_RFM95_IRQ_PIN
    #define MY_SOFT_SPI_MOSI_PIN 27
    #define MY_SOFT_SPI_SCK_PIN 5
    #define MY_RFM95_FREQUENCY (RFM95_868MHZ)
    #define MY_RFM95_MODEM_CONFIGRUATION RFM95_BW125CR45SF128
    
    #define MY_GATEWAY_ESP32
    
    #define MY_WIFI_SSID "WiFi_SSID"
    #define MY_WIFI_PASSWORD "password"
    
    // Set the hostname for the WiFi Client. This is the hostname
    // it will pass to the DHCP server if not static.
    #define MY_HOSTNAME "ESP32_GW_LoRa"
    
    // Enable MY_IP_ADDRESS here if you want a static ip address (no DHCP)
    //#define MY_IP_ADDRESS 192,168,1,100
    
    // If using static ip you can define Gateway and Subnet address as well
    //#define MY_IP_GATEWAY_ADDRESS 192,168,1,1
    //#define MY_IP_SUBNET_ADDRESS 255,255,255,0
    
    // The port to keep open on node server mode
    #define MY_PORT 5003
    
    // How many clients should be able to connect to this gateway (default 1)
    #define MY_GATEWAY_MAX_CLIENTS 2
    
    #include <MySensors.h>
    
    void setup()
    {
    	// Setup locally attached sensors
    }
    
    void presentation()
    {
    	// Present locally attached sensors here
    }
    
    void loop()
    {
    	// Send locally attached sensors data here
    }
    

Log in to reply
 

Suggested Topics

  • 4
  • 9
  • 17
  • 2
  • 15
  • 4

41
Online

11.4k
Users

11.1k
Topics

112.6k
Posts