lynchlab
@aoife_l22 · Nisan 2025 tarihinde katıldı
Engineering student · university
- Konular
- 15
- Yanıtlar
- 79
- Puan
- 0
Oluşturulan forum yanıtları
Yapay zekâ tarafından English dilinden çevrildi ·
0: phy0: Wireless LAN
Soft blocked: no
Hard blocked: no
Sadece Wi-Fi var, hiç Bluetooth girişi yok.
0: phy0: Wireless LAN
Soft blocked: no
Hard blocked: no
Only Wi-Fi, no Bluetooth entry at all.
Yapay zekâ tarafından English dilinden çevrildi ·
Kurulu, yoksa bluetoothctl çalışmazdı.
It’s installed, bluetoothctl wouldn’t run otherwise.
Yapay zekâ tarafından English dilinden çevrildi ·
Pi’yi her konum tespiti arasında ESP32’de olduğu gibi derin uykuya alabilir misiniz?
Could you put the Pi into deep sleep between fixes like an ESP32?
Why does the reference matter so much? Couldn’t it use the internal 1.1 V bandgap?
Yapay zekâ tarafından English dilinden çevrildi ·
Maalesef her yerde aynı ağ yok. İki bina ayrı bir IoT SSID’sinde, bir laboratuvarın kendi yönlendiricisi var ve şifreler her dönem değiştiriliyor. Ayrıca token’ların zaten her düğüm için farklı olması gerekiyor.
Not the same network everywhere sadly. Two buildings are on a separate IoT SSID, one lab has its own router, and the passwords get rotated each term. Plus the tokens have to be different per node anyway.
Liam’s half right. avr-libc’s printf family is built without float support by default to save flash, so %f prints ?. You can link the float version (-Wl,-u,vfprintf -lprintf_flt) but it costs about 1.5 KB of flash and the Arduino IDE makes the flags annoying.
What I do on Nanos is convert the floats with dtostrf first, then format strings:
char ts[8], hs[8], buf[96];
dtostrf(t, 0, 2, ts); // width 0 = no padding
dtostrf(h, 0, 1, hs);
snprintf(buf, sizeof(buf), "{"temp_c":%s,"rh":%s,"seq":%lu}", ts, hs, seq);
Or send integers: temp_c10 as 2154 and scale it back later. Same quota, zero float formatting. Also check for NaN when the SHT31 read fails: dtostrf prints nan, which isn’t valid JSON, and the whole message gets stored as raw text. Skip the key when the read fails.
That field is the TSF, it’s the access point’s own uptime counter in microseconds. Not a date or time.
Both fixed. The society bought the isolated carrier for the pH circuit and the 0.3 jumps are gone. The JSON rule with the any group saved fine, and the pump ran three times today without a single alarm. Then I dropped the probe in pH 4 buffer to test and it opened after five minutes, as expected.
Yapay zekâ tarafından English dilinden çevrildi ·
Gerçekten faydalı, teşekkürler. Yönetici „kartta public CA, sırlar şifreli NVS’te“ yaklaşımını kabul etti. X.509 kısmı bana bir hafta kazandırdı; openssl ile bir CA üretmeye zaten başlamıştım. Garip ama geçen hafta ikinci bir kart için kartı klonlamıştım ve veriler eksik çıktı; tam da ele geçirme (takeover) meselesiydi.
Really helpful, thank you. Supervisor accepted “public CA on card, secrets in encrypted NVS”. The X.509 bit saved me a week, I had already started generating a CA with openssl. Funny enough I had cloned the card for a second board last week and the data was patchy, it was exactly the takeover thing.
Why not torque mode with a low limit? Then hitting the end stop wouldn’t hurt.
Yapay zekâ tarafından English dilinden çevrildi ·
Son sınıf bitirme projemizde hemen hemen bunun aynısını yaptık (2G üzerinden akıllı sayaçlar, kendi trafiğimizi dinledik). Laura’nın dediklerinin hepsi doğru. Sizin yerinizde ne yapardım, sırasıyla anlatayım.Birincisi, profili ayırın. 38 TLS cihazı için yeni bir profil oluşturun ve varsayılan ayarda bırakın, yani yalnızca 8883 üzerinden TLS. Cihazları bu profile taşıyın. Bu profildeki cihazlar 1883 üzerinden hiç giriş yapamaz, dolayısıyla biri onlara dokunsa bile hiçbir şey açık metin olarak gitmez.İkincisi, 12 eski cihaz için düz MQTT’ye izin veren ayrı bir profil oluşturun ve bunu sıkı şekilde kilitleyin:
- İzin verilen ağlar: Yalnızca operatörünüzün trafiğinin geldiği adres aralığını girin. Mümkünse operatörden özel bir APN isteyin; böylece aralık onların özel aralığı olur. Bunun dışından gelenler reddedilir (CONNACK 5).
- TLS olmadan izin verilen komutlar: Boş bırakın ya da en fazla
sys.infoekleyin. Aslasys.rebooteklemeyin. Diğer komutlar yalnızca bir TLS oturumu bekler; bu cihazların hiçbir zaman sahip olmayacağı bir oturum olduğundan bu komutlar zaman aşımına uğrar. - İzin verilen kimlik doğrulama: Yalnızca erişim belirteci kullanıyorlarsa onu seçin.
Üçüncüsü, test uzmanının ele geçirdiği kabinin belirtecini yenileyin; dürüst olmak gerekirse 12’sinin de belirtecini yenileyin, çünkü iki yıldır internet üzerinden açık metin olarak geçiyorlar.Yazılım güncellemeleri ve cihaz ayarları zaten hiçbir zaman açık metin gönderilmez, dolayısıyla bunları sızdırmıyorsunuz. Yukarıdakilerin tamamı bu sayfada: Device transport security. BT ekibine verilecek dürüst yanıt şu: “38’i uçtan uca şifreli, 12’si şifreli değil ve değiştirilene kadar izole edildi”.
Did our final-year project on almost exactly this (smart meters over 2G, we sniffed our own). Everything Laura said. Here’s what I’d do in your position, in this order.
First, split the profile. Make a new profile for the 38 TLS units and leave it on the default, TLS only on 8883. Move them over. That profile’s devices can’t log in on 1883 at all, so even if somebody pokes at them nothing goes in clear.
Second, the 12 old ones get their own profile with plain MQTT allowed, and you lock it down hard:
- Allowed networks: put in only the address range your operator’s traffic comes from. Ask the operator for a private APN if you can, then it’s their private range. Anything outside gets refused (CONNACK 5).
- Commands allowed without TLS: leave it empty, or at most
sys.info. Neversys.reboot. Other commands just wait for a TLS session, which these units will never have, so they expire. - Allowed authentication: only access token if that’s all they use.
Third, rotate the token of the cabinet the tester captured, and honestly all 12, because they’ve been crossing the internet in clear for two years.
Firmware updates and device settings are never sent in clear anyway, so you’re not leaking those. Everything above is on this page: Device transport security. For IT, the honest answer is “38 are encrypted end to end, 12 are not and are fenced in until they’re replaced”.
Yapay zekâ tarafından English dilinden çevrildi ·
Güç tasarrufu açıktı. Yapılandırma dosyasını ekledim, NetworkManager’ı yeniden başlattım ve o zamandan beri 3 gündür kesintisiz çevrimiçi. O zamandan beri Log sekmesinde keepalive_timeout yok. SSH bağlantısı da anında gerçekleşiyor; bunun bağlantılı olduğunu fark etmemiştim bile. Teşekkürler Ciaran!
Power save was on. Added the conf file, restarted NetworkManager, and it’s been online for 3 days straight now, no keepalive_timeout in the Log tab since. SSH is instant too, which I hadn’t even realised was related. Thank you Ciaran!
Yapay zekâ tarafından English dilinden çevrildi ·
Dün çalıştırdım, laboratuvardaki herkes bayıldı. IT’ye hiç sormak zorunda kalmadım, bu ayrı bir kazançtı. Tek sorun: önce status=active kullandım, seen-set boş olduğu için yeniden başlatmadan sonra onaylanmış alarmları tekrar tekrar okumaya devam etti. Sizin yazdığınız gibi OPEN’a geçtim. Ayrıca piper “frz” olarak okuduğu için cihaz adlarını “frz-03” yerine “freezer three” olarak değiştirmem gerekti.
Got it running yesterday, everyone in the lab loves it. Had to ask IT nothing, which was a win. Only thing: I first used status=active and it kept repeating acknowledged alarms after a restart because my seen-set was empty, switched to OPEN like you wrote. Also had to change device names from “frz-03” to “freezer three” because piper read it as “frz”.
Yapay zekâ tarafından English dilinden çevrildi ·
Başsız, hiç ekranı yok. Yine de ihtimale karşı ekran kararmasını (blanking) kapattım, değişiklik olmadı.
It’s headless, no screen at all. I turned blanking off anyway just in case, no change.
Yapay zekâ tarafından English dilinden çevrildi ·
Geçen yıl bir laboratuvar için Edison breakout kartıyla uğraştım. Bu kartta /dev/ttyMFD1 dosyasını açmak yetmiyor: 0 ve 1 numaralı pinler bir pin çoklayıcı ve seviye dönüştürücülerden geçiyor; bunlar ayarlanana kadar UART başlığa bağlı değildir, pinler yalnızca düz GPIO’dur. Bu yüzden port hatasız açılıyor ama hiçbir şey okunmuyor.Kolay yol, UART’ı kart numarasıyla açtığınızda mux’ı sizin yerinize ayarlayan mraa kütüphanesini kullanmaktır:
import mraa
u = mraa.Uart(0) # pins 0/1 on the Arduino breakout, sets the mux
u.setBaudRate(115200)
u.setMode(8, mraa.UART_PARITY_NONE, 1)
while True:
if u.dataAvailable(1000):
line = u.readStr(64).strip() # "caps_ok=1823;caps_rej=12"
vals = dict(kv.split("=") for kv in line.split(";"))
# add to the payload the Edison already sends:
payload["caps_ok"] = int(vals["caps_ok"])
payload["caps_rej"] = int(vals["caps_rej"])
Ayrıca kablolamanın çapraz olduğunu kontrol edin: OpenMV TX, Edison’un RX (pin 0) ucuna; OpenMV RX, Edison’un TX (pin 1) ucuna bağlanmalı. Breakout kartında pin 0 RX’tir; yazdığınız şey kablolamayla birebir aynıysa bunları birbiriyle değiştirin.
I fought the Edison breakout for a lab last year. Opening /dev/ttyMFD1 isn’t enough on that board: pins 0 and 1 go through a pin multiplexer and the level shifters, and until those are set up the UART isn’t connected to the header at all, the pins are plain GPIO. That’s why it opens fine and reads nothing.
The easy way is the mraa library, which sets the mux for you when you open the UART by its board number:
import mraa
u = mraa.Uart(0) # pins 0/1 on the Arduino breakout, sets the mux
u.setBaudRate(115200)
u.setMode(8, mraa.UART_PARITY_NONE, 1)
while True:
if u.dataAvailable(1000):
line = u.readStr(64).strip() # "caps_ok=1823;caps_rej=12"
vals = dict(kv.split("=") for kv in line.split(";"))
# add to the payload the Edison already sends:
payload["caps_ok"] = int(vals["caps_ok"])
payload["caps_rej"] = int(vals["caps_rej"])
Also check the wiring is crossed: OpenMV TX to the Edison’s RX (pin 0), OpenMV RX to the Edison’s TX (pin 1). Pin 0 is RX on the breakout, so if what you wrote is exactly how it’s wired, swap them.

