How to go about reading real time data over USB to a PC /MAC?

Hello!

I am brand new to Arduino, but am excited for the possibility. I have not even touched it yet but am planning my first project.

I have never messed with Arduino or similar things before so this is all new to me, but I do have a computer science degree and a few years of programming expreiencce beyond that, so I don't think software would be a problem if I am able to look up stuff.

Anyway here is what I plan on doing.

I want a laser and sensor to act as a tripwire so I can be notified when someone enters or leaves my room. The laser part seems easy enough but all the tutorials just connect it to a simple counter.

I was originally looking at a wifi or enthernet shield but they are expensive and I don't want to spend a lot.

So is there a way I can just get the data over USB? I assume there is but I don't really know a way to go about this. And then whenever the even is triggered software I write on the computer will send me an email or something.

Any suggestions? Is this a dumb plan?
Thank you!

Simple project.
If you can count the laser beam breaks, you can do a simple
Serial.print( "alarm" ); // send some text in ASCII
or
Serial.write( alarm ); // send a number
instead that goes out to the PC and the PC can then do whatever.

I can't help on the PC side, I've only used the Serial Monitor in the IDE.

Are you married to the laser part? It's unnecessary and potentially someone could get blinded for life.

Suppose you get notice on the net? What you do then? Set up a hidden DVR and record the intruder.

An html module costs less than $10 if you shop around. There's a direct relation between board size and product cost that does not favor lightly populated shields. Look around for sport DVR's on eBay.

On the PC side have a look at processing.org. That is the PC language (a Java variant) that Arduino was made to match. They code similarly but there's some differences.

You can probably do the PC side with Perl, Python, Java, or C#. Also it used to be possible right from Windoze console (command.com), might still.

CrossRoads:
Simple project.
If you can count the laser beam breaks, you can do a simple
Serial.print( "alarm" ); // send some text in ASCII
or
Serial.write( alarm ); // send a number
instead that goes out to the PC and the PC can then do whatever.

I can't help on the PC side, I've only used the Serial Monitor in the IDE.

Hey thanks, should be able to get me started at least.

GoForSmoke:
Are you married to the laser part? It's unnecessary and potentially someone could get blinded for life.

Suppose you get notice on the net? What you do then? Set up a hidden DVR and record the intruder.

An html module costs less than $10 if you shop around. There's a direct relation between board size and product cost that does not favor lightly populated shields. Look around for sport DVR's on eBay.

On the PC side have a look at processing.org. That is the PC language (a Java variant) that Arduino was made to match. They code similarly but there's some differences.

You can probably do the PC side with Perl, Python, Java, or C#. Also it used to be possible right from Windoze console (command.com), might still.

No it doesn't have to be a laser. Was thinking infrared though or something. Like how a garage door opener safety device works.

What exactly is an html module? Can't find any arduino module called that? or do you mean ethernet shield? Perhaps I'm looking in the wrong places but looks like those are $40+.

PC side I was planning on using C# but open to any programming language. I'll look into processing.org Looks interesting.

As for DVR, maybe in the future, but right now this is more of a curiosity, not full one security.

I don't actually have my Arduino yet, just my raspberry pi and my dekstop.

Thanks!

This will get you on the internet cheaply, mates to Arduino via SPI interface


We created a simple time server with one. Needed enough SRAM that a '1284P chip was needed (16K SRAM), '328P (2K SRAM) wouldn't cut it.

Set up your IR detector so it has a very small field of view, like at the back of a tube with a flat black inside. Point it at an IR led and you have a beam tripwire. If the IR beams that go down that tube are blocked (for some real interval), it's tripped. You could arrange multiple trips on 1 IR source, buy small parts in 10's or more and you get better piece price.

CrossRoads:
We created a simple time server with one. Needed enough SRAM that a '1284P chip was needed (16K SRAM), '328P (2K SRAM) wouldn't cut it.

A lot of text buffering and processing? Other buffers including library?

You can use a free terminal programme like RealTerm, and send the message to that simply with

serial.print("tralala");

and RealTerm will will record the event to file and timestamp it as well.

About as easy and cheap as you can get.

He wants it to send a message through internet.

With the Arduino driving an Ethernet module, you only need a router.
OTOH with Bluetooth you only need a nearby wifi router.

But you still have to hack the net,

Funny what a simple site search turns up. Search words: arduino html

Lot of arduino laser tripwire info like below. IR should also work for a doorway and modules are inexpensive. The w5100 ethernet shields are currently about $7.

https://www.google.com/search?as_q=arduino+laser+trip&as_epq=&as_oq=&as_eq=&as_nlo=&as_nhi=&lr=&cr=&as_qdr=all&as_sitesearch=&as_occt=any&safe=images&as_filetype=&as_rights=&gws_rd=ssl

http://www.ebay.com/sch/i.html?_from=R40&_sacat=0&_sop=15&_nkw=arduino+ethernet+w5100&rt=nc&LH_BIN=1