Posts by foovax

11) Message boards : Number crunching : using a GMC-300 for a project detector? (Message 1985)
Posted 3904 days ago by foovax
I have no access to source code. I've presented the code above that comes from the gmc-300 linux driver code to assist with the startup problems but no implementation as of yet.

I run the bash script which is also posted above and that keeps the work going on my machine.
12) Message boards : Number crunching : using a GMC-300 for a project detector? (Message 1977)
Posted 3913 days ago by foovax
I posted the above a few weeks ago and it appears to reference this issue?

// clearUSB is public method to clear the read (input) buffer of
// the serial port. This method exists due to vagaries of the
// turn_on_cps_cmd. Since there is no protocol for the returned
// data (ie, no start, no stop, no ack, no nak), the synchronization
// of the getAutoCPS() method with the GQ GMC is flakey. Consequently,
// when the turn_off_cps_cmd happens, there may be left over
// data in the USB input buffer. So this method simply reads the
// USB input buffer until it is empty.
void
GQGMC::clearUSB()
{
uint32_t rcvd(0);
char inp;

// Assume that there isn't that much left over from any previous
// read. In other words, we couldn't ever get that far off.
// So read only 10 bytes.
const
uint16_t kMaxtries(10);

// Read returned data until input buffer is empty as indicated by
// rcvd = 0 or not. If rcvd = 0 then the buffer empty and that is
// what we want.
for(uint16_t i=0; i<kMaxtries; i++)
{
rcvd = read(usb_serial, &inp, 1);
if (rcvd == 0) break;
} // end for

// Not good, there are still more characters in input buffer,
// so declare error.
if (rcvd > 0)
error_code = eClear_USB;

return;
}// end clearUSB()



The above code comes from the gqgmc linux driver code that is linked to from the official website for the gmc-300. I'd try implementing this function in and calling it before opening the ports.
13) Message boards : Number crunching : using a GMC-300 for a project detector? (Message 1968)
Posted 3925 days ago by foovax
Radioactive@Home app rev $Rev: 178 $ for GMC-300 starting...
Trying to open: /dev/ttyUSB0
Open retval: 7
tcgetattr() returned 0
tcsetattr() returned 0
tcflush() returned 0
/dev/ttyUSB0 opened for read/write
<GETVER>> returned GMC-300Re 2.38
Connected to GMC-300 Re 2.38 (revision int: 568)
<GETCPM>> returned 0 22
4000,3,2013-8-8 22:45:55,f,0.1 minutes,22.0 cpm,0.41 uSv/h
<GETCPM>> returned 0 16
188000,52,2013-8-8 22:48:59,n,3.1 minutes,16.0 cpm,0.09 uSv/h
<GETCPM>> returned 0 15
372000,98,2013-8-8 22:52:3,n,3.1 minutes,15.0 cpm,0.09 uSv/h
<GETCPM>> returned 0 20
556000,159,2013-8-8 22:55:7,n,3.1 minutes,20.0 cpm,0.12 uSv/h
<GETCPM>> returned 0 16
740000,208,2013-8-8 22:58:11,n,3.1 minutes,16.0 cpm,0.09 uSv/h
<GETCPM>> returned 0 21
924000,272,2013-8-8 23:1:15,n,3.1 minutes,21.0 cpm,0.12 uSv/h
<GETCPM>> returned 0 13
1108000,311,2013-8-8 23:4:19,n,3.1 minutes,13.0 cpm,0.07 uSv/h
<GETCPM>> returned 0 20
1292000,372,2013-8-8 23:7:23,n,3.1 minutes,20.0 cpm,0.12 uSv/h
Trickle sent
<GETCPM>> returned 0 11
1476000,405,2013-8-8 23:10:27,n,3.1 minutes,11.0 cpm,0.06 uSv/h
<GETCPM>> returned 0 25
1660000,481,2013-8-8 23:13:31,n,3.1 minutes,25.0 cpm,0.14 uSv/h
<GETCPM>> returned 0 17
1844000,533,2013-8-8 23:16:35,n,3.1 minutes,17.0 cpm,0.10 uSv/h
Trickle sent
Done - calling boinc_finish()
19:16:35 (14240): called boinc_finish


