Ford Transit USA Forum banner

Van automation (Technical Discussion ONLY)

9956 Views 83 Replies 23 Participants Last post by  edumartins
8
As I have hinted in other threads I have been working on an automation and control system for the van. The 3 phases of this project are:

1. Single pane of glass control of all devices (to include vehicle controls as well)
2. Sensor and data collection; local and internet
3. Automate various tasks based on sensor data

Step 1 involves turning most of your disparate 'dumb' devices into relays which can be controlled by the MCUs. Some things like the MaxFan and the CnC AC are pretty straight-forward. I haven't started on the Espar yet, but I imagine I'm in for a load of fun. As for vehicle controls, they're pretty well documented, and for the most part I will render the physical vehicle controls inoperable. This also includes relay controls for lighting, pnematics, and really anything else that needs a power switch.

Step 2 is gathering the values which will be needed to make the automation workflows. Throughout the van there will be sensors that I will install such as temp/pressure/contacts/lidar/ultrasonics, etc. In addtion, the CerboGX has a ton of data on the electrical system, and there are also various APIs I can pull from online, such as weather data. I also have OBD-II data feed and the vehicle status outputs from the High Specification Vehicle Interface Connector.

Step 3 is the fun part. Most of automation will revolve around lighting and environmental controls. I will be able to write logic using any of the sensor data collected to make these tasks as intelligent as possible. For example, the solar panels might only extend if the vehicle is off, distance sensors detect no obstructions, the weather report says winds are less than 50 mph, and the system SOC is less than 90%.

All of this is accomplished with various MCUs around the vehicle collecting sensor data and controlling relays. This data is all sent to an MQTT server where other MCUs can act on the information. This is a fairly common and well documented method of DIY automation. I'm using Teensy 4.1s because of the built-in ETH PHY along with the extremely beefy (for an MCU) hardware specs. For example my panel code is already using 200 Kb of RAM whereas your standard Arduino Uno only has 2 Kb of RAM max.

The panel is an 800x480 capacitive touchscreen and is essentially stateless like all the other MCUs. I'm making a few more at the moment for the inside and rear of the van. On powering up it pulls all the MQTT topics which describe relay status and other variables and is able to immediately represent the status of the system. This happens anytime the topic values are updated, whether it's another panel changing something or automation code.

As with everything in the van, the current status is "temporary working example". I'm not particularly fond of the GUI I came up with, but I did just refactor all the backend code to make additions to the system very easy. It's really down to building proto-boards at this point in order to bring everything up.
Communication Device Tablet computer Gadget Mobile device Output device

Circuit component Electrical wiring Hardware programmer Passive circuit component Electronic engineering

Passive circuit component Circuit component Hardware programmer Electronic engineering Electrical wiring

Passive circuit component Circuit component Automotive tire Bumper Electrical wiring

Circuit component Hood Gesture Finger Hardware programmer

Product Tablet computer Communication Device Gadget Output device

Output device Communication Device Gadget Mobile device Portable communications device


BONUS pic of electrical system...
Motor vehicle Vehicle Trunk Automotive design Mode of transport
See less See more
  • Like
  • Wow
  • Love
Reactions: 5
1 - 20 of 84 Posts
I don't have time to read this now, but I love it already. I'd love to learn more details.
Super freaking cool!!!

For the Espar side, Mike had mentioned folks looking to have remote switches & sensors for the heater have accomplished it using the analog bus.

Just curious, what is your endgame with this?
  • Like
Reactions: 1
I agree - very cool.
I don't know how committed you are to your current path, but if you were starting from scratch I would strongly recommend you take a close look at Home Assistant and ESPHome. They are a hugely popular and active open-source project intended to do exactly what you are envisioning. I believe that you could accomplish 100% of your goals with 30% of the time and effort.

That said, I do understand that sometimes it is the journey and not the destination, so you may have very good reasons to continue down your current technical path.
  • Like
Reactions: 1
Your rear end is a work of art!

NO, NOT LIKE THAT! 😛

