Skip to content
  • Home Assistant update changed USB port name

    Home Assistant
    3
    0 Votes
    3 Posts
    31 Views
    E
    What I did not try but might work: copy your persistence file, delete the old GW and create a new one with the persistence file you copied. Maybe the devices are preserved like this. Maybe you should create a full backup before... <edit: typo>
  • 0 Votes
    2 Posts
    34 Views
    OldSurferDudeO
    I have success! (oops, that's suppose to be Timer1) I only sample for 1/60 of a second. What I did was to back up all the timer registered I used and then resorted them after I was done sampling. (As opposed to initializing the registers in setup and then starting the timer when needed.) Now I have a Nano sampling the data and sending it to a MySensors Gateway on an RPi3B+ which then sends it to an MQTT broker runing on an old laptop. Also running on the laptop is Home Assistant running inside of VirtualBox. If MySensors does use Timer1, it appears that restoring the registers allows it to be shared. //------------------------------------------------------ISR ISR(TIMER1_OVF_vect){ // interrupt service routine for overflow TCNT1 = TimerPreloadValue; // must be first line! starts the timer counting again digitalWrite(TRIGGER_START_SAMPLE_PIN,HIGH); samplesVolts[--sample]=analogRead(VOLTS_IN_PIN); // decrement before capturing samplesCurrent[sample]=analogRead(CURRENT_IN_PIN); digitalWrite(TRIGGER_START_SAMPLE_PIN,LOW); if (!sample){ // count down to zero digitalWrite(TRIGGER_START_SAMPLE_PERIOD_PIN,LOW); // indicate that sampling is complete samplingEnd = micros(); TCCR1B &= 248; // turns off timer } } //------------------------------------------------------sampleOneCycle void sampleOneCycle(){ // back up timer registers uint8_t TCNT1_b = TCNT1; uint8_t TCCR1B_b = TCCR1B; uint8_t TCCR1A_b = TCCR1A; uint8_t TIMSK1_b = TIMSK1; // configure timer which starts the sampling noInterrupts(); // disable all interrupts TCCR1A = 0; TCCR1B = 0; TCNT1 = TimerPreloadValue; // preload timer //TCCR1B |= (1 << CS10)|(1 << CS12); // 1024 prescaler TCCR1B &= 248; // turns off timer? TIMSK1 |= (1 << TOIE1); // enable timer overflow interrupt ISR // demark sampling sample = NUMBER_OF_SAMPLES; // count down to zero digitalWrite(TRIGGER_START_SAMPLE_PERIOD_PIN,HIGH); samplingStart = micros(); TCNT1 = 65535; // first trigger right away! TCCR1B |= 1; // turns on timer interrupts(); // enable all interrupts // wait for sampling to be complete while(digitalRead(TRIGGER_START_SAMPLE_PERIOD_PIN)){}; samplingEnd = micros(); // restore timer registers TCNT1 = TCNT1_b; TCCR1B = TCCR1B_b; TCCR1A = TCCR1A_b; TIMSK1 = TIMSK1_b; }
  • 0 Votes
    1 Posts
    26 Views
    No one has replied
  • Raspberry pi gateway problem after change of Pi

    General Discussion
    2
    0 Votes
    2 Posts
    44 Views
    Vasilis VlachoudisV
    After re-installing the previous 32bit raspbian version, the gateway seems to work ok. It seems to me there is a problem with the 64bit version.
  • 2 Votes
    1 Posts
    40 Views
    No one has replied
  • Sensebender Gateway (SAMD21)

    Development
    10
    0 Votes
    10 Posts
    89 Views
    P
    Just for completeness: the right way to do this is to add the json under ~/.platformio/boards and the other files as described in https://community.platformio.org/t/how-use-a-same-chip-but-with-different-environment/18082/4
  • Can not compile on Arduino Nano ESP 32

    Troubleshooting
    15
    0 Votes
    15 Posts
    123 Views
    E
    @ctodor You are very welcome
  • Gateway stops communicating (again)

    Troubleshooting
    2
    0 Votes
    2 Posts
    28 Views
    E
    Hm, maybe the problem is that your rPI has a short interruption in the WIFI connection, the MQTT TCP connection is interrupted and does not autostart again. Maybe there is something in the logs. Maybe you can find something about reconnects in one of these: journalctl --unit=systemd-networkd journalctl --unit=wpa_supplicant You could try to run wpa_cli in daemon mode to react to disconnects and connects. Create a script like this: #!/bin/bash case "$2" in CONNECTED) <your command to start the gateway>; ;; DISCONNECTED) <your command to stop the gateway>; ;; esac then, start wpa_cli in deamon mode: wpa_cli -a /path/to/your/script #use sudo if your gateway commands need sudo If that helps, you could create a service from this command. Regards, Edi
  • FOTA using OptiBoot copy_flash_pages

    Development
    2
    2
    0 Votes
    2 Posts
    43 Views
    E
    IT WORKS I got a first working version, using an ATmega1284P running on MightyCore 2.2.2 (as soon as I began developement, they switched from Optiboot to Urboot in version 3.0.0, whicht does not include the copy_flash_pages function anymore, but I'm working on a work around there). Only thing I could not solve is to do a CRC check of the image after download... You can try it out here: https://github.com/eiten/MySensors/tree/FOTAInternalFlashTest It's not beautiful yet with much Serial.prints in it, but maybe it helps you if you find errors.
  • HVAC Controller

    My Project
    3
    2
    1 Votes
    3 Posts
    50 Views
    OldSurferDudeO
    We are of like minds, Don't like the cloud based controls (that's another discussion). In my case I have a Bryant/Connex system, heat pump, variable speed fan and 4 zones. There's a lot going on: the 4 zones creates 16 profiles. The fan speed for a profile will depend on the indoor and outdoor temperature. The thermal fluid pump also has to be controlled. A profile will have an optimal air pressure, so there's a sensor there. The controller works just fine not being connected to the cloud. But I want to set the parameters remotely, Bryant/Connex can do this. I also wnat the status of the various actuators and sensors to show up in Home Assistant. The signals sent over the RS422 are proprietary. My plan was to reverse-engineer the signals. After doing this I'll have to experiment to get the right mix of air pressue, fan speed and thermal fluid flow for each profile. I'd like to do the same for my AO Smith heat pump water heater. I'd like to follow your progress. OSD
  • Arduino Nano Every problem

    Hardware
    6
    1 Votes
    6 Posts
    106 Views
    OldSurferDudeO
    I bought the Every because it implied it was backward compatible with the nano. No, it's not, as we found out. Be that as it may, any word on a getting the Every working with mySensors?
  • Radio RFM95 does not send ATmega1284p

    Troubleshooting
    2
    3
    0 Votes
    2 Posts
    31 Views
    E
    Don't ask me why, but now it works. I changed nothing! Went to my girl over the weekend, coming back, the node was registred. Maybe a jammer went away?
  • OH3 - MySensors Binding

    OpenHAB
    135
    0 Votes
    135 Posts
    2k Views
    kerberosK
    Hi @CyborgAndy many thanks for providing the binding update for MySensors 4.0.4! I upgrade my OpenHAB 3.4.4 a few minutes ago to 4.0.4 successfully with your binding update. I use a USB connected serial-gateway. The OpenHAB manual installation upgrade works perfect. I need to do afterwards the following steps in the Karaf console, to get the gateway online again, after the update: feature:install openhab-transport-serial feature:install openhab-core-io-transport-mqtt feature:install openhab-core-io-transport-serial-javacomm Many thanks again! kerberos
  • can't make getStream() work

    Troubleshooting
    2
    0 Votes
    2 Posts
    41 Views
    E
    @Mizar03 sorry for the late response. getStream() only works for firmware transfers. I'd suggest getString(), this should also work for all types of payloads, as they are normaly ASCII and not binary data.
  • Best VOC sensor for detecting a wide range of VOC's?

    Hardware
    3
    1 Votes
    3 Posts
    107 Views
    NeverDieN
    @eiten I haven't yet made any progress on finding a good VOC sensor, but along the way I did find out something interesting regarding CO2: namely, if you sleep with your bedroom door closed at night, then the odds are good that the CO2 levels rise to surprisingly high and unhealthy levels. The better CO2 sensors are factory calibrated and never again need recalibration for the life of the sensor (usually around 10 years or so), because they are used in HVAC systems to control fresh air intake to guarantee indoor air quality. As a for instance, here is one such CO2 sensor: https://www.digikey.com/en/products/detail/senseair/006-0-0008/15790694 At around $50 for just the sensor element itself, it's not exactly cheap, but then again, I'd say it's worth it, because who wants to be burdened by remembering to calibrate their CO2 sensors? Ideally, I'd like to find a sensitive VOC sensor that also will never require calibration. Nearly all, and maybe all, of the off-the-shelf IAQ montoring stuff that you might buy for, say, $300 or less seems to require periodic calibration. For that reason, this might be one of those occasions where build is rather than buy.
  • 13 Votes
    198 Posts
    85k Views
    I
    @tekka Is there any changelog to it also or it was just made officially available again? although last online status was 22 AUG 2020, so anyone else can confirm anything about it? I'd just be cautious without confirmation.
  • High power consumption NRF52832 & SI7021

    Troubleshooting
    24
    0 Votes
    24 Posts
    291 Views
    W
    I don't know if any of you guys are still around and using this stuff - I moved and am reviving a few of these 51/52 boards that I had built. Prior to moving I had decent luck with all these fixes though I don't quite remember where I was with any of this stuff seeing as it was 3 years ago. I had a few motion sensors and some temp/humd based on these fixes and they were working great, no dips. Not sure any of you will ever see this but hey it all worked.
  • How control W5500/W5100 (with STM32) by mysensors library

    Development
    2
    0 Votes
    2 Posts
    31 Views
    MarcinM
    I found procedure gatewayTransportInit(), it works great. However, I cannot find a procedure that will enable detection of a network connection at level mysensors. I noticed that disconnecting the network plug or resetting the W5500 (37 pin to ground) changes the device's IP address to 0.0.0.0 - then I call gatewayTransportInit() - but mysensor's library must have such procedures - please tell me how to diagnose ethernet connection.
  • problem with Dallas temperature

    Development
    3
    1
    0 Votes
    3 Posts
    39 Views
    M
    hello, I just deleted the eeprom but I still have the problem. [image: 1698703321335-capture.png]
  • Halloween Lights

    My Project led strip light ws2812b
    1
    5
    3 Votes
    1 Posts
    32 Views
    No one has replied

12

Online

11.7k

Users

11.2k

Topics

113.1k

Posts