Senor pack delivered!
Spiral_72
Posts: 791
I've been saving.... I burned $97 on the Parallax sensor pack (PING, compass, 2-axis accelerometer, and Ir motion detector) and an extra Ir motion detector. I received it Thursday!!! YEA!!! WOOHOO!
I loaded the PING sample code that displays in/cm on the console. I had to adjust the constants for an accurate reading but that's no big deal. I haven't played with the other sensors yet.
My first project was put the PING on a positioning servo and map the room out on my PC. I had to work around XP to get hardware access to the parallel port UGH! and finally got the port talking to the PING. I made my program in QBasic, but much to my disappointment, I think the language is too slow to pick up the pulse from the PING. I've verified the PING works, but my QBasic routine never sees the pulse. I suppose I'll have to get out my assembly compiler.... It's been a while for that!
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
"puff"...... Smile, there went another one.
I loaded the PING sample code that displays in/cm on the console. I had to adjust the constants for an accurate reading but that's no big deal. I haven't played with the other sensors yet.
My first project was put the PING on a positioning servo and map the room out on my PC. I had to work around XP to get hardware access to the parallel port UGH! and finally got the port talking to the PING. I made my program in QBasic, but much to my disappointment, I think the language is too slow to pick up the pulse from the PING. I've verified the PING works, but my QBasic routine never sees the pulse. I suppose I'll have to get out my assembly compiler.... It's been a while for that!
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
"puff"...... Smile, there went another one.
Comments
It looks like the ping triggers off the negative slope of a 5V pulse..... Then I have 750us to be back waiting for the input which may be held high for 115us to 18.5ms...
Ok, well then I get the stuff back out and go over it again.
Mapping a room is for practice/learning/experimentation more than anything. My little Stamp can't hold all that data!
Thank you....... It's really exciting to get a Parallax box in the mail!
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
"puff"...... Smile, there went another one.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
"When the government is afraid of the people there is liberty, when the people are afraid of the government, there is tryanny"
· Thomas Jefferson
·
http://en.wikipedia.org/wiki/QBasic
Jim
Qbasic is a BASIC programming language that's been around since 1987 for the PC still a very capable language.
Spiral_72,
I believe also that Qbasic is fast enough, but you may need to run it in a strict DOS mode.
Years ago, before Parallax BS1, I wrote a program to control the position of RC servos through the parallel port using an 8088 processor. A pulse width ranging from 1ms to 2ms, a challenge in and of itself. By today's standards in terms of processing and computer speed, this should be a piece of cake. I'm willing to bet that Windows is the culprit and interfering with your timing.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Beau Schwabe
IC Layout Engineer
Parallax, Inc.
I KNEW I should have made this a dual boot system. I have on every computer till this point, and for some reason I only put XP on this one.
I still couldn't get my program to work. I've been over and over it. I used integers instead of default (floating point), and trimmed every instruction I could out. I'll probably let it slide. The project was just for fun anyways. It's too bad though.
It's amazing how accurate the PING is on the BS2! There's plenty of resolution!
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
"puff"...... Smile, there went another one.