Ethernet connection

Quick question, if I enable Ethernet do I still need to have WiFi? I just enabled Ethernet on my unit, connected it up, but no FarmBot online until I configured the WiFi as well.
Thanks,
Jon

Usually you don’t need WiFi if you choose Ethernet. You should make sure that your Ethernet connection is has access to the internet (in case that you use my.farmbot.io).
Maybe there was a typo in your login data?

So here’s what I’ve done:-

  1. Start up Farmbot, wait for the WiFi network and connect.
  2. Enable Ethernet, fill in the login details, submit.
  3. Connect to FarmBot via the Ethernet, which gives me the configurator screen.
  4. Farmbot remains ‘offline’ form the web app.
  5. Fill in the WiFi details in the configurator (from the wired connection), submit.
  6. Farmbot comes on line.

So I don’t think it connects using the wired Ethernet, unless something else needs enabling?
Thanks,
Jon

Since my WiFi is quite bad where my bot is, I’ve attempted Ethernet too. But it also didn’t seem to work for me. So using crappy WiFi only at the moment.

Hello

Yesterday I lost the contact with the “farmbot test”

Version 3.14

Ethernet + Wifi works together.
I lose touch with Wifi but not with ethernet but don’t work not
Now work with ethernet,
WiFi is no longer connected, identify and Exchange data (where what with whom?)

Hey all,

Hope everyone is staying socially distant, but not too distant! Picking up this thread as I’m now troubleshooting a wired Ethernet connection. The RasPi is having issues connecting. BLUF: I’m not finding any diagnostic information upon entering the Configurator after the auto-factory reset when the FB doesn’t get a connection. What am I missing?

Symptoms:

  1. It’s only gotten an IP once from the DHCP server, but it didn’t seem to ‘work’. RasPi was not
    pingable, and the FB never synched to the FB-run server.
  2. I tried a static IP, to no avail.
  3. When the FB factory resets, I see no diagnostic information telling me what happened.

Some things I’ve tried:

  1. [Rule out bad cabling] Testing the RasPi end-point of the calbing with a laptop. Laptop was able to get a DHCP lease and enjoy free range internet.
  2. [Rule out weak signals from the Pi] Sticking a switch between my main switch and FB (RasPi). I never get link lights on the middle-man switch.

The only time I was able to see that the RasPi got a lease, was on the run without the middleman switch.

Any thoughts?

Cheers!

In my setup, I always use static IPv4 addressing in the Configurator ADVANCED page.
For this, though, you do need to set both your local DNS (name server) address and the local IPv4 gateway address. Take care, also, with the network mask value for your chosen static IPv4 interface address.

Are you able to login to the router/gateway that hosts your DHCP server and check its configuration ? It’s possible that it hands out unusable addresses to certain MAC clients.
Look for lists of “MAC reservations” too.

Thanks @jsimmonds! I did try that, and still nothing. On a hunch, I checked all of my connectors and noticed that I had use a cross over scheme between the Farmbot and the switch. I redid the connectors in a straight patch through scheme. I was able to get link lights again! The FB was able to retrieve an address via DHCP and I was also able to ping the FB locally. However, the FB couldn’t connect to the FB servers. So, I triggered a factory reset and selected the Ethernet connection again. No link lights. I now cannot get the FB to connect to the switch. My biggest issue is that I have zero visibility into any errors the Pi is experiencing, making this maddeningly frustrating.

Some questions:

  1. Should I expect link lights when I plug into the Pi, even of if the FB is configured for wireless?
  2. Should I expect link lights when the FB is in ‘Configurator’ mode?
  3. Does anyone know why the Configurator page is not showing me the last encountered connection-related error?

You can get Elixir and Linux command line access at all times with a Serial Console Cable ( FTDI Chip TTL-232R-Rpi is recommended ).

Yes for me, but I use a Raspberry Pi 3 model B Plus to run FBOS.

I searched around the web just now to find what the 2 LEDs on the wired Ethernet socket indicate . . and came up empty-handed.

Continuing my example, for wired I plug my wired Ethernet into the back of an Apple AirPort Extreme router.
I get only the LED adjacent to the USB sockets On and Flashing ( activity ) AMBER ( assume that means a 1Gb PHY link up (?) ) . .
whether I’ve Configurated static or dhcp wired or wireless IPv4.

Yes, if your PHY is healthy.

Not sure about that one. I recall that FBOS v8 used to display the last Reset reason if the Configurator had to re-start. Maybe @RickCarlino knows more.

This problem is concerning . . when you used that wired connection into your laptop, did you get Internet ? Did you Configurate the WebApp server name correctly ?

I wonder whether time might be saved by trying a different known good RPi ?

1 Like

Hi @fuzzynickel

Somehow, this message slipped through the cracks and I did not see it when I do my daily forum checks, so I apologize for the late reply. I am going to take a look now to ensure ethernet is still working as expected on FBOS v10.0.0.

With regards to the issue of having better debug visibility during offline scenarios, it is sometimes possible to see the last reset reason at the top of the configurator page, but not always.

Here are some alternative options:

  • If you can at least see the devices on the network and you know the devices IP address, you may be able to visit the /logger endpoint to see live logs. So, for instance, if your local IP is 10.11.1.74, you would be able to visit http://10.11.1.74/logger and see a live stream of logs without any special hardware or software.
  • You can purchase a USB-to-TTL serial cable as @jsimmonds has recommended. They typically can be purchased on Amazon for less than $15 and are great for debugging. With that being said, be sure to read the review comments prior to purchasing to make sure that the cable works on your OS and is compatible with RPi (as opposed to Arduino, which uses different voltages). Some users, particularly Windows users, have noticed that some brands are not supported on their OS.
  • If you have access to a machine that supports ext4 partitions (all major Linux distributions), it is possible to extract a database dump from the SD card. After powering the device down, look for a file named logs-prod.sqlite3 on the SD card partition that is formatted as ext4. The logs are viewable from the logs table in any SQLite compatible SQL client (such as this web based one). You would need to run SELECT * FROM logs. Obviously, this is not ideal and I view this as a last resort if /logger or a debug cable are not an option. We plan to add a download link to configurator in a future release.
  • If none of these options work for you, and you are able to create a zipped backup of your SD card, I would be willing to take a look and extract the files for you. We can arrange the transfer over private message if this is the only option.

