Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

px4_fmuv4:Add Runtime SPI4 #11301

Merged
merged 7 commits into from
Jan 29, 2019
Merged

px4_fmuv4:Add Runtime SPI4 #11301

merged 7 commits into from
Jan 29, 2019

Conversation

davids5
Copy link
Member

@davids5 davids5 commented Jan 25, 2019

@dagar, @DanielePettenuzzo - Ready for test.

The build is built with SPI4. At run time the signal
GPIO_8266_GPIO2 it tested. If it is low the SPI4 is configured.
if it is high SPI4 is not configured.

@dagar - The mods to use the ESP module and SPI4. I would suggest making a cable to Y VDD3v3_PERIH and GND to both devices. The key here is to isolate ESP 8266 6, 5, 4, and 3 from FMU connector.

Mods
Wire FMU connector to SPI device:
1 - SPI device GND
3 - GOIO2 to GND - Signals board to enable SPI4 on this connector.
6 - SPI device MOSI
5 - SPI device CLK
4 - SPI device MSIO
8 - SPI device VDD3V3
10 - SPI device Chip Select

On ESP 8266
3 - Leave not connected.

On the ESP 8266 Connect pins 8 to 6 and 4 together.
Wire FMU connector to ESP 8266 :
1 - ESP 8266 Pin 1 GND
2 - ESP 8266 Pin 2 TxD
7 - ESP 8266 Pin 7 RxD
8 - ESP 8266 Pin 8 VDD3V3
10 - SPI device Chip Select
You must Isolate ESP 8266 6, 5, 4 and 3, from FMU connector.

image

// #error "add the required spi dev from board_config.h here"
// #endif

#define PMW3901_BUS PX4_SPI_BUS_EXTERNAL
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@dagar - thank you the is cloned here.

@davids5 davids5 force-pushed the master_fmuv4_runtime_spi4 branch from 5d170c0 to a2f5277 Compare January 25, 2019 23:23
@davids5 davids5 changed the title [WIP]px4_fmuv4:Add Runtime SPI4 px4_fmuv4:Add Runtime SPI4 Jan 25, 2019
@davids5
Copy link
Member Author

davids5 commented Jan 25, 2019

@DanielePettenuzzo @dagar - run time detections is ready to test.

When a ESP2866 is plugged in it should work and have no activity on
6 - SPI device MOSI
5 - SPI device CLK
4 - SPI device MSIO
10 - SPI device Chip Select

When wired as described here and

3 - GOIO2 to GND

SPI4 attached devices should work.

David Sidrane and others added 6 commits January 29, 2019 12:31
   The build is built with SPI4. At run time the signal
   GPIO_8266_GPIO2 it tested. If it is low the SPI4 is configred.
   if it is high SPI4 is not configured.

   We still need a call out in the driver start to test if the bus
   should be used. I.E manifest.
@dagar dagar force-pushed the master_fmuv4_runtime_spi4 branch from a2f5277 to da8eb74 Compare January 29, 2019 17:33
@dagar dagar added this to the Release v1.9.0 milestone Jan 29, 2019
*
************************************************************************************/

enum board_bus_types {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks good for now, but ultimately I'd like to see if we can unify this with Device (https://github.com/PX4/Firmware/blob/master/src/lib/drivers/device/Device.hpp) where we already have a notion of bus type.

@dagar dagar merged commit 6f9a9b3 into master Jan 29, 2019
@dagar dagar deleted the master_fmuv4_runtime_spi4 branch January 29, 2019 18:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants