ButterFlight / butterflight

GNU General Public License v3.0
106 stars 26 forks source link

strixf10 beeper wont work from aux and curr pad doesnt show reading #252

Open JustinBluntFPV opened 5 years ago

JustinBluntFPV commented 5 years ago

I cant find which pin the beeper is resourced to and the curr pad wont show a reading when connected to my Matek XT60 w/ external current sensor. resource list shows adc_curr 1 a0, but when i resource it to pin a01 and then save, it doesnt save/keep. unfortunately its a strixf10 board running the latest butterflight and IMU-F.

lorentzm commented 5 years ago

I had a look at this today since I'm still annoyed that the beeper doesn't work. It was a super simple fix, I'll copy the diff below. However, I don't have access to push a branch and open a pull request on the repo and I couldn't get the Slack invite to work so I can talk to someone about getting the fix pull requested.


diff --git a/src/main/target/STRIXF10/target.h b/src/main/target/STRIXF10/target.h
index e5ceec458..d05e012be 100644
--- a/src/main/target/STRIXF10/target.h
+++ b/src/main/target/STRIXF10/target.h
@@ -22,7 +22,8 @@

  #define LED0_PIN                PB7

- #define BEEPER                  PC15
+ #define USE_BEEPER
+ #define BEEPER_PIN              PC15
  #define BEEPER_INVERTED

  #define USE_GYRO
daehani79 commented 5 years ago

@lorentzm Perfectly work!! Thank you!

mmakam2 commented 5 years ago

I am also having issues with the current pad. Not sure how to get it to work, tried everything, If anyone has gotten it to work, please share config.

lorentzm commented 5 years ago

The current pad was working for me. I was using an Aikon AK 32 4-in-1 which for some reason has noise on the current output when using DSHOT but not when using ONESHOT. So, I wouldn't get anything useful for current when using DSHOT but got correct readings with ONESHOT. I was able to clean up the noise and use DSHOT by soldering a 10000pf 50V cap between the current pad and the ground on the STRIXF10 board.

mmakam2 commented 5 years ago

can you please share your config?

mmakam2 commented 5 years ago

I'm seeing activity on onboard adc.even when esc is disconnected from current pad, am I supposed to use that or msp sensor?

lorentzm commented 5 years ago

I killed my board putting it in a different quad yesterday :( But current was working from the current pad by using "Onboard ADC".

mmakam2 commented 5 years ago

ok thanks, did you have to remap any resources?

lorentzm commented 5 years ago

No resources needed remapping.