The Combine Forum banner

21 - 40 of 4139 Posts

·
Registered
Joined
·
3,681 Posts
At present I can get serial input into Wine (and it tests using a terminal emulator like putty), but for whatever reason the AgOpenGPS.exe is not able to enumerate the serial ports and thus I can not select it. To keep things simple I've assigned my device to com1. Also none of the settings such as sections, tractor, etc, seem to save for me. Some strange wine interaction perhaps. I'll do some more digging.

EDIT: So the first problem is a problem with Wine and it's mono subsystem. I created a short program to enumerate serial ports in C# and it works great on Linux with mono, but in wine, it lists nothing. Once I figure out how to get it to save settings I'm sure I can work around this issue by just hard coding the serial port in the config file or registry.

The settings issue is in Mono I think (which wine uses). I'm trying to install the official dotnet runtime in wine, which I've done before recently, but for some reason having issues tonight because I'm on a 64-bit system and using a hybrid 32-bit/64-bit installation of wine. What a mess! :)
 

·
Registered
Joined
·
291 Posts
All this talk about programming in c# inspired me to sign up for a Microsoft course on the subject. Whether I ever get that far but I used to play around with Basic in school and liked doing so. My autistic son is computer savvy and thought what a great bonding experience if him and I could learn the language and make a few games or such. As well, I can understand what you guys are talking about. Besides if enough of us can open source a bunch of ag software and maybe we can tailor stuff to better suit our needs and not have to sell our first born for overpriced stuff.
 

·
Registered
Joined
·
3,681 Posts
Sounds good, Snapper22. Another language that might be appealing is Python. In some ways it's quicker to get going on than C#, since there's no compiler you have to run each time you make a change, and it has an interactive mode for playing with small snippets of code. Google for Python tutorial if you are interesting in that. There are lots of good tutorials out there.
 

·
Registered
Joined
·
560 Posts
Besides if enough of us can open source a bunch of ag software and maybe we can tailor stuff to better suit our needs and not have to sell our first born for overpriced stuff.
Without offending anybody I guess this is cool but what is the ultimate goal? Trimble, JD, and name your company charge fees for unlock codes which sucks because I believe they are excessive. Ipads and tablets are less then $1000 US whereas JD and trimble displays are $5000 + before unlocks. I get the money savings, but If I already have this overpriced stuff I probably wouldn't switch to this kind of setup. ( Not that the BrianTee would care anyway.)

Is the idea for updating older or customized equipment with new technology for fraction of the price? Or maybe a guy is running new equipment valued at $200k-800k and wants to save a little and stick it to the man. I'll pick on JD... If you buy a JD tractor with EH valve and pull an airseeder/planter with section control, blockage, etc. it would be wicked to have an Android tablet run all of it as you could save an easy $15k doing so... When this can control and monitor a Bourgault Aircart then sign me up as I despise their system.

I have a hard time thinking outside the box, but if the goal is to make this open software better then the existing setups out there and not just for money savings then I will question no more as I do not have enough creativity to make them better other then to streamline their menus and help functions.

ISOBUS is like the United Nations. Sounds good in theory, but nobody plays by the same rules and it ends up being a cluster*&&^
 

·
Registered
Joined
·
291 Posts
Sounds good, Snapper22. Another language that might be appealing is Python. In some ways it's quicker to get going on than C#, since there's no compiler you have to run each time you make a change, and it has an interactive mode for playing with small snippets of code. Google for Python tutorial if you are interesting in that. There are lots of good tutorials out there.
Thank you I will try that.
 

·
Registered
Joined
·
3,681 Posts
Without offending anybody I guess this is cool but what is the ultimate goal? Trimble, JD, and name your company charge fees for unlock codes which sucks because I believe they are excessive. Ipads and tablets are less then $1000 US whereas JD and trimble displays are $5000 + before unlocks. I get the money savings, but If I already have this overpriced stuff I probably wouldn't switch to this kind of setup. ( Not that the BrianTee would care anyway.)
If you have to ask... it's not for you. :) I think the goal here is to scratch an itch, fill a personal need, really. Learn how to do cool things. It's fun and very educational. I'm not sure that competition with Trimble, Deere, etc, is really that relevant to this endeavor, though if something became good enough to actually compete, that would be a good thing. I suppose at some point freedom is a part of it; we don't want all the world's knowledge locked up in proprietary systems.

Personally, Brian's project is actually fairly immediately useful to me. I have two outfits I would love to add automatic sectional control to, and in its present state it's almost ready to step in and do this. I already have a SmartBoom on one sprayer, but I payed a lot of money for that and it's now obsolete, unsupported hardware. For a fraction of the price of the Smartboom unit, with Brian's software I can set up a sectional controller for my other sprayer that includes a nice graphics display. So yes this is very useful to some of us.

