May 17, 2025

Sun 3/280 - running a raspberry pi as a remote console aceess point

So yesterday I set up a raspberry pi to act as a network "gateway" to a USB to serial adapter to allow handy access to the sun3/280 in another room. I was working fine when I went to bed, now this morning I cannot ping or ssh to the machine "rpi".

Spoiler - this was due to the dhcp server on my linux machine failing to start properly. I fixed this by setting a static IP in the rpi.

Naturally this is frustrating. I want to work on the Sun 3/280, not troubleshoot some Raspbeerry Pi issue. Of course I first try the obvious thing and cycle power to the Rpi a couple of times, with no result other than blinking lights.

Maybe it is the network cable or my ethernet switch? I seem to remember having some issues with this switch, and I haven't used it in a long time. I dig up a really long ethernet cable, test it, then run it from a known working switch to the Rpi. No response.

One thing about that switch. It is the main distribution point for internet in my workshop. I am using it this very second to type this and have had no issues whatsoever getting to the internet via that switch from my desktop.

Dig up a working Orange Pi board running Armbian

I want to know if I put this thing on the original cable that goes to the Rpi if it will work. If it does I may replace the Rpi with it, label the balky Rpi, and shove it in a box so I can get on with my work. The board I dig up has a USB to serial device attached to the console connector, so if I need to I can just use any old USB cable and get to the console (unlike the Rpi that has no obvious place to connect to a console). This board boots right up as 128.168.0.132 (via dhcp) and I can ssh to it. I type halt, wait a few seconds for lights to stop blinking and then move it to the other room.

The Orange Pi does not work on that cable either. (note after the fact -- I have no idea why the Opi didn't work when I moved it to this location and cable).

This may be a classic case of two problems at the same time. The ethernet switch and the Rpi are both flakey! Times like this I wish I had a small portable serial terminal. Also, one complaint about the Orange Pi is that:

So, I only see the single LED on, but I know that U-Boot turns it on, so for all I know the boot may be hung in U-Boot somehow.

Static IP for the Orange Pi

On my old unit (probably running Debian Jessie) you edit the file
/etc/network/interfaces
Change "dhcp" to "static" and add these lines:
iface eth0 inet static
       address 192.168.1.100
       netmask 255.255.255.0
       gateway 192.168.1.1
       dns-nameservers 8.8.8.8 1.1.1.1
Then:
systemctl restart networking

Check out that Raspberry Pi

I removed it from where I had it mounted, brought it in next to my desktop and powered it up. It has a power LED (that does sometimes blink out!) and an LED next to it marked AC1 that every now and then briefly blinks on. I give it a reasonable amount of time and still cannot ping it.

The question now is how to connect a serial console to the Rpi. It is an old unit. A raspberry pi 2 model B ver 1.1 is on the silkscreen. It has no 3 or 4 pin header for a serial console like most (all) of my other small ARM boards provide.

I am reading that I may need to enable the console (why?). The game is to place the card in a card reader and edit /boot/config.txt, then add two lines:

dtparam=uart0
dtparam=uart0_console
Maybe also check /boot/cmdline.txt for this line and remove it if it exists:
console=serial0,115200
A maze of little twisty passages!
OK, but where are the pins? I need to find Rx and Tx on the GPIO connector. They are on pins 14 and 15. This link at adafruit shows where these pins are. Signal levels are 3.3 volts. I have my USB to serial gadget right here and handy on my Orange Pi, so let me record how it is connected so I can put it back. This board has a 3 pin header for this between the HDMI connector. Here is the setup
HDMI connector
yellow wire  Tx (Rx on dongle)
green wire   Rx (Tx on dongle)
blue wire  ground
It turns out I don't need to do any editing of files in /boot, probably because this board is so old.

Evil doings by DHCP

I fire up picocom, hit return, and am greeted by a login prompt! I login as root, type "ifconfig -a" and discover that this board has been assigned 192.168.0.133 -- and yes we can ping that IP.

Such are the mysteries of DHCP. Why did it nicely come up on 29 yesterday? I went through a bunch of trouble to set up DHCP, and it worked then.

systemctl status dhcpd
  Active: failed (Result: exit-code) since Fri 2025-05-16 19:29:30 MST; 20h ago
   Main PID: 1069 (code=exited, status=1/FAILURE)
May 16 19:29:30 trona.mmto.org systemd[1]: dhcpd.service: Main process exited, code=exited, status=1/FAILURE
May 16 19:29:30 trona.mmto.org systemd[1]: dhcpd.service: Failed with result 'exit-code'.
May 16 19:29:30 trona.mmto.org systemd[1]: Failed to start dhcpd.service - DHCPv4 Server Daemon.
Well, OK then. The dhcp server failed to start around 7:30 last night. Then perhaps a lease expired on the rpi and when it asked again, my router responded and gave it a DHCP pool address.

I do "systemctl start dhcpd" and it starts up just fine. The answer to all of this is a static address for this board.

A static IP for the rpi

I look at /etc/network/interfaces and am greeted by this message
# Please note that this file is written to be used with dhcpcd
# For static IP, consult /etc/dhcpcd.conf and 'man dhcpcd.conf'
This seems counterintuitive (using a dhcp config file to set up a static IP), but whatever...

Note that these filenames are dhcpcd not dhcpd.
I go with this:

# Example static IP configuration:
interface eth0
static ip_address=192.168.0.29/24
#static ip6_address=fd51:42f8:caae:d92e::ff/64
static routers=192.168.0.1
#static domain_name_servers=192.168.0.1 8.8.8.8 fd51:42f8:caae:d92e::1
static domain_name_servers=192.168.0.1 8.8.8.8
I shutdown dhcp on my desktop (so I won't be fooled by it getting its address from it) and then reboot to test this. It works!

Add a user to my rpi

su
adduser tom
passwd tom

I set my password to tom.
I add tom to dialout in /etc/group
I log out and in again as tom

Then -- "picocom /dev/ttyUSB0" and I am talking to the 3/280


Feedback? Questions? Drop me a line!

Tom's Computer Info / tom@mmto.org