[chbot] Simple robot programming

Charles Manning cdhmanning at gmail.com
Tue Jun 30 23:53:39 BST 2009


No single robot programming environment can cut it for everyone.

If you just want something that does very elementary things, like
blink some lights when a switch is pressed, or a bump and turn robot,
then ladder logic or the Lego Mindstorms style drag and drop
programming can work well.

If you want to do anything more complex then you really need something
a bit more meaty. Picaxe can take you to the next level, but soon
reaches its limit.

If you want to go further than that: programming up reasonably complex
behaviour, navigation, etc, then you do better with C, Java etc.

For instance, programming a GPS-based guidance system would be hell in
ladder logic or Picaxe.

It is possible to make a fusion of different languages. For example, a
C program and ladder logic program can share some variables so that
ladder logic variables can then be processed in C then passed back to
ladder logic.

Morris: There are three parts to ladder logic programming:
1) The GUI engine where you draw the pictures. Sure that can be done
over a web interface, but probably needs a relatively capable web
server. Perhaps more than your WRT can handle.
2) Compiler: reduces the picture representation to executable byte
code. Can likely fit on the WRT.
3) Interpreter. Tiny and can definitely exist on the WRT (well it has to :-).

The web interface is perhaps where you want to end up, but I would
suggest that it is far easier to start off by doing the drawing GUI,
at least, on a host and sending down the byte codes.

