Memory Stick Datalogger not working
mschneid
Posts: 3
I installed the Memory Stick Datalogger and am experiencing something that appears to be it going to sleep before it is supposed to. I tried both sample codes (Test and Demo), and have a similar result. Per the LED's on the stick and the logger, it goes to sleep at different times in the code (per the debug output). The symptoms are: the code hangs in the same "neighborhood" (but not exact location in the code) at the same time all the lights go out.
Has anybody else got this to work and/or having issues with it? I formatted the (1 gig) stick for both FAT and FAT 32, with no apparent difference. I have a BSP40 stamp.
The code freezes at the second iteration of the following for loop. The Demo code was modified to use a random number instead of a measured quantity.
FOR counter = 1 TO NumSamples ' Number Of Samples To Log
'HIGH Sensor ' Charge Capacitor
'PAUSE 1 ' Wait 1 ms
'RCTIME Sensor, 1, result ' Measure Discharge Time
RANDOM result
DEBUG "Sample ", DEC5 counter, " of ", DEC5 NumSamples,
" --> ", DEC5 result, CR ' Display Results
SEROUT TX\CTS, Baud, [noparse][[/noparse]$08, $20, $00, $00, $00, $0D, CR,
DEC5 counter, ",", DEC5 result, CR, LF, CR]
PAUSE 500 ' Write Results/Delay
GOSUB Get_Data ' Purge Receive Buffer
NEXT
Has anybody else got this to work and/or having issues with it? I formatted the (1 gig) stick for both FAT and FAT 32, with no apparent difference. I have a BSP40 stamp.
The code freezes at the second iteration of the following for loop. The Demo code was modified to use a random number instead of a measured quantity.
FOR counter = 1 TO NumSamples ' Number Of Samples To Log
'HIGH Sensor ' Charge Capacitor
'PAUSE 1 ' Wait 1 ms
'RCTIME Sensor, 1, result ' Measure Discharge Time
RANDOM result
DEBUG "Sample ", DEC5 counter, " of ", DEC5 NumSamples,
" --> ", DEC5 result, CR ' Display Results
SEROUT TX\CTS, Baud, [noparse][[/noparse]$08, $20, $00, $00, $00, $0D, CR,
DEC5 counter, ",", DEC5 result, CR, LF, CR]
PAUSE 500 ' Write Results/Delay
GOSUB Get_Data ' Purge Receive Buffer
NEXT
Comments
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
- Stephen
If the attachment does not come through, the file is 99% the same as the demo file, but without the extra sensor input (replaced with random number).
http://www.parallax.com/Portals/0/Downloads/docs/prod/comm/DataloggerDemoV1.0.zip
matt
Does the unedited example code hang for you as well?
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Chris Savage
Parallax Tech Support