@jamesgopsill/renold-chain-selector
TypeScript icon, indicating that this package has built-in type declarations

0.1.0 • Public • Published

(Unnofficial) Renold Chain Selector TS client

This repo contains the source code for an unofficial typescript wrapper around the Renold Chain Selector online tool. The primary goal is to aid in integrating this fantastic tool into engineering design workflows and we use it within our courses to teach our students about design automation.

Installation

To install, use your preferred node package manager.

> bun install @jamesgopsill/renold-chain-selector

Example

const chainCriteria: ChainCriteria = {
	powerValueType: "InputPower",
	powerValue: 10,
	speedValueType: "InputSpeed",
	speedValue: 1_000,
	startSpeed: 1,
	finishSpeed: 1000,
	speedIncrement: 10,
	targetWorkingLife: 15_000,
	workingLifeTolerance: 100,
	drivingSprocketTeeth: 19,
	drivenSprocketTeeth: 19,
	centreDistanceRoundingMode: "EvenNumberOfLinks",
	centreDistance: 900,
	numberOfLinks: 0,
	userSuppliedNumberOfLinks: false,
	drivingMachineCharacteristics: "SlightShocks",
	drivenMachineCharacteristics: "ModerateShocks",
	lubricationRegime: "Insufficient",
	customWearFactor: 0,
	environmentCondition: "Normal",
	environmentDomain: "Indoor",
	productRangeId: ProductRange.SYNERGY,
	chainStandardId: Standard.BRITISH,
	unit: "Metric",
}

const r = await getChainOptions(chainCriteria)
if (r.ok) {
	const results = await r.json()
}

Docs

The docs have been produced using TypeDoc and can be accessed here. If you enter the IP address of your machine in your browser window then that will take you to the API documentation.

TODO

  • Create the validation function to validate the criteria before sending it to the API.
  • Enable manual chain selection (currently set to automatic selection).

Readme

Keywords

Package Sidebar

Install

npm i @jamesgopsill/renold-chain-selector

Weekly Downloads

2

Version

0.1.0

License

none

Unpacked Size

10.8 kB

Total Files

5

Last publish

Collaborators

  • jamesgopsill