Showing posts with label scratch. Show all posts
Showing posts with label scratch. Show all posts

Sunday 22 November 2015

It is a good time to play with robots

In the previous blog posts for this 'series' "It is a good time...." 

  • Post 1 looked at the hardware unpinning some of this positive rise in robots;
  • Post 2 looked at social robots;
  • Post 3 looked at a collection of small robots;

This post continues with small robot idea a bit more, looking at some of the other robots I have been fortunate to be able to play with. The opinions are from a personal point of view of playing with them, but comments are very welcome.

Kbots

The kilobots (http://www.k-team.com/mobile-robotics-products/kilobot)were designed to be relatively low-cost devices specifically designed for work on swarm/collective intelligence experiments. Developed at Harvard University as a scalable system to program groups of robots (now into the thousands) (http://www.eecs.harvard.edu/ssr/projects/progSA/kilobot.html).



Individually these are quite simple units, they move by vibration. The real advantage, in my opinion, of the system though is you can program lots of them in one go - scalability is therefore not that difficult.

The video below is from a colleague's work who used these during his MSc work on collective intelligence. To read more on this go to: http://robotsandphysicalcomputing.blogspot.co.uk/2015/07/narinders-swarm-robots.html





Scratch Robot Arm


It is not physical but CBiS Education have release a free robot arm simulator for Scratch. 

Downloadable from their site here - it includes a Scratch project, guidance on Scratch along with an exercises in using the robot arm simulation and an exercise with teacher's guidance. 

CBiS produce a physical version of this, details are available at  http://www.cbinfosystems.com/cardboard2code_module3.aspx




What I like about this is, apart from being free, is it is Scratch-based and it does simulate physical problems such as the need to co ordinate multiple parts of the arm often to achieve a task.


LEGO
Where do I start with these? LEGO have done a great deal to get a lot of people interested in, and provided a route into robotics. Whether though the 1980 - 1990s with the Technics range or when they released their Mindstorms (I can see another post coming on here).

My interest has been focused for the last ten years or so on their use in teaching problem-solving and Java Programming to undergraduates (read more here). The combination of either the earlier RCX or NXT ranges with the incredible LeJOS (http://www.lejos.org/) provides an accessible and easy (I think easy some times) way to link robots and undergraduate programming in Java.

I will expand on these a little more in a post of dedicated to LEGO .


Junkbots

Another shameless plug, Junkbots, was a project that started close eight years ago concerned with linking computing, engineering and environmental science in activities for use in schools. The core was to use and look at waste and how could we combined waste materials and robotics to either build a 'bot' out of junk or used in combination with robotics (initially based around LEGO) to clear small junk piles (a few light materials - nuts, bolts). To read more on this project go to http://junkbots.blogspot.com/ .

The area that quickly became the focus was the building 'bots' out of junk (session plan: http://junkbots.blogspot.co.uk/2015/08/junkbot-session-overview.html). This evolved into the building one of these but controlled via a raspberry Pi. This is the idea discussed below.

The card chosen to control the motors was the 4Tronix PiRoCon card. It fits straight onto the Pi through the GPIO - no extra cables needed. ScratchGPIO has it as an addon so it makes programming it even easier (see http://cymplecy.wordpress.com/2013/10/31/pirocon-from-4tronix/). It is quite easy plug the board directly on to the GPIO connector of the Raspberry Pi (4tronix provide some advice in section 15 of http://4tronix.co.uk/blog/?p=22 on mounting the board). The only other changes I needed to make because I wasn't powering the motors through the DC input I had to change the jumper settings next to Vin Connector (see http://4tronix.co.uk/blog/?p=41 for layout) to reflect this.

Now for the fun bit getting the whole thing to draw (see Figure 1 and the video at the end)!

The junkbot itself is made up of a drinks can, three supports ( LEGO was used here but it equally could be straws, sticks), a pen/pencil, and a  motor and broken propeller combination to create an unbalanced motor.

With the Raspberry Pi off, the the motor's wires are connected to the controller card at the connections for MotorA and the battery is also connected. Turn the Pi on and run ScratchGPIO5plus.


Figure 2
Figure 3





Figure 4















The first task is to make the variables AddOn (which will be used to tell the program we are using the PiRoCon card) and MotorA for the motor (see Figure 3).

In Figure 4 the program can be seen, essentially the left and right key spin the junkbot clockwise or anticlockwise by setting the Motor to either +ve or -ve values from 0 to 100. The space bar is used to stop the motor.

As it moves because one of the supports is a pen it draws. See the video below to watch it draw a squiggly line - control is still a challenge.

 
The bot was developed by Hayden Tetley and Scott Turner. Hayden's time was paid  for through the Nuffield Research Placements  Scheme (http://www.nuffieldfoundation.org/nuffield-research-placements).

Related Link

 




In the next post in the series I want to look at the software a bit more.




All opinions in this blog are the Author's and should not in any way be seen as reflecting the views of any organisation the Author has any association with.

Sunday 23 August 2015

When is a bug not buggy - CodeBug

When it is a Codebug - a board with 5x5 LED matrix and 4 connectors that can be either inputs or outputs. 





Programming is through a Blockly interface (as above). Code can be tested using the simulator on the left, before downloading to the CodeBug. The site contains a excellent video showing all the steps (see http://www.codebug.co.uk/gettingstarted/ ).





Codebug, Experimenter Kit CODEBUG-EXPKIT at the moment is usually programmed on-line. There is though a Scratch version in development by  Cymplecy (SimpleSi) http://simplesi.net/scratchcodebug-beta-testing/ that is an potential option for off-line programming. It is currently at the Beta testing stage but is good fun to play with.


What is nice about Codebug and, in fact, most of the Physical Computing device coming out that the moment is the developing community. There is a lot of sharing of projects, ideas and solutions to problems being provide to others through the site (and via Twitter)

I like the Codebug it is a small, relatively inexpensive device (or will be when it comes on the market- most of the ones out there at the moment are in the hands of those who contributed to the Kickstarter funding). The site (http://www.codebug.co.uk/) is full of useful links, examples and ideas.


All opinions in this blog are the Author's and should not in any way be seen as reflecting the views of any organisation the Author has any association with.

Thursday 23 July 2015

Scratch Robot Arm

It is not physical but CBiS Education have release a free robot arm simulator for Scratch. 









Downloadable from their site http://www.cbinfosystems.com/cardboard2code_module2.aspx - it includes a Scratch project, guidance on Scratch along with an exercises in using the robot arm simulation and an exercise with teacher's guidance.

Left my son with it, asked him if he could make it do something if a new sprite is added and the gripper touched it (similar to the exercise in the notes). He went on to produce a sprite that when it is touched by the gripper, went on to change colour a few times. I could see this being potentially used in Coding Clubs within schools.





CBiS produce a physical version of this, details are available at  http://www.cbinfosystems.com/cardboard2code_module3.aspx




All opinions in this blog are the Author's and should not in any way be seen as reflecting the views of any organisation the Author has any association with.

Sunday 19 July 2015

Raspberry Pi Controlled robot from junk


In previous posts I start looked at using ScratchGPIO to control a junkbot - more about junkbots can be found at:http://junkbots.blogspot.com

Previous Posts:
 (http://junkbots.blogspot.com/2014/08/junkbot-pi-1-scratchgpio.html) and showed a Pi controlled junkbot briefly in action (http://junkbots.blogspot.co.uk/2014/08/junkbot-raspberry-pi-2-raspberry-pi.html).

In this post I aim to discuss
- Choice of motor controller card
- Provide an example of a drawing junkbot controlled through Scratch and Raspberrry Pi


Choice of interface/Controller card
The card chosen was the 4Tronix PiRoCon card  (http://4tronix.co.uk/store/index.php?rt=product/product&product_id=182). Selected for four reasons
- Price is reasonable (in my opinion).
- Fits straight onto the Pi through the GPIO - no extra cables needed.
- ScratchGPIO has it as an addon so it makes programming it even easier (see http://cymplecy.wordpress.com/2013/10/31/pirocon-from-4tronix/).
- Others are using it for robot projects.

Use it is quite easy plug the board directly on to the GPIO connector of the Raspberry Pi (4tronix provide some advice in section 15 of http://4tronix.co.uk/blog/?p=22 on mounting the board). The only other changes I needed to make because I wasn't powering the motors through the DC input I had to change the jumper settings next to Vin Connector (see http://4tronix.co.uk/blog/?p=41 for layout) to reflect this.



Example
Now for the fun bit get the whole thing to draw (see Figure 1 and the video at the end)!

The junkbot itself is made up of a drinks can, three supports (we used LEGO here but it equally could be straws, sticks), a pen/pencil, and a  motor and broken propeller combination to create an unbalanced motor.

With the Raspberry Pi off, the the motor's wires are connected to the controller card at the connections for MotorA and the battery is also connected. Turn the Pi on and run ScratchGPIO5plus.


Figure 2
Figure 3





Figure 4















The first task is to make the variables AddOn (which will be used to tell the program we are using the PiRoCon card) and MotorA for the motor (see Figure 3).

In Figure 4 the program can be seen, essentially the left and right key spin the junkbot clockwise or anticlockwise by setting the Motor to either +ve or -ve values from 0 to 100. The space bar is used to stop the motor.

As it moves because one of the supports is a pen it draws. See the video below to watch it draw a squiggly line - control is still a challenge.

 
The bot was developed by Hayden Tetley and Scott Turner. Hayden's time was paid  for through the Nuffield Research Placements  Scheme (http://www.nuffieldfoundation.org/nuffield-research-placements).

Related Link

 




If you would like to know more about the Junkbots project contact scott.turner@northampton.ac.uk. The views and opinions is the authors and should not be taken as representing the views of any organisation the author is associated with.



All opinions in this blog are the Author's and should not in any way be seen as reflecting the views of any organisation the Author has any association with.

Top posts on this blog in March 2024

The Top 10 viewed post on this blog in March 2024. Covering areas such as small robots, augmented reality, Scratch programming, robots. Micr...