My Start Here Bot

Well its been a while, but i finally finished the base. Right now everythings held down with double sided foam tape, but i plan on cable tying the motors down. Thanks to oddbot's tutorial i made a nice mounting bracket, cept the lighter discoloerd the shapelock a bit. I got all the wiring sorted out, thanks to isotope i was able to get my ping running. Right now i just have to order some header pins, and maybe the wheels (if anyone has a link to nice ones that fit onto the geared motors in the "start here" bot that'd be great) but i was waiting a bit because im going to order an arduino at the same time. I just need some help with the code, ill be attaching it to this post hopefully. Due to the lack of a servo, the entire body of the bot will be turning left and right to scan once it detects an object. Vid will be up soon. Im still unsure if i got the code for the ping down.

 

Last minute edit:

i added the servo and screwed the ping bracket onto the servo horn

 

 


This is a companion discussion topic for the original entry at https://community.robotshop.com/robots/show/my-start-here-bot-1

Fan-damn-tastic

Alright here we go… The Parralax sonar unit is confusing as hell. There is the Paralax Ping))) unit which is a 3 pin and a SRF005 unit which is a 4 pin. We had a huge hub-bub around here with myself arguing about the fact that the paralax won’t work with a picaxe. It will. I don’t know how to do it. However, a lot of people want to show me up so someone will get back to you on it. I dunno, a search of ping and picaxe might bring it up. It’s somewhere, I just don’t know where.

To do:

Start a basic file called “Basic” moves… Some thing like this:

main:

gosub ??? 'instead of the ??? you will insert one of the below names…

fwd:

high whatever

low whatever

high whatever

low whatever

return

backup:

high whatever

low whatever

high whatever

low whatever

return

rightspin:

high whatever

low whatever

high whatever

low whatever

return

leftspin:

high whatever

low whatever

high whatever

low whatever

return

There are a total of 4 pins that go to the motor controller --you have already found 2. Find the other two and then find the combination of highs and lows to go, fwd,back,R and L. --Oh, add a low,low,low,low for a total-stop too. Substitute the “whatevers” with those pin numbers. Changing the ???'s with any of the names “leftspin” “rightspin” etc. will zip the program down to that subroutine ignoring the rest. This way you can write out all the robot moves you will need and be able to test each one… one-by-one. After you get all these goiing the way they should, Save the file and label it “Final Basic Moves” or something like that. This way, when you are writing other code, you will always have this to go back to and you can cut and paste. Later, you will do the same with the sonar “Final -Read sonar and debug” and all the other little chunks of code. This will make it much easier as you progress. Also, when you are writing code, use an apostrophy! Anything after a ’ the code ignores, so write a lot of notes to yourself -You will be amazed at what you will figure out today and forget tom. morning.

–There is your start, kid.

 

 

 

 

Seems pretty straighforward.
Seems pretty straighforward. I’m going to do what you suggested and try and write a basic code to run through all of the basic wheel functions, and try the de-bug on that. And coding the Ping sounds like nightmare, ill probably save that for a week off i get. Thanks again for all the help chris.

If you use the search
If you use the search function in this site and type picaxe 28x1 starter kit it should bring up fritsl’s most excellent pictorial post on that board with great color coded locations for everything on it. Just wished I’d got that board as I bought the rkeducation one with built in 5 amp transistors for output. Common collector and NO pin jumper to the chip so I bootleg the pins and No docs on it from the vendor don’t help either. Good luck and for wheels my first bot used vienna sausage cans for wheels. Ya use what ya got folks…I need to post that one as it is fun as heck…

lol sounds great and i would
lol sounds great and i would love to see it, i was hoping to somehow use the wheels from the old mindstorms set. thanks for the tip, ill take another look at that post

Found it… Ping…
https://www.robotshop.com/letsmakerobots/node/1276

thanks chris
thanks chris

ya wat he said

start of program should be like:

 

main:

(whatever ur variables are)

high 4 //blah blah blah, u know, the main execution

return

 

 

ps: i no this cuz i used 2 have a BS2 before i fried it w/ my stupid LEDs

I sorta remember a little

I sorta remember a little surplus shop on Canal street near Mulberry maybe. And possibly another on/near Canal.

Used to be Robot Village on Broadway but they appear online only now.

If all else fails, find some dead computer to gut parts from.

commented code is always better

Your code would be much more readable if you had written comments.

Use comments as inline documentation : intended vs observed behaviour and pinouts.

For example.

I spent
a good hour last night writing a begginers guide to coding for you, it went through most of the basics of coding from oporators to variables. Unfortunatly i was too tired to finish it last night and planned to do it now. However i didnt save it and my missus either turned it off or a windows update installed, eitehr wya i lost it when my computer restarted. I will make time to do it again for you tonight,

2nd power supply

You should see the jumper on your board

2ndSource_1.jpg

Remove it

2ndSource_2.jpg

And hook up your second power supply to pins. Could look like this.

2ndSource_3.jpg

Check the Picaxe manual for correct polarity. You can actually see it on last image below the project board. :)

alright thanks mate, cant
alright thanks mate, cant wait to see it

awesome, so after its hooked
awesome, so after its hooked up like you showed the second power supply is automatically diverted to motors/servos?

Yes,
All outputs are powered by 2nd power supply if you use it.

Great start
I am working on the same project, I wish I had slowed down and played with the code a bit as I built mine. I think the way you are going you will end up with a great bot :slight_smile:

thanks man, i saw your bot
thanks man, i saw your bot and it looked really clean and well built. I just glanced through the manuals and tried a couple of the projects in it.

Noticed it the video and
Noticed it the video and stills there is NO capacitors on those motors. You really need to put a .01 or so disc cap on each one to keep the noise from arcing brushes getting into the works and gumming it all up electrically speaking of course.You got a good start keep it going.

Parts
Wrong address maybe. Just refound 269 Electronics at 269 Canal street, between Lafayette and Broadway. Mentioned in the MakeNYC links.

oh awesome, thats pretty
oh awesome, thats pretty close to me, also a guy at radioshack told me there was some surplus electronics store near fulton street which ill have to check out.