I have a vending machine attached to a ubuntu system as the master computer and I want to connect USB and RS-232 port for various machine operations using hex codes using this connection with the help of a UI on the master computer, but I am not able to properly configure the serial ports to actually run those commands. Hi, thanks for the post, helped me immediately to resolve wine serial port availibility. I'm running on wine 3.0 (Ubuntu 3.0-1ubuntu1) and after adding a group dialout to a user and restart, I was able to access the port from wine app. The only issue I have was that the app has only visible two com ports and my USB/RS232 cable was com33.
- I have a vending machine attached to a ubuntu system as the master computer and I want to connect USB and RS-232 port for various machine operations using hex codes using this connection with the help of a UI on the master computer, but I am not able to properly configure the serial ports to actually run those commands.
- Ubuntu 20.10 » Ubuntu Desktop Guide » Networking, web & email » Wired networking » To set up most wired network connections, all you need to do is plug in a network cable. The wired network icon ( ) is displayed on the top bar with three dots while the connection is being established.
Over the last few weeks I have been researching what I can achieve with home automation. After browsing countless web articles and watching hours of various YouTube videos the first decision I made was what wireless protocol I would use for connectivity, I decided on Zigbee. For those who don't know much about IOT and smart devices, most sensors and devices connect wirelessly using either WiFi, Zigbee or Z-Wave. Each of these protocols have their pros and cons which I won't cover here, but there were a few reasons I choose ZigBee.
1) New Cisco access points are starting to support ZigBee, I don't currently know what this means for me specifically, but I thought it may something to play around with in the future if I hit any range issues.
2) I didn't want to utilise WiFi, I tinker a lot with my network and didn't want any smart home devices relying on WiFi.
3) ZigBee is an open standard, Z-Wave isn't.
To prevent having to own a separate 'smart hub' for each smart-device I purchased, I opted to centralise everything into an open source piece of software called Home Assistant (https://www.home-assistant.io/) - it also has a Docker container! There are other benefits of using something like this as opposed to each manufactures own smart hubs. Firstly all your data is stored locally on your own server within your control and secondly with everything is processed locally and not in the cloud. Cloud based solutions can add a fair amount of latency from what I have seen. A good example of this would be if you wanted to automatically turn on a light when motion is detected. There could be several seconds delay in motion being detected and the light turning on, especially if the smart bulb and motion detectors are by different manufactures using their own independent hubs or cloud solutions
In order to connect my smart devices into Home Assistant I needed something that could communicate using the ZigBee protocol. After some research there was one clear winner that everyone recommended which was the ConBee II USB gateway by Dresden Elektronik. The only issue I had with this device was the price, at close to £40 quid it took me a while to bite the bullet. I could have got something for cheaper, but I wanted something reliable, it may well be controlling key-parts of my home in the future!
The device can be purchased on Amazon and this is what arrived in the post:
Now I just needed to get this connected to my Docker host and pass it through to the Home Assistant Docker container. I haven't ever tried passing through USB devices in Docker before, but how hard can it be?
Ubuntu Usb Port Permission Denied
First you have to change your USB access rights by using the below command, I also rebooted my server at this point.
I then connected the USB gateway to my server and I could see the device recognised in Ubuntu, a good start...
To interface with the USB gateway I spun up a Docker container running deCONZ using the below Docker-Compose snippet. You can think of this as the middle man between the USB gateway and Home Assistant.
Once the container was running, I navigated to 'Configuration' -> 'Integrations'vwithin Home Assistant where I could see the ZigBee gateway automatically discovered.
Upon clicking 'CONFIGURE' I was shown the following and had to scratch my head for a few minutes and do some Google'ing before figuring out what I had to do next.
It turns out the Deconz container runs 'Phoscon App' on port 80 by default. I navigated to this, where it showed my gateway as seen in the below screenshot. If you already have a container using port 80, you can change the Phoscon port by using the environmental variable 'DECONZ_WEB_PORT=8080' within docker-compose.
Once selecting your Gateway you will be prompted to a set a new name and password. Once set you will be asked to connect some lights, I don't have any lights so chose the 'Proceed without lights' option on the top right of the page.
Linux List Usb Disk
Once on the below page, choose the menu button on the top left, 'Settings', 'Gateway', 'Advanced' and 'Authenticate App'.
Once you have clicked 'Authenticate App' you will see a 60 second countdown, now is time to go back to Home Assistant and click 'Submit' to see a message like below.
The Zigbee gateway is now integrated into Home Assistant! The next step is to try and pair the Zigbee door / window sensors I purchased but I will cover that in another post.