Category Archives: Projects

Dong Shin 02.08.2011

  • FGMDEV backup
    • still missing database dump files….
    • modified the script to tar up the dump files and transfer, check tomorrow
  • PPM Changes
    • FinancialStatusDataGrid acting weird… Could not select anything other than last one. Turned out the uid field in the class causing it. Had same uid’s populated on the data. Changed it to dataUid, works now….
    • Errors reported on the latest deployed version
      • changed Create Project to set program_element and FACTS_PE fields to NULL for existing data
      • updated server code to remove INSERTs
    • Fixing bugs
      • Funding request warning dialog has “financial” misspelled as “fianancial”.
      • Removed limit of data in Names list  – had 100 entries
      • Increased width of Contract Number in Direct Cite Window
      • added RTAs to Funding Type
      • check for Start Date and End Date, also disables dates based on selection
      • working on SelectContractWindow

Tom.DeVito 1.4.2011

I2C:

  • Found out that com port was not being initialized properly.  Thought this might be due to cstring not converting to lcpcwstr.  Changed com ports name variable to char[].   This did not convert right either.  wchar_t is the correct type to convert to lcpwstr.  This was not the problem though.
  • For some reason, adding a colon after the COM4 made windows happy.  I don’t think this is always necessary considering it is in none of the examples.  How I figured this out was by adding a GetLastError() after the CreateFile call which gave me the error of 123 or file does not exist.  There were many different solutions to the problem and adding a colon doesn’t always work but this time it did.
  • Still can’t write to the register but at least I have a valid HANDLE now.
  • Figured out what was wrong.  To write to the register you need to send 5 bytes to the controller.
  1. Controller Command: This is different for different IC.  We want to use 0x55 because we want to talk to chips that have a 1byte internal address
  2. Address of the chip: These will be 0x5z. z will depend on how the address pins are set.  If both address pins are set to group 0x58 is what you want to send.
  3. Internal Address bit:  0x00 is what I used,  I believe 0x80 will give you the second register but i am not positive.  You can also mute with this byte again not tested yet.
  4. How many bytes of data will be sent:  In our case this is 1 do 0x01.  This is what I was missing when I tried this before.
  5. Step number you want in hex:  Put in whatever range you want 0-255 decimal in hex form.  It is approximately 40 ohms per step.

The way this looks in c

void changeResistance(){

BYTE sbuf[100];
DWORD n;

hCom = CreateFile( temp, GENERIC_READ | GENERIC_WRITE, 0, NULL, OPEN_EXISTING, 0, NULL);
//set-up com port settings
if (INVALID_HANDLE_VALUE == hCom)
{
printf(“Error: Could not open the RS232 port!”);
getch();
}

sbuf[0] = 0x55;  //controller command
sbuf[1] = 0x58; //address
sbuf[2] = 0x00; //internal address
sbuf[3] = 0x01; //# of bytes to be sent
sbuf[4] = 0x0A; // steps of resistance
WriteFile(hCom, &sbuf, 5, &n, NULL);
ReadFile(hCom, &sbuf, 1, &n, NULL);

getch();

}

Your supposed to set-up the com port settings which is not shown here.  The ReadFile is not really used in this program but would allow you to read the data you just put in to confirm it.

Repairing the hand:

Repairs are almost completely done.  Everything is attached and most of the pairs are responding with good sensitivity. The only pair not working is the index finger.  For some reason the top was settled 100ohms higher then it was supposed to be.  Ground off this connection and glued a new strain gauge and terminal to it.

Tom.DeVito 2.3.2011

I2C:

Still not working but here are some notes.

  • The usb-i2c adapter has the pull up resistors for the sda/scl lines built into the pcb.
  • start, stop, acknowledge bytes are handled by the i2c master and do not need to be done manually
  • Finally figured out how to use the i2c test application.  The chip seems to be working but it is changing the values for both registers instead of only one.  At least I know the address I was using is right.  I think the c program is not writing properly because whenever it writes, a green led should light up on the adapter.

