![]() |
|
|
#1 (permalink) |
|
Registered Member
Join Date: Feb 2004
Posts: 6
|
OnScanResult()
I tried using OnScanResult() even though the official specs say it's not being used. Too bad this was true, it's not being called. I wonder why this is the case ? Having this callback/event with SSID / Signal / WEP etc. would be EXTREMELY useful and I can't imagine it's more than a few minutes of work to expose that information to the script.
Combined with the MS speech to text API this would be so nice to have, as you can currently only output lost / found APs and best signal strength. please please add this simple callback ;-) |
|
|
|
|
|
#2 (permalink) | |
|
Did you do the math?
Join Date: Apr 2002
Location: Villa Straylight
Posts: 10,084
|
Re: OnScanResult()
Quote:
![]() Having done a bit of programming, my experience is the "few minute" jobs are those that seem to take the longest. Then of course there are the 10 million other "few minute" requests that people think the Marius should do. Moved to the appropriate forum.
__________________
Thorn "I'm The Doctor. I'm a Time Lord. I am from the planet Gallifrey in the constellation Kasterborous. I'm 903 years old and I am the man who is going to save your lives and all 6 billion people on the planet below... You got a problem with that?" |
|
|
|
|
|
|
#3 (permalink) |
|
Registered Member
Join Date: Feb 2004
Posts: 6
|
I also got quite a bit of programming experience, also with the windows scripting host, and I honestly don't think it would be more than a few minutes of work. If the app was open source, I would happily do it myself.
Of course do I understand that this is a free app and that he can spent his time in every way he wants. It's just that NetStumbler is a truely great app and it would become even more useful to me if I could script a bit more. Thanks for moving it to the correct forum, you're right. |
|
|
|
|
|
#4 (permalink) | |
|
Ruwach ra'
Join Date: Sep 2003
Location: Southeast Michigan
Posts: 73
|
Re: OnScanResult()
Quote:
__________________
Never Argue With An Idiot. He'll Drag You Down To His Level And Then Beat You With Experience. |
|
|
|
|
|
|
#5 (permalink) |
|
Registered Member
Join Date: Feb 2004
Posts: 6
|
First, if your machine can't handle it you don't need to use scripting. it's an optional feature and disabled by default. Also, anybody can come up with some super crazy script that can slow down any machine. I just don't accept that argument ;-)
If you have a new scan every second, and you find 100 APs, even a slow laptop can handle that. WSH scripting languages like JScript are not fast, but having 100 script calls per second is is acceptable. Also, why not make a callback that gets only called for new APs ? This would already be very useful and it wouldn't do to many script calls for a scan. In any case, that feature would be optional and not raise the min. system requirements |
|
|
|
|
|
#6 (permalink) | |
|
Ruwach ra'
Join Date: Sep 2003
Location: Southeast Michigan
Posts: 73
|
Quote:
__________________
Never Argue With An Idiot. He'll Drag You Down To His Level And Then Beat You With Experience. |
|
|
|
|
|
|
#8 (permalink) | |
|
Ruwach ra'
Join Date: Sep 2003
Location: Southeast Michigan
Posts: 73
|
Quote:
__________________
Never Argue With An Idiot. He'll Drag You Down To His Level And Then Beat You With Experience. |
|
|
|
|
|
|
#9 (permalink) |
|
Registered Member
Join Date: Feb 2004
Posts: 27
|
Actually, it is probably more of a technical issue. I can easily see why it could cause problems.
You really want NS to be as fast as possible, in other words, to be able to pick up new AP's as soon as it sees them. Well, if it calls an external routine when it finds an AP then it has to wait for the external routine to finish (return) before it can detect another AP. So you could miss AP's because of this. On the other hand, you could construct NS to call the external routine "asynchronously" in which case you wouldn't slow down NS. But now you run into another problem, that you could end up calling the same routine twice in a row really fast. So you still need to serialize the calls somehow. The only way to do that would be to buffer the call until it can be processed, which can be a complex undertaking. That's why such a routine is a little more complicated than one might think. -niko Last edited by nikolatesla20 : 02-24-2004 at 03:07 PM. |
|
|
|
|
|
#10 (permalink) |
|
Registered Member
Join Date: Feb 2004
Posts: 6
|
good point. I was assuming that the script calls are already being made in a separate thread. Currently I assume the search for APs is performed in a different thread then UI. The task of placing a script call in qeue is probably similar to adding AP data to the list control in the UI thread. The thread communication wouldn't be to difficult since it's one way with probably only one point of data exchange.
But yeah, I see your point ;-) Too bad the developer doesn't feel comfortable with releasing the source so far. |
|
|
|
|
|
#11 (permalink) | |
|
Ruwach ra'
Join Date: Sep 2003
Location: Southeast Michigan
Posts: 73
|
Quote:
OnScanResult() Parse Data ... Open Database Write Database Close Database Exit Script Overlapping as you pick up 30 APs back to back driving near the university, each triggering the event every scan, every second. Then add in the mapping program to keep track of where you are, and where you stumbled. Might get real ugly real quick.
__________________
Never Argue With An Idiot. He'll Drag You Down To His Level And Then Beat You With Experience. |
|
|
|
|
|
|
#12 (permalink) |
|
Registered Member
Join Date: Feb 2004
Posts: 6
|
Yes, I was thinking of writing a little mapping app and doing a realtime display. Also I wanted to add some more details to my text-to-speech thing. The speech engine actually eats up a lot of CPU and it can get sortof problematic when running on a Crusoe CPU in power save mode.
I think the db app would be perfectly fine, as writing a few rows to a db is pretty cheap ;-) |
|
|
|
|
|
#13 (permalink) | |
|
Ruwach ra'
Join Date: Sep 2003
Location: Southeast Michigan
Posts: 73
|
Quote:
__________________
Never Argue With An Idiot. He'll Drag You Down To His Level And Then Beat You With Experience. |
|
|
|
|
|
|
#14 (permalink) |
|
Registered Member
Join Date: Feb 2004
Posts: 27
|
As long as you make a big enough buffer, you could do this real time - the mapping would be a "pull". It would pull the data when available. The main program's job when a new AP is found is simply to shove it on a stack and return, so it suffers no speed problems.
-niko Last edited by nikolatesla20 : 02-24-2004 at 05:59 PM. |
|
|
|
|
|
#15 (permalink) | |
|
Ruwach ra'
Join Date: Sep 2003
Location: Southeast Michigan
Posts: 73
|
Quote:
__________________
Never Argue With An Idiot. He'll Drag You Down To His Level And Then Beat You With Experience. Last edited by Kazig : 02-24-2004 at 06:11 PM. |
|
|
|
|
![]() |
| Thread Tools | |
| Display Modes | |
|
|