Please let me know if any of those methods help. I will now do a QA check of ethernet functionality on FBOS 10 and report back my findings shortly.

2 Likes

Thanks, John! This is great info.

  1. I’ll look into the the FTDI RS-232 converter. I know them well.
  2. The laptop enjoy full range internet upon connecting.
  3. Yeah, I double-checked all of the WebApp servers. I have not changed them from the defaults provided by the Configurator.
  4. I’ll see if I can snag another RPi for testing. That’s where my my current thinking is as well. I think in the short term, I’m going to find a known good Enet cable and by pass the in-ground link that has all of the grounding and multiple connections. My first priority is to consistently get link lights. The RPi 3 is a Fast Enet (10/100) and not Gigabit. This is important b/c the Gigabit Enet has auto-sensing goodness that figures our the wiring. 10/100 does not and is sensitive to wiring schemes. If I am incorrect about the RPi3’s Enet, please let me know!

@RickCarlino Thanks for the info and the reply!! I’ll give the logs a try.

We have rainy weather here so it may be a few days before I can get out back and try all of this, save the logs. That can be done from inside :slight_smile:

1 Like

@fuzzynickel I was able to use ethernet on a device configured via DHCP. It seems that Ethernet still works on v10. I will hold off on investigating any further until we see some error logs.

1 Like

Yes, you’re right about that and in accord with the official RPi 3B tech specs . . but as I mentioned I’m using an RPi 3 B+ which does have Gigabit PHY ( but it runs over USB 2.0 internally, so they say expect around 300 Mbps :slight_smile: )

Note that this page is also present when the Configurator AP is running ! ( 192.168.24.1 )

1 Like

Ok fellas, I ran the logger, both from the configurator and from the Wirelessly configured FB. Nothing popped out to me about an aborted wired ethernet interface, successful or otherwise. I tried connecting and reconnecting the cabling a few times for good measure (no link lights became lit). Curiously, going to the configured FB on the local IP address got me back to the configurator. You can see the HTTP requests in the after config log file.Debug Logger - after config.html (2.6 KB) Debug Logger - before config.html (8.2 KB)

I also tried to do a log dump, as per https://developer.farm.bot/docs/gathering-a-log-dump but that gave me a 404 error. Perhaps that’s been replaced by the /logger url?

Finally, I attempted to SSH in. In the configurator, it asks me for the use name/pass, which per https://developer.farm.bot/docs/farmbot-os-faq, is not available. At this point, there is no public key available, so … is there a way to ssh into the Configurator?

I supplied a public key for the FB during the Configuration, and was able to poke around in the Elixir APIs within the FBOS.

  1. I attached to RingLogger and it did not give me any errors or status for eth0 as I plugged and unplugged cables.
  2. I did not find any APIs that expose the status of the eth0 device, with my search ending somewhere in the VintageNetwork library. I did find where I could configure the network, but that would either require me to compile my own custom OS (not ready to do that right now) or dig a little deeper into the data structures of the Elixir language (my wife is starting to pay attention to how much attention I’m giving the Farmbot).

I’ll scour to see if I can find another RPi to test with. @RickCarlino, will FB and an RPi 4 get along? The pinouts and form factor look to be the same…not sure about the underlying chipset vs OS etc etc. According to Cana, the major difference that would be of import would be the higher amperage requirements (3.0 Amps). https://www.canakit.com/raspberry-pi-4-4gb.html

The only way to have SSH ( with Public Key auth ) available in Configurator is to build your own FBOS as a dev env build, and having your public key available in a known place as id_rsa.pub ( it’s all in the “d.i.y.” developer doc ).

This is where your Serial Console cable ( TTL to USB ) is really handy, though maybe not so much if the bot is already fully installed in the field :slight_smile:

Hardware-wise : probably . . software-wise : definitely No with current FBOS . . RPi4B needs its own nerves_system_rpi4 tailored and then bundled into FBOS.

Plain RPi3B and RPi3B+ both work with FBOS v10.0.0. Maybe quicker to trouble shoot this by pulling out the RPi3 from the bot and running it on your bench, while connecting to the same router port ?

1 Like

If you go into the Advanced configuation page (where you can set static IP, for example), you can also include a public RSA ssh key there. You don’t have to rebuild the image.

Thanks @jebba . I was able to successfully use that route to SSH into a fully configured FB. I wanted to SSH into the Configurator (where you would paste the SSH key) to do some troubleshooting there. By default, that’s not possible unless you build a custom version of the FBOS (as John mentioned above) to include the public key.

1 Like

Yea, you’re right John. I’ll see if I can do that tear down and test once I get a serial console cable. Thanks for the info!

@jebba, that’s interesting . . Have you tried adding your SSH key and then doing a Factory Reset to get Configurator up and then tried SSH ?

As I understand it, your personal SSH PublicKey is associated with your personal User Account on the WebApp and then made available to FBOS when FBOS boots, connects and authenticates against your account.

After Factory Reset, that association is broken.

Cable’s been ordered and should be here some time tomorrow. For the curious, this is the one I bought from Amazon. The EZSync012 (great name, right?)

1 Like