Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
HubsanTx Class Reference
Class for communicating with a Hubsan X4 using the A7105TxRx library. More...
#include <HubsanTx.h>
Public Member Functions | |
| HubsanTx (PinName mosi, PinName miso, PinName clk, PinName cs, uint32_t freqHz) | |
| int8_t | init () |
| Initialize the A7105 to communicate with a Hubsan X4. | |
Detailed Description
Class for communicating with a Hubsan X4 using the A7105TxRx library.
Example:
#include "mbed.h" #include "HubsanTx.h" #define A7105_SPI_FREQUENCY 10000000 // 10MHz HubsanTx hubsan(D4, D5, D3, D6, A7105_SPI_FREQUENCY); int main() { // init hubsan.init(); }
Definition at line 34 of file HubsanTx.h.
Constructor & Destructor Documentation
| HubsanTx | ( | PinName | mosi, |
| PinName | miso, | ||
| PinName | clk, | ||
| PinName | cs, | ||
| uint32_t | freqHz | ||
| ) |
- Parameters:
-
mosi Pin used to transmit data to the slave miso Pin used to receive data from the slave clk Pin used for the clock cs Pin used for the chip select freqHz Frequency used to clock data in and out
Definition at line 4 of file HubsanTx.cpp.
Member Function Documentation
| int8_t init | ( | ) |
Initialize the A7105 to communicate with a Hubsan X4.
Definition at line 8 of file HubsanTx.cpp.
Generated on Sun Jul 17 2022 01:39:15 by
1.7.2