Do I need a GPS guidance system for my tractor, no not really; GreenStar works well. But I would like an autosteer for my swather. Currently the quote is about $10k. If we could get basic guidance going for a couple of grand that's a win for me.

This isn't the first time you or someone else has questioned the motivation for doing this sort of work. And that always surprises me. I guess I come from a completely different background (academia). Different strokes for different folks. Fortunately farming offers a lot of different kinds of hobbies.
 

·
Registered
Joined
·
3,681 Posts
Brian, I got things working better in Wine. I had to ditch my 64-bit wine and go with straight 32-bit, and installed the official dotnet45 runtime. I had to do a registry tweak to get my pass-through serial ports to enumerate in windows, but they do now. Unfortunately, my fake serial device doesn't work (Wine/win32 says it's not a valid serial port) with AgOpenGPS, though I can get it to work with other software like putty... But the real serial port works. I'll try it on my laptop in a tractor when I get a chance.

I'm not sure if this is quite what I think it is, but there's a C# library and some software for Arduino to control the Arduino from inside of C#via the serial link. Arduino Playground - Csharp .
 

·
Registered
Joined
·
5,783 Posts
Discussion Starter #28
Without offending anybody I guess this is cool but what is the ultimate goal?
As my yoga instructor says.... live in the moment. Namaste.:biggrin:

If you find an application for it, great. If you learn something, great. If it inspires a new idea, please share it. Beyond that, we are just having fun learning.
 

·
Registered
Joined
·
5,783 Posts
Discussion Starter #29
Brian, I got things working better in Wine. I had to ditch my 64-bit wine and go with straight 32-bit, and installed the official dotnet45 runtime. I had to do a registry tweak to get my pass-through serial ports to enumerate in windows, but they do now. Unfortunately, my fake serial device doesn't work (Wine/win32 says it's not a valid serial port) with AgOpenGPS, though I can get it to work with other software like putty... But the real serial port works. I'll try it on my laptop in a tractor when I get a chance.

I'm not sure if this is quite what I think it is, but there's a C# library and some software for Arduino to control the Arduino from inside of C#via the serial link. Arduino Playground - Csharp .
Yes I have, its the next step. While there are lots of ways to do this, the auto connect is really nice. Darn serial ports, it can be very frustrating. Always a problem, especially to go Bluetooth SPP.

The other challenge is tablets generally only have a one usb. Either everything goes thru the arduino including the nmea or a powered hub that may or may not work. The other problem is many tablets won't charge while using USB. The road is bumpy yet.
 

·
Registered
Joined
·
5,783 Posts
Discussion Starter #30
All this talk about programming in c# inspired me to sign up for a Microsoft course on the subject. Whether I ever get that far but I used to play around with Basic in school and liked doing so. My autistic son is computer savvy and thought what a great bonding experience if him and I could learn the language and make a few games or such. As well, I can understand what you guys are talking about. Besides if enough of us can open source a bunch of ag software and maybe we can tailor stuff to better suit our needs and not have to sell our first born for overpriced stuff.
If i could make a suggestion, it would be get to know the Arduino. You will learn structured programming and you can make so many neat projects with your son. The development environment is absolutely free and there are a million billion projects on line, with amazing tutorials, all the source code and so very much help in huge forums. Once you learn one language, and Arduino is specifically designed to give you success in learning, move on to other languages.

Do a search on "arduino" and let the adventure begin.
 

·
Registered
Joined
·
291 Posts
If i could make a suggestion, it would be get to know the Arduino. You will learn structured programming and you can make so many neat projects with your son. The development environment is absolutely free and there are a million billion projects on line, with amazing tutorials, all the source code and so very much help in huge forums. Once you learn one language, and Arduino is specifically designed to give you success in learning, move on to other languages.

Do a search on "arduino" and let the adventure begin.
Thank you.
 

·
Registered
Joined
·
3,681 Posts
Arduino is neat because you are programming things that interact with the real world. Buttons, lights, sensors, motors. It's extremely rewarding. And it gives a good sense of the underlying technology behind our modern farm machines. After you spend some time with an Arduinoo board doing a project, you'll understand what your tractor computer means when it says a sensor is having a problem and is shorted to the high (or low) source. Arduino does require you to learn some basic electronic principles like ohms law, but the amount of circuitry required to do some pretty advanced things is minimal. It's a forgiving system but if you do make a mistake, well it's a good thing you can buy arduinos for under $20 a pop! I have a drawer full of burned out boards from when I was learning and was trying to interface with some 12V controls (linear actuator). Forgot which side of my breadboard was the 5v side and which was the 12V side. Poof, magic smoke[1] released.

[1] It's a well-known fact that computers and electronic devices run on magic smoke. We know this because if you ever let the smoke out of something, it will not work any longer.
 

