Personal monitoring app with photon, mysql and node.js

Hi, i,ve been trying to get as much info as i could but i cant find a way to solve this already:
I want to make a monitoring app in which i read for example a potentiometer and i show it in a dashboard (web page or app or mobile i will check that later) the problem is how can i do it all by myself? like i know i can use a platform like ubidots to manage that but what if i dont want to, i was thinking about node.js + mysql to store the data but what would be the correct data process, have a server to store the readings from the photon into the tables in mysql and then have another server to upload the last reading on the table into a webpage and start plotting?
how can i make it work? im not using a 3th party platform because i want to send like 100 readings per second.
I know we have this topic

but thats just printing directly everything what it recieves, but what if i want to have control on users and devices?
Like only a user can see data from the devices he own... Thats why i want to integrate mysql to keep track of that and just relate tables
I think i covered like 50 topics but i didnt knew how to put me in context without all the topics.
Thank you for all the help!

This is one of those projects where the answer comes awfully close to:"if you have to ask...".

That's a big project you're talking about, interacting with several systems. All of which have difficulties of their own. The best advice I can give is splitting the project up in smaller, more manageable pieces. You're not going to find a guide of tutorial that shows you how to do the project as a whole, but there might be ones out their for parts of it.

The topic you linked to is a great example of that: it shows you how to do the device -> server part, as well as a server -> webpage part:

So, you've got the code to get your data to a local node.js server, now you'll need to find a way to store that data in a database somewhere. For that, there are tutorials available. Then, you need to figure out how to make a nice front-end to display said data, for which there are tutorials available as well. Then, you need to figure out how to get the data from the database to said front-end, for which there are guides, too.

There's a reason there are services out there that are making good money from this: this isn't the easiest things to do, and will take some serious TLC even if you're familiar with systems like these. It depends on how much your time is worth whether or not it might be a good idea to invest in one of the existing platforms, or DIY something.

Should you go for DIY, then break if down into sizable pieces, and go at them one by one, not all at once.

1 Like

Thanks bro, thats actually a pretty good answer since i was getting a little overwhelmed D:, do tyou think this infrasructure/data managment is correct? That way i can have the project in a big picture so i can break it into smaller projects.

im talking about the devices->server1->database->server2->frontend

i think theres probably more than 1 way to do it but idk if my idea is actually correct or viable.
Im mechatronic engineer im a lot into programming but im not any where close to a software engineer

Anyway thank you for your help you actually helped me a lot :smile:

Seems about right, though there’d most likely be only one server.
The devices write to the database using the server and the front-end withdraws data from the database using that same server.

Any particular reason why you want to build a system like this by yourself?

Thank for all your help, i’ve tried to work with already working platforms like ubidots, losant,azure and i keep struggling getting all i want, like ubidots have users managment, easy control, and an easy access with particle but i can get at much 6 readings per second and i may want to try at least going for 100 per sec, i think they dont allow to do that bc i would over saturate their system since they recover data from at least 3 months ago, i dont need that, i just need that the readings get to the frontend and as they were showed they can be eliminated so i wont saturate my system, in azure i can have those speed rates but at a really high cost + they aren’t as flexible as ubidots and so and so and so, eery single system i tried cant fully cover my needs so thats why im trying to do a simplier version of those by myself, but that way i can just give me the specs i need and nothing more.
“hopefully” lol hahaha

By the way, I have an example of streaming data over TCP to a node.js server and storing it in MySQL as well. It’s advertised as a local server, but really you could deploy the same thing on AWS, Heroku, whatever and do it over the Internet.

I think im getting all the pieces together to start coding but do you think its a good idea to start everything locally and then try to jump to global internet? or i should just rent a server already on the internet and work on that??
btw omg the man rickkas7 himslef :open_mouth:

I prefer trying things locally since I then don’t have to deal with all the “extra” stuff that comes with running it on a live server. That, and I don’t have to pay for something that’s still under development.
On the other hand, if you build it on the server you’re going to be running it from, it ensures you have the most relevant debugging/testing.