Mastertronic Essentials

ffiren

Community Member
View Badges
Joined
Oct 26, 2020
Messages
40
Reaction score
55
Location
Perth, WA
Rating - 0%
0   0   0
hey guys,

I'm thinking about buying a Mastertronic Essentials to replace my Trident/TridentNP. Does anyone know how their data is exposed so I can use it for other things?

I can see they don't have an API. Is there an integrated webserver or is everything locked behind proprietary software?

EDIT: Actually, I think they do have an API, they just dont advertise it.

Please can anyone with a mastertronic enter this into a browser window for me. You will need to be on the same wifi as the device and put in the correct ip address: http://MASTERTRONIC_IP/api/getTestHistory

If the API is exposed then you should get something like this in return:
{"tests":[{"type":"ALK","value":7.8,"timestamp":1700000000}, ... ]}

Then it will be easy to integrate into Apex/Home Assistant :)
 
Last edited:
OP
OP
F

ffiren

Community Member
View Badges
Joined
Oct 26, 2020
Messages
40
Reaction score
55
Location
Perth, WA
Rating - 0%
0   0   0
If a Mastertronic could integrate into an Apex...it would open up a lot more users!
Yeah, difficult to test without having access to one.

Quick search of GitHub shows that you can get the data from the cloud using your credentials. I've emailed the author of the code for more info
 

JonoH

ɹǝpunʍoᗡ ƃuıɟǝǝᴚ
View Badges
Joined
May 16, 2023
Messages
2,273
Reaction score
4,459
Location
Adelaide, Australia
Rating - 0%
0   0   0
Yeah, difficult to test without having access to one.

Quick search of GitHub shows that you can get the data from the cloud using your credentials. I've emailed the author of the code for more info
You would think they'd be keen to be able to integrate, as it provides an option to not use the Apex Testers, but still use the base unit.
 
OP
OP
F

ffiren

Community Member
View Badges
Joined
Oct 26, 2020
Messages
40
Reaction score
55
Location
Perth, WA
Rating - 0%
0   0   0
Just got a response back from the guy that made the github repo. Seems he sold it a few years ago so can't comment. He did say it was powered by a raspberry pi though...

I'm keen to ditch my Apex but also twitchy about buying one of these without testing...

I'll likely do it anyway. Importing TridentNP reagents into Australia is a headache and my last two packages have been intercepted by border security. Just ordered eight months worth of regents and they all have an exp date of Feb'26 🙄


EDIT: Yeah, the author states it's a messy bash script that collects the data and then pushes it to their cloud server over http. He states there wasn't even any authentication.... He said that the only thing exposed locally was an SSH server but you can obviously pull and read the sd card. Should be easy to load ssh credentials on to the sd and then amend the bash script to either redirect the URL or create a cron job to push that data elsewhere.

Be handy if anyone with a device could bind it to an isolated access point running wireshark and see what the traffic is. If the push to remote server isn't encrypted then you can easily redirect that traffic.... Be possible to get that data into Apex Fusion but easier to export it into the likes of home assistant.

Doesn't sound like its been very well thought out - that sounds good to me!
 
Last edited:

JonoH

ɹǝpunʍoᗡ ƃuıɟǝǝᴚ
View Badges
Joined
May 16, 2023
Messages
2,273
Reaction score
4,459
Location
Adelaide, Australia
Rating - 0%
0   0   0
Just got a response back from the guy that made the github repo. Seems he sold it a few years ago so can't comment. He did say it was powered by a raspberry pi though...

I'm keen to ditch my Apex but also twitchy about buying one of these without testing...

I'll likely do it anyway. Importing TridentNP reagents into Australia is a headache and my last two packages have been intercepted by border security. Just ordered eight months worth of regents and they all have an exp date of Feb'26 🙄


