Showing posts with label Raven. Show all posts
Showing posts with label Raven. Show all posts

Wednesday, 6 April 2016

Raven SmartBoom Part 3

Well the SmartBoom unit is now installed in the tractor, connected to John Deere's GPS over the serial cable, and plugged into the Flexi-coil switch box using the circuitry I designed and spoke about previously. In dry run tests it appears to work! The system has one weakness and that is that, as far as I know, it does not compensate for the way the sprayer tracks behind the tractor as it turns. I believe SmartBoom assumes the booms are perpendicular to the tractor's direction of travel. For most things I think that will work okay. For spring herbicide we can always manually override it from time to time as the turning wedges get tighter as the we get towards the outside edges of the circle. For fungicide and insecticide it's not quite as critical and I'd rather concentrate on not hitting the bee tents! If it does turn out to be too much of a problem, a computer with 2 serial ports could probably calculate the tracking path and adjust the reported position sent to SmartBoom. I'm looking into this.

Homemade Harness and Plugs

Rather than pay $500 for a SmartBoom wiring harness that I could chop up, and since I couldn't find the necessary plug anywhere on the internet, I ended up machining my own end cover and making my own plugs. Since I did not want to modify the board in any way, I chose not to solder any wires to the board. Instead I made up little plugs with male 2mm pitch pin strips that plugged into the appropriate pins on the female pin plugs that I referred to earlier. Serial is 3 pins on one connector, and the sections come from 4 pins on another connector. I chose not to mess with the master switch at this time, so I didn't bring those wires out of the chassis. I'm just using the Enter button on the front to toggle SmartBoom on or off.

For the serial port I used an RJ-45 jack, wired to Cisco's serial standard, though only using the Gnd, TX, and RX pins:

For the section control signals, I used a standard 4-pin Mic plug. I put a female plug on the SmartBoom, and another female plug on the switch unit, and use a cable with two male ends to connect them, though I could have wired the cable permanently on the SmartBoom end of things. I chose not to since I wasn't sure what length of cable I wanted as I plan to use SmartBoom on other outfits in other tractors doing things like spreading edge with the Valmar.

Tying it all Together

Here's a pic of the inside of the switch unit. This is my spare switch unit and when I get the replacement toggle switch I need, I'll wire it all up and post pictures of that here. For now you can see the mic plug and the little tiny circuit board wrapped in a nice electrical tape blanket. The colored wires will attach to switches 1,2,3, and 4, and the black wire will go to ground.

Inside the tractor, a 4-conductor cable attaches from the back of the SmartBoom to the Switching unit:

As you can see, it's working. Here it's driving the sections. Even though the switches are down, the red lights are on, showing that the section is operating. The main on/off switch still works so I can easily shut down the sections if I need to quickly stop things. Here's a picture where the sprayer is overlapping and is only running two sections:

Pretty exciting! In a few days we'll try it with foam markers and water and see if we can get it tuned right.

Sunday, 21 February 2016

Raven SmartBoom Part 2B

Solid State Interface

Rather than use Relays which are prone to mechanical failure and which generate voltage spikes down the wires coming from the SmartBoom (and though the SmartBoom is robust enough to deal with it), it occurred to me that MOSFET or BJT transistors could be used to convert the 12V signalling logic to the switching logic used by the Flexicoil switch box.

The reason to use MOSFETs instead of traditional BJT transistors is that MOSFETs can switch on voltage, 12V easily, whereas BJTs switch on current. Either way would work of course. With BJT transistors, a resistor would limit the current into the transistor. Theoretically no resistor would be needed with a MOSFET. Though in either case, a resistor would need to tie the gate or base to ground (though I have a hunch the SmartBoom driver chips already do that), to keep the transistor off when the voltage goes away, such as when SmartBoom not connected to the switch unit at all.

Here's a schematic for using N-type MOSFETs. BJTs would be similar, though perhaps the resistor values would differ:

I have plenty of transistors on hand; I don't think I have any FETs. I'll run some simulations in 123d-circuits and then decide. I can order FETs easily and quickly online.

Update

Looks like normal BJT transistors work fine with similar resistor values to the ones I would have used with FETs. With a 100k resistor to pull the Base to ground, and a 10k resistor on the input signal (limiting current to 1.4ma) to the base, it should work. In simulation on 123d-circuits, current flow even at signal voltages as high as 30V are very low. And the current that flows through the internal pull-up resistor inside the switch box input line is very small. So FETs are probably overkill and besides I don't have any on hand. I don't know how much current from the input line to ground is required for the processor to see a low logic level; depending on the transistor gain I might have to use a lower value resistor on the 12V input lines. That'd be one benefit to the FETs--they switch on voltage so the resistor value matters a lot less. Since the input line to the microprocessor is probably tied to a base of a transistor or the gate of FET internally, I doubt much current, if any, is required to change the logic level. So I'll try it as I've described.

Here's a picture of my little circuit board with NPN transistors and some resistors. The input wires (12V signals) come in on the light colored wires, and the solid color wires connect to the signal side of the section switches. When 12V is applied to the input wire, the corresponding solid wire is pulled to ground through the transistor:

This little prototype board works out pretty well. The two rails down the center are ground (black wire). The transistor emitter is tied to ground as well, with the base pulled to ground with 100k, and the 12 signal attached to the base also through a 10k resistor. The collector of the transistor (middle wire) is the output to the switch.

Further Update

The circuit works! I can apply 12V to any of my four input lines and it pulls the signal low just like flipping the switch does.

Friday, 19 February 2016

Raven SmartBoom Part 2

Just a quick progress report on making the Raven SmartBoom work with our old New Holland SF216 sprayer. After figuring out how the SmartBoom signals work, the next step was to interface with the old controller our sprayer uses. I figured the easiest way would be to tie into the section control switch box.

After opening the switch box it because clear that whatever voltages the switches were using, it wasn't 12V. The switch box itself is a bank of switches tied to a microcontroller. This microcontroller communicates with the master sprayer controller over some sort of RS485 bus. I don't know what protocol it uses, but I imagine it's some master and multiple slaves system (maybe modbus?) as you can attach more than one switch box to the controller and other devices also, including other automatic section control systems.

The ideal, non-invasive thing to do would be to use an arduino to interface between the 12V signals coming from the SmartBoom and talk directly to the main controller over this bus, much like the Flexi-coil native section control system does. However the simpler thing to do would be to use a bank of relays to act in parallel with the switches. So that's what I implemented.

Using Relays

The toggle switches are all single-pole double-throw (three conductors), but the off side of the switch isn't connected to anything. The switches switch digital logic inputs on the microprocessor. A resistor holds each line to 5 volts (high). When the switch is thrown to the "on" position, it shorts this signal to ground. This makes it very easy to interface with. Here's a simple diagram that shows how relays can bridge between the 12V signal and the pull-down signals that go to the switches:

The fact that each switch shorts the section signal to ground makes the wiring of the relays very simple. All the grounds from every coil are tied together, and also the common part of the normally-open contacts on the relay itself. These are tied to the main ground coming into the box through the normal wiring harness. The normally-open contact can wire directly to the on side of the toggle switch. This means we need only bring 4 12V signals in from SmartBoom (we only have 4 sections on the sprayer; more additional wires could drive additional relays for more), and only four wires need to connect to the circuit board itself. Here's a picture of the circuit board and the relay bundled up underneath with the four signal wires ready to attach (note the broken and missing switch).

Normally it's a good idea to have a diode to absorb the current generated when the relay is switched off and its coil discharges. In this case I have no protection because the driver circuits in the SmartBoom are already protected and designed to drive solenoids and other forms of relays. Besides a very robust driver chip, each signal line is protected in the SmartBoom by a beefy Transient Voltage Suppression diode, or TVS IC. And since the other side of the relay is merely connecting to ground, we don't need to do anything further to protect the circuit on the switch box side of things.

