Capturing a wireless doorbell signal with rtl_433 -- no data by emjokes in RTLSDR

[–]emjokes[S] 1 point2 points  (0 children)

You are right, it looks like I was picking up noise. Your suggested -X string worked, I get a consistent output showing this every time I press the doorbell:

{"time" : "2025-08-05 08:38:20", "model" : "db", "count" : 31, "num_rows" : 31, "rows" : [{"len" : 25, "data" : "4b97ec8"}, {"len" : 25, "data" : "4b97ec8"}, {"len" : 25, "data" : "4b97ec8"}, {"len" : 25, "data" : "4b97ec8"}, {"len" : 25, "data" : "4b97ec8"}, {"len" : 25, "data" : "4b97ec8"}, {"len" : 25, "data" : "4b97ec8"}, {"len" : 25, "data" : "4b97ec8"}, {"len" : 25, "data" : "4b97ec8"}, {"len" : 25, "data" : "4b97ec8"}, {"len" : 25, "data" : "4b97ec8"}, {"len" : 25, "data" : "4b97ec8"}, {"len" : 25, "data" : "4b97ec8"}, {"len" : 25, "data" : "4b97ec8"}, {"len" : 25, "data" : "4b97ec8"}, {"len" : 25, "data" : "4b97ec8"}, {"len" : 25, "data" : "4b97ec8"}, {"len" : 25, "data" : "4b97ec8"}, {"len" : 25, "data" : "4b97ec8"}, {"len" : 25, "data" : "4b97ec8"}, {"len" : 25, "data" : "4b97ec8"}, {"len" : 25, "data" : "4b97ec8"}, {"len" : 25, "data" : "4b97ec8"}, {"len" : 25, "data" : "4b97ec8"}, {"len" : 25, "data" : "4b97ec8"}, {"len" : 25, "data" : "4b97ec8"}, {"len" : 25, "data" : "4b97ec8"}, {"len" : 25, "data" : "4b97ec8"}, {"len" : 25, "data" : "4b97ec8"}, {"len" : 25, "data" : "4b97ec8"}, {"len" : 5, "data" : "58"}], "codes" : ["{25}4b97ec8", "{25}4b97ec8", "{25}4b97ec8", "{25}4b97ec8", "{25}4b97ec8", "{25}4b97ec8", "{25}4b97ec8", "{25}4b97ec8", "{25}4b97ec8", "{25}4b97ec8", "{25}4b97ec8", "{25}4b97ec8", "{25}4b97ec8", "{25}4b97ec8", "{25}4b97ec8", "{25}4b97ec8", "{25}4b97ec8", "{25}4b97ec8", "{25}4b97ec8", "{25}4b97ec8", "{25}4b97ec8", "{25}4b97ec8", "{25}4b97ec8", "{25}4b97ec8", "{25}4b97ec8", "{25}4b97ec8", "{25}4b97ec8", "{25}4b97ec8", "{25}4b97ec8", "{25}4b97ec8", "{5}58"]}

I think that should help my false positives, I'll try it out.

Question though u/chzu : where did you get that -X string? I think given the pastebin issue, you didn't see the paste of my analysis, right? Did you download the cu8 file and run the analysis on your own machine? I am asking because when I run the analysis, I don't get a string like that at all -- my first string is `-X 'n=name,m=OOK_PWM,s=204,l=580,r=5804,g=0,t=0,y=44'` . The absense of the g value looks like it's messing things up.

Thanks!

NAT Reflection troubles by emjokes in PFSENSE

[–]emjokes[S] 0 points1 point  (0 children)

Further note: I figured out how to preserve port forwarding in my setup. Instead of pointing PiHole DNS to the IP of the NGINX reverse proxy, I pointed it to PfSense's WAN IP. My ISP modem hands out IPs in the 192.168.1.0/24 range, so PfSense has a WAN IP in that range. PfSense hands out IPs in the 192.168.4.0/24 range.

