User Tools

Site Tools


din-exp

This is an old revision of the document!


Expandable DIN module

Firmware

Download on GitHub

Implemented functions

  • Connectors (T1 and T2) for connecting two DS18B20 digital thermistors with automatic detection. Reading temperature every 20 seconds and sending to MQTT with topic /T1-Celsius
  • Ethernet connection using RJ45 connector with IP address retrieval from DHCP server. Static IP address setting is not implemented
  • http web server publishing two pages
    • mqtt-wall, which is a web MQTT client, for displaying messages that the device has sent to the MQTT broker
    • SETUP page for configuring the device contains settings
      • MQTT topic
      • Device ID
      • RS485 (USB-C) BAUDRATE
      • MQTT broker IP
      • MQTT broker PORT
      • websocet MQTT PORT
      • MQTT Login
      • MQTT Password
  • Saving device settings to internal eeprom
  • OTA update - allows you to update the device firmware via Ethernet via the web interface. Available at [IP]:82/update, or from the link on the main page of mqtt-wall
  • MQTT client for sending and receiving messages from the broker
  • Measuring POE voltage and sending the value to MQTT when it changes
  • Watchdog timer, triggers a device restart if the firmware stops for longer than 60s
  • detect USB-C plug and publish to MQTT with topic /USBdetect
  • RS485-MQTT proxy - received RS485 data forward to MQTT with topic /RS485_RX

Hardware interfaces

Front view pinout
1 - 11-13.8V / 1A max DC PWR input
2 - GND
2x JST 1-wire for DS18B20 thesrnistor
1 - +3,3V / max 500mA
2 - 1-wire bus (Gpio15)
3 - GND
2 - RS485-A
1 - RS485-B
Four LEDs RED - fail fuse
GRN - ETH 100M
GRN - ETH ACT
GRN - Power
USB-C serial
+5V VBUS
SBU1 - 3V3 Gpio33 (I2C SDA)
SBU2 - 3V3 Gpio32 (I2C SCL)
1,2,3,6 - Ethernet
4+5 - POE DC power input 12-24V/max 1A, any polarity
7+8 - POE DC power input 12-24V/max 1A, any polarity
Green LED - 100M
Yelow LED - ACT

GPIO

1 - +12V from DC jack or POE
2 - +12V from DC jack or POE
3 - GND
4 - GND
5 - GPIO5
6 - +3,3V from internal step down
7 - GPIO33
8 - GPIO15
9 - GPIO12
10 - GPIO14
11 - GPIO02
12 - GPIO13
13 - GPIO04
14 - GPIO0
15 - GPIO39
16 - GPIO16
17 - GPIO32
18 - GPIO36
19 - GND
20 - GND

BOM

din-exp.1762116835.txt.gz · Last modified: by ok1hra