hakan_dev
@keskin-h · Joined December 2025
Backend geliştirici · yazılım
- Topics
- 5
- Replies
- 38
- Points
- 0
Forum Replies Created
MQTT’yi seri hatta taşımaya gerek yok bence, Hermetry için TLS de gerekiyor, Nano onu zaten yapamaz. Bende iki tane böyle Nano var, şöyle çalışıyor:
Nano her 10 saniyede bir satır JSON basıyor:
Serial.print("{"oil_temp":");
Serial.print(t, 1);
Serial.print(","pressure_bar":");
Serial.print(p, 2);
Serial.println("}");
Pi’de Python, pyserial ile satırı okuyor, paho-mqtt ile 8883’e TLS’le bağlanıp v1/telemetry‘ye QoS 1 gönderiyor:
line = ser.readline().decode(errors='ignore').strip()
try:
data = json.loads(line)
except ValueError:
continue # bozuk satırı atla
if isinstance(data, dict):
client.publish('v1/telemetry', json.dumps(data), qos=1)
O try/except önemli: Nano reset atınca ya da hat parazit yapınca yarım satır geliyor. JSON olmayan bir gövdeyi Hermetry raw diye tek bir anahtar olarak saklıyor, sonra telemetri sekmesinde saçma metinler görürsün.
İkinci Nano gelince Pi’yi gateway yap: cihazı eklerken “This device is a gateway” seç, iki Nano’yu v1/gw/telemetry ile ayrı alt cihaz olarak gönder, mesela {"Kompresor-1": {"values": {...}}, "Kompresor-2": {...}}. Her biri Hermetry’de kendi cihazı olur, alarmları ayrı kurarsın.
Translated from Türkçe by AI ·
OK, I think it’s time to retire my cron script.
Tamam, benim cron script’i emekliye ayırma zamanı galiba.
Translated from Türkçe by AI ·
Run a script against the API in a loop and put it in cron. That’s how I do it.
API’den bir script ile döngüde at, cron’a koy. Ben öyle yapıyorum.
Translated from Türkçe by AI ·
Is the baud rate correct? What was the board’s default?
Baud doğru mu? Kartın varsayılanı neydi?
Yazılım tarafında satırı CRC ya da en azından format kontrolüyle doğrulamıyor musunuz? Bozuk satırı atmak ilk iş.
Translated from Türkçe by AI ·
Keep logging RSSI in telemetry. If you also set a threshold rule, you will get early warning if the antenna cable loosens.
RSSI’ı telemetride tutmaya devam edin, bir eşik kuralı da koyarsanız anten kablosu gevşerse önceden haber alırsınız.
Pi başına 30 sensör çok mu? Belki iki Pi’ye bölmek gerekir?
Translated from Türkçe by AI ·
Set the window to 50, it will be more stable.
Pencereyi 50’ye çıkarın, daha stabil olur.
Translated from Türkçe by AI ·
What RSSI are you seeing? If you add WiFi.RSSI() to the telemetry in the code, you’ll see it on the graph instead of guessing.
RSSI kaç görüyorsun? Kodda WiFi.RSSI()‘yi telemetriye ekletirsen grafikte görürsün, tahmin yürütmek yerine.
Netplan’da macaddress satırı yazınca düzeliyor diye hatırlıyorum.
Translated from Türkçe by AI ·
Don’t connect an oscilloscope while it’s plugged in. Most of these boards have no isolation, the GND is directly tied to the mains. If you short the scope’s ground with it, you lose the probe and yourself.
Fişe takılıyken osiloskop bağlama. Bu kartların çoğunda izolasyon yok, GND doğrudan şebekeye bağlı oluyor. Osiloskobun toprağı ile kısa devre yaparsın, hem prob gider hem sen.
Translated from Türkçe by AI ·
Solved, thanks.I couldn’t find a USB-RS232 converter, so I got a MAX3232 module from the electronics guy. I connected it, still got garbage, then as Esra said I crossed pins 2 and 3, and the lines started coming in properly. I also turned off the serial console, the login screen disappeared. GPIO15 also came out fine, I got lucky.Thanks to Tuğba’s note, weight_kg is going out as a number from the very start, and it’s being plotted as a graph on the dashboard.
Çözüldü, sağ olun.
USB-RS232 çevirici bulamadım, elektronikçiden MAX3232 modülü aldım. Bağladım, yine çöp geldi, sonra Esra’nın dediği gibi 2 ile 3’ü çaprazladım, satırlar düzgün gelmeye başladı. Seri konsolu da kapattım, login ekranı kayboldu. GPIO15 da sağlam çıktı, şanslıymışım.
Tuğba’nın notu sayesinde ilk günden weight_kg sayı olarak gidiyor, dashboard’da grafik çiziliyor.
Translated from Türkçe by AI ·
I checked the menu, it says 9600 8N1. The manual says so too.
Menüden baktım, 9600 8N1 yazıyor. Kılavuz da öyle diyor.
Translated from Türkçe by AI ·
You’re right Esra, I mixed it up with a different product. If you need the History API script, I have a Python example that runs with cron, just let me know.
Haklısın Esra, başka bir üründen karıştırmışım. History API scripti lazım olursa bende cron’la çalışan bir Python örneği var, yazın.
Translated from Türkçe by AI ·
For the report part: I think Hermetry itself sends the monthly report by e-mail; I remember there is a scheduled report setting.
Rapor kısmı için: Hermetry bence aylık raporu kendisi mail atıyordur, zamanlanmış rapor ayarı vardır diye hatırlıyorum.

