Navigation

    • Register
    • Login
    • Search
    • OpenHardware.io
    • Categories
    • Recent
    • Tags
    • Popular
    1. Home
    2. Sasquatch
    3. Posts
    • Profile
    • Following
    • Followers
    • Topics
    • Posts
    • Best
    • Groups

    Posts made by Sasquatch

    • RE: How to properly handle variable requests

      I see it this way:
      NodeA sends C_REQ of Var1 to NodeB
      NodeB processes C_REQ message in receive();
      NodeB replies with C_SET of Var1 to NodeA just as controller would
      NodeA processes C_SET message in receive();

      You can use echo/ACK functionality or not, it doesn't matter.

      If you want both nodes to synchronise their variables, then it seems best to:
      a)request values on boot
      b)On variable change send values without prompt

      That way you cut traffic by half compared to request-reply approach.

      posted in Development
      Sasquatch
      Sasquatch
    • RE: House renovation, how to a good electrical system oriented to MySensors?

      @alowhum said in House renovation, how to a good electrical system oriented to MySensors?:

      What do you mean with running it in a loop? Where could I learn more about that?

      wires in the loop:
      PSU-----GW----Node1----node2
      |____________________________|

      Use switching regulators to keep current down.

      posted in Hardware
      Sasquatch
      Sasquatch
    • RE: Solar Energy Harvesting for wireless motes

      I made pcb for it it's on the roof of my flat, will dig trough my archives to see if i have kicad project for it.

      posted in Hardware
      Sasquatch
      Sasquatch
    • RE: Solar Energy Harvesting for wireless motes

      cough cough , so much dust here in the archives... πŸ˜‰

      @NeverDie SPV1050 is what you are looking for, only Maximum Power Point Tracking IC from all IC's you mentioned/tested in both your topics. And trust me, it makes a whole world of a difference. ST even have online component calculator for matching it to solar panel and battery used. My usage scenario was outdoor rechargeable coin cell battery and calculator solar cell. Only drawback: you have to determine maximum power point of your solar cell.

      posted in Hardware
      Sasquatch
      Sasquatch
    • RE: ESP8266 Gateway (RFM69) Soft WDT reset every 5 - 10 min

      just a thought, since resets are happening under heavy trafffic:
      What is your serial speed? 9600 could lead to buffer overflows under heavy traffic

      posted in Troubleshooting
      Sasquatch
      Sasquatch
    • RE: The "new" Arduino Pro IDE

      @BearWithBeard said in The "new" Arduino Pro IDE:

      When I first heard about the Pro IDE, I was curious if they would manage to implement an open hardware debugger for AVRs, because as of yet, this is AFAIK still only possible with proprietary Atmel / Microchip hard- and software. But I doubt that this is going to happen.

      AFAIK only IAR uses atmel(sadly Microchip now) hardware for debugging, no other IDE i tried can use dragon or ICE for more than just programming. Expecting Arduino to support hardware debuggers was insanely optimistic.

      posted in Development
      Sasquatch
      Sasquatch
    • RE: The "new" Arduino Pro IDE

      Still same crap as it was, throws you an error without even a line number to make finding it possible!!!

      @TRS-80 arduino didn't lower board prices, aliexpress clone sellers did πŸ˜‰

      posted in Development
      Sasquatch
      Sasquatch
    • RE: BATERY CHARGER CONNECTION ?

      In Proteus you click on terminal end to draw a wire connection πŸ˜‰

      But on serious note - with copper with help from soldering alloy on PCB πŸ˜‚ .

      If you are asking for exact schematics then do your own homework and look in TP4056 datasheet. You are looking for typical application drawing.

      Tp4056 is linear regulator, very inefficient, look at spv1040 or spv1050 instead - MPPT tracking propper solar chargers.

      posted in General Discussion
      Sasquatch
      Sasquatch
    • RE: PIR with no interrupt - doubts.

      If it stopped working after adding mysensors then it must be at fault.
      Do you see normal mysensors debug messages?
      Does it connect to gateway?
      Try adding :

      #define MY_TRANSPORT_WAIT_READY_MS 5000
      
      

      before

      #include <MySensors.h>
      

      that will allow to execute your loop(); even without radio link working.

      posted in Troubleshooting
      Sasquatch
      Sasquatch
    • RE: Domoticz/Mysensors

      put your code in code tags, makes it much easier to read, use bar above text field it's </> icon.

      posted in Domoticz
      Sasquatch
      Sasquatch
    • RE: Second setup, choosing a radio

      @projectMarvin
      nrf52 rx current is ~5mA - 480h on 2400mAh battery
      rfm69 rx current is 16mA - 150h same battery

      Both times rather pathetic, you never run battery powered node in constant rx mode.
      If you power down radio as often and for as long as possible you can get 5+ years out of both radios on single AA lithium thionyle battery and keep data flowing every minute or so. I suspect that on Nrf it might need less programming acrobacy.

      As for OTA, you should need to update your firmware only when security patches come out for library, once a year maybe?
      pulled from nrf52840 datasheet:

      The non-volatile memory controller (NVMC) is used for writing and erasing of the internal flash memory
      and the UICR (user information configuration registers).
      (...)
      The CPU must be halted before initiating a NVMC operation from the debug system.
      

      It looks to me that self programming is not possible. BUT i have never worked with tem (or any other M4) so what do i know πŸ˜‰

      posted in Hardware
      Sasquatch
      Sasquatch
    • RE: Second setup, choosing a radio

      I found that 2.4 GHz is too noisy for stable operation in area, had problems with range and missing packets. Radios worked fine, 80-90 meters in open field, 2 meters indoors across one room !!! but i can see 20+ WIFI networks within reach.
      Long story short: check your environment before you buy many radio modules.

      I'm currently in finishing stages of ultimate low power node - 5+ years on single AA(LITHIUM) battery with one minute update/report interval, based on RFM69+atmega328p.

      If you really need/wand OTA then nrf24 or rfm69/rfm95 is the way to go. Possibly gateway could be nRF52840 and nodes nrf24, not 100% sure, but should be compatible.

      posted in Hardware
      Sasquatch
      Sasquatch
    • RE: Suggestions for my setup? Very new here.

      Imagine thermostat relying on IFTTT/cloud to work on schedule and your internet fails(winter, someone crashes car into ISP cabinet)... πŸ˜‰

      posted in General Discussion
      Sasquatch
      Sasquatch
    • RE: Suggestions for my setup? Very new here.

      @Smart-Projects-ABC
      1- not really. HA can use any sensor with Google Assistant(not sure if alexa was added since I last used it)
      2-flash requried? - going back to 2005 is IMHO not the way forward, what kind of advanced automation cannot be done in, say Domoticz or HomeAssistant?
      3-as little different protocols as practicable is a good idea
      4- I would add: avoid cloud based sensors at all cost for security and future proofing reasons. Cloud based sensor can be rendered useless by vendor deciding it's time to sell you a new one. Having local controller talking to sensors/actuators over WIFI/ZIGBEE/RFM69/NRF24/MagicBeam and allowing remote control over GA/Aexa/an app is more robust solution than every sensor talking to a server in china over different open port and ten talking trough outdated website(ittt.com) to talk to controller over yet another open port....

      And yes, with a bit of creativity and couple seeedstudio.com orders you can get every sensor you want on MySensors transport πŸ˜‰

      posted in General Discussion
      Sasquatch
      Sasquatch
    • RE: Help needed to setup a RFM69 & ESP8266 Gateaway on Adafruit Feather Huzzah

      @scalz I do agree,
      I found that even USB powered NodeMCU gateway needed at least 10uf ceramic or 47uF electrolytic capacitor on radio supply, without it heavy traffic was causing gateway freezes and reboots. There is 100nF capacotor on rfm69 and 220nf on RFM69H modules(at least my Aliexpress cheap clones have them) right next to the VCC pin, so i skip the external one.

      posted in Development
      Sasquatch
      Sasquatch
    • RE: Domoticz/Mysensors

      @alco plenty people here ready to help

      posted in Domoticz
      Sasquatch
      Sasquatch
    • RE: Help needed to setup a RFM69 & ESP8266 Gateaway on Adafruit Feather Huzzah

      @scalz great explanation of new driver functionality.
      Some cheapest Aliexpress boards are not marked at all or marked with Frequency only. H versions have additional sot23-6 chip near antenna pin.

      Wonder why the new driver wasn't stable enough to do 12kB OTA firmware update even once, regardless of settings πŸ€” . Same GW and node works flawlessly on old driver over 10-100 meters.

      posted in Development
      Sasquatch
      Sasquatch
    • RE: V_ARMED vs V_TRIPPED questions.

      Agree with @Yveaux.
      V_ARMED can be used in battery powered door sensors to preserve battery, or to reduce traffic. don't send V_TRIPPED if V_ARMED is not set. Sounding alarm is controller's decision.

      posted in Development
      Sasquatch
      Sasquatch
    • RE: [SOLVED] Go to loop(); when parent/gateway can't be found.

      @BearWithBeard my bad, looked at wrong post and understood your answer wrong, bloody small text on phones ;~)

      posted in Development
      Sasquatch
      Sasquatch
    • RE: Domoticz/Mysensors

      interesting schematic. another way of controlling lights is:
      rewire standard light switch to low voltage input of arduino node
      use node's relay to control light, works even if you don't have neutral wire in light switch backbox.

      posted in Domoticz
      Sasquatch
      Sasquatch
    • RE: [SOLVED] Go to loop(); when parent/gateway can't be found.

      @BearWithBeard
      If you omit

       #define MY_TRANSPORT_WAIT_READY_MS 1000
      

      or define it as 0 and transport is not ready on boot then sketch will never reach loop();

       if (!isTransportReady())
          {
              // No uplink
          }
      

      Is handy for skipping sending data to gateway in fault condition, saves battery/power.

      posted in Development
      Sasquatch
      Sasquatch
    • RE: Help needed to setup a RFM69 & ESP8266 Gateaway on Adafruit Feather Huzzah

      @hlehoux no idea, i have mix of HW, W and H marked, all play together nicely.

      posted in Development
      Sasquatch
      Sasquatch
    • RE: RFM gateway and sensors node with range issue

      @wiredfrank roll back to old driver, use 17cm(433Mhz)/8.5cm(868 MHz) piece of straight wire as antenna.
      Solder extra 100-470uf capacitor directly to supply pins of the radios too, especially HW versions. Transient current spikes can cause all sorts of problems.

      I'm using rfm69 mixed HW and non HW versions , and 500m meters is easily achieved, even on spider dupont wire connections and 2.4v supply(2x nimh aa cells).

      also, don't rely on controller for connection tests, use debug serial output on both ends to confirm link.

      posted in Troubleshooting
      Sasquatch
      Sasquatch
    • RE: ESP8266 Gateway (RFM69) Soft WDT reset every 5 - 10 min

      https://www.mysensors.org/uploads/57c1a2411730a6c715b6b1b0/image/RFM69.png
      Solder it between GND and 3v3 pins.
      sorry, can't find a picture on internet and can't take picture of mine atm.

      posted in Troubleshooting
      Sasquatch
      Sasquatch
    • RE: Help needed to setup a RFM69 & ESP8266 Gateaway on Adafruit Feather Huzzah

      try adding :

      #define MY_RFM69_FREQUENCY   RFM69_868MHZ
      

      just in case....

      My first prototype using dupont cables and piece of wire as antenna gave me 500m range with 3 or 4 houses between me and gateway.
      Try old driver, no RSSI reporting, but my whole network runs on old driver.

      @hlehoux 1m range is usually caused by radio type misconfiguration, like running HW radio as low power or other way round. Another possibility is faulty radio.

      posted in Development
      Sasquatch
      Sasquatch
    • RE: ESP8266 Gateway (RFM69) Soft WDT reset every 5 - 10 min

      Try adding 220-470uf capacitor across radio supply pins, had similar problem with my gateway(NodeMCU) and RFM69HW during node OTA firmware updates.

      You know you can map serial port to VM, right?

      posted in Troubleshooting
      Sasquatch
      Sasquatch
    • RE: Generic pressure sensors -SOLVED

      It is most likely OP amp output you are seeing,
      connect 5v, resistors as needed and multimeter to resistor output, check if works satisfactory, simple....

      posted in Hardware
      Sasquatch
      Sasquatch
    • RE: RFM gateway and sensors node with range issue

      Your node sketch is configured as HW model but you said you're using standard radio on it

      comment out line below

      #define MY_IS_RFM69HW
      

      in sketch running radio without 6 legged chip next to ant pin

      Been there done that, but I was getting 10 cm range on coil type aerials πŸ˜‰

      posted in Troubleshooting
      Sasquatch
      Sasquatch
    • RE: Issues when upgrading EnergyMeterPulseSensor from 1.5.x to 2.3.2

      V_Var1 is variable(your total pulses) stored in the controller - HomeAssistant, Domoticz etc....
      Assuming you have controller shut down you have to send that value from MYSController.

      This request will be fulfilled by controller after you configure it to use node's 7 child 1

      posted in Development
      Sasquatch
      Sasquatch
    • RE: Mysensors Node not being recognized (added)

      you add entry for your door sensor node to mysensors.json
      AFAIK HA can't detect and automatically add your nodes

      posted in Home Assistant
      Sasquatch
      Sasquatch
    • RE: API questions regarding Home Assistant Core.

      I haven't used HA for a while, but i used node ID's(numeric) and node child ID's(again, numeric) to identify sensors. Never added anything to node sketches, no need to, you add all your nodes, sensors and their names in config file anyway...
      there are much better controllers IMHO, at least from ease of use point of view.

      posted in Home Assistant
      Sasquatch
      Sasquatch
    • RE: Radio waking up for no reason.

      Update:
      After few hours with AVR dragon snooping execution paths I found that after each loop() radio is woken up by code executed after each loop().
      My solution is to never leave loop() by creating infinite loop inside of it, so far, after 10 h everything runs stable.
      8-10 years on a single 1/2AA Lithium thionyl battery seems possible πŸ™‚

      posted in Development
      Sasquatch
      Sasquatch
    • RE: [SOLVED] Go to loop(); when parent/gateway can't be found.

      @mfalkvidd Thank You!!!
      @skywatch just search forums, plenty of use examples, knowing what to search for was a key problem ;).

      posted in Development
      Sasquatch
      Sasquatch
    • RE: PlatformIO instead of official Arduino IDE?

      @TRS-80
      "Arduino IDE" is hardly an glorified notepad, it is beyond useless, why can't it save your board config with your project FFS!!!.
      I'm using arduino plugin for atmel studio, since it's only way to use hardware debuggers, both AVR dragon and ATMEL ICE work great.

      posted in Development
      Sasquatch
      Sasquatch
    • [SOLVED] Go to loop(); when parent/gateway can't be found.

      I have all light switches in my flat running a relay node with local switch.
      Recent gateway PSU failure rendered all my lights nonoperational.
      PSU tripped RCB and killed gateway, after power was resumed no light switch worked.
      All nodes were stuck in endless loop trying to find gateway and never reached loop(), where local switch interactions are programmed.
      Is there a way to prevent this? I had no working lights for 3 days before new gateway parts arrived!!!

      posted in Development
      Sasquatch
      Sasquatch
    • Radio waking up for no reason.

      Hi.
      I'm working on low power pulse power meter based on atmega328p@3.3v/8MHz.
      My plan is:
      a: Send KWh for day/night meter every 100 pulses
      b: power radio ON only on 100th pulse
      πŸ˜„ For (b) reason I'm not using sleep(); as sleep(); is powering up radio every time cpu is woken up.
      sleep(0); => 20mA x 8ms
      PowerDown(); => 4mA x 0.5ms
      Using sleep(0); my node battery would last approx 80 times shorter than without it.
      d: Calculate average power consumption every 30 minutes.
      e: For reason (d) I'm running on internal oscillator with 32.768kHz crystal feeding Timer2 in asynchronous mode.

      Now the problem.
      Before I enabled TIMER2 overflow interrupt everything worked fine. Pin change interrupts work as intended, radio stays down until data is ready to be sent.
      As soon as I enable TIMER2 interrupt, wake up from it (every 8 seconds) and radio gets turned on by receiveDone(); called from f****k knows where.
      I know it's receiveDone(); because I'm using AVRStudio and DebugWire debugging.
      i could call transportDisable();(that's what sleep uses to switch radio off) but it takes 4 ms to cycle radio power, 8-10 times more power used that needed.

      posted in Development
      Sasquatch
      Sasquatch
    • RE: Arduino pro mini, rfm69 with 2 Reed switches on interrupts?

      Just a thought.
      I would personally go for one child ID/sensor.
      "There is uncollected mail" indicator.
      Set it to true when small door is tripped, and set to false when big door in open.

      posted in Development
      Sasquatch
      Sasquatch
    • RE: Arduino pro mini, rfm69 with 2 Reed switches on interrupts?

      @kiesel

      Found on here:
      Quote:

      Commented by Manoraj Gnanadhas (Atmel)
      2015-01-20 06:23:36 GMT
      [Recipients: Nick Gammon]

      Hello Nick,

      Our design team has confirmed that β€œNote-3 mentioned under Table 10-1” is a datasheet bug. So you can use any type of interrupt (Rising edge/ Falling edge / Low level / Any logical change) to wake up from sleep mode. Sorry for the inconvenience caused.

      Best Regards,
      Manoraj Gnanadhas

      Not responding to reed relay:
      PRIMARY_BUTTON_PIN interrupt is active only in sleep. if you're (un)lucky enough to move magnet when cpu is awake it will ignore it.

      More likely is that relay bounce longer than wake up time + 5ms in your loop.
      Do away with pin reading, serial print and delay, shorter your loop, longer battery life.
      In ISR (PCINT0_vect) set flag, then in a loop check for that flag.
      If it's set it's secondary buttton pin that avoke your cpu,
      if it's not set it's primary button .

      I'm reusing your variables:

      #include <avr/sleep.h>
      #define DEBUG  // coment out when ready to go into the box 
      #ifndef DEBUG //disable serial in production compile, potentially saves few uA in sleep mode
           #define MY_DISABLED_SERIAL
      #endif
      ISR (PCINT0_vect) // handle pin change interrupt for D8 to D13 here
       {    
          //delayMicroseconds(2);
          valueSecondary = true; // ISRs need to finish very fast or the arduino crashes. 
      void loop()
      {
         // Sleep until something happens with the sensor
        //sleep(PRIMARY_BUTTON_PIN-2, CHANGE, SECONDARY_BUTTON_PIN-2, CHANGE, 0);
        sleep_bod_disable();//disable BOD  - saves~ 15uA
        sleep(PRIMARY_BUTTON_PIN-2, CHANGE, 0);
      
        #ifdef DEBUG   //get rid of unnecessary slow downs when ready    
        Serial.println("Woken up");
        #endif
        
      
        if (valueSecondary == true){
               valueSecondary = false;
               #ifdef DEBUG     //get rid of unnecessary slow downs when ready    
               Serial.print("Secondary:");
               #endif
               send(msg2.set(1)); //box emptied/mail in the box
        }
        else{
            #ifdef DEBUG   //get rid of unnecessary slow downs when ready    
             Serial.print("Primary:");
            #endif
            send(msg.set(1));//mail in the box/box emptied
        }
      }
      

      Unless you really need to know if box was opened then closed, then check pin states in my if/else after 10-50ms delay, experiment until you get no bounce errors. BUT it will increase battery drain SIGNIFICANTLY.
      You will have 2 messages sent per event, one per door opening and one per door closing.

      posted in Development
      Sasquatch
      Sasquatch
    • RE: Which battery measurement to use?

      power consumption wise resistor-less method and running directly from LiFePo4(rechargeable 2.8-3.6V) or LiSoCl(3.6v non rechargeable) battery is best. Unless you remove regulator and USB/rs232 chip it's all wasting your time.

      @mfalkvidd said in Which battery measurement to use?:

      But if you get a "good" booster, the battery life will be more limited by the self-discharge of the battery than by the power usage of the node. Same goes for the non-boosted variant.

      Depending on battery chemistry, LiSoCl will last 15 years. with carefully designed MyS node you can get 10 years on single AA LiSoCL battery. Something like power meter pulse counter transmitting once every kWh.

      posted in Development
      Sasquatch
      Sasquatch
    • RE: Multiple relay arduino nano

      @hakha4 said in Multiple relay arduino nano:

      Hi
      Or use a Mcp23017, 16 extra pins and only sda/scl pins from Arduino (I have a functioning sketch for this including reading multiple ds1820 sensors that can be used as a template. Let me know of you want this)
      Regards HΓ₯kan
      ds18x20 need 1 pin for up to 255 sensors(can't remember exactly but more than practical).

      @robert said in Multiple relay arduino nano:

      Hi.
      I would like to connect an 8 channel relays to arduino nano. I use rs485 communication. Rs485 uses pins 2,8,9. How to make 2,3,4 used? I miss pins.
      Thx.

      Without knowing what else you're using it's impossible to know how to help you. but you may use A0-A7 as digital outputs too.

      posted in General Discussion
      Sasquatch
      Sasquatch
    • RE: NodeManager sensors with multiple interrupt pins

      @j54n1n said in NodeManager sensors with multiple interrupt pins:

      So can somebody confirm that pin change interrupts can wake up a sleeping node loaded with a NodeManager template sketch?

      I have got the impression by reading here in the forum that the ATmega328p microcontroller has problems waking up from pin change interrupts. Maybe I am wrong?

      You are wrong, i have one sitting on my bench right now sleeping and waking up on A5 pin change.
      it's bare 328p test bead drawing mere 1uA in sleep...
      Use sleep(0);
      All the code you need to set things up:(tested on nano and mini boards)

      void pciSetup(byte pin)// enables pin change for given pin
      {
      	*digitalPinToPCMSK(pin) |= bit (digitalPinToPCMSKbit(pin));  // enable pin
      	PCIFR  |= bit (digitalPinToPCICRbit(pin)); // clear any outstanding interrupt
      	PCICR  |= bit (digitalPinToPCICRbit(pin)); // enable interrupt for the group
      }
      void pciClear(byte pin)// disables pin change for given pin
      {
      	*digitalPinToPCMSK(pin) &= ~(bit (digitalPinToPCMSKbit(pin)));  // disable pin
      	PCIFR  |= bit (digitalPinToPCICRbit(pin)); // clear any outstanding interrupt
      	PCICR  &= ~(bit (digitalPinToPCICRbit(pin))); // disable interrupt for the group
      }
      
      
      ISR (PCINT0_vect)//pins d8-d13
      {
      	
      }
      ISR (PCINT1_vect)// pins a0-a7
      {
      	
      }
      ISR (PCINT2_vect)//pins d0-d7
      {
      	
      }
      
      

      If you want to get several readings and then send them to gateway(power meter pulse counting) it's better to write your own sleep function. Built in sleep(); wakes radio on every wake up.
      :work in progress:

      void PowerDown(void)
      {
        ADCSRA &= ~(1<<ADEN);//disable ADC - 120uA
        sleep_bod_disable();//disable bod  - 15uA
        set_sleep_mode(SLEEP_MODE_PWR_DOWN);
        wdt_disable();
        sleep_enable();
        sleep_cpu();
        sleep_disable();
       ADCSRA |= (1<<ADEN);//enable ADC
       }
      

      then call transportDisable(); before powering down
      and transportReInitialise(); before sending your data.

      posted in NodeManager
      Sasquatch
      Sasquatch
    • RE: πŸ’¬ MYSController

      latest version I can find is 1.0.0 beta... but i've seen screenshots of 1.2.2. where can i get it from?

      posted in Announcements
      Sasquatch
      Sasquatch