·
Premium Member
Joined
·
551 Posts
Without offending anybody I guess this is cool but what is the ultimate goal?
I dunno what Brian's goal(s) are and besides he's already answered but what I do know is that crowds are in and open source can be as good or better than proprietary. The real plus for open source is that it is developed and updated by people who actually use it. That means you don't see useless updates that hide features which you use regularly. You also don't tend to see a bunch of "fluff" - stuff that makes the software look pretty but doesn't add any functionality.
 

·
Registered
Joined
·
76 Posts
This looks really good Brian. Thanks for sharing. It's a good reminder that I should shake the rust off my hardware/software skills and get back up to speed on this stuff. I will definitely be looking at your source code in the near future. If I have any questions or insight I will let you know.

As for the question why, here's my thoughts. There are tons of posts on this forum from people who have made mods to their combines or other equipment. This is really no different. Just people using what they know to make things work better.
 

·
Registered
Joined
·
76 Posts
[1] It's a well-known fact that computers and electronic devices run on magic smoke. We know this because if you ever let the smoke out of something, it will not work any longer.
I tried explaining this to my wife and daughter recently, and all I got was blank stares. It seems they are hopeless.
 

·
Registered
Joined
·
3,681 Posts
Brian, a quick thought on something you might want to implement eventually:

As well as a master on switch, switches for each section to either turn them off, force them on, or auto. (make sense?) Software switches are fine, though having hardware switches via arduino made possible would good eventually. Turning off a section would be reflected in the coverage map of course. I find while spraying I sometimes need to do that.

I had another thought but forgot it for now... hope I can remember it later.
 

·
Registered
Joined
·
318 Posts
WOW...for a "farmer" to do something like this is amazing. I'm in the process of getting an android tablet (probably Samsung) and I'm definitely going to give it a go. If I go back through my university text books I'm sure I could add something somehow but actually writing code could be a bit of a stretch.

The more I think about it, a control loop for a Boomspray rate control would not be that difficult, it's just when you start switching sections on and off that you start throwing a bit of a spanner in the works.

Keep up the good work. If you want any feedback or suggestions dont be afraid to ask but I'm not a whole lot of use at coding.
 

·
Registered
Joined
·
4,423 Posts
Somethi g like this awesome just for slug pelleting with four wheeler or broadcasting seed etc.

Excuse my ignorance but to hook in an external gps...i take it that it goes in usb port...then this app does the set up and controlling of that external device...

If i wanted a on off switch external can that be done or must use tablet screen?

Ant...
 

·
Registered
Joined
·
5,783 Posts
Discussion Starter #39
Somethi g like this awesome just for slug pelleting with switchesfour wheeler or broadcasting seed etc.

Excuse my ignorance but to hook in an external gps...i take it that it goes in usb port...then this app does the set up and controlling of that external device...

If i wanted a on off switch external can that be done or must use tablet screen?

Ant...
The software needs to see an nmea0183 stream coming from a GPS antenna/receiver via a serial port to the tablet. Almost every unit has that output. A USB to RS232 cable adaptor is all that is required. About 20$. Set both to speak the same speed with at minimum an RMC sentence.

https://www.amazon.ca/Plugable-Adapter-Prolific-PL2303HX-Chipset/dp/B00425S1H8

For this software to control anything it needs another port to control something like an arduino to either read manual switches or control booms to turn them on off. Yet to happen, but is the easy part of this project.

Perhaps I should write up an NMEA and serial port tutorial.

This software is in alpha development. Should make a lot of progress this winter. Also, making sure it runs in both Linux and windows. Android, not sure yet on Crossover and Wine/Mono development there, but even that looks promising.
 

·
Registered
Joined
·
3,681 Posts
The more I think about it, a control loop for a Boomspray rate control would not be that difficult, it's just when you start switching sections on and off that you start throwing a bit of a spanner in the works.
Yes a basic rate controller would be a fun thing to develop. When you think about it, there's not much to a sprayer. It's mainly just plumbing, electronic valves, and rate controller. The principle by which the rate controller works is a technique called "proportional/integral/differential control", also called PID. PID is something that most of us do in our brains without thinking. For example, your brain does it when you're driving a car, steering, or accelerating to a certain speed and maintaining that speed with your foot.

It's easy to implement in code, but very hard to tune! I spent many weeks trying to make rate controller work with a servo on a small 1/2" butterfly valve work. I almost got it working.

There are ways of dealing with sections coming on and off. When a section turns off, the computer could right away shut the valve a certain amount, then let the PID loop seek to the new equilibrium position. Or just let the PID loop find it by itself. On my old flexicoil, when I stop a section, my rate does jump up quite a bit for a couple of seconds while the controller adjusts.
 
21 - 40 of 4139 Posts
Top