Simulating Rubicson-Temperature from esphome

33 views
Skip to first unread message

Dariusz

unread,
May 21, 2025, 10:01:23 AMMay 21
to rtl_433
Hi


I'm trying to send Rubicson-Temperature packet from esphome.
My intention is to send the temperature data from Home Assistant some other sensor.

The original sensor send data like this (which I broke by pressing wrong button on lab supply and pushing 12V through it :( ) :
time      : 2025-05-15 00:46:00
model     : Rubicson-Temperature                   House Code: 88
Channel   : 1            Battery   : 1             Temperature: 25.0 C       Integrity : CRC

Through looking at the code and looking at the signal in tests of rtl_433 I managed to send the packet that is correctly received from rtl_433 (sending code 88 and temperature of 4 degrees)

time      : 2025-05-21 15:55:08
model     : Rubicson-Temperature                   House Code: 88
Channel   : 1            Battery   : 1             Temperature: 4.0 C        Integrity : CRC

https://triq.org/pdv/#AAB00D050101E4256003DC07A00FAC8155+AAB000050101E4256003DC07A00FAC828382838382828283828282828282828282838283828282838383838383838383828382848283828383828282838282828282828282828382838282828383838383838383838
28382848283828383828282838282828282828282828382838282828383838383838383838283828482838283838282828382828282828282828283828382828283838383838383838382838284828382838382828283828282828282828282838283828282838383838383838383828382848283828
38382828283828282828282828282838283828282838383838383838383828382848283828383828282838282828282828282828382838282828383838383838383838283828482838283838282828382828282828282828283828382828283838383838383838382838284828382838382828283828
2828282828282828382838282828383838383838383838283828155

But the device/clock does not receive the data, do you have any idea what I'm missing?

I'm sending multiple pulses like that:
- remote_transmitter.transmit_raw:
code: [
500, -976, 500, -1940, 500, -976, 500, -1940, 500, -1940, 500, -976, 500, -976, 500, -976,
500, -1940, 500, -976, 500, -976, 500, -976, 500, -976, 500, -976, 500, -976, 500, -976,
500, -976, 500, -976, 500, -1940, 500, -976, 500, -1940, 500, -976, 500, -976, 500, -976,
500, -1940, 500, -1940, 500, -1940, 500, -1940, 500, -1940, 500, -1940, 500, -1940, 500, -1940,
500, -1940, 500, -976, 500, -1940, 500, -976, 500, -4000
]
carrier_frequency: 433920000
repeat:
times: 10
wait_time: 0ms

Any ideas?

Dariusz

unread,
May 27, 2025, 4:53:33 PMMay 27
to rtl_433
Hi
I found that when I disable carrier_frequency it works.
I didn't mention it, but I am using stx882 to send the data.

For those interested, I did sending sensor data that way:


- platform: homeassistant
device_class: temperature
entity_id: sensor.YOUR_SENSOR
id: send_sensor_temperature
on_value:
lambda: |-
static auto sendTemperature = new remote_base::RawAction<>();
sendTemperature->set_transmitter(remote_transmitter_remotetransmittercomponent_id);
sendTemperature->set_send_times(12);
sendTemperature->set_send_wait(4000);
sendTemperature->set_code_static(rubicson(88,x*10), 73);
sendTemperature->set_carrier_frequency(0);
ESP_LOGI("HA", "sending temperature %f", x);
sendTemperature->play_complex();


And quick hack of a encoding function:
crc8 is from rtl_433 code.

int32_t* rubicson(uint8_t housecode, uint16_t temperature) {
    uint8_t tmp[5];
    int32_t static s_messagebuffer[73];
    tmp[0]=housecode;
    tmp[1]=0x80 + ((temperature >> 8) & 0xf);
    tmp[2]=temperature & 0xff;
    tmp[3]=0xf0;
    const uint8_t mask[] = {128,64,32,16,8,4,2,1};
    uint8_t index = 0;
    uint8_t maskindex = 0;


    tmp[4] = crc8(tmp, 4, 0x31, 0x6c);
    for(int bit=0; bit<72; bit++)
    {
        if ((bit % 2) == 0)
        {
            s_messagebuffer[bit]=500;
            continue;
        }
        bool send = tmp[index] & mask[maskindex];

        if(send) {
            s_messagebuffer[bit]=-1940;
        } else {
            s_messagebuffer[bit]=-976;
        }
        if (maskindex == 7) {
            maskindex=0;
            index++;
        } else if (index == 3 && maskindex == 3){
            maskindex=0;
            index++;
        } else {
            maskindex++;
        }

        s_messagebuffer[72]=500;

    }

    return s_messagebuffer;
}

Reply all
Reply to author
Forward
0 new messages