EDIT: Yeah, the author states it's a messy bash script that collects the data and then pushes it to their cloud server over http. He states there wasn't even any authentication.... He said that the only thing exposed locally was an SSH server but you can obviously pull and read the sd card. Should be easy to load ssh credentials on to the sd and then amend the bash script to either redirect the URL or create a cron job to push that data elsewhere.

Be handy if anyone with a device could bind it to an isolated access point running wireshark and see what the traffic is. If the push to remote server isn't encrypted then you can easily redirect that traffic.... Be possible to get that data into Apex Fusion but easier to export it into the likes of home assistant.

Doesn't sound like its been very well thought out - that sounds good to me!
There was a guy making Home Assistant controllers on here - check out this site.

The one drawback was that there is no auto tester that can go with this - but if it could be integrated to a Mastertronic that would make it a much more viable (and affordible) option.

One of the reasons there isnt the Trident NP for sale in Aus yet is because they cant legally bring in the reagent for them, from what I understood they were trying to source a local supplier for this so they can release it.
 
OP
OP
F

ffiren

Community Member
View Badges
Joined
Oct 26, 2020
Messages
40
Reaction score
55
Location
Perth, WA
Rating - 0%
0   0   0
There was a guy making Home Assistant controllers on here - check out this site.

The one drawback was that there is no auto tester that can go with this - but if it could be integrated to a Mastertronic that would make it a much more viable (and affordible) option.

One of the reasons there isnt the Trident NP for sale in Aus yet is because they cant legally bring in the reagent for them, from what I understood they were trying to source a local supplier for this so they can release it.
I think they were still fighting over new distribution if honest. I spoke to the distributer at the beginning of the year....

If the info Cody (the Focustronic GitHub guy) gave me is still accurate then it would be easy to integrate into HA, though may need modification to the SD card. I'll have a look and see if I can find a dump of the card online. I'm sure I saw a thread about someone needing to rebuild one. I just want to see how that data is stored and exposed.

I've got all my kit managed through node-red in HA and don't want to give that up. I'm just fed up of the crappy nature of Apex gear. I've had so many failures and only have them attached now for the Trident/TridentNP. Even then, I don't trust the readings enough to let it actually dose anything!
 
OP
OP
F

ffiren

Community Member
View Badges
Joined
Oct 26, 2020
Messages
40
Reaction score
55
Location
Perth, WA
Rating - 0%
0   0   0
Yeah so device arrived yesterday. Really well packaged. No instructions or tax invoice!

It's running a raspberry pi4 with an sd card - I'll be swapping that over for an NVME as sd cards are not great for anything with frequent logging.

Can confirm that it's already been ran through the firstboot prior to delivery but it's trivial to mount the ext4 partition and add your own SSH key to get full access. I can see that it is running Apache and has an exposed API. Should be easy enough to get the test results but I cant do anything more as it will be two weeks before the reagents arrive as they split the postage!

A formal HA integration with local control will only be viable if I can get the results from the API, otherwise you'll need SSH access first. I can see a few scripts that do the tests etc so I am confident I can get it to do what I want.

I'll know more when I've ran it through the initialisation process but I need reagents first for that.
 

JonoH

ɹǝpunʍoᗡ ƃuıɟǝǝᴚ
View Badges
Joined
May 16, 2023
Messages
2,273
Reaction score
4,459
Location
Adelaide, Australia
Rating - 0%
0   0   0
Yeah so device arrived yesterday. Really well packaged. No instructions or tax invoice!

It's running a raspberry pi4 with an sd card - I'll be swapping that over for an NVME as sd cards are not great for anything with frequent logging.

Can confirm that it's already been ran through the firstboot prior to delivery but it's trivial to mount the ext4 partition and add your own SSH key to get full access. I can see that it is running Apache and has an exposed API. Should be easy enough to get the test results but I cant do anything more as it will be two weeks before the reagents arrive as they split the postage!

A formal HA integration with local control will only be viable if I can get the results from the API, otherwise you'll need SSH access first. I can see a few scripts that do the tests etc so I am confident I can get it to do what I want.

I'll know more when I've ran it through the initialisation process but I need reagents first for that.
Awesome, cant wait to see what you can do with it, and how you can integrate it.

I imagine if you could integrate it with an Apex it would be a huge selling point. Again not sure why they havent done this themselves...
 

ReefGreg

New Member
View Badges
Joined
Mar 18, 2025
Messages
2
Reaction score
1
Location
Poland
Rating - 0%
0   0   0
Really interested in this thread.
For me the Mastertronic Essentials make sense only if I could get access to the API and could integrate with Home Assistant.
 

ReefGreg

New Member
View Badges
Joined
Mar 18, 2025
Messages
2
Reaction score
1
Location
Poland
Rating - 0%
0   0   0
I've just found video showing that there is integration between HYDROS and Mastertronic



so it looks like it should be possible to add similar integration with Home Assistant.
 
OP
OP
F

ffiren

Community Member
View Badges
Joined
Oct 26, 2020
Messages
40
Reaction score
55
Location
Perth, WA
Rating - 0%
0   0   0
I've just found video showing that there is integration between HYDROS and Mastertronic



so it looks like it should be possible to add similar integration with Home Assistant.


Yeah, making an integration will be easy. Doing it in a way that doesn't require the user to first gain ssh access to the device is the hard bit. It's not difficult to do but you need to know how to safely mount an ext4 partition and then use the terminal to modify a few very important files. Very safe, very easy, but trivial to stop it all working if you make a mistake...

I've already got an image of the sd card as they don't publicly release it

Once I've verified mine is working and I have no warranty issues, I'll reach out to the company and start a discussion. They have emailed me a bit so I'm hopeful... There are github repos that scrape the data from their server - that costs them money so that's the ticket to have a discussion. Having that chat without them invalidating my warranty is another issue.... Having said that, and despite their AU website, this came direct from China. There is no warranty I can legally enforce.

I cant even get Neptune to RMA a DOA feeder from AU 😖

All they would need to do is add a single line of code to push the data to the /www folder of the Apache server - that would make the data available over http so the integration would do the rest. I can easily add that line, but if they make it part of the firmware, even if they do nothing else, then that will help others...
 

JonoH

ɹǝpunʍoᗡ ƃuıɟǝǝᴚ
View Badges
Joined
May 16, 2023
Messages
2,273
Reaction score
4,459
Location
Adelaide, Australia
Rating - 0%
0   0   0
Yeah, making an integration will be easy. Doing it in a way that doesn't require the user to first gain ssh access to the device is the hard bit. It's not difficult to do but you need to know how to safely mount an ext4 partition and then use the terminal to modify a few very important files. Very safe, very easy, but trivial to stop it all working if you make a mistake...

I've already got an image of the sd card as they don't publicly release it

Once I've verified mine is working and I have no warranty issues, I'll reach out to the company and start a discussion. They have emailed me a bit so I'm hopeful... There are github repos that scrape the data from their server - that costs them money so that's the ticket to have a discussion. Having that chat without them invalidating my warranty is another issue.... Having said that, and despite their AU website, this came direct from China. There is no warranty I can legally enforce.

I cant even get Neptune to RMA a DOA feeder from AU 😖

All they would need to do is add a single line of code to push the data to the /www folder of the Apache server - that would make the data available over http so the integration would do the rest. I can easily add that line, but if they make it part of the firmware, even if they do nothing else, then that will help others...
One of the biggest gripes with the Mastertronic is their app...so this could potentially solve that right?
 

dhochheiser

Community Member
View Badges
Joined
Feb 15, 2025
Messages
89
Reaction score
164
Location
Baton Rouge
Rating - 100%
4   0   0
Curious and following on....I just ditched all my apex stuff and used this as the testing solution.

A couple of hiccups (mostly user error) as I got started, but pretty happy with it as a testing solution
 
OP
OP
F

ffiren

