Are you using Home Assistant in your van?

oooh! and the ID in the sensor is the Cerbo's ID, not the HA ID....

I think we may be onto something here!
 
Not sure why you are doing this. Before you go any further, why the 'Mosquitto' file in share? Mosquitto doesn't save anything, it is just a man in the middle for passing messages to and from a central point (think Post Office Sorting Office - but a bit more efficient). Try this link. Also, not sure why the Teltonika Conf file as you are using HA.
 
I'm very much at the 'monkey see, monkey do' stage of copying stuff and trying to understand why things work (and why they don't)

I don't really know what the Mosquitto folder in share does other than house the victron.conf file.

It's all taken from the Smarty Van video which is a good 'follow along' guide, but it doesn't really explain what those .conf files are doing, however it does work....

 
Mosquito is just another MQTT broker isn’t it. I guess you can chain them together but my instinct would be it’s not really helping and probably confusing things. I think people do it to use mosquito as a debugger/viewer.

Do you have a diagram of all the brokers and clients you have - publish and subscribe with IP addresses of everything.
 
Do you have a diagram of all the brokers and clients you have - publish and subscribe with IP addresses of everything.
No, and I think I should probably factory reset everything and start over now that I understand it a bit better and document what I've done as you suggest.

There's a good chance that I've done something along the way that's created problems which will be hard to diagnose as I really didn't know what I was doing to start with!

Subscribers  do not see these advertisements

 
Multi MQTT Brokers can be confusing, and work against you as you don't know where messages are going. Rog NotJane has a good idea to see what you are doing.

With NR I normally run Mosquitto on the same server, RUTX has a MQTT server, Venus OS has MQTT server, they all do the same thing, but to simplify what goes where, in this case I only use Venus MQTT Server, as it was already loaded and I was running on a RPi Zero 2 W, not a device with a lot of 'spare room'!! KISS Keep in simple s****d, a maxim that has served me well over the last x years (more than I care can remember!).
 
Well, just for the learning experience I think I'm going to give REST Api a shot.

(I know, I know... :D)

Partly because it's interesting and new, and partly because I've got to the point where my frustration with modbus and MQTT is preventing me from seeing the wood for the trees.

I've got some good resources to have a look at and when all that fails I'll be able to come back to MQTT with a fresh pair of eyes!

Shame that I've still not managed to get any information from anyone who's succeeded in linking Teltonika and HA.

Found a few threads on the HA community forums asking the same question but only one person who posted a solution, which sadly no longer works with current versions of RUT-OS.

I feel like I'm trying to uncover some dark secret! However, if I succeed then I'm going to be shouting it from the rooftops for all the other people who've been down the same painful journey.

It's the only way to learn though, so I'm off to see my old pal the brick wall again.... :ROFLMAO:
 
Nothing wrong with REST, we built a large IoT platform with webhooks with are effectively REST. The issue you might face is network complexity, each REST API is different and you need to set it up individually.

To that end, MQTT should make things simpler to add new sources (i.e. sensors and devices) and sinks (e.g. HA or NodeRed or whatever). But, because MQTT doesn’t specify a format for the data, it’s (I think) a level lower than where people really need.

It’s a bit like plumbing that automatically connects itself but you don’t know if it’s going to deliver hot water, cold water or gravy.
 
My thought was to use REST API just for pulling the Teltonika data so I shouldn't need to learn more than one.

When I stand back and have a high level look at this I've actually achieved most of what I needed to.

Controlling the lights was where this all started, which was easily done using ESP-32 and WLED. In fact it was so easy that it lulled me into believing that this was all going to be really easy and I'd have it set up in a couple of days!!

For the rest of what I need to control in HA I'm pretty close. The fan will be next, but I have a good guide to work from on that, and may eventually end up buying a completely redesigned circuit board if the chap developing it decides to go down a commercial route.

I've got all the victron data coming in nicely and may add an inverter which I'd just want to have an 'on / off' switch for.

On the list of 'future possibles' for HA:
  • Afterburner for diesel heater so that can be controlled (possibly add temp sensor for auto triggering)
  • Tank level sensors (although these might be on the Bobil system - undecided)
  • CCTV / MDVR type thing
  • Gas/CO detection sensor that opens the fans on full and sounds an alarm (although I might not be fitting gas to the van, so...)
  • Voice control for lights / fans
  • Water flow sensor
  • Remote water / waste dump valve
 
The NR Flow uses the REST API - look at the msg.url in the node before the HTTP Request (not the Authorise one) in the flow I posted in the PM.

Good luck with whichever way you end up using. You will learn something and everyone is different and uses the solution most suited to them.

If you have questions I can answer I will do so!

Subscribers  do not see these advertisements

 
Thank you so much again CeeJay13.

I will look at MQTT again and see if I can get that working too.

Then I can hopefully compare that to the REST API method and decide which I prefer.

Impossible to know until you've tried both I guess :)
 
I have recently upgraded to an N305 it has 8 cores. You just need a 12v stabiliser to power it from the habitation battery.
I've been looking into adding Voice to HA and it's strongly suggested to go with something more powerful than a Pi in order to minimise lag.

Just found an N305 with 16GB RAM and 512GB NVME (plus integrated cooling fan) for £300. I'm contemplating the 1TB NVME variant for £330 as it's not a massive increase in cost and if I'm using a multi-camera system to record 24/7 then it will quickly eat into storage.

Sound about right price wise matbic?
 
Yes for voice (local not over internet) an N305 is recommended. That’s about the going rate - might shave £20/30 off on AliExpress if you catch a deal going through. It’s easy to upgrade RAM and NVME with these boxes.
 

Join us or log in to post a reply.

To join in you must be a member of MotorhomeFun

Join MotorhomeFun

Join us, it quick and easy!

Log in

Already a member? Log in here.

Latest journal entries

Back
Top