Lets now move to SDCC, because SDCC is free and the free version of Keil has limitations. We will also move away from Windows to Ubuntu 64 bit
Installing SDCC on your Ubuntu PC
Download 64 bit snapshot from: http://sdcc.sourceforge.net/snap.php#Linux
The archive file would be named something like: sdcc-snapshot-amd64-unknown-linux2.5-20180712-10467.tar.bz2
Download it to your ~/Documents directory
Then execute the following commands from the same directory (~/Documents) where you have placed the downloaded archive: tar xjf ../sdcc-snapshot-amd64-unknown-linux2.5-20180712-10467.tar.bz2 cd sdcc sudo cp -r * /usr/local
This will install sdcc binaries into: /usr/local/bin/ header files into: /usr/local/share/sdcc/include/ non-free header files into: /usr/local/share/sdcc/non-free/include/ library files into: /usr/local/share/sdcc/lib/ non-free library files into: /usr/local/share/sdcc/non-free/…
A few months ago, I got my hands on ESP8266 Black cloud features Board T5 which has an ESP8266, an 8051 microcontroller and a few sensors. The 8051 microcontroller acts as a master to the ESP8266 and comes loaded with a demo program which is supposed to work with some android app. ESP8266 can be directly programmed using Arduino, so it would be better if I would reprogram the 8051 to act as a slave connected to ESP8266. The ESP8266 will run an Arduino sketch (that I would write) and ask the 8051 for the sensor readings (over UART). To do that I would need to program the 8051 with come C program that I have written.
So the first step was to learn how to compile a simple blinky program for the 8051 and be able to download and run it on it.
One of the big issues with IoT is somehow enabling two end nodes to communicate with each other in the presence of Network Address Translation (NAT)
Now days most ISPs (and Mobile Network Operators or MNOs) use NAT by default and assign you local IP addresses in 10.*.*.* subnet. You usually have to pay an extra fee to get static global IP addresses assigned to you - this could be a security concern.
If your end nodes run embedded linux, the following solutions can be used:
Use DDNS and UPnP together DDNS is not usually free, but the manufacturer of your embedded linux device (routers from goodlife of Vstarcam's IP camera) might provide you this service for free as it uses almost nil resources on the server side. Most ISPs have UPnP support disabled on their gateway. In a home environment, if you have your own static global IP for your home router, you can use UPnP and DDNS to your advantage. An end node will use UPnP to request your WiFi Router to open ad forward certain outward fa…
We all want our smartphone to charge quickly. And different phone manufacturers have either created their own propriety method of charging (Oppo VOOC or MediaTek PumpExpress+ or Motorola's TurboPower or OnePlus's Dash) or have opted to comply with a industry wide standard like Qualcomm's Quick Charge series of standards).
These technology work my allowing a phone to tell the charger to step up the voltage beyond 5 volts so that the power available to the phone for charging the battery is more than what a good 5 volt / 2 ampere wall/car charger can supply.
I have a Moto G4 plus and I wanted to make sure that I had access to fast charging at home/office, in car or while travelling. So I went ahead and got the following accessories
Voltmeter This small device is what allowed me to check at what voltage/current the various chargers were charging my phone or regular devices.It has a USB male and female receptacle so that it can sit between the charger and the USB cable.It shows…
Plastics! Cancer! Correlation!
And so we move away from plastic bottles to glass bottles.
But glass bottles pretty but fragile.
So what do we do?
We get food huggers!!!
Food huggers seemed onle somewhat useful to me all this while until now
The silicone rubber food huggers will protect the bottom of the bottles - I was worried that I might end up banging them on the floor when I have a sip in the middle of the night.
The food huggers come as a set of 4. Only the two larger ones have diameters large enough for the glass bottles linked to above. The smaller two won't fit. So if you get 6 bottles, you will need to order 3 sets of food huggers. Of the 12 pieces of food huggers, you will end up using only 6 of them.Various sized food huggers seem to be colored differently to match the color of the vegetable/fruit they are supposed to protect. Yellow is for lemons, Purple for onions, Green for capsicum, Red for tomatoes. This is …
If you are an IoT enthusiast who uses devices that run OpenWrt (routers from Goodlife, or MT7688), you would have considered creating a plugin for LuCI so that you can expose the functionality of any sensors/actuators that you may have connected to your OpenWrt box via OpenWrt's builtin web console.
This article on openwrt.org's wiki will tell you exactly how to do that.
As maybe obvious from the page, if you want to create dynamically generated web content, you will need to write lua scripts.
When trying out the steps from the wiki article for my GL-MiFi, I had to modify the file locations for placing various script like so:
new_tab.lua had to be placed in: /usr/lib/lua/luci/controller/myapp cbi_tab.lua had to be placed in: /usr/lib/lua/luci/model/cbi/myapp-mymodule cbi_file can be put in the same place as mentioned: /etc/config view_tab.htm had to be placed in: /usr/lib/lua/luci/view/myapp-mymoduleOnce I had the placed the files in the right location, I could see them in the web UI: