#RaspberryPi – 1st setup without monitor: auto connect to WiFi, enable SSH, rename, update and more!

Buy Me A Coffee

Hi!

Ok, let’s assume you did the tutorial and installed the latest raspbian image in an SD card. If you want to access and control remotely your device you may want to follow this steps.

Configure Wireless connection

In the SD Card, you need to create a file named [wpa_supplicant.conf] in the root of the SD card with the following information:

country=ca
update_config=1
ctrl_interface=/var/run/wpa_supplicant

network={
 scan_ssid=1
 ssid=" Your WiFi SSID"
 psk="You amazing password"
}

The file content is very straight forward to understand. Main values to complete are [ssid] and [psk].

Once you put the SD card in the device and start the device, it will automatically connect to the configured WiFi.

Enable SSH

If you also want to enable SSH, you need to create a blank file named [ssh] to the main partition.

Once you put the SD card in the device and start the device, it will automatically enable the SSH service.

Find the IP address in your network

And that’s it, your Raspberry Pi will be connected to the Wifi and with SSH enabled. At this moment we can use a tool like AngryIp (see references) to detect the new device in the network

My new device IP is: 192.168.1.246

Access via SSH

I used to like Putty to connect to my device, however during the past months I’ve been using Windows Terminal and Powershell. In order to access the device I need to execute the command

ssh user@deviceaddress

and my data is

  • user: pi
  • ip: 192.168.1.246
  • password: raspberry

You can now start working with your Raspberry Pi !

Change Password

The default password for the device is “raspberry”, and as usual, it’s recommended to change it. In order to do this, in the ssh terminal, let’s access to the device configuration

sudo raspi-config

This will open the configuration for the device.

Option number 1 will allow us to change the password.

Rename the device

In the same Raspberry configuration tool, we can rename the hostname that our device will use for network operations.

Select the options

  • Network Options
  • Hostname

And define the new name for the Raspberry Pi device.

Expand FileSystem

Another important option in the configuration is to expand the SD disk.In the same configuration screen, select

  • 7. Advanced Options
  • Expand File System

Now we need to reboot and after the reboot the file system should have been expanded to include all available space on your micro-SD card. Reboot with the command

sudo reboot

Update the device

Of course, at this moment you should change your default password and update everything with a command like this one

sudo -- sh -c 'apt-get update; apt-get upgrade -y; apt-get dist-upgrade -y; apt-get autoremove -y; apt-get autoclean -y'

Conclusion

And that’s it, we have our device updated and running with the latest software versions and we didn’t use a monitor! I’ll update this post frequently to make it relevant with my personal best practices.

Happy coding!

Greetings

El Bruno

References

My posts on Raspberry Pi

Dev posts for Raspberry Pi
Tools and Apps for Raspberry Pi
Setup the device
Hardware

#Humor – Vulnerability severity levels (via @PatchFriday)

Buy Me A Coffee

Source

Happy coding!

Greetings

El Bruno

#JetBrains – JetBrains Mono, a nice and useful console font. Bonus: @justgetflux

Buy Me A Coffee

Hi!

I don’t spend as much time as I want in front of any of my Code Editors. And because of work, when I do, is mostly at night. So, I’m usually kind of tired andI really appreciate every help I got there.

I’m already using flux to to make the color of my computer’s display adapt to the time of day, warm at night and like sunlight during the day (see references).

And a few days ago, JetBrains released a new Consola style font which looks amazing after a 1st trial.

JetBrains Mono

Therefore, while working on JetBrains Mono we focused, among other things, on the issues that can cause eye fatigue during long sessions of working with code. We have considered things like the size and shape of letters; the amount of space between them, a balance naturally engineered in monospace fonts; unnecessary details and unclear distinctions between symbols, such as I’s and l’s for example; and programming ligatures when developing our font.
Today, we proudly present JetBrains Mono – a new open-source typeface specifically made for developers. Check out what makes JetBrains Mono unique in the big family of monospaced fonts and try it in your favorite code editor. Have a look at JetBrains Mono, your eyes will thank you for it.

JetBrains blog.

And as every font, is very easy to install in Windows. Just download and extract the package, and right click and install

In Visual Studio 2019, the configuration to use the font is very easy. Before going there, let’s take a look at the default font used in VS2019.