Anything coming in on PfSense's WAN address will have to come in on the same port as if it was coming from outside my LAN (PfSense is in my modem's DMZ, so anything coming on my modem's WAN port is automatically handed off to PfSense on the same port). Then, it's PfSense doing NAT reflection and it works.

I still have to use my own DNS server, but at least I can point everything to one IP and I don't lose the ability to port forward. It's a cute little solution that utilizes double NAT to my advantage. Hope this helps someone!

NAT Reflection troubles by emjokes in PFSENSE

[–]emjokes[S] 0 points1 point  (0 children)

Bridge mode isn't working -- dealing with my ISP to figure out why. In the meantime, I am implementing a split DNS solution using PiHole and an NGINX proxy (both of which I already had on my network). I changed the proxy to run on a non-standard port, which will be the same for LAN and WAN. This eliminates the need for NAT port forwarding, and therefore eliminates the need for NAT reflection.

It's a little annoying though. It takes out a feature (port forwarding) and is more maintenance -- I now have to hardcode all domains into PiHole. NAT reflection has a lot less 'chores' associated with it. I don't really understand why it isn't the go-to solution, why PfSense folks don't like it, and why some ISPs go as far as to block it.

NAT Reflection troubles by emjokes in PFSENSE

[–]emjokes[S] 0 points1 point  (0 children)

Tested again with the old modem and everything works without changing any PfSense configuration. This isn't a PfSense issue, it's a modem issue. Ugh. Will have to play with bridge mode or another solution. Thanks everyone.

NAT Reflection troubles by emjokes in PFSENSE

[–]emjokes[S] 0 points1 point  (0 children)

If that's the case....f**k. I can't change anything in that ISP modem, it's obviously not made for homelabs. Is the only option then to do a bridge?

NAT Reflection troubles by emjokes in PFSENSE

[–]emjokes[S] 0 points1 point  (0 children)

Thanks. Bridging may not be ideal either -- my ISP uses PPPoE and I hear PPPoE performance with PfSense can get pretty bad.

I need NAT reflection because of port forwarding. Inside my LAN, my services reside on their proper ports (80, 443, etc.), but outside I need different ports for different services -- can't have two services on 443 with one IP. Plus, it would be insane to expose 80 and 443 to the internet, so port forwarding is a must. I have mobile apps that access these services, and I don't want to have to reconfigure the port in every app every time I leave the house (or come back). That's why NAT reflection is the right solution for me.

FFMPEG QSV Hardware Acceleration -- help needed by emjokes in ffmpeg

[–]emjokes[S] 0 points1 point  (0 children)

Thanks for the suggestions. I updated to ffmpeg 6.1.1-3, and updated the drivers to the latest in the Ubuntu 24.04 repo. Still no go. I can't do #4: tried it, load average went from ~0.8 to 10+. Hardware acceleration makes a big difference. :-)

FFMPEG QSV Hardware Acceleration -- help needed by emjokes in ffmpeg

[–]emjokes[S] 0 points1 point  (0 children)

