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.

Sound Pressure Level Bricklet in javascript client returns Error:31

Featured Replies

Geschrieben

Hi,

 

I connect a Sound Pressure Level Bricklet to brickd without problems. Data already be shown in Brickv (2.3.15).

If I use the simple example from website [https://www.tinkerforge.com/de/doc/Software/Bricklets/SoundPressureLevel_Bricklet_JavaScript.html#sound-pressure-level-bricklet-javascript-examples].

After connected I receive getting the data an Error:31.

 

As I see data from the bricklet are received from Brickd. The connection between node.js client and brickd is also working.

What can be the reason for that?

 

Thanks in advance

 

Geschrieben

Error code 31 means timeout. The Bricklet didn't respond in time to a request send by the example, see https://www.tinkerforge.com/de/doc/Software/Bricklets/SoundPressureLevel_Bricklet_JavaScript.html#api.

 

Did you change the UID in the example to the UID of your Bricklet, as stated in line 5 of the example?

 

var UID = 'XYZ'; // Change XYZ to the UID of your Sound Pressure Level Bricklet

 

If you didn't then the example tries to talk to a Bricklet that doesn't exists and therefore will not answer, resulting in a timeout error.

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.