Once the font is installed, we can go to Options / Fonts and Colors and select JetBrains Mono as the default font.

Then, the same code will look lot more amazing.

So, now it’s time to use this font for a while in my different machines and give an honest review after a couple of weeks.

Use JetBrains Mono in Visual Studio Code

In Visual Studio Code in the preferences section, we can search for FONT and change the font to use JetBrains Mono.

And the code will start to look also amazing!

Happy coding!

Greetings

El Bruno

References

Comparing Azure Kubernetes Networking Scenarios – Part 4 Http App Routing

Roy Kim on Azure, Office 365 and SharePoint

In this 3rd configuration profile, I will walk through the resulting configuration of AKS and its effect on the Load Balancer, Virtual Network, VM network interface card, deploy and test a web application into the Azure Kubernetes Service (AKS) cluster. The configuration profile is mainly around the Azure CNI network model and enabling the HTTP Application Routing Feature.
The HTTP application routing solution makes it easy to access applications that are deployed to your Azure Kubernetes Service (AKS) cluster. When the solution’s enabled, it configures anIngress controllerin your AKS cluster. As applications are deployed, the solution also creates publicly accessible DNS names for application endpoints.

Please read the Part 1 intro of this blog series if you haven’t already. This will explain the background and what each configuration setting means. Here is the previous blog post for Part 3 Azure CNI.

Configuration Profile 3

  • Network Model/Type: Advanced…

View original post 289 more words

#Python – How to fix “ERROR: Could not find a version that satisfies the requirement tensorflow (from versions: none)” on #Windows10 #TensorFlow

Buy Me A Coffee

Hi!

Ok, I’ll write this down. I face this issue from time to time, and then after some searching and reading, I found the solution (again!) and I realize I’ve been done this before.

So, I’m installing Tensorflow on Windows with the amazing single command

# Requires the latest pip
pip install --upgrade pip
# Current stable release for CPU and GPU
pip install tensorflow

And then I get this error

ERROR: Could not find a version that satisfies the requirement tensorflow (from versions: none) 
ERROR: No matching distribution found for tensorflow
error installing tensor flow on windows

So, I decided to see what’s happened and I realize that I only have installed Python 3.8. And there is no official TF version for Python 3.8. So, I need to downgrade Python to 3.7.

Time to install earlier Python version

python current version 3.7.6

and then, try to install TensorFlow again. Now, it’s installing

installing tensorflow with current python version

and after installation, test current TF version

tensorflow installed and tested on windows terminal

So, remember: Using the latest Python version, does not warranty to have all the desired packed up to date. Specially with TensorFlow.

Happy coding!

Greetings

El Bruno

References

Comparing Azure Kubernetes Networking Scenarios – Part 3 Azure CNI

Roy Kim on Azure, Office 365 and SharePoint

In this 2nd configuration profile, I will walk through the resulting configuration of AKS and its effect on the Load Balancer, Virtual Network, VM network interface card, deploy and test a web application into the Azure Kubernetes Service (AKS) cluster. The configuration profile is mainly around the Azure CNI network model.

Image result for aks azure cni

Please read the Part 1 intro of this blog series if you haven’t already. This will explain the background and what each configuration setting means. Here is the previous blog post for Part 2 Kubenet.

Configuration Profile 2

  • Network Model/Type: Advanced (Azure CNI)
  • Http application routing: Disabled
  • Virtual Machine Scale Set: Enabled
    2 VM instances in the scale set

AKS Networking settings

Resources in the AKS Infrastructure Resource Group

Virtual Machine Scale Set (VMSS)
In this screenshot, I just happened to stop one VM instance in the scale set. This is just arbitrary and has no purposes for…

View original post 287 more words

#Ebook – Code the Classics, amazing book for programming games in #Python. From the #RaspberryPi library.

Buy Me A Coffee

Hi!

My son is a crack and he already passed the Scratch stage. He is part of an amazing Code Ninja programming program and he is asking for some new challenges.

Last month, when I see the release of the Code the Classics – Volume 1 book, I get one for us. And it’s amazing. I mean, he needs to understand Python now, so it’s another challenge. But you know me, any excuse to keep him away from JavaScript!

Code The Classic - Volume 1

By the way, all the code is available in GitHub, and it will take just 5 minutes to set everything up to test the games. And, most important, the book is also available FOR FREE IN EBOOK FORMAT.