First job ran to completion as expected. Second didn't start:

Radioactive@Home app rev $Rev: 178 $ for GMC-300 starting...
Trying to open: /dev/ttyUSB0
14) Message boards : Number crunching : using a GMC-300 for a project detector? (Message 1967)
Posted 3925 days ago by foovax
Radioactive@Home app rev $Rev: 178 $ for GMC-300 starting...
Trying to open: /dev/ttyUSB0
Open retval: 7
tcgetattr() returned 0
tcsetattr() returned 0
tcflush() returned 0
/dev/ttyUSB0 opened for read/write
<GETVER>> returned GMC-300Re 2.38
Connected to GMC-300 Re 2.38 (revision int: 568)
<GETCPM>> returned 0 22
4000,3,2013-8-8 22:45:55,f,0.1 minutes,22.0 cpm,0.41 uSv/h


Port issue appears resolved. Running in boinc now with interval set to .5 and my keep alive script disabled. Will see if it can end 1 work unit and proceed with the next work unit.
15) Message boards : Number crunching : using a GMC-300 for a project detector? (Message 1963)
Posted 3925 days ago by foovax
The server uses fixed divider 111, I think it's the correct value for MD-4011. If it's not, it can be very easily tweaked. Just a single field in database.


I think once the app's are finished and move from beta then calibration can fix the charts based on this comment above in this thread.
16) Message boards : Number crunching : using a GMC-300 for a project detector? (Message 1962)
Posted 3925 days ago by foovax
I'm running the same in Linux and have the same results on the chart with ~.1 higher than average.

17) Message boards : Number crunching : using a GMC-300 for a project detector? (Message 1959)
Posted 3926 days ago by foovax
18:06:40 (30187): Can't open init data file - running in standalone mode
gmc_ReadPortNumber(): Wrong port number
18:06:40 (30187): called boinc_finish


<gmc>
<comsettings>
<comment>Edit port number below</comment>
<portnumber>0</portnumber>
<comment>On Windows, the app tries to open COM<x> where <x> is the specified port number</comment>
<comment>On Linux, the app tries to open /dev/ttyUSB<x> where <x> is the specified port number</comment>
<baud>57600</baud>
<bits>8</bits>
<parity>n</parity>
<stopbits>1</stopbits>
</comsettings>
<options>
</options>
</gmc>
18) Message boards : Number crunching : using a GMC-300 for a project detector? (Message 1953)
Posted 3927 days ago by foovax
Sounds good. I think as stated in that code above about the clearusb. The device has an odd way of sending the data and it's not clearing out properly so I think if before you attempt the connection you perform something similar to that gqgmc function that would probably get this working as expected.

When I open minicom or screen when the gmc300 binary is stuck it immediately displays the version number without <GETVER>>.
19) Message boards : Number crunching : using a GMC-300 for a project detector? (Message 1951)
Posted 3928 days ago by foovax
Having heard nothing I was eager to pass back results. I put together a script that when run in cron will detect a new task, init the port, restart the apps and keep results running all day using the first version of the linux code provided here and by creating a symbolic link to ttyS99 as referenced above.



#!/bin/bash
BOINC_PATH="/var/lib/boinc-client/slots"

SLOT=`grep -rH radio $BOINC_PATH/* | egrep -o 's/[0-9]{1,2}/i'`
arrSLOT=(${SLOT//// })
SLOT=${arrSLOT[1]}

RAH_OUT="$BOINC_PATH/$SLOT/stderr.txt"
tail -n 1 $RAH_OUT | grep -q 'starting...'
if [ $? == 0 ]
then
screen -dmS boincclearport /dev/ttyS99 57600
sleep 1
kill $(ps aux | grep '[b]oincclearport' | awk '{print $2}')
kill $(ps aux | grep '[g]mc300 read' | awk '{print $2}')
fi


Which has keep the jobs running without pause.

20) Message boards : News : New detectors release soon! (Message 1949)
Posted 3932 days ago by foovax
In the forum where that image came from they mentioned to remove the rechargeable battery if it's in use on USB in a constant on state.


Next 10 posts

Main page · Your account · Message boards


Copyright © 2024 BOINC@Poland | Open Science for the future