There are a lot open-source domotica systems available like Calaos, Domoticz, Home Assistant and OpenHab to name a few. Now there is one more, my own (for now) nameless system. Why make your own I hear you asking! First of all because I want to learn how to create such thing from the ground up, and I want to find out how I would build such system without being influenced by other domotica systems. I haven’t checked any source code of my direct competitors and I haven’t checked how they solved various issues. I googled some of their interfaces and in most cases I hope I can do it better. Because in my opinion most of them look really outdated! In this blog I want to show you what I have build so far. Keep in mind it is by far not yet ready or usable.
I don’t know exactly what started my interest in Machine Learning and AI in general, but it’s a topic that I monitor for a long time now. The vast amount of possibilities sparkle my creativity and I love to experiment with it. Especially now services from Google and Azure made it so simple to build cool stuff with it. But I am also interested in how things work, that’s why I love to dive deeper into the subject. And when I gain some knowledge, it’s always fun to share that knowledge with others. This blog is about an introduction to the topic Machine Learning I gave at my work. It was a small presentation just covering some of the basics, but just enough to get started with it.
Sometimes you struggle with issues that seem to be small at first glance but still consume a lot of time to find out what the real problem is especially when the issue can only be reproduced when a specific browser or version is used. In my case I build a script to download a PDF file in PHP. It seemed to work in all browsers until a client uploaded a very specific PDF file that wouldn’t open in chrome’s buildin PDF viewer but worked in all other browsers and also offline. Ahhhrr is it a chrome bug, or did I do something wrong? Continue reading to find out what I did to solve it.
Ajax requests are only possible when the protocol, domain and port number are the same. But sometimes you want to do Ajax calls to a different domain for example when you are creating a shared service that people should be able to call using Ajax or when you are developing locally and you are testing on a remote server. There are multiple ways to get around this restriction for example by using CORS, an iFrame or JSONP. In my last project I got around the restriction using JSONP, so I will explain that here. See links for more information about solving it using CORS.