Community Member
View Badges
Joined
Oct 26, 2020
Messages
40
Reaction score
55
Location
Perth, WA
Rating - 0%
0   0   0
One of the biggest gripes with the Mastertronic is their app...so this could potentially solve that right?
Yeah - I have no desire to ever use their app

I drafted an email to them last night - they obviously have reasons for wanting to do it their way, as is their right. I do think their sales would increase if they would to improve interoperability.

I get my reagents on Wednesday - only then can I run it through the test cycles and see how it gets the data. It's literally running Debian and I think uses kamoer pump heads, so it's going to be trivial to poke about and see what it does.

I'm impressed with the build quality - significantly better than Neptune. Just hope it works as intended!
 

dhochheiser

Community Member
View Badges
Joined
Feb 15, 2025
Messages
89
Reaction score
164
Location
Baton Rouge
Rating - 100%
4   0   0
Yeah - I have no desire to ever use their app

I drafted an email to them last night - they obviously have reasons for wanting to do it their way, as is their right. I do think their sales would increase if they would to improve interoperability.

I get my reagents on Wednesday - only then can I run it through the test cycles and see how it gets the data. It's literally running Debian and I think uses kamoer pump heads, so it's going to be trivial to poke about and see what it does.

I'm impressed with the build quality - significantly better than Neptune. Just hope it works as intended!
It has for me so far...The app is meh, but it's not more terrible than other things...certainly if it integrates into HA there is a lot more flexibility to do things there.
 
OP
OP
F

ffiren

Community Member
View Badges
Joined
Oct 26, 2020
Messages
40
Reaction score
55
Location
Perth, WA
Rating - 0%
0   0   0
It has for me so far...The app is meh, but it's not more terrible than other things...certainly if it integrates into HA there is a lot more flexibility to do things there.
yeah, scraping the data should be easy

initiating the test should be a simple case of running the appropriate bash script - there's a few in the /pi user dir. I haven't had chance to take a good look at them as I was doing everything though the home assistant console terminal which meant I had to type my ssh key out by hand.

Now I have ssh access, I'll use SCP to copy them over and have a good look.

There is an /api dir on the apache server - I called some of the commands but they had binary frames which messed up the terminal session - again it will be easier to just do it properly. If you can initiate the test remotely via the app, then you can easily use a mitmproxy to intercept the command.

Control should be fine. Getting the data off it so i dont need their app is my priority.

As I said, I haven't even gone through the initialisation process yet but will get it mounted on the weekend and then have a proper play next week when the reagents arrive.

I'm not great at coding, but I have enough skills to get by! I'll get this to work for me I'm sure, but making a formal HA integration may require a bit of research. It wont be difficult and am confident that I'll figure it out. It just would be nice if the manufacturer was supportive to skip the ssh step for less linux proficient users.
 
OP
OP
F

ffiren

Community Member
View Badges
Joined
Oct 26, 2020
Messages
40
Reaction score
55
Location
Perth, WA
Rating - 0%
0   0   0
Sooo… my device won’t successfully complete a test. 🙄

That being said, whilst I wait for the manufacturer to provide guidance, I have decompiled their firmware and can make a HA integration that gives full control using their SQ3Lite DB.

You still need to gain ssh access to create a helper that will expose the important bits over their api.

For those interested, the useful stuff is in usr/mt and etc/systemd/system/mastertronic.service 👍


I’ve reverted mine to stock whilst I await their reply
 

TOP 10 Trending Threads

WHAT AMOUNT OF LIVE ROCK AND SAND SHOULD BE PRIORITIZED FOR OPTIMAL BIODIVERSITY/FILTRATION?

  • 100% live rock + bagged sand

    Votes: 34 26.6%
  • 100% dry rock + 100% live sand

    Votes: 45 35.2%
  • 50/50 live/dry rock, 50/50 live/bagged sand

    Votes: 28 21.9%
  • 75% live rock, 25% live sand

    Votes: 11 8.6%
  • 25% live rock, 75% live sand

    Votes: 10 7.8%
Back
Top