Can I use ESP8266 with edgeSDK? - raspberry-pi

I've started testing edgeSDK in a prototype IOT environment.
The idea is to connect devices with sensors and other nodes (Raspberry Pi, ESP8266, macOS, etc.) and exchange data or messages between them on the edge, trying to avoid communicating through the cloud.
(I will be also "mirroring" this exchanges in an AWS central cloud environment, to establish some comparisons/evaluations).
At this point, I have edgeSDK running on macOS and the Raspberry Pi and would like to add ESP8266 into the mix.
My Question is:
Can I get ESP8266 to work with edgeSDK? I don't see it listed as a supported platform.
If yes, which OS? (I was thinking about Mongoose, keeping the JavaScript coding and follow the standard).
Any other comments/suggestions or similar references would be very welcome!

ESP8266 is a microcontroller, which edgeSDK does not support. However, you can run a RESTFul API client on ESP8266 to call a API served by a microservice hosted by edgeSDK on a Raspberry Pi for example.

Related

How to emulate BACnet communication protocol on raspberry pi stacks

I am currently working on my senior design project. I have made the stack of raspberry pi's. I am just wondering on how to create a BACnet stack where each raspberry pi device is a unique device, with a unique device ID. Additionally, we plan to use a cisco switch to connect with other raspberry pi stacks. I understand that there is a bacpypes module, which is amazing but it is mainly for dealing with a bacnet device. In my scenario, I need to create a stack of raspberry pi's emulating the BACnet communication protocol.
It would be really helpful
Quickest way:
Compile Steve Karg's BACnet stack by following this: "How to build a FOSS BACnet Server based on Steve Karg’s SourceForge project" on the BITS blog.
Run the BACnet SErver sample executable on each of your Pis:
cd /demo/server
./bacserv
May I suggest trying BAC0, a python implementation of BACnet.
BAC0 is a high level wrapper around bacpypes. And when launched, becomes a BACnet device on any network.
https://github.com/ChristianTremblay/BAC0
https://bac0.readthedocs.io/en/latest/

Leshan connect to server and cloud

I have the task of implementing iot device management using Eclipse Leshan. I have difficulty understanding how Eclipse Leshan works in connecting IOT sensors with servers and cloud. Is it true if I declare that Eclipse Leshan does not require a gateway like Eclipse Kura to connect into server and cloud?
Does anyone know where the complete documentation about Eclipse Leshan is? it would be very helpful if there were examples of programs in implementing the eclipse leshan.
Thank you
Eclipse Leshan is a library for implementing applications that use the LWM2M protocol to manage devices. As such, your application can use Leshan's Java API in order to interact with devices that also support LWM2M.
LWM2M does not per se mandate a transport protocol. However, the spec is written assuming that CoAP over UDP is used for that purpose. In fact, the LW in LWM2M stands for Lightweight and as such, using CoAP as the transport protocol makes a lot of sense for managing constrained devices.
Eclipse Leshan itself does not connect to a server or cloud but instead is usually part of an application that is hosted on a server (on the cloud). However, you need to implement that application yourself because Leshan, as indicated above, is just a library. The devices then interact with your LWM2M enabled application. Because CoAP/UDP uses standard IP, this interaction can occur over public internet infrastructure if desirable in your use case, i.e. no gateway is necessarily needed. You can, however, also connect your devices to a local gateway, e.g. Kura, and then connect the gateway to your LWM2M server in the cloud instead. It really depends on your use case and the capabilities of the devices.

IoT using Google Cloud Service IoT solutions (Weave): How to connect Raspberry Pi and lighting the LED?

I am trying to connect my raspberri pi with Google IoT Cloud solutions using Weave. I have done it already using AWS and IBM Bluemix, but could not find a way to do the same using Google Cloud. As per their documentation, it seems that some of the fies have been deprecated or not been updated.
Moreover, they have been written in C language and I am not much of a C guy. I used Python for both the IBM Bluemix and AWS to connect my Pi to IoT and then establish the subscriber and exchange messages using MQTT gateway.
Can anyone suggest anything regarding this?
Google Weave getting started
To be more specific, certain packages which I saw in error logs while installing the below step:
make -C examples/host/light
it showed in logs the message like
could not find lldap
could not find llssh2
Even after installing them in my developer machine.
Due to error above, the below command
./out/host/examples/light/light
is not executed as the location
/out/host/examples/light/light
is not created by the above make command. Any suggestions for this?
You might want to try instead to use the new Google Cloud IoT Core product instead of Weave - full disclosure, I worked on it. It's currently in public beta and enables the scenarios you're trying to address. You should be able to use MQTT to communicate to/from your device.
There's a high-level overview of the platform on YouTube as well as an industrial applications focused talk from Google I/O.

Bacnet on Raspberry Pi

Currently I am working on simulation of SCADA system using bacnet protocol for network communication with my Raspberrry Pi for my final year project.
Current status: Raspberry Pi 2 able to run openplc (act like PLC)
done installing ScadaBR (act like SCADA system)
Current issue: How would I implement bacnet protocol for data link to make connection between both Raspberry Pi and my workstation?
I tried to research on bacnet stack protocol, implement some opensource but there is no luck. But I using the demo of youtube video (http://www.youtube.com/watch?v=0TJIrnAPsw4).
It making raspberry pi act as a bacnet server. the code is working perfectly. How can I find a bacnet protocol (client version) running on my Raspberry Pi.
here are some question I unable to source:
Which bacnet stack able to control the bacnet communication between PLC (Raspberry Pi) and ScadaBR?
How Raspberry Pi (openPLC preinstalled) communicate with ScadaBR?
use which bacnet stack to implement both workstation.
The BACpypes library is written Python and runs on a variety of platforms, if you still have some time before the end of the term for your final project, contact me (the author) and maybe we can make something work. I see that your question is tagged with Java, but maybe you have other options.

Send data from server to a client (Raspberry Pi) without pull request

I have a Raspberry Pi and I am developing an application on the Pi that can be controlled by a web portal.
So I need to know, if I change something in my website, how will that be transferred to my Pi which is a client without any pull request from the client.
One solution could be to install Apache on your Raspberry and setup a basic http PHP or Python API. When a change is posted on the website, the back-end script makes a API call to the Raspberry API service.
If you are using PHP as your web server, you could use json_decode(file_get_contents(...) to access the Raspberry API.
I'll suggest you to use Websockets.
Websockets are bidirectional and client and server can communicate whenever they want as TCP session is ongoing. So, yo will not need to do polling.
You can download and compile libwebsockets for your raspberry as server or as I did in one of my previous projects, you can install nodejs into the raspberry and use socket.io library to handle all. Of course, you will need to do some modifications in your web page to behave like websocket client or socket.io client.
Good luck!