mailto: blog -at- heyrick -dot- eu

Navi: Previous entry Display calendar No next entry
Switch to desktop version

FYI! Last read at 12:24 on 2024/04/19.

RISC OS WiFi - restarting

The Pi 3B+ WiFi antenna
Bzzt! Bzzzt! Bzzzzt!

Normally when you are connected to a WiFi access point, everything pretty much looks after itself. If you perform an ifconfig on the WiFi device, it'll look something like this:

*ifconfig wb0
wb0: flags=808843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST,AUTOCONF4> mtu 1500
 lladdr xx:xx:xx:xx:xx:xx
 groups: wlan egress
 media: IEEE802.11 autoselect (HT-MCS0 mode 11n)
 status: active
 ieee80211: join AP_Name_Here chan 112 bssid xx:xx:xx:xx:xx:xx -49dBm
   wpakey wpaprotos wpa2 wpaakms psk wpaciphers ccmp wpagroupcipher ccmp
 inet 192.168.1.12 netmask 0xffffff00 broadcast 192.168.1.255

The WiFi driver is smart enough to cope with automatically reconnecting, should the connection drop out. The middle lines of the above will briefly say:

 media: IEEE802.11 autoselect (OFDM6 mode 11a)
 status: no carrier

If you wait a few moments, it'll be back up.

However, there are times when this will fail. Resetting your router, for example, isn't a simple "reconnect and continue" situation.

So, what to do?

Well, you could shut down all your apps, reboot, and rerun the !StartWiFi script that I gave you two weeks ago.

Or, you know, just kick the interface a little.

The first thing to do is to kill the DHCP session. To do this, open a TaskWindow and enter:

*DHCPExecute -r wb0

Once you have done that, prod WiFi to get it to reconnect. Enter:

ifconfig wb0 join MyRouter wpakey 53C7E7

Obviously, "MyRouter" should be replaced with your router's SSID, and "53C7E7" by your password.

Wait a few moments for that to do its thing.

Finally, restart DHCP to get an IP address. Enter:

DHCPExecute wb0

 

To put this in terms of a script, something like this (call it "RestartWiFi"):

echo Restarting WiFi
|
| End DHCP session
DHCPExecute -r wb0
<Obey$Dir>.DoWait5
| 
ifconfig wb0 join MyRouter wpakey 53C7E7
<Obey$Dir>.DoWait5
<Obey$Dir>.DoWait5
|
DHCPExecute wb0
<Obey$Dir>.DoWait5
Echo IP address is <Inet$EtherIPAddr>, done!

 

When is a fork not a fork?

A few years back, a company called Sodebo who makes prepackaged food, in this case various types of salad, flexed their green by announcing the end of the disposable plastic fork that came with the salad. The salad itself, still in a plastic box with plastic film lid, with a cookie in a plastic baggie and a sort of bread stick thing in a plastic baggie, and a little test tube of oil and balsamic vinegar in a plastic tube. So, you know, getting rid of the fork wasn't saving much on the plastic waste and it was making the salad less desirable as a product because you could no longer just buy it and eat it, you had to either remember cutley, or buy some...

A Manhattan salad
The salad, in its box.

It is called "Manhattan" because it is chicken and (something resembling) cheese with little pasta shells.
I dunno, if you asked me to name something "Manhattan", I'd suggest a pastrami bagel, but what do I know? I've never been there...

This is what's inside. Note all the plastic.

All the plastic that a salad is packed in
All the plastic that a salad is packed in.

I'm guessing Sodebo felt the pain of not providing an eating implement with their salad, as there's now a fork.
Sort of.

A really peculiar fork
What the fork is this?

It... is functional as a fork, in much the same way that gaffer-taping some nails to a pencil might be. It took several tries but I was eventually able to prong an egg, but generally I just scooped up stuff, as if it were a spoon.

The peculiar fork having pronged an egg
This was harder than it should have been.

Now the obvious question is what the hell did they manage to do to a bamboo fork in order to get it to end up so bizarre?

Well...

The peculiar fork is actually edible
Once you've used the fork to eat, you can eat the fork.

...it isn't bamboo. It is edible! Some sort of solid biscuit-like concoction (not unlike the dry crunchy bread sticks), covered with a glaze to make it resist the liquids like the oil and vinegar.

You can probably eat the prongs, and maybe some of the body of the fork. But much beyond that you'll need really solid teeth as the handle of the fork is hard.

 

 

Your comments:

No comments yet...

Add a comment (v0.11) [help?]
Your name:

 
Your email (optional):

 
Validation:
Please type 60317 backwards.

 
Your comment:

 

Navi: Previous entry Display calendar No next entry
Switch to desktop version

Search:

See the rest of HeyRick :-)