Skip to content

Help with multiple RCSwtich.h devices? #64

@stickboy135

Description

@stickboy135

Hi - I'm new to this, so please bear with me. I have two RC devices (Christmas tree and fireplace). I'd like to use one ESP8266 board (and 303MHz transmitter) to control both, and this sketch seems like it would work. Note - I previously used the earlier single switch version of your code (which is a lot more complex, and I was having some discovery issues i'm working through). I am able to properly control both devices using a simple webserver sketch however.

Here is my question - I think there are some fundamental differences between rcswitch.h and switch.h. Can you give me a few pointers on how to use the rcswitch library instead of switch.h? For example, I dont think the server loop function works, and the creation of the rcswitch object in fundamentally different. How do I intercept a request, determine which device is being requested, and then execute the proper on/off function? In your single switch version, binarystate tells me on/off, but i wasn't sure how to modify that to control two devices, which is why this version looks more attractive, but not sure how to use rcswitch instead of switch.h. Any pointers?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions