Author Topic: "Intelligent" way finder-robot made in 45 minutes  (Read 10756 times)

0 Members and 1 Guest are viewing this topic.

Offline fritslTopic starter

  • Full Member
  • ***
  • Posts: 67
  • Helpful? 0
  • letsmakerobots.com
"Intelligent" way finder-robot made in 45 minutes
« on: April 01, 2008, 02:57:31 PM »
By using a standard board, old code slightly modified, tape, glue-gun and the likes, I managed to make quite a way finder in just 45 minutes:

http://video.google.com/videoplay?docid=-9011106691096348058

(sorry for the second half of the video, only robot in the first.)

I know webmaster hates me for linking like this, sorry, but if not someone will ask me for specs and code, and I wil have to write it anyway ;) It is here:

http://letsmakerobots.com/node/254

Thanks,

/ Fritsl
« Last Edit: April 11, 2008, 05:29:07 PM by fritsl »

Offline superchiku

  • Supreme Robot
  • *****
  • Posts: 952
  • Helpful? 5
  • cooll
Re: 45 minutes "intelligent" way finder-robot
« Reply #1 on: April 02, 2008, 01:25:25 PM »
nice one , GOod work!

i got one doubt well how do u make ur servo turn from left to right and then rght to left continuously

i mean how many pulses do u apply to the servo to get to a specific position??
JAYDEEP ...

IT AND ROBOTICS ENGINEER

"IN THE END IT DOESNT EVEN MATTER"

Offline fritslTopic starter

  • Full Member
  • ***
  • Posts: 67
  • Helpful? 0
  • letsmakerobots.com
Re: 45 minutes "intelligent" way finder-robot
« Reply #2 on: April 02, 2008, 11:56:37 PM »
I use Picaxe, it is much cheaper than BS (tha I assume you use?), faster.. and I just write

servo 1, 213

Then the Picaxe itself does the rest, keeps the servo stay where it should.

/ Fritsl

Offline superchiku

  • Supreme Robot
  • *****
  • Posts: 952
  • Helpful? 5
  • cooll
Re: 45 minutes "intelligent" way finder-robot
« Reply #3 on: April 03, 2008, 12:16:20 AM »
no i dont use picaxe or bs i use atmega16 so thats why i wanted to know
JAYDEEP ...

IT AND ROBOTICS ENGINEER

"IN THE END IT DOESNT EVEN MATTER"

Offline Ro-Bot-X

  • Contest Winner
  • Supreme Robot
  • ****
  • Posts: 1,431
  • Helpful? 25
  • Store: RoBotXDesigns.ca
    • Ro-Bot-X Designs
Re: 45 minutes "intelligent" way finder-robot
« Reply #4 on: April 03, 2008, 02:48:18 PM »
Yes, nice job! I love the ease of building and programming using PicAxe (or Stamp, or others...). A lot less headache than the more powerfull(!) and widely appreciated C. Hehe. I bet some people can't believe their eyes things can be so easy when then make them so difficult. And they call them "advanced programming". I really hate it. I should get back to Basic and have my robot done in half a day! I am also using AVR, but there is Bascom-Avr that works even easier than Arduino software doing the same advanced functions...
Check out the uBotino robot controller!

Offline ed1380

  • Supreme Robot
  • *****
  • Posts: 1,478
  • Helpful? 3
Re: 45 minutes "intelligent" way finder-robot
« Reply #5 on: April 03, 2008, 07:51:32 PM »
wow. all these bots are great. you should be promoted to expert roboticist
Problems making the $50 robot circuit board?
click here. http://www.societyofrobots.com/robotforum/index.php?topic=3292.msg25198#msg25198

Offline fritslTopic starter

  • Full Member
  • ***
  • Posts: 67
  • Helpful? 0
  • letsmakerobots.com
Re: 45 minutes "intelligent" way finder-robot
« Reply #6 on: April 04, 2008, 02:35:22 PM »
Thank you ed 1380 :)

Ro-Bot-X: I could not say it any better!

Offline Ro-Bot-X

  • Contest Winner
  • Supreme Robot
  • ****
  • Posts: 1,431
  • Helpful? 25
  • Store: RoBotXDesigns.ca
    • Ro-Bot-X Designs
Re: 45 minutes "intelligent" way finder-robot
« Reply #7 on: April 10, 2008, 06:28:02 AM »
For people interested to see the difference between Arduino software and Bascom-AVR compiler, take a look here:
http://www.rhombus-tek.com/BC4Arduino.html

Here is a quote from that site:
Quote
Six of the Arduino 'C' sample programs have been converted over to BASCOM and are available below. The resulting code is more compact, and when controlling I/O Pins runs faster than Arduino 'C'. Plus the absence of 'extra characters' makes it perfect for learning, but it is equally well suited to serious control applications.

BASCOM also offers integrated commands for LCDs Char/Graphic, I2C chips, 1WIRE chips, Keypads, RC5, RC6, software UARTs, SPI and much more. No searching for libraries and then trying to adapt them.

...

Side by side comparison of code will help the user see the differences. Of the 6 Arduino examples that have been converted, two are shown below -  all comments had to be removed for space reasons. 

The totals of bytes used over all 6 examples suggest that the BASCOM demo will allow the equivalent of 14,500 bytes of Arduino 'C' code.
 
Arduino Example: 'Blink'
int ledPin = 13;
void setup()
{
  pinMode(ledPin, OUTPUT);
}
 
void loop()
{
  digitalWrite(ledPin, HIGH);
  delay(1000);                 
  digitalWrite(ledPin, LOW);
  delay(1000);               
}
'1112 bytes
 
BASCOM Example: 'Blink'
$Include "DuinoLib.inc"
Config Pin13 = Output

Do
  Set Out13
  WaitmS 1000
  Reset Out13
  WaitmS 1000
Loop
'220 bytes

...

Some of the BASCOM Statements: 

Decision and structures
IF, THEN, ELSE, ELSEIF, END IF, DO, LOOP, WHILE, WEND, UNTIL, EXIT DO, EXIT WHILE, FOR, NEXT, TO, STEP, EXIT FOR, ON .. GOTO/GOSUB, SELECT, CASE.
Input and output
PRINT, INPUT, INKEY, PRINT, INPUTHEX, LCD, UPPERLINE, LOWERLINE,DISPLAY ON/OFF, CURSOR ON/OFF/BLINK/NOBLINK, HOME, LOCATE, SHIFTLCD LEFT/RIGHT, SHIFTCURSOR LEFT/RIGHT, CLS, DEFLCDCHAR, WAITKEY, INPUTBIN, PRINTBIN, OPEN, CLOSE, DEBOUNCE, SHIFTIN, SHIFTOUT, GETATKBD, SPC, SERIN, SEROUT

Numeric functions
AND, OR, XOR, INC, DEC, MOD, NOT, ABS, BCD, LOG, EXP, SQR, SIN,COS,TAN,ATN, ATN2, ASIN, ACOS, FIX, ROUND, MOD, SGN, POWER, RAD2DEG, DEG2RAD, LOG10, TANH, SINH, COSH.

I2C
I2CSTART, I2CSTOP, I2CWBYTE, I2CRBYTE, I2CSEND and I2CRECEIVE.

1WIRE
1WWRITE, 1WREAD, 1WRESET, 1WIRECOUNT, 1WSEARCHFIRST, 1WSEARCHNEXT.

SPI
SPIINIT, SPIIN, SPIOUT, SPIMOVE.

Interrupt programming
ON INT0/INT1/TIMER0/TIMER1/SERIAL, RETURN, ENABLE, DISABLE, COUNTERx, CAPTUREx, INTERRUPTS, CONFIG, START, LOAD.

Bit manipulation
SET, RESET, ROTATE, SHIFT, BITWAIT, TOGGLE.

Variables
DIM, BIT , BYTE , INTEGER , WORD, LONG, SINGLE, STRING , DEFBIT, DEFBYTE, DEFINT, DEFWORD.

Miscellaneous
REM, ' , SWAP, END, STOP, CONST, DELAY, WAIT, WAITMS, GOTO, GOSUB, POWERDOWN, IDLE, DECLARE, CALL, SUB, END SUB, MAKEDEC, MAKEBCD, INP,OUT, ALIAS, DIM , ERASE, DATA, READ, RESTORE, INCR, DECR, PEEK, POKE, CPEEK, FUNCTION, READMAGCARD, BIN2GREY, GREY2BIN, CRC8, CRC16, CHECKSUM.

Compiler directives
$INCLUDE, $BAUD and $CRYSTAL, $SERIALINPUT, $SERIALOUTPUT, $RAMSIZE, $RAMSTART, $DEFAULT XRAM, $ASM-$END ASM, $LCD, $EXTERNAL, $LIB.

String manipulation
STRING, SPACE, LEFT, RIGHT, MID, VAL, HEXVAL, LEN, STR, HEX, LTRIM, RTRIM, TRIM, LCASE, UCASE, FORMAT, FUSING, INSTR.

Besides the fact that I rendered my ATmega8 and ATmega168 invizible to Bascom and never got the bootloader to work with Arduino (I must be stupid at something...) I think wanting to learn C was a stepback for me. It seems that Arduino uses too much of the precious free memory and adds no real functionality (compared to Bascom) for any of the programs written for the robots described by Admin or the other members. I don't say that C isn't better. But it adds lots of frustration to robot building.

Just 5 days ago I have loaded a small 128bytes bootloader into a mega8 for use with Bascom for a friend. His works and my Arduino bootloader fails. The only way I can revive my 2 chips is high voltage programming. They still work with uisp that just loads the hex file (without verifying the signature byte), no matter if it is written in Bascom, Arduino or any other language that produces hex files.

Heh, I realy liked the idea of the Arduino software, too bad it didn't turn out to be what I was looking for.

This message is intended as an informal one. People might want to know that not all C flavours are good (fast, flexible and so on) and not all Basic flavours are bad (slow, limited and so on).
Check out the uBotino robot controller!

Offline ScorpIon

  • Full Member
  • ***
  • Posts: 52
  • Helpful? 0
  • Nobody said it was gonna be easy.
Re: 45 minutes "intelligent" way finder-robot
« Reply #8 on: April 10, 2008, 07:47:11 AM »
Great video, cool robot, love the music :P

What are you gonna add instead of a screwdriver? A nailgun that shoots bolts at people with red shirts?

Offline fritslTopic starter

  • Full Member
  • ***
  • Posts: 67
  • Helpful? 0
  • letsmakerobots.com
Re: 45 minutes "intelligent" way finder-robot
« Reply #9 on: April 10, 2008, 09:06:28 AM »
2 hands over the head, lifting stuff, making gestures and kicking stuff. Already made, but no time to finish code, film etc - soon ;)

Offline superchiku

  • Supreme Robot
  • *****
  • Posts: 952
  • Helpful? 5
  • cooll
Re: 45 minutes "intelligent" way finder-robot
« Reply #10 on: April 10, 2008, 10:27:35 AM »
thats a nice idea , just dont make it kick ur..... ahem!

i was expecting some kinda advice like how u lock on ur sonar on the target until it has been completely avoided, like use timers and stop ur servo there??
JAYDEEP ...

IT AND ROBOTICS ENGINEER

"IN THE END IT DOESNT EVEN MATTER"

Offline fritslTopic starter

  • Full Member
  • ***
  • Posts: 67
  • Helpful? 0
  • letsmakerobots.com
Re: 45 minutes "intelligent" way finder-robot
« Reply #11 on: April 11, 2008, 05:21:12 PM »
Sorry, please come again?

Are you asking about what is made (Step II, this video), or what you would like to see in step III, the one with the arms etc?

thanks

Offline superchiku

  • Supreme Robot
  • *****
  • Posts: 952
  • Helpful? 5
  • cooll
Re: "Intelligent" way finder-robot made in 45 minutes
« Reply #12 on: April 12, 2008, 02:02:23 AM »
no the way u lock on to the obstacle??
JAYDEEP ...

IT AND ROBOTICS ENGINEER

"IN THE END IT DOESNT EVEN MATTER"

Offline ScorpIon

  • Full Member
  • ***
  • Posts: 52
  • Helpful? 0
  • Nobody said it was gonna be easy.
Re: "Intelligent" way finder-robot made in 45 minutes
« Reply #13 on: April 12, 2008, 03:08:33 AM »
Uuh, just stop the servo rotating the sonar? When sonar no longer sees the obstacle it will return to sweep around.

Based on observations.

Offline fritslTopic starter

  • Full Member
  • ***
  • Posts: 67
  • Helpful? 0
  • letsmakerobots.com
Re: "Intelligent" way finder-robot made in 45 minutes
« Reply #14 on: April 12, 2008, 04:51:21 AM »
Ah.. ;D

Not stopping the serovo/head, but turning torso away from obstacle, while turning head towards obstacle, until head is turned to a degree that torso can drive forward without touching with the wheel. This gives the "locking-effect".

But this is just a part of the truth; It is several "layers" of decisions, influencing on each other and on how hard to turn (spin, slide, jerk-reverse). It was my first navigational system for my first robot:

http://www.societyofrobots.com/robotforum/index.php?topic=3284.0

You can download the complete code ready for implementing to your hardware, and I have made pseudo-code, illustration as well for this way of navigating.

Offline superchiku

  • Supreme Robot
  • *****
  • Posts: 952
  • Helpful? 5
  • cooll
Re: "Intelligent" way finder-robot made in 45 minutes
« Reply #15 on: April 12, 2008, 08:29:17 AM »
well the logic will be enough thanks for the help...
JAYDEEP ...

IT AND ROBOTICS ENGINEER

"IN THE END IT DOESNT EVEN MATTER"

Offline fritslTopic starter

  • Full Member
  • ***
  • Posts: 67
  • Helpful? 0
  • letsmakerobots.com
Re: "Intelligent" way finder-robot made in 45 minutes
« Reply #16 on: April 12, 2008, 09:58:51 AM »
No prob - just remember that it should also have the opposite; "be curious" when there is space, else you will not get anything but a paranoid bot, not going anywhere.

Offline superchiku

  • Supreme Robot
  • *****
  • Posts: 952
  • Helpful? 5
  • cooll
Re: "Intelligent" way finder-robot made in 45 minutes
« Reply #17 on: April 12, 2008, 01:17:29 PM »
will be will be  :D
JAYDEEP ...

IT AND ROBOTICS ENGINEER

"IN THE END IT DOESNT EVEN MATTER"

Offline Admin

  • Administrator
  • Supreme Robot
  • *****
  • Posts: 11,703
  • Helpful? 173
    • Society of Robots
Re: "Intelligent" way finder-robot made in 45 minutes
« Reply #18 on: April 20, 2008, 05:53:34 PM »
Nice job with the ultra-smooth control. Reminds me of my old Hypersquirrel robot. :)

Offline fritslTopic starter

  • Full Member
  • ***
  • Posts: 67
  • Helpful? 0
  • letsmakerobots.com
Re: "Intelligent" way finder-robot made in 45 minutes
« Reply #19 on: April 21, 2008, 01:52:10 AM »
Hyper? Can you post a link to it? What was it made in?

Seams every other controller or method out there has a hard time with servos. I use Picaxe, and it is just to write "servo 2, 150" to position, and it stays there..

Modified this post_________

OH - Found it via Google; Hyper Squirrel. The video is quite dark to put it mild ;) So it is hard to tell - but the robot seams to just "bounce" the wall, no? It does not exactly find passages, tell middle of dorways etc?

I like the idea of having 2 sensors.. perhaps - it is new thinking to me, may try it out to reduce scanning time..

/ Fritsl
« Last Edit: April 21, 2008, 02:23:45 AM by fritsl »

Offline fritslTopic starter

  • Full Member
  • ***
  • Posts: 67
  • Helpful? 0
  • letsmakerobots.com
Re: "Intelligent" way finder-robot made in 45 minutes
« Reply #20 on: April 21, 2008, 02:25:23 AM »
Hey - here is another using the same algorithm that I used. You can tell how the bot is actually finding the middle of passages, breaking out etc, which is why I call it "intelligent wayfinder":

http://letsmakerobots.com/node/474

/ fritsl

Offline Admin

  • Administrator
  • Supreme Robot
  • *****
  • Posts: 11,703
  • Helpful? 173
    • Society of Robots
Re: "Intelligent" way finder-robot made in 45 minutes
« Reply #21 on: April 26, 2008, 06:17:42 AM »
Quote
It does not exactly find passages, tell middle of dorways etc?
Well, actually it did, sorta. I didn't have the turn gains up high enough, but as it approaches a wall you can see it curving. It was years ago so I was still a noob back then . . .

My goal for that robot was to do mapping (for object avoidance) at really really high speeds. Try tripling your robot speed and see if it still intelligently avoids stuff :P

 


Get Your Ad Here