Jump to content
View in the app

A better way to browse. Learn more.

Tinkerunity

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Featured Replies

Geschrieben

Hi,

 

tried to run on a Raspberry Pi with Master Brick, Wifi Ext 2.0, Ambientlight the ExampleSimple.js.

When running from the commandline $node ExampleSimple.js, received error:

module.js:340

    throw err;

          ^

Error: Cannot find module 'tinkerforge'

 

The line in ExampleSimple.js not changed:

var Tinkerforge = require('tinkerforge');

 

Installed the javaScript bindings using npm. Steps taken as user Pi with install message.

cd /home/pi

sudo npm -g install tinkerforge

tinkerforge@2.0.9 /usr/lib/node_modules/tinkerforge

 

When adding the full path to require('/usr/lib/node_modules/tinkerforge') it is working.

 

How to setup without the need to add the full path in require.

 

Any help appreciated.

 

Geschrieben

I had the same behaviour. After I installed the Tinkerforge modules globally, it was finally located in e.g. /usr/lib/node_modules.

But its needed to add this location in NODE_PATH var to env in Linux like

# export NODE_PATH=$NODE_PATH:/usr/lib/node_modules
# env
...
NODE_PATH=:/usr/lib/node_modules
...

 

Ref.: http://www.tinkerunity.org/forum/index.php/topic,2216.msg14527.html#msg14527

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Gast
Reply to this topic...

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.