Nп/п : 36 из 60
 От   : pozz                                2:5075/128        07 сен 23 09:54:06
 К    : Theo                                                  07 сен 23 10:57:02
 Тема : Re: Configure network of an embedded device
----------------------------------------------------------------------------------
                                                                                 
@MSGID: 2@dont-email.me> 9223627d
@REPLY: FNJpz@news.chiark.greenend.org.uk>
608d85fc
@REPLYADDR pozz <pozzugno@gmail.com>
@REPLYTO 2:5075/128 pozz
@CHRS: CP866 2
@RFC: 1 0
@RFC-Message-ID: 2@dont-email.me>
@RFC-References: 1@dont-email.me>
FNJpz@news.chiark.greenend.org.uk>
@TZUTC: 0200
@PID: Mozilla/5.0 (Windows NT 10.0; Win64; x64;
rv:102.0) Gecko/20100101 Thunderbird/102.15.0
@TID: FIDOGATE-5.12-ge4e8b94
Il 06/09/2023 22:56, Theo ha scritto:
> pozz <pozzugno@gmail.com> wrote:
>> So I`m wondering if there`s a standard or quasi-standard way to manage
>> network configuration of devices on the same LAN.
>>
>> The situation isn`t so uncommon. IPCams are network oriented devices
>> that can be controller by a Cloud service from the manufacturer, but
>> mainly from a web page. It usually happens that more than one IPCam are
>> installed on the same LAN.

> There are several ways to do this.

> If there`s ethernet, it`s not too complicated.  When the device boots, make a
> DHCP request and provide your hostname as the device name plus a serial
> number.  For example, supposing your product is called `HomeBox` and the
> device`s serial number (MAC address?) is 12:34:56:78:90:ab.  Then make a
> DHCP request and specify your hostname as `homebox90ab`.  Use enough digits
> to minimise the changes of name collisions.  A user can either look on the
> router for the `homebox` device, 

This isn`t an option for typical users without technical knowledge.


> or you print instructions telling the user
> to go to http://homebox90ab/ on a label.  

Interesting. That URL has a simple hostname that must be resolved by the 
router. Is it guaranteed that the router is able to resolve the host in 
URL in the device with the same hostname? What happens if more than one 
device on the LAN make DHCP requests with the same hostname?


> At that site they can configure
> the network settings if they want a fixed IP or whatever.

> For wifi, it`s harder because you need to preconfigure wifi settings before
> the device appears on the network.

> One way is to include Bluetooth functionality, which is included on many
> wifi chipsets.  An app is told the wifi config by the user, connects to the
> Bluetooth and sends the details that way.  The device then connects to the
> wifi and may shut down the Bluetooth interface.  To reconnect, a factory
> reset via a pinhole reset button will clear the wifi settings and re-enable
> Bluetooth.

> If you don`t have Bluetooth or a mobile app, another option is to power up
> in factory mode offering an access point with a default SSID, say
> `homebox90ab`, and no password.  The user connects to the SSID and goes to a
> web page as the ethernet example.  There they configure their wifi
> credentials and, once saved, the device reboots and tries to connect to that
> wifi network.  If it fails, the user must do the pinhole reset and try
> again.

>> For example, Dahua IPCams usually start with the fixed IP address
>> 192.168.1.108. They have a software (Config Tool) that can be used[3] to
>> manage network configuration of multiple IPCams, even if they are
>> installed at the same time with the default IP address 192.168.1.108.

> On an enterprise network, maybe expecting any kind of DHCP is too much.  In
> which case the initial setup could be its own DHCP server: you plug in a
> laptop which gets an IP address handed out by the device, and go to
http://192.168.1.1/ (or http://homebox90ab/) which is the device.  

Are you thinking to have a DHCP server running *on* the embedded device? 
How does the device know if send a DHCP request (to receive an IP 
address from an external DHCP server) or launch a DHCP server?
Maybe it can try a DHCP request a revert back to internal DHCP server if 
that fails.


> From
> there you configure its IP address and other settings.  Next time it reboots
> it uses the new settings.  If it is no longer accessible, there`s the
> pinhole reset procedure.

We can say that in professional environment (enterprise network) it`s 
simple to find experts with sufficient knowledge to set network 
configuration of a device.


> While it`s possible for the device to answer at a specific hardcoded IP,
> it`s a bit awkward from the user perspective - you have to configure your
> laptop with a particular static IP, netmask and so on.  Many OSes make that
> annoying, and you can`t easily switch to another network without going in
> and deleting all the settings (eg you want to search for help while
> configuring the device).

It`s very strange there isn`t any protocol at MAC level that manages IP 
configuration. MAC addresses are unique in the LAN and they could be 
discovered or printed on a label.
With this protocol, you could connect and power up all the devices and 
use a simple software to manage network IP configurations.


> On IPv6, a lot of these problems go away if SLAAC is enabled: you know your
> network prefix, you know what the device`s MAC address, so it`s trivial to
> work out the device`s static IP, or at least one IP that it`ll respond to if
> you try to connect to it.

> Theo

 --- Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101
Thunderbird/102.15.0
 * Origin: A noiseless patient Spider (2:5075/128)
SEEN-BY: 5001/100 5005/49 5015/255 5019/40 5020/715
848 1042 4441 12000
SEEN-BY: 5030/49 1081 5058/104 5075/128
@PATH: 5075/128 5020/1042 4441



   GoldED+ VK   │                                                 │   09:55:30    
                                                                                
В этой области больше нет сообщений.

Остаться здесь
Перейти к списку сообщений
Перейти к списку эх