On Tue, Jun 30, 2009 at 10:18 PM, jimmy allen<jimmy1248 at gmail.com> wrote:
> i know that is why i moved on from them
> by way are you a member on bright sparks because your name looks familiar
>
> On 6/30/09, timothy manning <tfhmanning at gmail.com> wrote:
>> Hi Jimmy
>>
>> The problem with Picaxes is it's very limited and not expandable.
>> It is also very expensive. If you want a BASIC lanuguage then use an
>> AVR and run BASCOM on it.
>> This way you can upgrade to C with out changing your controller board
>> and it's very cheap compared to a Picaxe.
>>
>> -Timothy
>>
>>
>>
>> On Tue, Jun 30, 2009 at 5:43 PM, jimmy allen<jimmy1248 at gmail.com> wrote:
>>> have any of you use picaxe system
>>> it is good for beginners as you can write up programs using flow
>>> charting or the basic language
>>> you can write up fairly complex projects
>>>
>>>
>>> On 6/30/09, Morris <skibear at gmail.com> wrote:
>>>> I love ladder logic and had been thinking about it!
>>>>
>>>> Ladder logic is functional programming (which will make Paul Davey
>>>> happy!).
>>>>
>>>> Ladder logic has an obvious DHTML web interface for it (that said I am
>>>> not volunteering to do that because I do Ajax web development for my
>>>> job :) but given how common it is I would hope there is something free
>>>> out there already. I personally am attempting to avoid requiring
>>>> anything installed on a PC, that way web-phones can be used for
>>>> development and for remote control, and also so there is no dependency
>>>> on having either Windows or Linux installed.
>>>>
>>>> Charles, I am very keen to hear what you find out - especially if it is
>>>> web based open-source (Python would be perfect, but PHP, Ruby, Lua, Perl
>>>> or Linux CGI apps can all be hosted on the wifi router web server -
>>>> probably even DOS apps in DOSBox).
>>>>
>>>> Simon - is that a volunteer I hear! ;)
>>>>
>>>> Cheers
>>>>
>>>> Morris.
>>>>
>>>> On Tue, 2009-06-30 at 10:22 +1200, Simon Knopp wrote:
>>>>
>>>>> That project looks interesting. I agree, ladder logic is a good way to
>>>>> get started with programming simple robots.
>>>>>
>>>>> What would really make a tool such as that powerful would be the
>>>>> ability to create functional blocks, either of ladder logic or code. A
>>>>> block of ladder logic would allow higher level commands like in
>>>>> Mindstorms---"turn 90º left" or "move forward for 1 second". A block
>>>>> of code (much like PLCs' structured text) could allow one to write a
>>>>> function in C (for example) and have it represented as a block within
>>>>> the ladder logic environment. These blocks could be created by anyone
>>>>> who knows the language and distributed easily to those that don't.
>>>>>
>>>>> I know I'm sort of just describing what PLCs can already do, but to my
>>>>> (relatively uninformed :-) mind it wouldn't be too difficult a feature
>>>>> to implement into a system like that you linked to and would make more
>>>>> powerful programming with ladder logic feasible and accessible to more
>>>>> people.
>>>>>
>>>>> Just my two cents worth.
>>>>> Simon.
>>>>>
>>>>>
>>>>> On 29/06/2009, at 9:55 PM, Charles Manning wrote:
>>>>>
>>>>> > Morris and I had a very interesting conversation about simplifying
>>>>> > robot programming.
>>>>> >
>>>>> > Many people are drawn to Mindstorms-like drag and drop programming.
>>>>> > This is indeed a simple way to do very simple programming (but is
>>>>> > hopeless for anything of reasonable complexity). These tools are also
>>>>> > no open source or free.
>>>>> >
>>>>> > Fortuitously I got into a discussion with Timothy about PLC "ladder
>>>>> > logic" programming. This could be a simple way to do very simple
>>>>> > programs. There are a few very interesting open source ladder logic
>>>>> > projects out there that compile a ladder and generate a "byte code"
>>>>> > which runs on a tiny interpreter. These can be simple enough to run on
>>>>> > a small AVR, moderate PIC, Linux box etc. Anything that can eat C.
>>>>> >
>>>>> > Ladder logic is a graphical representation of an electrical circuit
>>>>> > that operates on inputs and outputs
>>>>> > eg.
>>>>> >  |     IN1   IN2  OUT1  |
>>>>> > +-----[ ]---[ ]---( )------+
>>>>> > |                                |
>>>>> >
>>>>> > If IN1 is on and IN2 is on then turn on output 1.
>>>>> >
>>>>> > Better descriptions in http://en.wikipedia.org/wiki/Ladder_logic
>>>>> >
>>>>> > A ladder logic tool I'm going to look at more is at
>>>>> > http://www.cq.cx/ladder.pl
>>>>> >
>>>>> > --Charles
>>>>> >
>>>>> > _______________________________________________
>>>>> > Chchrobotics mailing list Chchrobotics at lists.linuxnut.co.nz
>>>>> > http://lists.ourshack.com/mailman/listinfo/chchrobotics
>>>>> > web site: http://kiwibots.org
>>>>> > When replying, please edit your Subject line to reflect new content.
>>>>>
>>>>>
>>>>> _______________________________________________
>>>>> Chchrobotics mailing list Chchrobotics at lists.linuxnut.co.nz
>>>>> http://lists.ourshack.com/mailman/listinfo/chchrobotics
>>>>> web site: http://kiwibots.org
>>>>> When replying, please edit your Subject line to reflect new content.
>>>>
>>>
>>> _______________________________________________
>>> Chchrobotics mailing list Chchrobotics at lists.linuxnut.co.nz
>>> http://lists.ourshack.com/mailman/listinfo/chchrobotics
>>> web site: http://kiwibots.org
>>> When replying, please edit your Subject line to reflect new content.
>>>
>>
>> _______________________________________________
>> Chchrobotics mailing list Chchrobotics at lists.linuxnut.co.nz
>> http://lists.ourshack.com/mailman/listinfo/chchrobotics
>> web site: http://kiwibots.org
>> When replying, please edit your Subject line to reflect new content.
>>
>
> _______________________________________________
> Chchrobotics mailing list Chchrobotics at lists.linuxnut.co.nz
> http://lists.ourshack.com/mailman/listinfo/chchrobotics
> web site: http://kiwibots.org
> When replying, please edit your Subject line to reflect new content.
>



More information about the Chchrobotics mailing list