npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

tame4

v4.3.1

Published

TAME 4: TwinCAT ADS Made Easy

Downloads

31

Readme

TAME 4: TwinCAT ADS Made Easy

Build Status

Introduction

TAME is JavaScript library created for an easy and comfortable access to the TwinCAT ADS WebService. The name is an acronym for „TwinCAT ADS Made Easy“ and stands also for „taming“ the complexity of ADS and AJAX requests. Originally a „wast product“ from the programming of a browser based visualisation for my home, it has become a (in my opinion) useful little piece of software and I hope it will help others who want to develop their own visualisations. I'm not a professional programmer (in fact this is my first "serious" project), so don't get upset when you look at the code.

The library allows to exchange data with a TwinCAT PLC without any knowledge of ADS. The browser connects to the webserver running on the PLC device and the ADS commands are wrapped in AJAX/SOAP requests. Have a look at the manual and the examples for more information.

If you want to know more about the basics of the access to the ADS WebService visit the Beckhoff website [here] (http://infosys.beckhoff.com/content/1033/tc3_adswebservice/html/webservice_intro.htm).

TAME 4 became necessary because the synchronous XMLHttpRequest outside of workers is in the process of being removed from the web platform. It's already deprecated in most browsers and will be removed over the years. TAME 3 uses synchronous requests for fetching the symbol information and the TPY-file from the PLC. With asynchronous requests became a new 'onReady' function nessecary and the process of starting the client is different to TAME 3. If you want to replace V3.x with V4 you have to change the way of starting your scripts!

Features

  • Methods for read and write access to single variables, variable blocks, arrays and structures exists.

  • Supported data types: BOOL, BYTE, WORD, DWORD, USINT, SINT, UINT, INT, UDINT, DINT, TIME, TOD, DT, DATE, REAL, LREAL and STRING. Bounds checking is implemented but can be switched off.

  • Sum commands are supported (read and write).

  • Handles are supported. Access to single elements of structures and arrays and also internal variables and parameters of FB's is possible.

  • The TPY-file generated by TwinCAT can be used. The file contains information about the PLC, the symbols and the data types. With these informations one no longer have to set NetId, port or alignment. Reading structures from the PLC the JavaScript objects can be built automatically without the need of structure definitions. Access to single elements of structures and arrays and also internal variables and parameters of FB's is possible even without using handles.

  • Special „type“ named INT1DP: It's an INT variable in the PLC, but in JavaScript the variable is of type float with 1 decimal place (i.e. a value of 568 in the PLC is 56.8 in JavaScript).

  • Built-in conversion of date and time values to formatted strings.

  • REAL values can be rounded to a desired number of decimal places.

  • Add prefix and suffix to values for a user defined output.

  • Automatic structure padding for exchanging data with TwinCAT 2 and ARM-based devices (i.e. CX90xx) or with TwinCAT 3.

  • Export/import functions for symbols and data types to/from JSON. Intented for the use with Tasker (Android).

  • Force synchronous XMLHttpRequests for easier scripting in Tasker.

Requirements

Requried is a running ADS WebService, look at the [Beckhoff Infosys] (http://infosys.beckhoff.com) for more information about the installation.

License

TAME is dual licensed under the MIT and the GPLv3 license.

Beckhoff® and TwinCAT® are registered trademarks of Beckhoff Automation GmbH.