The layout is clean and just plain well done. Good job with that. It looks like someone opened up a panel on the ISS. (Okay I'm only guessing on that one...)
  • Like
Reactions: 1
Wow. Just wow. And here I felt pretty darn proud of myself for utilizing an arduino and some relays to do some minor automation projects. Impressive.

I actually kinda like your UI - reminds me a bit of Star Trek.
  • Like
Reactions: 2
I don't know how committed you are to your current path, but if you were starting from scratch I would strongly recommend you take a close look at Home Assistant and ESPHome. They are a hugely popular and active open-source project intended to do exactly what you are envisioning. I believe that you could accomplish 100% of your goals with 30% of the time and effort.

That said, I do understand that sometimes it is the journey and not the destination, so you may have very good reasons to continue down your current technical path.
I haven't looked at either really. These days I pretty much assume everything involves an internet connection and a phone app. I don't need to remotely do anything (even though I will add a secure way to do that in the future) and I'd prefer to just throw my phone away. The other big thing is that the interfaces I'm building are all custom, so at some point I'm going to have to do a lot of work. I'd much rather fit it into my framework than adapt it. My way probably isn't better, but at least I know how the pieces fit. And as you say, it is a journey, I started the project knowing that it probably wouldn't be completed before moving on to the next thing. A lot of things I've tried to make modular to facilitate that transition when it comes.
  • Like
Reactions: 3
Amazing work. Please please please throw this into a github repo. If you aren't familiar I'm happy to help you get started with that.
I haven't looked at either really. These days I pretty much assume everything involves an internet connection and a phone app.
I am 100% with you on the "no mandatory cloud" principle. But that's the thing: Home Assistant was founded on just that principle. They bend over backwards to keep everything local (although you CAN access remotely if you like). It really is at least worth a look. You might at least find it useful to fill in the cracks until you have a chance to cover them properly.

BTW: I agree about your work. First rate.
I think what you have already put together there is incredibly impressive. Good on you. This suggestion is likely simple in comparison, but I'd be pretty please with just a set of roof sensors, that can serve as Roof Height Obstruction warning.

I don't know why Ford hasn't thought of this already themselves, but with so many Hight Roof Transits being sold around the world now and just by the looks of how many of them have damage and or scaring around their roof sections this seems like would be helpful to a lot of us. Me included, not wanting to miss something one day and end up catching it in the huge forehead of the van or along one of the sides.
  • Like
Reactions: 2
That has to be the most impressive Victron setup I've ever seen! If you ever decide to sell your vehicle, I imagine Victron would love to take it off your hands for road shows :) You wouldn't happen to have any wiring diagrams (even sketches) would you?

I am of the same mindset (and similar plans) on automation. I don't want a wall of thermostats and controls, just give me automation based on battery condition, driving/parked, outside temp, tank levels etc. Like others have mentioned, my plan of attack is ESPHome + Home Assistant. FYI, MQTT control is still an option with HA, so you could integrate the work you've already done. There's also a Victron integration as well. ESPHome is especially nice for the climate controls.

Do you have any details you could share on the Cruise N Comfort AC wiring (and the Maxxfan)? I reached out to them for details and got nowhere (they won't even provide a manual for their wifi thermostat so I have no idea what capabilities it has). Undermount AC at least publishes their wiring diagrams, but they don't offer a true 24 volt system.
See less See more
For the Espar side, Mike had mentioned folks looking to have remote switches & sensors for the heater have accomplished it using the analog bus.
Could you elaborate on this? What "analog bus" are you referring to?
I will be using a Rixen's system, and I have been assuming that I will end up sniffing the Espar CANbus. There seems to be nothing on the Net as of yet, at least that I could find.
2
Could you elaborate on this? What "analog bus" are you referring to?
I don't have enough info to be actionable, but here is what little I think I know.

The bottom coil of the harness in this picture is the analog bus that can be used with the earlier generation controllers. In the current generation heaters, that branch is unused, just protect the ends from shorting and tuck it away.
Wood Art Font Circle Jewellery




In the diagram below, c2 is the analog bus pictured above. Mike mentioned that the red & yellow wires on the analog bus is what folks were using to accomplish the remote control of the heater.

My caveat is that tons of info was going back & forth during the multi-hour troubleshooting session with lots of off-topic tangents like this one. Please don't take this as gospel.



Rectangle Slope Font Parallel Schematic
See less See more
  • Like
Reactions: 1
If someone wants to ship me a unit for non-destructive reverse engineering, I'd be happy to do it just for the challenge and bragging rights. I'll return the unit (your postage) undamaged or purchase/replace it in the rare event that I screw up.

I can almost guarantee that I'll be able to tell you how to hook it up and control it. Possibly multiple ways if they exist.

I figured out my Propex, but it is admittedly pretty darn simple. I'd love to see what's going on with the CANBUS on some of those units and add the capability into my own control system for future flexibility.
OK, I have been biting my lip. I completely understand that many consider it to be "cool" to be able to control everything from the phone or a single screen, but ...

What are the actual practical advantages over a more typical setup where the heater/AC have their own thermostat, the fan has an on/off switch and speed control, and the inverter comes with a battery monitor? Add tank level sensors if the tanks are hidden from view, and what else is there?

Just trying to understand why this consolidation of everything is considered an advantage. Doesn't it significantly increase the odds of a single failure shutting down many systems? What is gained?
  • Like
Reactions: 1
OK, I have been biting my lip. I completely understand that many consider it to be "cool" to be able to control everything from the phone or a single screen, but ...

What are the actual practical advantages over a more typical setup where the heater/AC have their own thermostat, the fan has an on/off switch and speed control, and the inverter comes with a battery monitor? Add tank level sensors if the tanks are hidden from view, and what else is there?

Just trying to understand why this consolidation of everything is considered an advantage. Doesn't it significantly increase the odds of a single failure shutting down many systems? What is gained?
What you’re missing is the ability to automate. If you put it all on one automation system then you can now have things happen automatically based on state changes. So if for some reason you want to turn off your AC and go ahead and switch to fan based on some rule like “if ambient outside temp is below 78F and battery capacity is below 40%” or whatever.

These are things that can happen while you’re sleeping or while you’re not even at the van.

I can see uses for this, but you’re not wrong that it’s also a potential failure point. Obviously folks engineering these systems have some level of trust that they can fix it in the field if necessary, especially if it’s a system you wrote from the ground up. I personally love the idea enough to follow it, but not quite enough to bother in my own van.

I would be willing to donate to a project to reverse engineer the Espar, though not because I want to automate it, just because I want to replace the incredibly annoying control unit it ships with. I pretty much hate how it works.

—Donnie
See less See more
  • Like
Reactions: 1
OK, I have been biting my lip. I completely understand that many consider it to be "cool" to be able to control everything from the phone, but ...

What are the actual practical advantages over a more typical setup where the heater/AC have their own thermostat, the fan has an on/off switch and speed control, and the inverter comes with a battery monitor? Add tank level sensors if the tanks are hidden from view, and what else is there?

Just trying to understand why this consolidation of everything is considered an advantage. Doesn't it significantly increase the odds of a single failure shutting down many systems? What is gained?
Advantage 1: Visibility
There are a lot of things that should be monitored, but generally aren't. Is your freezer cold enough? Are your undercarriage water tanks too cold? Are your shore power cord and TV antenna stowed before you drive away? All hatches closed? Is the temperature rise across your Espar as expected? Is everything set properly when you leave for a day hike?...

Advantage 2: Vigilance
Once you have all of the above available somewhere, who is going to watch it all? Did anybody notice that the battery isn't charging? That the waste tanks were getting full? That the A/C is cycling abnormally?.... Having automatic setpoints on such things is invaluable.

Advantage 3: Convenience
You settle into the driver's seat and put on your belt and then realize you left the ceiling fan open -- Can you fix it from your seat? Sitting down to watch TV -- set all those nice LED lights all over the van to an appropriate setting without scurrying around. etc...

Advantage 4: Automation
Set thermostat appropriately for bedtime, based on outside temperature and time of year. Define modes for "living", "sleeping", "away", "storage" and get them right every time. Power up/down subsystems as needed in order to conserver battery. Modify such behavior depending on battery level. Manage charging behavior depending on more than simple SOC. Automatically shut off inverter when it hasn't been used recently. Automatically shut down systems when faults detected,,,

Advantage 5: Consistency
Rather than learning a dozen random user interfaces for various systems, they can be presented to the user in a consistent, easy to learn manner.

Yes, I understand that you currently get by without any of this, and you are perfectly capable of doing most of it manually. But it is silly to argue that none of it has value. And, many traveling companions have no interest in understanding enough about, say, lithium battery charging to be prepared to know how to best manage it by hand.

Just trying to understand why this consolidation of everything is considered an advantage. Doesn't it significantly increase the odds of a single failure shutting down many systems? What is gained?
This is a legitimate point, and one that is often overlooked. But, the kind of systems being discussed here use distributed controls that eliminate single point failures. This is what projects like ESPhome are all about.
See less See more
  • Like
Reactions: 4
What you’re missing is the ability to automate ... if for some reason you want to turn off your AC and go ahead and switch to fan based on some rule like “if ambient outside temp is below 78F and battery capacity is below 40%” or whatever.
I understand that. It's the "or whatever" that so far I don't get. I have spent a lot of time living in my campers (usually about two months at a time) and I never wished I had this automation. The thinks I want automated are already automated (temperature control via thermostat, battery charge via charge control). If I want a light or fan or pump activated, I operate a switch.

I am trying to understand actual, practical advantages of having a system like this.
I understand that. It's the "or whatever" that so far I don't get. I have spent a lot of time living in my campers (usually about two months at a time) and I never wished I had this automation. The thinks I want automated are already automated (temperature control via thermostat, battery charge via charge control). If I want a light or fan or pump activated, I operate a switch.

I am trying to understand actual, practical advantages of having a system like this.
You are not alone.

It is fun to read the posts about automation. There are some very talented people here who have abilities that far exceed mine.

Each of us have a different idea about how to do a conversion. What is interesting is the range of ideas that appear.

I have no need for automating but that does not mean that it is not important to someone else. I do like my two dial microwave that automatically turns off after a set time.

Being a Luddite has its advantages. Just sold a 2017 Porsche and one of the reasons was all the automation. I prefer a car instead of a computer on wheels. I also prefer a conversion that is as simple as I can make it.

I also prefer a pocket watch instead of a cell phone. Not normal but we are all different. :)
  • Like
Reactions: 1
1 - 20 of 84 Posts
Top