27
Views
19
Comments
Data Acquisition from Arduino

Hello,

I am currently working on a project with my task being to have the data from a temperature sensor from an Arduino be read into outsystems. I was wanting to know what the best way to implement this would be.

I was thinking of having the Arduino send live data to an excel sheet, but I didn't know if outsystems would be able to read data from an excel sheet while the Arduino is simultaneously writing data to the same sheet.

If that doesn't work then I also have another idea. I only need to take an average temperature reading every few hours, so if I wrote a delay in my arduino code to have it only write live data to the excel sheet for 5 minutes every 2 hours, would the outsystems then be able to read the data from the excel sheet during the 2 hour delay?

What are some other methods that would be better than mine?


Thanks for the help! 

Hi Akash,

Do you want data to be uploaded to outsystems in real time?

Regards,

Samiksha.


Rank: #43958

Yes, if that is possible.

Are you using ethernet oy wifi to connect to network?


Rank: #43958

The arduino is connected via usb to my laptop. 

Hi Akash,

There are two method depending on Arduino is connected to internet or not

  1. Arduino not connected to internet: In this case you can dump the reading from sensor to sdcard connected to Arduino. I suggest to use to .csv to write the data. Once data is written in sdcard, you can pull the card and copy the csv file and then upload it to outsytems via a developed portal/webpage. This will be an indirect way.
  2. If Arduino is connected to internet: Then will suggest to directly post the data to Rest endpoint exposed by you in outsystems. This will be a direct and realtime way.

Hope this help.

Regards,

Samiksha

Rank: #43958

Hi,

So, to confirm, if I connect the Arduino to the internet, then it will be relatively easy to send live data to the outsystems?

Is there a guide to doing this?

Thank you for the help,

Akash 

 

Rank: #43958

Akash Patel wrote:

Hi Samiksha ,

So, to confirm, if I connect the Arduino to the internet, then it will be relatively easy to send live data to the outsystems?

Is there a guide to doing this?

Also, do you know the best way for me to get wifi onto my Arduino? I'm currently using an Arduino mega.

Thank you for the help,

Akash 

 

 

 

Champion
Rank: #275

Hi Akash,

  It's fairly easy to do, simplest way is to use standard REST API calls, In Outsystems there are some details in the training modules but REST is fairly easy to use. For the Arduino you will need to use one of the REST API libraries, there are a lot of guides on the net for that just search for REST Arduino for examples or look through the Arduino libraries for one.

Champion
Rank: #275

Here is a starting point for the Arduino side,


https://www.survivingwithandroid.com/arduino-rest-api-iot/


Rank: #43958

Jeanene Williams wrote:

Here is a starting point for the Arduino side,


https://www.survivingwithandroid.com/arduino-rest-api-iot/


 Thank you for the help I will look into your link! 

I'm currently using an Arduino mega, so I would need to find a way to find a device that would enable wifi onto it. 

Would it be simpler for me to get this arduino uno board that comes with wifi?

https://store.arduino.cc/usa/arduino-uno-wifi-rev2

 

Champion
Rank: #275

I use these, you can program standard arduino and they have a lot of very easy sensors and devices to plug in. Also full WiFi built in

https://www.seeedstudio.com/Grove-Starter-Kit-for-Arduino-p-1855.html


Champion
Rank: #275

Sorry Wrong Link thats the Arduino shield version, hang on I'll find the correct one.

Champion
Rank: #275

This is the one I meant, can take all the grove sensors

https://www.seeedstudio.com/Wio-Link.html


Hi Akash,

You can refer this:

https://www.arduino.cc/en/Guide/ArduinoEthernetShield

Let me know if this work.

Regards,

Samiksha


Rank: #43958

Hello,


So far I have been able to connect my arduino to wifi and have to collect temperature data.
How do I go about using an API to collect data from the arduino and sending it to be stored in the outsystems app?

Hi,

If you have connected arduino to wifi network and want to store data in Outsystems, best way would be to expose a API from Outsystems and then push data from Arduino to that exposed API , in this case.. Outsystems will be acting like a server and in Arduino you have to write web client code.

Thanks


Rank: #43958

Hi,

Thank you for replying so quickly. I'm fairly new to Arduino. Do you know of any guides or tutorials that would help me do this?

Rank: #43958

Thanks for the fast reply.
I will work on it tomorrow and let you know!

Akash