Static IP address for Raspberry Pi

34 views
Skip to first unread message

Louis LaBrunda

unread,
May 24, 2024, 11:05:26 AMMay 24
to VAST Community Forum
Hi Mariano and Friends,

I would like to be able to change the IP address for the Raspberry Pi from within VA Smalltalk code.  I was changing /etc/dhcpcd.conf to set both the eth0 and wlan0 addresses to the same IP address.  It seems that dhcpcd has fallen out of favor.  I think one can still get it and use it but I would just as soon move on.

I don't know how/where Linux keeps this information but it seems like /etc/dhcpcd.conf isn't really its home and Linux (via a dhcpcd server) takes the values from /etc/dhcpcd.conf and puts them where it wants them.

Are there any command line commands or function calls that I can make to change the values?

Lou

Noschvie

unread,
May 29, 2024, 6:39:17 AMMay 29
to VAST Community Forum

Louis LaBrunda

unread,
May 29, 2024, 11:07:01 AMMay 29
to VAST Community Forum
Hi Noschvie,

Thanks for the link.  I stumbled on nmcli and the GUI version of NetworkManager.  It looks like nmcli can do what I was asking for but I probably don't really need it.  I have two programs that run on a Raspberry Pi.  I share one of these with my cousin.  The programs run without a keyboard and monitor.  They act as a web server allowing the user to change setting with a web browser.  I wanted an easy way to change some to the Linux settings from within my setting web page.  With the older way of changing the IP address in a file, it was easier for me to change the file from within my program than to have my cousin change it with say RealVNC.  But now the  GUI version of NetworkManager and RealVNC make it easy.

Lou

Reply all
Reply to author
Forward
0 new messages