Module RIKA Firenet
Ce module, vendu assez cher, permet de domotiser la plupart des poêles RIKA. C'est un convertisseur USB / Serial disposant d'une puce WIFI et qui se connecte en https vers un serveur chez Rika.Vue du circuit imprimé:
Schéma de principe:
Trouver l'IP du Rika Firenet.
Le hostname de la clé: iwm-BE-50-AF
Le mieux est de faire une réservation dans le serveur DHCP.
Les liens disponibles:
http://192.168.1.65/index.html
ST SPWF01S Intelligent WiFi Module
Welcome to the ST SPWF01S intelligent Wi-Fi module.This page was delivered from the SPWF01S internal HTTP server.
SPWF01S Configuration Settings Page
SPWF01S Status Page
SPWF01S Peers Page
More information about the SPWF01S and other ST products can be found at ST's website: http://www.ST.com/.
http://192.168.1.65/output_demo.html
http://192.168.1.65/input_demo.shtml
http://192.168.1.65/remote.html
http://192.168.1.65/message.shtml
http://192.168.1.65/remote.html
http://192.168.1.65/firstset.html
Flux:
LAN | tcp | 192.168.1.65:56050 -> 176.34.185.163:443 |
LAN | tcp | 192.168.1.65:55509 -> 54.247.85.77:443 |
LAN | tcp | 192.168.1.65:64735 -> 46.137.190.145:443 |
Il s'agit du nom de domaine : rika-fire-stv.herokuapp.com https://www.whatsmydns.net/#A/www.rika-firenet.com
User-Agent: RIKA-Stove
Host: rika-fire-stv.herokuapp.com
POST /api/stove/
Dialogue avec le SPWF01S d’après le firmware:
AT
AT+CFUN=1
AT+S.HTTPGET=www.rika.at,/Verbindungstest.html
AT+S.TLSCERT2=clean,all
AT&F
AT+S.TLSCERT=f_ca,1246
AT+S.TLSCERT=f_content,0
AT+S.TLSDOMAIN=f_domain,stv.rika-firenet.com
AT+S.SCFG=wifi_priv_mode,2
AT+S.SCFG=wifi_priv_mode,0
AT+S.SOCKW=00, AT+S.SOCKW=00, AT+S.SCAN
AT+S.SETTIME=1538352000
AT+S.SOCKC=00
AT+S.SOCKON=rika-fire-stv.herokuapp.com,443,s,ind
AT+S.SOCKQ=00
AT+S.SOCKR=00, AT+S.SSIDTXT= AT&W
AT+S.SCFG=wifi_mode,1
AT+S.SCFG=wifi_wpa_psk_text,
Après plusieurs essais, la solution consisterait à écouter les transactions entre le host (STM32) et le SPWF01S.
Résultat d'un lsusb -v sur le dongle USB Rika:
Bus 001 Device 019: ID 0483:5740 STMicroelectronics Virtual COM Port
Device Descriptor:
bLength 18
bDescriptorType 1
bcdUSB 2.00
bDeviceClass 2 Communications
bDeviceSubClass 0
bDeviceProtocol 0
bMaxPacketSize0 64
idVendor 0x0483 STMicroelectronics
idProduct 0x5740 Virtual COM Port
bcdDevice 2.00
iManufacturer 1 STMicroelectronics
iProduct 2 STM32 Virtual COM Port
iSerial 3 48FBE3485324
bNumConfigurations 1
Configuration Descriptor:
bLength 9
bDescriptorType 2
wTotalLength 67
bNumInterfaces 2
bConfigurationValue 1
iConfiguration 0
bmAttributes 0xc0
Self Powered
MaxPower 100mA
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 0
bAlternateSetting 0
bNumEndpoints 1
bInterfaceClass 2 Communications
bInterfaceSubClass 2 Abstract (modem)
bInterfaceProtocol 1 AT-commands (v.25ter)
iInterface 0
CDC Header:
bcdCDC 1.10
CDC Call Management:
bmCapabilities 0x00
bDataInterface 1
CDC ACM:
bmCapabilities 0x02
line coding and serial state
CDC Union:
bMasterInterface 0
bSlaveInterface 1
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x82 EP 2 IN
bmAttributes 3
Transfer Type Interrupt
Synch Type None
Usage Type Data
wMaxPacketSize 0x0008 1x 8 bytes
bInterval 255
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 1
bAlternateSetting 0
bNumEndpoints 2
bInterfaceClass 10 CDC Data
bInterfaceSubClass 0 Unused
bInterfaceProtocol 0
iInterface 0
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x03 EP 3 OUT
bmAttributes 2
Transfer Type Bulk
Synch Type None
Usage Type Data
wMaxPacketSize 0x0040 1x 64 bytes
bInterval 0
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x81 EP 1 IN
bmAttributes 2
Transfer Type Bulk
Synch Type None
Usage Type Data
wMaxPacketSize 0x0040 1x 64 bytes
bInterval 0
Device Status: 0x0001
Self Powered
Liens:
http://www.emcu.it/WiFi/Presentazioni/WiFiMKT19may2014.pdf
https://www.st.com/content/ccc/resource/sales_and_marketing/presentation/product_presentation/group0/d9/23/1a/c2/0c/55/46/2c/STSW-IDW002%20Wifi%20hands-on%20training/files/stsw-idw002_wifi_training.pdf/jcr:content/translations/en.stsw-idw002_wifi_training.pdf