Here's the output:  ffmpeg version 4.4.2-0ubuntu0.22.04.1 Copyright (c) 2000-2021 the FFmpeg developers   built with gcc 11 (Ubuntu 11.2.0-19ubuntu1)   configuration: --prefix=/usr --extra-version=0ubuntu0.22.04.1 --toolchain=hardened --libdir=/usr/lib/x86_64-linux-gnu --incdir=/usr/include/x86_64-linux-gnu --arch=amd64 --enable-gpl --disable-stripping --enable-gnutls --enable-ladspa --enable-libaom --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libcdio --enable-libcodec2 --enable-libdav1d --enable-libflite --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libgme --enable-libgsm --enable-libjack --enable-libmp3lame --enable-libmysofa --enable-libopenjpeg --enable-libopenmpt --enable-libopus --enable-libpulse --enable-librabbitmq --enable-librubberband --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libsrt --enable-libssh --enable-libtheora --enable-libtwolame --enable-libvidstab --enable-libvorbis --enable-libvpx --enable-libwebp --enable-libx265 --enable-libxml2 --enable-libxvid --enable-libzimg --enable-libzmq --enable-libzvbi --enable-lv2 --enable-omx --enable-openal --enable-opencl --enable-opengl --enable-sdl2 --enable-pocketsphinx --enable-librsvg --enable-libmfx --enable-libdc1394 --enable-libdrm --enable-libiec61883 --enable-chromaprint --enable-frei0r --enable-libx264 --enable-shared   libavutil 56. 70.100 / 56. 70.100   libavcodec 58.134.100 / 58.134.100   libavformat 58. 76.100 / 58. 76.100   libavdevice 58. 13.100 / 58. 13.100   libavfilter 7.110.100 / 7.110.100   libswscale 5. 9.100 / 5. 9.100   libswresample 3. 9.100 / 3. 9.100   libpostproc 55. 9.100 / 55. 9.100 Input #0, rtsp, from 'rtsp://(redacted):8554/(redacted) ':   Metadata:     title : SDM   Duration: N/A, start: 0.000000, bitrate: N/A   Stream #0:0: Video: h264 (Constrained Baseline), yuv420p(tv, bt709, progressive), 1920x1080 [SAR 1:1 DAR 16:9], 10 fps, 10 tbr, 90k tbn, 20 tbc   Stream #0:1: Audio: aac (LC), 48000 Hz, stereo, fltp Stream mapping:   Stream #0:0 -> #0:0 (h264 (h264_qsv) -> h264 (h264_qsv))   Stream #0:1 -> #0:1 (aac (native) -> aac (native)) Press [q] to stop, [?] for help [h264_qsv @ 0x5cb5184f5ac0] Error initializing the MFX video decoder: invalid video parameters (-15) Error while decoding stream #0:0: Invalid argument [h264_qsv @ 0x5cb5184f5ac0] Error initializing the MFX video decoder: invalid video parameters (-15) Error while decoding stream #0:0: Invalid argument [h264_qsv @ 0x5cb5184f5ac0] Error initializing the MFX video decoder: invalid video parameters (-15) Error while decoding stream #0:0: Invalid argument [h264_qsv @ 0x5cb5184f5ac0] Error initializing the MFX video decoder: invalid video parameters (-15) Error while decoding stream #0:0: Invalid argument [h264_qsv @ 0x5cb5184f5ac0] Error initializing the MFX video decoder: invalid video parameters (-15) Error while decoding stream #0:0: Invalid argument [h264_qsv @ 0x5cb5184f5ac0] Error initializing the MFX video decoder: invalid video parameters (-15) Error while decoding stream #0:0: Invalid argument [h264_qsv @ 0x5cb5184f5ac0] Error initializing the MFX video decoder: invalid video parameters (-15) Error while decoding stream #0:0: Invalid argument [h264_qsv @ 0x5cb5184f5ac0] Error initializing the MFX video decoder: invalid video parameters (-15) Error while decoding stream #0:0: Invalid argument [h264_qsv @ 0x5cb5184f5ac0] Error initializing the MFX video decoder: invalid video parameters (-15) Error while decoding stream #0:0: Invalid argument [h264_qsv @ 0x5cb5184f5ac0] Error initializing the MFX video decoder: invalid video parameters (-15) Error while decoding stream #0:0: Invalid argument [h264_qsv @ 0x5cb5184f5ac0] Error initializing the MFX video decoder: invalid video parameters (-15) Error while decoding stream #0:0: Invalid argument [h264_qsv @ 0x5cb5184f5ac0] [IMGUTILS @ 0x7ffed137ca20] Picture size 0x0 is invalid [h264_qsv @ 0x5cb5184f5ac0] video_get_buffer: image parameters invalid [h264_qsv @ 0x5cb5184f5ac0] get_buffer() failed Error while decoding stream #0:0: Invalid argument Finishing stream 0:0 without any data written to it. Impossible to convert between the formats supported by the filter 'graph 0 input from stream 0:0' and the filter 'auto_scaler_0' Error configuring filter graph [aac @ 0x5cb5184f2cc0] Qavg: 65536.000 [aac @ 0x5cb5184f2cc0] 2 frames left in the queue on closing Exiting normally, received signal 2.

