Removed

Ideas and instructions how you can make your own bondage toys.
AnotherGinger
*
Posts: 5
Joined: 16 Nov 2020, 02:52

Re: TechCollar

Post by AnotherGinger »

Hey, kinbaku and Odin! I usually lurk, but you've hit a field I'm actually knowledgeable in, so I figure I should actually give something to this community. I'm no mathematician, but I do know a thing or two about rotations.

kinbaku is right in that you basically need to rotate the coordinate frame. I assume the IMU's tilt relative to the collar is constant, so that shouldn't be too difficult to manage. The resource on IMUs also seems like a good place for you to start. You probably don't actually need to understand quaternions for this problem, and the conversion equation looks like it should be doing the job. Furthermore, using 57.3 is probably accurate enough and wouldn't cause many problems. The calculation from quaternion to Euler angles does seem correct, though with some strange negative signs that cancel each other out. One option would be to copy Wikipedia's formula https://en.wikipedia.org/wiki/Conversio ... conversion. This could be the reason one of your variables enjoys flipping from positive to negative.

You say the readings are strange, so let me see if I understand the readings I'm seeing: you have a constant gyro orientation and a constant acceleration, so I assume that the device is just resting on a surface, but they're outputting varying angles despite its constant readings? I'm assuming you've already tried printing the quaternions themselves, and they should also be changing if the resultant angles are changing. Unfortunately, this means that filtering alone is unlikely to solve the problem. Filters are used when the data is changing in ways that are unexpected. If the data isn't changing, then filtering wouldn't help. I do recommend filtering, however, since you mentioned having noisy data. I've had success with a complementary filter, which can be described here: https://www.pieter-jan.com/node/11

The main thing, though, is that I am having some trouble understanding your gyro and accelerometer readouts (I assume that "Acceleration" and "Gyroscope" are their raw readings), however. What are their units, and what are their axes? Have you tried picking up the device and rotating it a few ways just to see how the readings change? I also notice that you have a magnetic sensor but censored it, probably to hide your location (which is fine, obviously). I assume it's constant, as well?

Either way, it's important first to figure out what the x, y, and z axes are with respect to the IMU itself, but you've probably already done that.

Edit: looks like my first post was approved after you already fixed your problem. Oops.
Last edited by AnotherGinger on 07 Dec 2021, 01:44, edited 1 time in total.
OneAndOnlyOdin
**
Posts: 109
Joined: 31 Mar 2019, 16:00

Removed

Post by OneAndOnlyOdin »

Removed
Last edited by OneAndOnlyOdin on 12 Jan 2022, 12:42, edited 1 time in total.
RIP Odin - Odin was killed to make place for other things. This forum will forever be a part of Odin's soul.
User avatar
Shannon SteelSlave
Moderator
Posts: 6531
Joined: 03 Feb 2019, 19:49
Location: New England, USA

Re: TechCollar

Post by Shannon SteelSlave »

Welcome to Bound Anna, Ginger.
Bondage is like a foreign film without subtitles. Only through sharing and practice can we hope to understand.
A Jedi uses bondage for knowledge and defense, never for attack.
I am so smart! I am so smart! S-M-R-T!....I, I mean S-M-A-R-T!
👠👠
User avatar
kinbaku
*****
Posts: 5053
Joined: 10 Jan 2020, 20:26
Location: Belgium

Re: TechCollar

Post by kinbaku »

Welcome AnotherGinger and thanks for your help. :hi:
Post Reply