Dong Shin 02.04.2011

  • FGMDEV backup…
    • mysql dump files missing again…. runs fine on command line. capturing output of cron job.
    • adjusted the script a bit, check again tomorrow.
  • Assisted Christine with Maven and Flex projects
    • went thru AccountManagers, EdgeUtils2, and IngestMananger
    • old projects use flexmojos-maven-plugin 3.2.0, we are using 3.8 now. 3.2.0 is not available at sonatype.org, we just have local server copy at fgmdev.com
    • old projects have duplicate entries for com.adobe.flex:license:3.2.0.3958 causing MavenAssist to crash
    • Maven generating different Flex project settings for Mac and Windows?
    • -locale flag in Compiler settings needs to be empty to compile in Flash Builder/Eclipse? It works fine on Mac, but Windows complains.
  • PPM Changes
    • added Tooltips to show contractor name and location on Contract Number ComboBoxes, both AddDirectCiteWindow and FundingRequest
    • mapping Funding Request Data to Financial Status
      • Submit Date (bf_submit_date) to Submitted To BA/BF
      • Certified Date (certified_date) to Certified Date
      • Acceptance Date (acceptance_date) to Acceptance
      • obligation_deadline_date to Funding must be obligated by
      • start_period_performance to Period of Performance
      • Missing Received Contract, Monthly Tech Report, Acceptance Received, MIPR/FAD Requested and Received Dates? dummy for now.
  • list of questions to ask…
    1. General flow of showing Financial Status
    2. Missing fields from Funding Request, if these are stored in Funding Request, where would you be entering data from? Just the Financial Status or Funding Request or both? If in Funding Request, where would it go?
      1. MIPR/FAD Requested from Service
      2. MIPR/FAD Request Received
      3. Date Acceptance Received
      4. Received Contract
      5. Initiate/Commit
      6. Monthly Tech Report
    3. Which are the editable fields in the financial status data form?
      1. PM Actual Outlay is calculated = obligation – outlay
      2. Remaining to Distribute = gradually subtract amount from total
    4. How are the summary data calculated?
      1. Available Balance
      2. Where would the goals come from?
    5. Reimbursable and Direct Cite mutually exclusive, can we control this like letting users enter data to only one place, not both?

Phil 2.3.11

7:30 – 4:30VISIBILITY

  • Deployed the new PPM and while testing it, found that there was some odd behavior in the comments. Took a screenshot and gave it to Dong, who was also perplexed.
  • Adding table updates (adding and deleting columns) and drop table capability to infoObjectManager.java – done
  • Need to add the same capability to InfoObjectManager.as.
  • It looks like we might need to write a tool that lets folks create update files that can then be emailed back to the financial folks for upload into the PPM database. Going to a meeting to discuss same
  • Added generic query to infoObjectManager.java.
  • Added check for “NULL” values when doing conversions from objects to sqlInfoObjects

Dong Shin 02.03.2011

  • FGMDEV backup not working properly.
    • found that sql dump files not transferred to philfeldman.com. The script works fine manually… will check again tomorrow
    • added output to the cronjob – /exchange/backups
  • PPM Changes
    • got many duplicate comments entries in View Comments??? looked at the database and code…. nothing.
    • fixed Date field in View Comments showing same Date…
    • currently deployed database – project_portfolio_02032011
    • saving database update sql – DBUpdateSQLs02032011.sql
    • fixed Funding Request updating type incorrectly
    • removed all additional fields from budget_amounts table – some fields go into funding_requests table
      • ALTER TABLE `budget_amounts` DROP `MIPR_requested_date` ,
        DROP `MIPR_request_received_date` ,
        DROP `submitted_to_BABF` ,
        DROP `document_number` ,
        DROP `certified_date` ,
        DROP `received_contract_date` ,
        DROP `initiate_commit` ,
        DROP `obligation` ,
        DROP `outlay` ,
        DROP `pm_actual_outlay` ,
        DROP `monthly_tech_report_date` ,
        DROP `comments` ;

