Documentation of my way to autosteer

I tried to add machine control to my setup, I thought I could just use a relay to act as a switch to trigger the three point hitch. Problem is that my tractor has a potentiometer that does the switching, I dont know how to deal with that. Anyone an idea?

Which tractor is it? Usually the potentiometer is there to set the working level but a three state switch selects the work position/neutral/raised position.

Its a Claas Ares 816RZ. I also thought it should be a three state switch, but to me it looks like a potentiometer…
DSC_1014

In the manual that switch is called “5-position mode switch (transport, high position, stop, working position ans dropping)”. If I hold down the switch to dropping, I do measure a fourth value for resistance, so it has at least four positions.

The best solution would be a tile for I2c. It just takes someone smart to write code for it. I have a similar switching method in my MF5455, there is a switch but it changes the resistance to several levels and it cannot be turned into an on / off switch.
It is possible to switch between the set of resistors

Did you measure the resistance figures with the switch connector detached?

You could do like baraki suggests or you could just use a relay to alternate between raise an lowered positions (if that is what you need). In either case I’m afraid you would need to build a master switch that swaps between the tractor switch and AOG control. A bit complicated to operate if manual override is needed in emergency or other scenarios.

It could be a sort of fault detection, if the resistances vary from the preset the control unit realizes that something is not working and can provide an error code.

Did you measure the potentiometer with the 3 pin plug disconnected from PCB?

Disconnecting changes the resistance, but it still looks like a potentiometer, a 5K.

I could just use a relay to switch between the original switch and the digital potentiometer. To detect when I use the original switch some kind of encoder might be useful. That way the arduino would automatically do the switching. So to use machine control, the original switch has to be at neutral position, when its moved away machine control gets deactivated and has to be enabled manually in AgOpenGPS again.

The Arduino could measure the voltage on the potentiometer (green wire) and the switch to manual control could be detected. In automatic mode it is enough to increase / decrease the resistance for lifting / lowering added in series with the green cable. It should work.

So you mean I set the manual switch to low position and kind of add the needed resistance to get it to raise? And when the voltage changes by manual switching, the arduino knows that because it did nothing to change voltage? When I connect the digital potentiometer in series, it needs to have a resistance of 0 ohms when not powered to make everything work normal without automatic control.

Just like that!
To achieve 0 ohms for manual control it is possible to put an NC contact relay in parallel with the digital potentiometer.
edit
Now I think it can be simplified even more because the ECU probably measures only voltage anyway, so the digital potentiometer is enough if it adds V to the green cable, adding a diode would allow you to still measure the voltage on the tractor potentiometer.

An additional series resistor might introduce issues. Usually the ECU monitors sensors for shorts and broken circuits and insists on a fixed resistance from each node towards ground. Even a simple on/off switch needs a specific resistance from the signal node toward ground when closed and another one when open. Unexpected values cause a fault state.

Some of the ideas above could perhaps be modified to take this into account.

1 Like

What I think I will do is use a relay to switch between original switch and the voltage generated by the digital potentiometer. That way I can always measure the voltage of the original switch to determine if I want to use the original switch manually. I will simply use a second arduino that uses the output of the arduino (with the machine control code on it) that normally triggers relays and convert that to a specific voltage for each state which goes into the tractor ECU. Ill order some parts and report the results

Got the parts and tried to test my setup, which worked pretty good on my bench. Problem is that the ground of the arduino and ground of the potentiometer, so the ECU, are not the same, I measure around 2.5V from the ECU ground to arduino ground and battery ground. The arduino is connected to the 5V output of the PCB V2. That way the output voltage of the original switch obviously isnt correct and the three point hitch doesnt work. Anyone know how to solve that?

Untitled Sketch_Steckplatine

You need to use a common ground point for all the components.

1 Like

2.5 V is too much to be a “simple” ground potential difference between different ground points.

EDIT: deleted some text.

Unfortunately I have no diagram or anything like that. There somewhere is a connection between the circuits, since I can measure around 9.5V between positive of the potentiometer and battery ground. I wanted to use the built in ADC, as far as I know there is no way of using it in differential mode. Maybe I could just try to use a voltage divider and then read the input with the arduino? Then set the digital potentiometer powered by the ECU to needed output? Problem is I didnt find a digital potentiometer which is capable of more than 5.5V, Id need 7V or more.

EDIT: just deleted the comment.

I do have the full PCB, but I try to use a single arduino just to convert the relay outputs from the machine control arduino to something useable for the tractor

Now I made another mistake. I thought I read WAS somewhere but the discussion is still about the switch (rear lift?). Please ignore my latest messages. I wonder if I should delete them to avoid confusion.