Shop OBEX P1 Docs P2 Docs Learn Events
Is a Propeller Fast Enough? — Parallax Forums

Is a Propeller Fast Enough?

Kirk FraserKirk Fraser Posts: 364
edited 2011-07-17 16:04 in Robotics
Can a Propeller be programmed to do these old 2009 demonstrations?
http://youtu.be/-KxjVlaLBmk
The sensors are said to operate at 1KHz, the result is performed in 100ms.

Can a Propeller operate fast enough to fuse sensors and actions at 20KHz?
An order of magnitude improvement would be impressive.

Comments

  • GeorgeCollinsGeorgeCollins Posts: 132
    edited 2011-07-17 08:48
    In the literal sense a propeller can sense and update at the speeds you are talking about, but almost certainly it can’t do the same thing in the same way as you are seeing in this video. A propeller can sample a very simple sensor at 1khz and update the position of servos or motors in less than 100ms. So you could, for example sample a touch sensor at 1khz and update a servo position in 100ms with ease.

    However, in this video it looks like they are using cameras to update the position of appendages. There is no way a propeller can accept image data quickly and in general trying to do much image processing on a propeller is hopeless because you quickly hit memory bottlenecks. Also, I would guess they are using some form of inverse kinematics with a lot of floating point operations. A lot of floating point operations is not something that prop is necessarily fast at. And when you have a lot of matrices for joints you quickly get into the kind of memory problems that you have with image processing.

    A propeller can easily update the position of servos a hundred times a second or faster. Really at that speed it doesn’t matter because a motor can only move so many degrees a second and at a hundred updates a second you are changing the position faster then the motor can keep up or by smaller amounts then the accuracy of the motor can distinguish.

    I have made a number of robots that sample an ultrasound sensors, compasses and/or motion sensors 20-100 times a second and update servos about fifty times a second. A prop excels at doing that.
  • Kirk FraserKirk Fraser Posts: 364
    edited 2011-07-17 12:05
    It sounds like the Propeller can sense at 1KHz and respond in a tenth of a second, but it can't process camera data or much other complex I/O that fast. Thank you, George.

    So a propeller with a reliable network could perform the low level I/O communicating with a PC and its gflop GPU for the higher level camera analysis and command decisions. How much would a Propeller network or the USB connection slow things down?

    In theory, a Propeller should be able to do the sense-respond part of the job 10 times faster if it were operating at 100MHz, thus actuating in 1/100th of a second or 10ms if sensor and motion devices can be found which work that fast. Anybody have ideas on faster sensors and actuators?
  • stevebzzzzzstevebzzzzz Posts: 38
    edited 2011-07-17 13:35
    :lol:

    I'm laughing as I watch this video. I'm new using the BS2, but I used to program in assembly years back. The Motorola 6802. I don't remember the clock speed of that thing, I just remember it being fast as heck!

    I can almost count in my head just as fast as the BS2 :tongue:

    I know the BS2 is entry level, but I couldn't help myself from laughing imagining the BS2 doing what that robot thing was doing!

    I don't know the specs of the propeller, but I'm still laughing lol! Amazing props to whoever built that robot, but I imagine there's a lot of hardware circuitry doing most of the signal processing.

    Just My Humble Opinion....,I'm still trying to figure out the servo in the BS2 kit...

    Cheers....
  • GeorgeCollinsGeorgeCollins Posts: 132
    edited 2011-07-17 13:59
    A small but powerful computer-- small enough to fit into a little robot-- could look at the images from a web cam (or a Kinect, even better) and send back the coordinates of a ball at say ten or twenty times per second via USB. A prop chip could take that information and calculate how to position servos or motors at that pace. That would work and probably be a reasonable solution to a problem where you wanted to try and get a mobile a robot to try and catch something.

    When you talk about the speed of a sensor and "fast sensors" there are two things to consider. First, how fast does the sensor actually take a reliable reading? Second, how fast can the sensor communicate with a processor?

    A Ping sensor takes time for its sonar signal to bounce back. A lot of color sensors take time to settle down to get a reliable reading. Neither of these sensors are probably good at 1,000 readings per second.

    The second thing is how fast can the sensor communicate the data? If your sensor is just a switch you can sample it 10,000 times a second by just polling a pin. A camera has to upload an image, that is always going to take some time and you are never going to be able to upload 10,000 high def images in a second with today's technology.

    Steve: A prop is really different then a stamp in terms of performance. Like the 6502 you don't have to program it through an interpreter so it is much faster. A prop is many times faster then a 6502 in general.
  • stevebzzzzzstevebzzzzz Posts: 38
    edited 2011-07-17 14:22
    I wish I could have stayed and continued my education from back in 84 when I was programming the 6802. I'm having to relearn lots of stuff now, and things have changed quite dramatically! Are there any "Controllers" based on the Intel chips? Am I wrong in assuming that if you had a controller based on the Intel i9 (or whatever the latest generation is) operating at 3GHZ it would be super fast? Do people even program in Assembly for this chip?

    Cheers....
  • Kirk FraserKirk Fraser Posts: 364
    edited 2011-07-17 14:50
    Once I saw a TV clip of a military camera they were using at 400 frames per second to get images of a bullet in flight so they could trace it back to its source so they'd know where random fire was coming from in a city. 400 FPS looked adequate but minimal for that job. How fast are other high speed cameras like the one used on Mythbusters?

    In my view it's best to have an idea of the state of the art as well as possibilities beyond it for even if you can't afford to play at that level, you never know when you may be able to realize a piece of the vision. That piece may be what helps you realize another piece and eventually bring the market to your door.

    It looks like a Propeller is the piece for low level actuator control. A PC/104 or similarly small PC may do for an on board computer. The Nokia may be the cell phone to choose for remote communication because of the Qt version of C++ which can create applications for both PC's (including Win & Lin) and their phone.

    Any other ideas on what an ideal robot would be made of? The PC had to go through years of iterative progress to get what we have now. Robots are mostly still at people's hobby stage like the Altair 8800 (first PC) with exceptions, for example the auto industry. To move robots along without the huge customer count Microsoft and Intel enjoyed we need to develop smarter while still in the starving inventor or hobby stage.

    The brick wall to avoid is given in the Bible - don't do anything that could be used as an abomination of desolation or image that speaks in the Temple in Israel (like they have in Japan). I suggest a GPS to detect location and self destruct if abducted to Jerusalem.

    Short of that, a robot economy could help people do lots of things, recover from disasters, and eventually retire all people so we can work on better things, like doing Jesus' miracles and more as He promised.
  • stevebzzzzzstevebzzzzz Posts: 38
    edited 2011-07-17 14:57
    Like the movie Surrogates with Bruce Willis. Most of the world population was robots, being controlled by their "sleeping at home" human controllers....
  • Kirk FraserKirk Fraser Posts: 364
    edited 2011-07-17 15:29
    Sadly today many people are programmed by the media. I saw statistics telling most people make culture decisions based on movies. Try to think outside the boxoffice. I'm sure you can develop a dream for a more hopeful future than anything the media shows. www.wantdesk.com may be a start.

    Anyway I'm still curious about the performance of a Propeller network. Say it's 10 Props with two or four pins controlled by a cog, in any arrangement, straight line, N-Cube, whatever. I know it would take time to clear a pin to send data. All Props trying to send at once could slow the network down to a tenth of a single Prop capacity. Is that still adequate for reporting sensor data and actuating position requests from the PC?

    A hierarchical network with one Prop in charge would reduce the competition to communicate and it would reduce the traffic to answering requests. Could that operate better than a decentralized network?
  • kwinnkwinn Posts: 8,697
    edited 2011-07-17 16:04
    Anyway I'm still curious about the performance of a Propeller network. Say it's 10 Props with two or four pins controlled by a cog, in any arrangement, straight line, N-Cube, whatever. I know it would take time to clear a pin to send data. All Props trying to send at once could slow the network down to a tenth of a single Prop capacity. Is that still adequate for reporting sensor data and actuating position requests from the PC?

    A hierarchical network with one Prop in charge would reduce the competition to communicate and it would reduce the traffic to answering requests. Could that operate better than a decentralized network?

    The optimum network topology depends on the application. CSMA/CD is not a good choice for connecting a large number of processors to a bus, or for a large number of small packets. Hierarchical, star, bus, ring, token passing, and others all have applications where they are good choices, but no single architecture devised to date is optimum (or even close) for all applications.
Sign In or Register to comment.