just another web log

27 Mar 2019:
nmap fights virtualbox on windows and nic wins
You remember the One True Ping?

Well nmap, popular network scanner has always given me problems in the same environment. Linux nmap on other networks, fine, but Windows in the managed office always did something weird.

Running nmap from WSL still does not work, but that is for everybody. So I tried running it from zenmap As Administrator, more weirdness. Would seem to be scanning the right things but would come back with only a couple of machines or ports.

Today I fought, and won!

It had to be;
The network ~ as with the UDP ports
Windows - Firewall or UAC
nmap/zenmap - bug, PCAP, etc.

and the culprit was ...

VirtualBox! Well, it was the many contributor. The actual issue was with nmap.

When you run nmap/zenmap it selects the best NIC to send the packets over. Only in my case the guess was wrong because(even though it was not running) VirtualBox had created a virtual NIC that looked better than my real Network Interface Card.

Issue diagnosed. Fix is to tell nmap/zenmap to use the correct NIC device name... But Windows does not do device names...

nmap --iflist
Which filled the terminal with a lot of networking information. But nestled in amongst was an reference to my IP address eth4

So now running
nmap -e eth4 -sS -p 22

now works 100%
24 Mar 2019:
one small pull request for quest smith one giat leap for robgithub
Finally finished the Quest Smith Interactive Web Interface and created a Pull request.

The author may have any of the following reactions.
Disgust - goes against the idea of having a thermal printer based adventure.
Apathy - general disinterest in this or the main project.
Concern - you have enable GitHub Pages(All) - which is in no way a security risk, but if you have never come across it might seem odd.
Acceptance - a Pull request is a Pull request.
Enthusiasm - what a good idea - will lead to more engagement with the project.

Or a mixture :)
24 Mar 2019:
random blender textures through the magic of logic gates
Quick Blender Shiny!

Was trying to work out a logical way of using Blender s Object-> Random Input Node to drive random Texture Node choices and after a few false starts ended up with.
Blender node setup for random textures, represented as colours

And applied to a 10x10x10 array of Cubes. Array Modifiers applied and then Separate -> By Loose Parts.

Blender node for random textures, represented as colours render in 1000 cube array

The use of BSDF colours is just for simplicity and any shaders can be used in their place. Including Image Textures and anything that results in a Shader output.

It looks really simple, but I and others have tried previously and ended up with much more complex monstrosities.

The first problem was, that in my head Less Than would let through any value less than Value. This imaginary passed-through value would then be checked with a Greater Than. The annoying thing was lots of my example values and experiments supported this, but that was pure coincidence and confirmation bias.

FYI, the Object -> Random Input Node produces a single value for each Object.

In the first Less Than Node any Value between 0.0 - 0.199 will result in an output of 1.0 or True, any value higher is 0.0 or False. This means the Blue BSDF Shader is Mixed in 100% when the True and 0% when False, resulting in the Light Blue BSDF Shader.

Then in the other Less Than Nodes the process continues and it is very important to keep the order of the connected Mix Shaders consistent. I think this is what went wrong so badly in my experiments. Does not help that Blender cannot colour the connection lines.

This Truth Table shows the Inputs at the top, the Results at the bottom and the Logic results per Less Than test. The Hashed colours are where the last colour has "fallen through" instead of being replaced.
truth table for Blender nodes example

If the random input is 0.56 then
is 0.56 < 0.2 = False = Blue chosen from Light Blue and Blue
is 0.56 < 0.4 = False = Pink chosen from Blue and Pink
is 0.56 < 0.6 = True = Pink chosen from Orange and Pink
is 0.56 < 0.8 = True = Pink chosen from Green and Pink

If the random input is 0.91 then
is 0.91 < 0.2 = False = Blue chosen from Light Blue and Blue
is 0.91 < 0.4 = False = Pink chosen from Blue and Pink
is 0.91 < 0.6 = False = Orange chosen from Orange and Pink
is 0.91 < 0.8 = False = Green chosen from Green and Orange

Adding more textures just means adding additional Less Than logic Nodes and updating the comparison values.
18 Mar 2019:
quest for the missing game url
and here is the missing PLAY NOW url

18 Mar 2019:
quest for the mobile git smith
So the Raspberry Pi Blog posted an article about a thermal printer powered Pi text adventure game.

The author put out a plea
Each level requires two versions of the story, which makes the
possibilities grow exponentially. So it will be very difficult for me to
finish a single story by myself. For the player to reach level 9, we will
need to have 1023 story parts to be written. If you can help me with
that, it would be amazing!

The story files are just plain text files, but I did not have a thermal printer to try it out on...

So the story TXT files are in GitHub. I wonder if they are accessible from the GitHub Pages ?

They are ! (just have to set the settings on your repo correctly)

I forked the project and got to work creating a simple Javascript based web interface that could run directly on GitHub Pages and allow the user to interact with the story files.

Today it works fine in a desktop browser. Before I try and get it merged back in to the origin repo I want to add specific functionality for Mobile. Nothing to fancy just better styling for Mobile layout.

18 Mar 2019:
a little bit of offline microbit python
Next on the MicroBit coding front is https://python.microbit.org/v/1.1

The way it works is the same, but instead of building with Blocks you use Python code. You then download the generated .hex file and away you go.
Sadly there is no real-time simulator, so expect to get "Syntax Error" scrolling on your MicroBit every now and then.

This is better than having the Microsoft logo hanging over you but I still long for an offline editor...

Welcome uflash (which is not you-flash but micro-flash)

To get uflash on Ubuntu I had to
sudo apt install python-pip
pip install uflash

and then to find where the install had gone, because it was not in my path.
pip show uflash
Name: uflash
Version: 1.2.4
Summary: A module and utility to flash Python onto the BBC micro:bit.
Home-page: https://github.com/ntoll/uflash
Author: Nicholas H.Tollervey
Author-email: ntoll@ntoll.org
License: MIT
Location: /home/ubuntu/.local/lib/python2.7/site-packages

Now, from within that directory I could run
python uflash.py ~/Downloads/microbit.py

It happily found my MicroBit auto mounted to /media and flashed it.

According to the docs, it will happily flash multiple MicroBits connected to the same PC.
10 Mar 2019:
MicroBit helloworld
Got my first MicroBit code working.

Not very exciting and really only to prove the process. It just lights an LED on opposite corners.

But, the process is interesting.
The MicroBit shows up as a USB drive when plugged into a computer and then you can copy across a .hex (bin) file and it automatically loads it as the program.
The program then just automatically runs.
Once the file has been transferred, it eats it, so make backups!

To create the .hex file there appear to be a number of options. I used the most basic, which is a Scratch-like block dragging website, powered and branded as Microsoft.

I know it is irrational these days, but the Microsoft name/logo just puts me on edge. Need to find a way to code offline.

There is at least two other ways I know of to code for the MicroBit Will give them a go soon.
09 Mar 2019:
dd a drive not a partition
Why do I always forget that when dd-ing an .iso to a USB stick to use the drive and not the partition!

Hours wasted and this is not the first time!
09 Mar 2019:
flub flog update
This a quick run down of various things going on at the moment;

I have been working on improving the Raspberry Pi materials in Blender and I have some plans to move that project forward.

Not done anything on the SV-3 VGA/HDMI situation, but the Pi Zero with adaptors sits on my desk so I cannot forget.

Got a massive haul of tech kit. Mostly for the Raspberry Pi, but also got a MicroBit and kit for that.

Then I found a git repo that needed cloning for a bit of tweaking.

Plus fighting Epsom printer drivers on Windows. Removing every piece of Epsom software fixed that!

Finally started decommissioning an old HP Windows 7 laptop. It is going to be my Ubuntu lab machine.

Digitised a load of old Sony handycam footage (in Windows 7), had no idea I had recorded so much, and so little.

and lots of other things ...
loading results, please wait loading animateloading animateloading animate
[More tags]
rss feed



flog archives

Disclaimer: This page is by me for me, if you are not me then please be aware of the following
I am not responsible for anything that works or does not work including files and pages made available at www.jumpstation.co.uk I am also not responsible for any information(or what you or others do with it) available at www.jumpstation.co.uk In fact I'm not responsible for anything ever, so there!