Git Product home page Git Product logo

softworks's People

Stargazers

 avatar  avatar  avatar

Watchers

 avatar

softworks's Issues

Add Matlab View Support

Problem Statement

Add support for opening and storing MATLAB views.

Proposed Solution

Add a matlab package view type for matlab.

View Package

/*****************************************************************
 *                                                               *
 *    Softworks Software Data Manager MATLAB Support Package     *
 *                                                               *
 *****************************************************************/
SdmMat = let(()

procedure(startIDE(@rest restArgs) let((cmd)
	if(restArgs then
		;cmd = sprintf(nil "matlab -r \"edit %s\" & \n" buildString(restArgs))
		cmd = sprintf(nil "tcsh -c \"matlab -r \"edit %s\" &\" &" buildString(restArgs))
		printf(cmd)
		system(cmd)
	else
		system("matlab &"))
))

procedure(DataTrigger(@optional argList)
	let((libName cellName file fileName objId viewFileName viewName viewType)	
	;printf("Calling SkyVer  View App Trigger on %L !\n", argList);
	libName = argList->libName
	cellName = argList->cellName
    viewName = argList->viewName
    viewType = argList->viewType
    viewFileName = ddMapGetViewTypeFileName( viewType )

    if( objId = ddGetObj(libName cellName viewName viewFileName nil "r") then
    	file = ddGetObjWritePath(objId)
		;printf("filename = %s\n" fileName)
		; Start matlab editor 
		if(isFile(file) then
			startIDE(file)
		else
			;warn("Issue!!!\n"))
			warn("%s/%s/%s doesn't appear to be a matlab View !\nMissing the *.py file!\n", libName cellName viewName))
	else
		warn("module must be created outside Cadence tools !!\n")
		;dbOpenCellViewByType(libName cellName viewName args->rootType "wn")
		case(viewType
			("matlab_code" fileName = strcat(cellName ".m"))
			(t fileName = strcat(cellName ".m"))
		)
		if(objId = ddGetObj(libName cellName viewName fileName nil "w") then
			dbSave(objId)
			file = ddGetObjWritePath(objId)
			StartIDE(file)
		else
			warn("Could not create the cellview"))
	)
	t
))
procedure(ViewAppTrigger(@optional argList)
	;printf("Calling SkyVer module View data Trigger on %L !\n", argList);
	t)
procedure(EnableTrigger(@optional argList)
	;printf("Calling SkyVer module View data Trigger on %L !\n", argList);
	t)

list(nil
	'startIDE startIDE
	'DataTrigger DataTrigger
	'ViewAppTrigger ViewAppTrigger
	'EnableTrigger EnableTrigger
))

SdmStartMatlab = SdmMat->startIDE
SdmMatlabDataTrigger= SdmMat->DataTrigger
SdmMatlabViewAppTrigger = SdmMat->ViewAppTrigger
SdmMatlabEnableTrigger = SdmMat->EnableTrigger

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
; Register Python Custom Cellviews ;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
when(!member("matlab_code" deGetAllViewTypes()) 
	deRegApp(
    	?appName "matlab"
    	?enableTrigger 'SdmMatlabEnableTrigger
    	?dataTrigger 'SdmMatlabDataTrigger
    	?viewType "matlab_code"
		?appTrigger 'SdmMatlabViewAppTrigger
    	?widgetType "graphics"
  	)
)

Documentation


MATLAB Views
============

`MATLAB <https://www.mathworks.com/products/matlab.html>`_ view support is
still under development

+-------------+-----------------+-------------+------------------------------+
| View Type   | Extensions      | Editors     | Description                  |
+=============+=================+=============+==============================+
| matlab_code | \*.m            | MATLAB,      | A MATLAB code file. Opened  |
|             |                 | gedit        | using MATLAB.               |
+-------------+-----------------+-------------+------------------------------+

Alternatives Considered

  • None

Proposed Action Plan

  • 1. Add the MATLAB view package
  • 2. Add MATLAB templates
  • 3. Add documentation

YAML file support

For the updated version, We will target to first release support for YAML files edited using VS code.

MVP

Problem Statement

Proposed Solution

Alternatives Considered

Proposed Action Plan

  • 1. we'll do this
  • 2. We'll do that
  • 3. Then we'll add tests for this and that.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.