benddennis
Member since Dec 2016 • Last active Jan 2017Most recent activity
-
I put together a simple color-coded compass using the Puck's magnetometer. It's admittedly less robust and doesn't contain much sophisticated math, but it more or less matches readings from my smartphone's compass app. See attached file.
Color Codes
Red, Green, Blue Sequential Flash = North (330 to 30 deg)
Solid Red = East (60 to 120 deg)
Solid Green = South (150 to 210 deg)
Solid Blue = West (240 to 300 deg)Possible enhancements:
- Turn compass on/off via button click
- Fade color in/out between cardinal directions. For example, when pointing to 135 deg, both Red and Green LEDs should be lit. As directions moves more toward 90 degrees, Red gets stronger and Green gets weaker. Or at least something similar to indicate intermediate directions.
See this thread for more sophistication: http://forum.espruino.com/conversations/297915/
- Turn compass on/off via button click
-
@Joakim I tweaked your code to create a Seinfeld clip randomizer as a PoC. Works as expected. https://enlightendata.github.io/
-
@Joakim Sounds like a cool project. I'd thought about doing something similar, though more of a soundboard-type project for work. Hadn't heard of noble before. Will check that out.
-
Thanks @prefectionist. This looks promising, at least for testing. Now, I need to figure out how to send messages to the Gateway.
-
Thanks @prefectionist. This looks promising, at least for testing. Now, I need to figure out how to send messages to the Gateway.
-
-
All,
I'm not clear on how to connect my Puck to the internet. I understand I'll need a Bluetooth Smart Internet Gateway ("With a suitable Bluetooth Smart to Internet gateway you'll be able to put your Puck on the internet!"), but I'm wondering if someone might be willing to be lead me in the right direction as to identify a "suitable Bluetooth Smart Internet gateway."
@Ollie Did you use the same offsets (x0, y0, and z0) or adjust them based on your own puck's readings? I took 4 separate readings (turning every 90 degrees +/-), and then averaged The X, Y, and Z values. I did this per a suggestion by from another post @Gordon.