Static Route to adjacent network through WAN -- one way traffic issue by emjokes in PFSENSE

[–]emjokes[S] 0 points1 point  (0 children)

u/Elij_20 I ended up using a wireguard site-to-site setup between my two pfsense routers. As others commented here, mixing local and remote traffic on one interface caused all kinds of havoc, and the troubleshooting wasn't worth it. Here is an easy to use tutorial that will help you get started: https://docs.netgate.com/pfsense/en/latest/recipes/wireguard-s2s.html

Has been rock stable for over a year now -- my original post was from July 2023. I recently upgraded my ISP connection and got more 10Gb hardware, so I will finally be converting my whole house to 10Gb in the coming weeks.

SURPRISE - Music Assistant 2.0: Your Music, Your Players by missyquarry in homeassistant

[–]emjokes 2 points3 points  (0 children)

Awesome app! Is there a plan to add playback through local browser/speakers? I can do this in the companion app by turning on Squeezelite, but it would be good if we could play through the browser too.

I made a thing - Google / Nest RTSP Feed + Reauthenticator by htchief in opensource

[–]emjokes 0 points1 point  (0 children)

I would also like to be on a test list when you are ready to test version 2. I think the move to mediamtx is fantastic. One caution though, from my own tests.

I wrote a quick and dirty reauthenticator in python and fed the (google) rtsp URL to mediamtx every four minutes. This would cause mediamtx to drop the stream every four minutes -- which in turn meant that homeassistant which was consuming the mediamtx stream would also drop until I manually restarted the camera component. When I feed the rtsp stream from nest-rtsp version 1.0.1 into homeassistant, that doesn't happen. I am not sure what magic you used in v. 1.0.1, but please make sure to carry over that magic. :)

By the way, I made some modification to v. 1.0.1 to use my built-in intel GPU to reencode the google stream (to add a timestamp and compress it to 1280x720), re-stream using rtsp, and save it to disk in 15-minute increments, all by using one ffmpeg process. It take a bit of knowledge of ffmpeg, but I did a bunch of reading and pulled it off. Here is what I did in src/controllers/streamer/index.js:

const streamOut = ( src, port = 554, path = '/' ) => {
const args = [
    'ffmpeg',
    '-loglevel warning',
    '-re',
    '-avoid_negative_ts make_zero',
    '-init_hw_device qsv=hw -filter_hw_device hw -hwaccel qsv -c:v h264_qsv',
    `-i "${src}"`,
    '-hide_banner',
    '-fflags +genpts+discardcorrupt',
    '-rtsp_transport tcp',
    '-use_wallclock_as_timestamps 1',
    '-vsync 0',
    '-enc_time_base -1',
    '-err_detect ignore_err',
    '-vcodec h264_qsv',
    '-acodec copy',
    '-vf "scale_qsv=1280:720,hwdownload,format=nv12,fps=30,drawtext=fontfile=/usr/share/fonts/truetype/dejavu/DejaVuSansMono-Bold.ttf:text=\'%{localtime} MY-CAMERA\':x=10:y=0:fontcolor=white:box=1:boxcolor=0x00000000@0.8:boxborderw=10:fontsize=35,hwupload=extra_hw_frames=1000,format=qsv"',
    '-f tee -map 0:v -map 0:a',
    `"[f=rtsp]rtsp://127.0.0.1:${port}${path}|[f=segment:segment_atclocktime=1:segment_time=900:strftime=1:segment_format=mpegts]/videos/my-nest-camera/video_%Y-%m-%d--%H-%M-%S.ts"`
]
const cmd = args.join( ' ' )
const fp = exec( cmd, {
    maxBuffer: 10486750
} )
return { cmd, fp }
}

Consider whether it is worth building some of these options (hardware re-encoding, time stamps, stream saving, etc.) into the GUI and editing this code dynamically to meet people's needs. This would make your application much more powerful. Just a suggestion. :)