So I'm just about ready to put all the pieces together, except that while drilling the hole in the side of the switch box the drill press gave everything a good spin and unfortunately the main toggle switch broke. So I am waiting for a replacement toggle switch which I will solder onto the circuit board in place of the broken one. Even when SmartBoom is operating, the main toggle switch is active and can be used to shut off the booms.

Wednesday, 10 February 2016

Adding GPS-driven Automatic Section Control to the Sprayer

Recently we were considering buying a second sprayer to have, partly as a spare, and partly to ease the burden of moving between crops in terms of rinse out.  Also with two different varieties of valuable hybrid seed canola this year, I liked the idea of having one sprayer for each variety so it would be easier and safer when we have to go back and forth between the two kinds of canola.  So while looking for a second sprayer I wondered what the feasibility would be of switching rate controllers to something we could install such that two different brands of sprayer could be compatible with the same in-tractor setup.  So I started researching what Raven had available.  Turns out it the cost of an upgrade would be very expensive.  Also we found a second sprayer that was identical to the current one so our existing controller could be used.

Raven SmartBoom

However, while researching I discovered an old, obsolete product from Raven called SmartBoom which is a fairly standalone solution for doing automatic section control:

From what I could tell, all it needed was a RS232 GPS input signal, which I already get off of our StarFire receivers, and it provides a 12V signal for each section to turn it on and off.  The 12V signal can provide up to 2 amps as well, so it can directly drive something like a magnetic clutch.  I was intrigued by this unit because it is simple and it should be able to, with a bit wiring, drive our existing sprayer controller's boom segment signals.  After a quick phone call to our local Raven rep in which he assured me that indeed this would not work the way I was thinking and I needed a full Raven system from stem to stern (I think he misunderstood what I was asking about) , I placed an order online for a steal of a deal for the SmartBoom.

I now have the SmartBoom and I've tested it out and it does indeed work like I want it to.  Unfortunately I could find no information on the pinouts from this thing and Raven wants $500 for a basic cable that is nothing but a big plug and bunch of pigtails to tie into your existing sprayer console. So by trial and error I figured out what the pins on the control output do and thought I'd share it here

SmartBoom Control Plug Pinout

Here's a diagram of the control plug on the SmartBoom:

The pins are labeled according to what they do. S means signal, Gnd is ground, MS is master switch, and the 3v and 12v pins are live with that voltage.  The numbers in parenthesis refer to a connector grid on the main board inside.  The plug itself is soldered to a daughterboard which interfaces with the mainboard using a standard  2mm pitch pin grid that's 3 by 7 pins.  The reason I mention this is because Raven wants $500 for their shortest cable that attaches to this plug.  I've been unable to locate a mating plug anywhere on the internet (if you can find me an IP67 circular plug (24 mm across) with 20 contacts, please let me know!), so I intend to solder my own wires directly to the board, bypassing the plug entirely, and will solder onto the ends of the pins in this grid where they stick through the board.


What the pins do

I'm not sure what the 12v pins are for, but the 3v pin and the MS pin form a master switch toggle.  When they are shorted together SmartBoom is in automatic mode, controlling sections as it desires.  When not shorted, SmartBoom sends no signals, allowing the normal section switches to work on the cab controller box.

The pins labeled S1, S2, S3 and so forth refer to the section control signal pins.  In Sprayer mode, when section 1 is active, S1 will be 12V.  When the section is off, the pin will be 0 volts.

So it's pretty simple, really.  All I need to do is run my own cable from the toggle switches into this box to the appropriate pins.  I'll show how I do this in another post.  Also the form factor of this box is really awkward, as far as mounting it where I can interact with the screen on it.  However only 5 wires drive the screen (it's driven entirely over a serial connection actually), so it's easy to make a cable that let's me place the screen anywhere I want. I plant to make a little box for the screen and run a cable down to the main unit which I'll probably place on the floor or against the side of the tractor's console.

So in the next blog post I'll talk more about how I will do that and probably document one or two other things about the circuit board.