VTI Pressure sensor Demo
Ok....I have a gripe....which for Parallax is uncommon.
The source code for the VTI is a bin file.....which the Propeller tool can load, but the code is not available.
I would like to have the code for my own uses.
Would it be possible to get the spin/asm file of the demo?
James L
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
James L
Partner/Designer
Lil Brother SMT Assembly Services
Please note: Due to economic conditions the light at the end of the tunnel will be turned off until further notice. Thanks for your understanding.
The source code for the VTI is a bin file.....which the Propeller tool can load, but the code is not available.
I would like to have the code for my own uses.
Would it be possible to get the spin/asm file of the demo?
James L
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
James L
Partner/Designer
Lil Brother SMT Assembly Services
Please note: Due to economic conditions the light at the end of the tunnel will be turned off until further notice. Thanks for your understanding.

Comments
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Chris Savage
Parallax Engineering
50 72 6F 6A 65 63 74 20 53 69 74 65
·
OK,
I'll let you slide this time.......
I understand these things happen.......
James L
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
James L
Partner/Designer
Lil Brother SMT Assembly Services
Please note: Due to economic conditions the light at the end of the tunnel will be turned off until further notice. Thanks for your understanding.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Chris Savage
Parallax Engineering
50 72 6F 6A 65 63 74 20 53 69 74 65
·
Well...to be honest....I can't gripe too much. I didn't buy my sensor from Parallax.........so I have no room to point fingers.
I was just going to take a peek at how you guys did the code.
James L
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
James L
Partner/Designer
Lil Brother SMT Assembly Services
Please note: Due to economic conditions the light at the end of the tunnel will be turned off until further notice. Thanks for your understanding.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Chris Savage
Parallax Engineering
50 72 6F 6A 65 63 74 20 53 69 74 65
·
it will also include how to access and display the temperature monitoring feature
of the VTI SPC1000 and not just the pressure readings.
Source code for the Basic Stamp would be very desirable as well.
phil
Post Edited (phil kenny) : 10/15/2009 6:25:39 PM GMT
I just responded in another thread that BASIC Stamp code would be available as well as updated Propeller code. I plan on including the temperature as well. I apologize for not meeting my timeline. I am trying to allocate some time to Propeller objects that need to be done. I am thinking next week will be possible. I will follow up on these threads as soon as I have something though. Rest assured.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Chris Savage
Parallax Engineering
50 72 6F 6A 65 63 74 20 53 69 74 65
·
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Chris Savage
Parallax Engineering
50 72 6F 6A 65 63 74 20 53 69 74 65
·
Not sure if I am comunicating what I am asking... If the .pdf for the BASIC stamp users is complete, could you post a link to it?
Larry Stroud
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Chris Savage
Parallax Engineering
50 72 6F 6A 65 63 74 20 53 69 74 65
·
My apologies, it turns out the firmware for that module is not available to the public; so only the binary files can be used
I hope this helps,
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Respectfully,
Joshua Donelson
www.parallax.com
Post Edited (Joshua Donelson (Parallax)) : 1/29/2010 7:42:53 PM GMT
'' SCP1000 Driver '' '' Pin assignments (relative to 'Pin' parameter passed to SCPInit): '' '' 0 SCK (output) '' 1 MOSI (output) '' 2 MISO (input) '' 3 CSB (output) '' 4 DRDY (input) '' '' CON SCK = 0 ' Clock MOSI = 1 ' Master Out, Slave In MISO = 2 ' Master In, Slave Out CSB = 3 ' Chip Select DRDY = 4 ' Device Ready AltCor = 1920 ' sealevel altitude correction (in mb * 100) VAR long Pin long status long rawtemperature, pressureH, pressureL long Temperature, Pressure long Stack[noparse][[/noparse]64] byte Cog PUB Start(PinStart) : okay Stop okay := (Cog := cognew(SCPInit(PinStart), @Stack) + 1) PUB Stop if Cog cogstop(Cog~ - 1) PUB Active : YesNo YesNo := Cog > 0 PUB SCPInit(PinStart) waitcnt(clkfreq/10 + cnt) ' wait 100 msec for SCP1000 to initialize Pin := PinStart ' save starting port pin number dira[noparse][[/noparse]PinStart..(PinStart+DRDY)] := %11010 ' set port direction bits CSB_HI ' set CSB high (inactive) SCK_LO ' set SCK low SCPWriteRegister($3, $a) ' select high-precision mode SCPReadRegister8($1f) ' dummy read of pressure register to clear DRDY SCPReadRegister16($20) SCPLoop ' kick off processing PUB SCPLoop | TempC, TempF repeat waitpeq(|< (Pin+DRDY), |< (Pin+DRDY), 0) ' wait for DRDY to go high status := SCPReadRegister8($7) ' read status register rawtemperature := SCPReadRegister16($21) ' read temperature register pressureH := SCPReadRegister8($1f) ' read pressure register (high bits) pressureH &= $7 ' only lower 3 bits are significant pressureL := SCPReadRegister16($20) ' read lower bits of pressure pressureL := (pressureH << 16) | pressureL ' merge pressure halves TempC := rawtemperature * 10 / 2 ' compute temperature in °C x 100 TempF := TempC * 9 / 5 + 3200 pressureL /= 4 ' convert raw pressure to mb x 100 pressureL += AltCor Temperature := TempF Pressure := pressureL PUB SCPTemp result := Temperature PUB SCPPressure result := Pressure PRI CSB_HI outa[noparse][[/noparse]Pin+CSB]~~ ' set CSB high (inactive) PRI CSB_LO outa[noparse][[/noparse]Pin+CSB]~ ' set CSB low (active) PRI SCK_HI outa[noparse][[/noparse]Pin+SCK]~~ ' set SCK high PRI SCK_LO outa[noparse][[/noparse]Pin+SCK]~ ' set SCK low PRI SCPWriteRegister(reg, value) reg <<= 2 reg |= $2 ' set bit to indicate write CSB_LO ' set CSB to enable sensor SCPSend(reg) ' write register address SCPSend(value) ' write register value CSB_HI ' disbale chip select PRI SCPSend(value) : rbyte | tmp, i tmp := value >< 8 ' reverse order of bits repeat i from 0 to 7 SCK_LO ' set SCK low outa[noparse][[/noparse]Pin+MOSI] := tmp & 1 ' write bit out to sensor tmp >>= 1 SCK_HI ' set SCK high rbyte := (rbyte << 1) | ina[noparse][[/noparse]Pin+MISO] ' accumulate incoming data SCK_LO ' lower SCK PRI SCPReadRegister8(reg) : rbyte reg <<= 2 reg &= $fc ' clear lower two bits to indicate read command CSB_LO ' enable sensor rbyte := SCPSend(reg) ' send register address to sensor rbyte := SCPSend(0) ' write dummy byte to allow sensor to respond with 8 bits of data CSB_HI ' disable chip select PRI SCPReadRegister16(reg) : rword | wordH, wordL reg <<= 2 reg &= $fc ' clear lower two bits to indicate read command CSB_LO ' enable sensor wordH := SCPSend(reg) ' send register address to sensor (and ignore return value) wordH := SCPSend(0) ' write dummy byte to allow sensor to respond with 8 bits of data (MSB) wordL := SCPSend(0) ' write dummy byte to allow sensor to respond with 8 bits of data (LSB) CSB_HI rword := (wordH << 8) | wordL ' return 16 bit result▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Respectfully,
Joshua Donelson
www.parallax.com
Best Regards
Jaime... microwaveteach@hotmail.com