Hi all,
I'd be really interested to hear what kinds of projects people might be cooking up with the remote sensor functionality in 1.3...I've been using it to introduce additional sensor functionality for use in end-user projects - for example, I have a small Processing/Java applet that provides Scratch with x/y co-ordinates for trackable objects moved in front of a camera (eg, moving a paper cut-out of a sprite in front of a camera results in the same sprite moving inside of Scratch).
Obviously fairly complicated to program, but for an end-user they have instant access via the sensor blocks to some new 'virtual' sensors to play with. I know there's a potential to use this functionality to interface with devices such as motors, accelerometers, etc - what kinds of things are people using remote sensors for?
Offline
lxt:
That sounds extremely cool. I've been working a bit with interfacing with an Arduino board using Processing:
http://sites.google.com/site/chalkmarrowfiles/
Offline
lxt wrote:
Hi all,
I'd be really interested to hear what kinds of projects people might be cooking up with the remote sensor functionality in 1.3...I've been using it to introduce additional sensor functionality for use in end-user projects - for example, I have a small Processing/Java applet that provides Scratch with x/y co-ordinates for trackable objects moved in front of a camera (eg, moving a paper cut-out of a sprite in front of a camera results in the same sprite moving inside of Scratch).
Obviously fairly complicated to program, but for an end-user they have instant access via the sensor blocks to some new 'virtual' sensors to play with. I know there's a potential to use this functionality to interface with devices such as motors, accelerometers, etc - what kinds of things are people using remote sensors for?
That sounds amazing! What sort of vision system are you using to allow the camera to locate the sprite cutout?
Offline
There are a couple of ways it could be done - mine is fairly simple, the back of each cut-out is tagged with a special symbol that is trackable via a GPL piece of software called reacTIVision (originally designed for multi-touch surfaces) in conjunction with a Processing library.
With that, I only had to write a fairly simple Processing sketch to translate the data I'm passed to something more Scratch-friendly and pass them on (although there's some more complex code in there for performance, detecting 'true' movement from errors, distinguishing tags, etc)
So, cutouts can be placed on a flat (transparent) surface and moved around with a camera beneath them, or alternatively mounted onto sticks and used as puppets, with the camera behind.
Like I said, there are other ways of doing it, but I think using visual markers is by far the cheapest (ie, free) - especially given that I can pass processing not just x/y co-ordinates, but angle of rotation as well. There were other methods I had thought of (eg, using IR LEDs on the cut-outs to be picked up by the camera), but I'm pretty happy with what I've got so far.
The great benefit is that someone can come along and - as long as the Processing applet is running - just drag and drop sensor blocks and use the 'virtual' sensors to quickly get motion tracking up and running. I could definitely see some applications, such as putting on 'virtual' puppet shows in class, etc. for which this could be beneficial.
Offline
lxt wrote:
There are a couple of ways it could be done - mine is fairly simple, the back of each cut-out is tagged with a special symbol that is trackable via a GPL piece of software called reacTIVision (originally designed for multi-touch surfaces) in conjunction with a Processing library.
With that, I only had to write a fairly simple Processing sketch to translate the data I'm passed to something more Scratch-friendly and pass them on (although there's some more complex code in there for performance, detecting 'true' movement from errors, distinguishing tags, etc)
So, cutouts can be placed on a flat (transparent) surface and moved around with a camera beneath them, or alternatively mounted onto sticks and used as puppets, with the camera behind.
Like I said, there are other ways of doing it, but I think using visual markers is by far the cheapest (ie, free) - especially given that I can pass processing not just x/y co-ordinates, but angle of rotation as well. There were other methods I had thought of (eg, using IR LEDs on the cut-outs to be picked up by the camera), but I'm pretty happy with what I've got so far.
The great benefit is that someone can come along and - as long as the Processing applet is running - just drag and drop sensor blocks and use the 'virtual' sensors to quickly get motion tracking up and running. I could definitely see some applications, such as putting on 'virtual' puppet shows in class, etc. for which this could be beneficial.
Do you have the source code for the Processing program available, and would you be willing to share it with people on this forum? Sounds like it would be fun to play with.
Offline
As a simple example of how to take information from a website and send it to Scratch, I uploaded a project that allows Gobo to read news headlines from RSS feeds:
http://scratchconnections.wik.is/Projects
Offline
chalkmarrow wrote:
As a simple example of how to take information from a website and send it to Scratch, I uploaded a project that allows Gobo to read news headlines from RSS feeds:
http://scratchconnections.wik.is/Projects
That looks like a fun application!
I've also posted my System Clock application to the same area. It has a Python script that sends PC system clock information to Scratch every second. The scratch project provided moves the hands of a clock and chimes on the quarter hour and tolls out the hours. It could be a good start on other time based projects, such as calendars, data recorders, whatever.
Offline
Paddle2See wrote:
chalkmarrow wrote:
As a simple example of how to take information from a website and send it to Scratch, I uploaded a project that allows Gobo to read news headlines from RSS feeds:
http://scratchconnections.wik.is/ProjectsThat looks like a fun application!
I've also posted my System Clock application to the same area. It has a Python script that sends PC system clock information to Scratch every second. The scratch project provided moves the hands of a clock and chimes on the quarter hour and tolls out the hours. It could be a good start on other time based projects, such as calendars, data recorders, whatever.
I really like the clock. Very useful scripts in there that can be re-used by a lot of people.
Offline