The project I’m going to describe today it’s a sort of proof of concept that will demonstrate the possibility to remote control sensors and actuators (for example a couple of relays) via Telegram.
Telegram is an instant messaging application, similar to the famous Whatsapp. Last June, the Telegram developers announced that a new set of APIs were available to develop bots.
My idea was to develop a bot, running on my Raspberry Pi, that receives commands via Telegram chats.
Starting with a Raspberry Pi 2, walk through the setup instructions here. You do need to have a Windows 10 today to installing Windows 10 IoT Core but at least it’s gotten a lot easier with the latest build for IOT. There’s an app that does all the work and you don’t need to go to the command line. Also get Visual Studio 2015 Community and the Windows IoT Core Project Templates. Basically just follow these step-by-step instructions.
Right now, all of the sensors and actuators are connected to Raspberry Pi GPIOs. At some point I may move them to the STM32.
I have disabled I2C on the PI and use the SDA/SCL pins as GPIO, reusing the external pull-up resistors on those lines for my sensor pullups. (Sensors are active-low)
GPIO 17, 27, 22, 23 (outputs) are used for the light and door toggles for the two garage doors.
Briefly, it’s a Raspberry Pi v1, Model B, Rev2 breakout with an STM32F030 microcontroller connected to the Pi UART, with all GPIOs for both broken out. There are also connectors for an NRF24L01+ module, a 12V boost module, and 315/433 Mhz wireless transmitters.
One board will serve as my Garage Door Controller, while the others will be used for general Pi hacking.
This was my first board manufactured at DirtyPCBs.com. I was very impressed with both the ordering and fulfillment process, as well as the boards themselves.
The PCWorld website posted an article about the open hardware Olimex OLinuXino single board computer. The article compares it to the Raspberry Pi, noting that the while Raspberry Pi hypes their board as open hardware, they have not released their CAD files or complete schematics yet and utilize components that are not available in small quantities. Olimex designed the OLinuXino board to address some of these concerns. All CAD files and complete schematics are available and they use an easy to find CPU. They use the Creative Commons Share-Alike license for all hardware and the GNU GPL license for all software associated with the OLinXino. The board uses a faster CPU than the Raspberry Pi and runs Android, debian, and other GNU/Linux distros. They also tout the board as being noise immune and working in industrial environments with a temperature range of -25 C to 85 C. The OLinuXino uses the standard nano-ITX form factor. The board is priced at 45 Euros (about $57). One point where we’d have to say the Raspberry Pi wins is on the name. It’s unclear how to pronounce OLinuXino, which can’t be good from a marketing standpoint.
So what about the actual specifications?
A13 Cortex A8 processor at 1GHz, 3D Mali400 GPU
512 MB RAM
6-16VDC input power supply, noise immune design
3 + 1 USB hosts, 3 available for users, 1 leads to onboard pinout
1 USB OTG which can power the board
SD-card connector for booting the Linux image
VGA video output
LCD signals available on connector so you still can use LCD if you diasble VGA/HDMI
RTC PCF8536 on board for real time clock and alarms
5 Keys on board for android navigation
UEXT connector for connecting addtional UEXT modules like Zigbee, Bluetooth, Relays, etc
GPIO connector with 68/74 pins and these signals:
17 for adding NAND flash;
22 for connecting LCDs;
20+4 including 8 GPIOs which can be input, output, interrupt sources;