So kudos to the publisher, and let’s go with the formal book description.

This stunning 224-page hardback book not only tells the stories of some of the seminal video games of the 1970s and 1980s, but shows you how to create your own games inspired by them using Python and Pygame Zero, following examples programmed by Raspberry Pi founder Eben Upton.

In the first of two volumes, we remake five classic video games – ranging from Pong to Sensible Soccer, each represents a different genre. We interview the games’ original creators and learn from their example, as well as utilise the art and audio engineering skills of two of the 1980s’ most prolific games developers for our recreated versions of the games.

Get game design tips and tricks from the masters

– Explore the code listings and find out how they work

-Download and play game examples by Eben Upton

– Learn how to code your own games with Pygame Zero

– Read interviews with expert graphics and audio creators

Happy coding!

Greetings

El Bruno

References

Locate Holograms with Spatial Anchors and Mixed Reality Toolkit in IOS

Hi everyone! As promised below you will find a simple tutorial on how to use Spatial Anchors in an iOS app with Mixed Reality Toolkit.

What is Spatial Anchors for?

Cross Platform

The way in which it is possible to share a hologram with other devices (we saw in previous tutorials that we are specifically IOS, Android and Hololens 2), is through the use of Spatial Anchors.

Spatial Anchors can be located by multiple devices in the same place and at the same time. With this application, if two different devices connect to the same session, they can locate the saved Anchors.

Let’s start!

This video shows the result of this tutorial.

Software requirements

Aditional Pachages for IOS

  • Ar Foundation version 1.5.0 preview 6
  • ARKit XR Plugin v.2.1.2

Creating the App

1. Create…

View original post 776 more words

#Event – I will be speaking at @devdotnext #devdotnext2020 this March in Colorado.

Buy Me A Coffee

Hi!

In a couple of weeks, I’ll be visiting one of the biggest events in Broomfield, Colorado: @devdotnext.

DevDotNext

DevDotNext hosts 150+ 75-minutes Presentations, 4 Keynotes/Panels, and 11 All-day Pre-Conference Workshops.

Topics covered include:

  • Languages
  • Design and Architecture Cloud
  • Server-Side
  • Frontend
  • DevOps
  • Microservices
  • Machine Learning
  • Testing
  • Being agile
  • Leadership
  • And more

I’ll be sharing some experiences and insights around Machine Learning, Computer Vision and IoT. Here are my session details.

How a PoC at home can scale to Enterprise Level using Custom Vision APIs (v2!)

It all started with a DIY project to use Computer Vision for security cameras at home. A custom Machine Learning model is the core component used to analyze pictures to detect people, animals and more in a house environment. The AI processing is performed at the edge, in dedicated hardware and the collected information is stored in the cloud.

The same idea can be applied to several CCTV scenarios, like parking lots, train stations, malls and more. However, moving this into enterprise scale brings a set of challenges, which are going to be described and explained in this session.

In this new version of the session, we will start from scratch and create a complete “Parking Garage Open Space Tracker” solution with live devices and live cars (small ones, of course)

Registration and event details

Hurry up, regular registration ends soon.
Register at https://www.devdotnext.com/register

Happy coding!

Greetings

El Bruno

Comparing Azure Kubernetes Networking Scenarios – Part 2 Kubenet

Roy Kim on Azure, Office 365 and SharePoint

In this 1st configuration profile, I will walk through the resulting configuration of AKS and its effect on the Load Balancer, Virtual Network, VM network interface card, deploy and test a web application in the Azure Kubernetes Service (AKS) cluster. The configuration profile is mainly around the Kubenet network model. Kubenet is a very basic, simple network plugin, on Linux only. It does not, of itself, implement more advanced features like cross-node networking or network policy.

Kubenet network model with an AKS cluster

Please read the Part 1 intro of this blog series if you haven’t already. This will explain the background and what each configuration setting means.

Configuration Profile 1

  • Network Model/Type: Basic (Kubenet)
  • Http application routing: Disabled
  • VM Scale Sets: Disabled
    1 Node/VM

The following are screen shots to show the resulting configuration across its related azure resources.

AKS Resource – Networking Profile

AKS Infrastructure Resource Group
When this AKS resource is deployed, behind the…

View original post 488 more words