Posts

Showing posts from March, 2011

Free CAD/CAM Options

There was a time when CAD and CAM software was simply not available for anyone without paying a substantial sum of money.  The version of AutoCAD 10 (which came on 10 floppies) that I used for a year at MFJ Enterprises to do product documentation cost almost $1000. Even low quality programs cost upwards of $99 or more.  However, in the past few years there have been many new free versions of software available that are high and even professional quality. Sketchup Arguably the first really free CAD software that was good quality was Sketchup . Sketchup was written by a company called  @Last Software which sold the software for $495.  The company wrote a plug-in for Google Earth and soon afterward Google bought the company.  In 2006 at Google Developer Day the developers of Sketchup were there presenting the software and giving away free Sketchup socks.   An important feature of Sketchup is that users can write short snippets of code in Ruby to configure or extend the application

Python and MySQL

Although PHP is used a lot for SQL scripts, Python is a fine alternative. The commonly used SQL library in Python is MySQLdb.  MySQLdb is an thread-compatible interface to the popular MySQL database server that provides the Python database API. ( from the documentation ) An example showing the guts of a Python MySQL script. import MySQLdb conn = MySQLdb.connect (host = " localhost ", user = " root ", passwd = " admin ", db = " databasename ") db = conn.cursor() db.execute ( " SELECT * FROM table1 ") data = db.fetchall() #do something with the data db.close () conn.commit () conn.close () Looking over the code example : After the import is a connect request to an SQL database.  The database in on the localhost and has the default username and password.  The the actual database name must be specified.  MySQL databases can have multiple databases on one host. Note that on all the code accessing data or running commands on the data