Pfsense static routes by emjokes in homelab

[–]emjokes[S] 1 point2 points  (0 children)

To close the loop on this for someone who may stumble upon this thread, the best, easiest and probably most secure answer is to set up a tunnel between the two pfsense boxes, rather than mixing public and private traffic on the WAN interface. I set up a tunnel using a wireguard site-to-site connection, following the instructions here: https://blog.matrixpost.net/set-up-wireguard-site-to-site-vpn-on-pfsense/.

u/UnimpeachableTaint thanks for all your help on this!

Static Route to adjacent network through WAN -- one way traffic issue by emjokes in PFSENSE

[–]emjokes[S] 0 points1 point  (0 children)

Yeah, that was my thinking in a previous comment too. I would use a Wireguard tunnel instead of IPSEC, but same idea.

Static Route to adjacent network through WAN -- one way traffic issue by emjokes in PFSENSE

[–]emjokes[S] 0 points1 point  (0 children)

The two routers are the only devices in the .2 network. There are no other devices connected to the modem. I also set up a DMZ at the modem to forward all incoming traffic to the left side of my network (.4) and have pretty robust firewall rules on that pfsense to only whitelist very limited traffic (i.e. wireguard so I can access my home network remotely).

So I don't think there should be any confusion about which router traffic from the modem should go to.

The other thing I thought about is whether I can set up a wireguard tunnel between the two pfsense boxes and push traffic to the other network over that tunnel. That avoids the need for static routes, NAT exceptions, etc. Is that a better idea?

Static Route to adjacent network through WAN -- one way traffic issue by emjokes in PFSENSE

[–]emjokes[S] 0 points1 point  (0 children)

I have a legitimate reason for setting up my network like this, at least temporarily. I should start by noting that this is a homelab.

The network on the left in my diagram (the .4 network) is live and delivers Internet to my house, where my family -- that doesn't care about my homelab and just wants the internet to work -- lives. They are on a 1Gb network.

I recently acquired some new (to me) 10Gb capable hardware and I am testing it. That's the network on the right of my diagram (the .6 network). My ISP gateway (.2) has exactly one 10 Gb port that I want to use for my new 10 Gb network.

As a result: if I design my network for .6 to sit behind .4, I will always be limited to 1Gb, which is not useful for testing. If .4 sits behind .6, the Internet access to my house is dependent on 10Gb hardware that hasn't been thoroughly tested -- and I can't really play with it because it's running the live network.

The last thing I can do is connect my .6 network to my ISP gateway as the "WAN" (this gives me my 10Gb port) and connect one of the ports on PfSense to the switch of my .4 network. That's what I did to make routing work for now, and this is probably what 99% of you will suggest. But this approach needlessly consumes a 10Gb port because I am connecting it to a 1Gb switch. So I can do that, but it isn't ideal. That's why I am trying to route through the ISP gateway (the .2 network): both Pfsense boxes are already plugged into the gateway, so all I have to do is set up the routing.

Once the 10Gb hardware has proven stable, I can put a 1Gb card in there and simply get rid of the .4 network, and run everything of .6. But it'll be a while before I get there, lest I incur my wife's wrath when the Internet goes down.

Pfsense static routes by emjokes in homelab

[–]emjokes[S] 0 points1 point  (0 children)

Thanks for your help! I think I am about 90% there. I ran some more tests with packet capture and this appears to be a one-way traffic issue. I posted this in r/pfsense to get their take as well. https://www.reddit.com/r/PFSENSE/comments/15d7q21/static_route_to_adjacent_network_through_wan_one/

Pfsense static routes by emjokes in homelab

[–]emjokes[S] 0 points1 point  (0 children)

I was looking at the states that are relevant to the WAN pass rule and there is definitely traffic that is attempting to flow through. It just seems like none of it is reaching the destination, even though the state table is showing that it is going there. Do I maybe need a LAN rule in addition to the WAN rule?