Dong Shin 02.02.2011

  • PPM Changes
    • fixed a bug Funding Request not updating project_id
    • Remaining to Distribute calculation – keep subtracting Amount from FY BUDGET
    • add outlay to Reimbursable and Direct Cites
      • ALTER TABLE `funding_requests` ADD `outlay_amount` DOUBLE NULL AFTER `reimbursable_amount`
      • ALTER TABLE `direct_cites` ADD `outlay_amount` DOUBLE NULL AFTER `obligation_amount`
    • add contract info for Reimbursable in funding_request
      • ALTER TABLE `funding_requests` ADD `contract_id` INT NULL ,
        ADD INDEX ( `contract_id` )
      • ALTER TABLE `funding_requests` ADD FOREIGN KEY ( `contract_id` ) REFERENCES `project_portfolio`.`contracts` (
        `uid`) ON DELETE SET NULL ON UPDATE CASCADE ;

  • backing up FGMDEV
    • created a shell script and added to crontab – /exchange/backups/backup.sh
      • runs at 1AM everyday, keep last 3 days of data
      • ftp information (vizncon@philfeldman.com to backups directory)
      • ~4GB of data, 90 minutes package and transfer……
    • SVN – svnadmin dump /path/to/reponame > /tmp/reponame.dump ;
    • Nexus Maven Repo
      • zip up /opt/sonatype-work
    • Blog
      • zip up /opt/lampp/htdocs/blogs and /opt/lampp/SCT-Blog
      • back up MySQL Database; fgmdev_blog and sct_blog
        • /opt/lampp/bin/mysqldump -u root –password=edge fgmdev_blog > /exchange/backups/fgmdev_blog.dump

Phil 2.2.11

8:00 – 4:00 VISIBILITY

  • Hey! No ice!
  • Described the new FGM development incentive structure do Dong. Also, he’s going to start regular backups of fgmdev just in case VA forgets to pay the bill.
  • Statistics class
  • Working on tying the server side code back to the flex side for generic table retrieval. First pass is done! Login is now handled in the new system.
  • Burned a disk of new PPM swf

Dong Shin 02.01.2011

  • PPM Changes
    • fixed User Management TextInputs and set User object not updating Save button
    • adding Financial Status information to budget_centers table
      • back up – budget_amounts_org
      • ALTER TABLE `budget_amounts` ADD `MIPR_requested_date` DATE NULL DEFAULT NULL ,
        ADD `MIPR_request_received_date` DATE NULL DEFAULT NULL ,
        ADD `submitted_to_BABF` DATE NULL DEFAULT NULL ,
        ADD `document_number` VARCHAR( 255 ) NULL DEFAULT NULL ,
        ADD `certified_date` DATE NULL DEFAULT NULL ,
        ADD `received_contract_date` DATE NULL DEFAULT NULL ,
        ADD `initiate_commit` DOUBLE NULL DEFAULT NULL ,
        ADD `obligation` DOUBLE NULL DEFAULT NULL ,
        ADD `outlay` DOUBLE NULL DEFAULT NULL ,
        ADD `pm_actual_outlay` DOUBLE NULL DEFAULT NULL ,
        ADD `monthly_tech_report_date` DATE NULL DEFAULT NULL ,
        ADD `comments` TEXT NULL DEFAULT NULL
      • grabbing data from all related tables…
      • SELECT r.funding_type, r.description, r.funding_amount, r.document_number, c.contract_number, c.name as contractor_name, c.location as contractor_location, b.center_number, a.amount
        FROM funding_requests r
        LEFT JOIN direct_cites d ON r.uid = d.funding_request_id
        LEFT JOIN contracts c ON d.contract_id = c.uid
        LEFT JOIN budget_centers b on r.project_id = b.project_id
        LEFT JOIN budget_amounts a on b.uid = a.budget_center_id
        WHERE b.project_id = 96
    • working on saving Financial Status Data from the Form Entry

Phil 2.1.11

7:30 – 3:30 VISIBILITY

  • Working from home today. When the roads melt, I’ll see if I can go install the PPM update from yesterday
  • Installing xampp – done. Worked the first time. Sooooooooooooooooooooo nice.
  • Working on a version of DbTable that tries to match a java data type to the sql data type. Done, at least for the types that Flex likes.
  • Walked through the concept of views into infinite data with Mike.
  • Installed the new PPM. When I updated the DB, I got some errors:
    • On the 10th item (UPDATE direct_cites SET contract_id = [SELECT uid FROM contracts WHERE direct_cites.contract_number = contracts.contract_number )], and the 13th item (UPDATE funding_requests SET project_id = [SELECT uid FROM projects WHERE funding_requests.project_number = projects.project_number )] I got the following error:
    • ERROR 1242 (21000): Subquery returns more than 1 row
    • I left it as is since things appeared to be working. Worst case I can roll it back to just before I made the change.

Phil 1.31.2010

8:00 – 5:30 VISIBILITY

  • Finally found out what was causing the “save problem” with PPM financial data. If a cell that has information has that info deleted, then when the window is closed, the save dialog appears.
  • Wrote up server requirements for Brian
  • Got most of the object transfer done. Need to get the typing on DbTable working better.

Dong Shin 01.31.2011

  • found a way to use the M2_REPO environment variable for Flex Projects so that the Build Path no longer requires the absolute path. Maven Assist should have this…. Updated MavenAssist, now V1.9.2.10
    • <configuration>
      <enableM2e>true</enableM2e>
      <useM2Repo>true</useM2Repo>
      </configuration>
    • cannot get to SourceForge FTP server – connection refused?
  • PPM Changes
    • fixed Financial Data saving problem
    • creating database upgrade scripts for Financial Status
      • DBUpdateSQLs01312011.sql

Tom.DeVito 1.28.2011

Noticed I never published my blog for yesterday

3D articulated hand with force feedback:

  • Noticed that the solar system is technically a joint so this is a good place to start from
  • Mapped out the measurements and angles of my hand in order to get an idea of scaling ratios and required degrees of motion
  • Going to start with the finger tips and work my way down the hand.
  • The palm and thumb are going to be tricky because its made up of oddly shaped polygons
  • Read up on 3d vector physics a bit

Repairing the hand

  • Wired up the hand.  Only broke one connection others seem good.  Flux helps a lot.  It seemed to protect the gold leads and lower the specific heat of the solder.
  • All connections are giving proper resistances but I have not tested them on the SG amps yet.

Dong Shin 01.28.2011

  • PPM Changes
    • continue working on Funding Request work with new tables….
      • Direct Cites/Contracts working
    • Multiple Direct Cites results in many same entries in Financial Status….
    • funding_request table missing project ID!!!
      • ALTER TABLE `funding_requests` ADD `project_id` INT NULL AFTER `statement_of_work` , ADD INDEX ( `project_id` )
      • ALTER TABLE `funding_requests` CHANGE `project_number` `project_number` VARCHAR( 256 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL
      • UPDATE funding_requests SET project_id = ( SELECT uid
        FROM projects
        WHERE funding_requests.project_number = projects.project_number )
      • ALTER TABLE `direct_cites` DROP `contract_number`
    • modified Funding Request to store Project ID
    • mapping Funding Request data fields to Financial Status

Phil 1.28.2011

7:30 – 5:30 VISIBILITY

  • Meeting with Matt and Anne from 3:00 – 4:00. Went very well. We’re going to try to get some more and better data into VISIBILITY
  • Class today – out between 9:30 and 11:30
  • working on  generic data handlers
    • Get insert working – Done, but I want to add precompiled queries as well
    • Get SELECT Query working
    • change User Info over to use new system
  • Spent some time improving the precompiled query code in DbHelper