goebish / nrf24_multipro

nRF24L01 multi-protocol RC transmitter
GNU General Public License v3.0
472 stars 195 forks source link

eachaine h8 mini (blue board) #25

Open alexkwinto opened 7 years ago

alexkwinto commented 7 years ago

Hi,

is seems that h8 mini (blue board) has changed the protocol. Is there any way to check it?

Alex

goebish commented 7 years ago

Where did you read that ? All the blue boards I've seen are using the same protocol than the green ones.

alexkwinto commented 7 years ago

just an assuption by failing to connect =) that is why i'm looking for a way to check it.

goebish commented 7 years ago

Have you checked your module with another machine ?

alexkwinto commented 7 years ago

no, i have no other copters to check. so yes the problem might be in my build

goebish commented 7 years ago

Yes, triple check your wiring, make sure you give only 3.3 Vcc to the nrf24l01, and depending of the transmitter you're using you probably have to adapt the level of the PPM output to 0-3.3V.

alexkwinto commented 7 years ago

i'm overrided protocol selection to bind to copter regardless the ppm values. is there a way to check arduino-nrf24 connection?

goebish commented 7 years ago

yes, check if NRF24L01_Reset() returns 1.

alexkwinto commented 7 years ago

TY, i will check it in few days and will let you know.

alexkwinto commented 7 years ago

hi again, NRF24L01_Reset() returns zero. im using arduino uno to debug and printing to port monitor

alexkwinto commented 7 years ago

ok i found the issue! THank you kindly!

goebish commented 7 years ago

Cool, can you explain the issue you had ?

alexkwinto commented 7 years ago

connection order( but now i can see an other issue - on low throlette the motors spinnig with interrupts

alexkwinto commented 7 years ago

also on hight trollette, can this be a connection interrupt or something?

goebish commented 7 years ago

Check your antenna, also, if you're using a nrf24l01 module with PA+LNA the 3.3V output of your Uno might not be able to provide enough current. In this case you can try a lower RF output power.

alexkwinto commented 7 years ago

no im powering nrf24l01 with separated 3.3v bec. i checked the operating voltage -3.29 so shoud be fine. also found some trolette action when the thorelette at minimum, if you need i can make a video to show.

goebish commented 7 years ago

Maybe the problem is your PPM output then, have you checked its voltage (with a scope, this can't be done with a simple multimeter ...) Which transmitter are you using ?

alexkwinto commented 7 years ago

i dont have a scope to check it, the only way on my mind to debug it is to print throlette values to the port monitor of arduino IDE.

goebish commented 7 years ago

Yes you can try that, but try to display the value only once per second for example (in update_ppm()), because I think using the UART too much will mess with PPM interrupt.

alexkwinto commented 7 years ago

can you please advice how to do that? im not that good with time delayed tasks. also what is a good place in code to set prints?

goebish commented 7 years ago

put that at the end of update_ppm:

static uint32_t next=0; if(millis() > next) { next = millis()+1000; println(ppm[THROTTLE]); }

alexkwinto commented 7 years ago

yes the numbers are not stable:

1252 1186 1414 1199 1415 1187 1414 1414 1011 1000 1413 1000 1414 1414 1414

goebish commented 7 years ago

Which transmitter are you using ? You need to adapt the level of the PPM output (in hardware).

alexkwinto commented 7 years ago

AT9

goebish commented 7 years ago

Do you have a n-mosfet handy ?

alexkwinto commented 7 years ago

yes STN4NF20L, it is supplyed with 3.3 BEC througth the 10k resistors on vcc and ppm

goebish commented 7 years ago

Here's a schematics, it should work with virtually any small power n-channel mosfet, such as the ones used to drive the motors in small toy quads. http://i.imgur.com/Km99vxX.png

If you do not have a n-mosfet you can try to make a voltage divider with 2 resistors, but I can't recommend a ratio for the 2 resistor as I've no idea of the voltage of your PPM output. The n-mosfet solution is more universal.

goebish commented 7 years ago

the 4NF20L should be fine, its Gate threshold voltage is low enough.

alexkwinto commented 7 years ago

also the ppm signal is stable as i checked it with simulator flights

goebish commented 7 years ago

On some transmitters, the PPM output is open drain, in this case, try to add a 10K resistor between PPM output (PPM_IN in the schematics) and +3.3V to pull it up.

alexkwinto commented 7 years ago

i added 10K resistor to pull up, if i use your print it looks fine but if i print more often sometimes i can see that:

1373 1000 1000 1000 1373 1373 1373 1373 1365 1365 1365 1374 1374 1374 1374 1374

goebish commented 7 years ago

Have you tried to add a pullup resistor on the PPM output (transmitter side) ?

alexkwinto commented 7 years ago

i added it only ppm-3v3

goebish commented 7 years ago

yes, also add one on the fet's gate, 3.3V ------[10K]------Gate

alexkwinto commented 7 years ago

as i said it was done

goebish commented 7 years ago

No idea then, you might ask to this guy, he got the module to work with his AT9: https://github.com/Sulya/nrf24_multipro_Radiolink

alexkwinto commented 7 years ago

ok still a BIG thank you! offtopic: do you know were i can take a look at h8 mini scematics? seems one of the motor leading transistors is dead.

goebish commented 7 years ago

Just replace the fet that's next to the non working (or always on) motor, IRLML2502 is a good candidate, better replace all 4 so they're the same. You can find some H8 mini experts here: https://www.rcgroups.com/forums/showthread.php?2512604-Eachine-H8-mini-acro-firmware ;)

alexkwinto commented 7 years ago

thank you again. an other offtopic question - have you met the issues with programming arduino pro mini?

goebish commented 7 years ago

I've programmed hundreds of pro-mini with this firmware without issues.

alexkwinto commented 7 years ago

my is not programming with FTDI or arduino isp

goebish commented 7 years ago

Maybe it's defective, I get mines in batches of 50pcs, sometime I find a few duds, this hasn't happened for months tho. Usually this is because the oscillator has bad soldering, only once I found one with a defective m328, it could be programmed with ISP, but not with the arduino bootloader, Tx or Rx pin wasn't connected internally.

alexkwinto commented 7 years ago

i think in that case i will just replace it with atmega328 and external quartz

goebish commented 7 years ago

Yeah you can do that, I like the pro-mini, it's small, easy to work with, and it doesn't cost more (sometime even less!) than a bare chip + crystal.