MultiRanger Expansion Deck reading 0s

Post here to get support
Post Reply
soso
Beginner
Posts: 5
Joined: Tue Dec 28, 2021 2:30 am

MultiRanger Expansion Deck reading 0s

Post by soso »

I am using a Crazyflie 2.1 attached with a multiranger expansion deck and an optical flow expansion deck. When using the Multiranger library to read the values from the multiranger deck I always get an output of 0 on all the sensors. I am not sure what the issue may be. The Crazyflie works fine otherwise. Any help will be appreciated!
jonasdn
Expert
Posts: 132
Joined: Mon Mar 01, 2021 3:13 pm

Re: MultiRanger Expansion Deck reading 0s

Post by jonasdn »

Hi soso!

That sounds weird! Could you please attach the output from the console when the drones start? So we could see if there us any relevant error message.

Jonas
soso
Beginner
Posts: 5
Joined: Tue Dec 28, 2021 2:30 am

Re: MultiRanger Expansion Deck reading 0s

Post by soso »

Hi!

So I am controlling the drone using a python script and I am not sure how to log information related to the multiranger or check any logged information. However, when I run the cfclient this is the information that is displayed when I establish the connection with the Crazyflie.

---
SYS: Crazyflie 2.1 is up and running!
SYS: Production release 2021.06
SYS: I am 0x20393430533350080027001F and I have 1024KB of flash!
CFGBLK: v1, verification [OK]
DECK_CORE: 1 deck(s) found
DECK_CORE: Calling INIT on driver bcFlow2 for deck 0
ZR2: Z-down sensor [OK]
PMW: Motion chip id: 0x49:0xB6
IMU: BMI088: Using I2C interface.
IMU: BMI088 Gyro connection [OK].
IMU: BMI088 Accel connection [OK]
IMU: BMP388 I2C connection [OK]
ESTIMATOR: Using Kalman (2) estimator
CONTROLLER: Using PID (1) controller
MTR-DRV: Using brushed motor driver
SYS: About to run tests in system.c.
EEPROM: I2C connection [OK].
STORAGE: Storage check [OK].
IMU: BMI088 gyro self-test [OK]
DECK_CORE: Deck 0 test [OK].
SYS: Self test passed!
STAB: Wait for sensor calibration...
SYS: Free heap: 17672 bytes
STAB: Ready to fly.
ESTKALMAN: State out of bounds, resetting
WARNING: LOG packets drop deteESTKALMAN: State out of boundsESTKALMAN: WARNING: Kalman preSYSLOAD: Task dump
SYSLOAD: Load Stack left Name
SYSLOAD: 1.41 230 Tmr Svc
SYSLOAD: 69.32 127 IDLE
SYSLOAD: 0.0 75 PWRMGNT
SYSLOAD: 0.65 213 CRTP-RX
SYSLOAD: 2.13 75 ZRANGER2
SYSLOAD: 2.48 191 FLOW
SYSLOAD: 0.0 115 PLATFORM-
SYSLOAD: 0.0 255 LOG
SYSLOAD: 0.0 223 MEM
SYSLOAD: 0.0 217 CMDHL
SYSLOAD: 0.0 95 PARAM
SYSLOAD: 0.14 157 SYSTEM
SYSLOAD: 0.05 61 CRTP-TX
SYSLOAD: 7.45 329 STABILIZE
SYSLOAD: 7.28 151 SENSORS
SYSLOAD: 6.47 309 KALMAN
SYSLOAD: 0.98 93 LEDSEQCMD
SYSLOAD: 0.41 107 CRTP-SRV
SYSLOAD: 1.14 176 SYSLINK
SYSLOAD: 0.0 114 USBLINK
jonasdn
Expert
Posts: 132
Joined: Mon Mar 01, 2021 3:13 pm

Re: MultiRanger Expansion Deck reading 0s

Post by jonasdn »

Thank you soso!

So, first, to log console from your python script, you can check this example: https://github.com/bitcraze/crazyflie-l ... console.py

And, for your log, this is with a Crazyflie with 2 decks? One flow and one multiranger? Because your log shows only a flowdeck found:
CFGBLK: v1, verification [OK]
DECK_CORE: 1 deck(s) found
DECK_CORE: Calling INIT on driver bcFlow2 for deck 0
ZR2: Z-down sensor [OK]
So something seems off with your multiranger deck. Could you try logging with just that one attached?
soso
Beginner
Posts: 5
Joined: Tue Dec 28, 2021 2:30 am

Re: MultiRanger Expansion Deck reading 0s

Post by soso »

Thanks for the reply. I had the orientation of the multiranger flipped and that's why it wasn't being recognized. After correcting the orientation, the ranger started to read the values correctly. However, I am running into another issue now.

The left sensor of the multiranger consistently fails upon initialization which causes the crazyflie to fail on start. What can be done to remedy this?

Thank you!
Post Reply