- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello
I have a developer board with a dht11 (umidity & temperature sensor)
How can I get the information ,maybe samplee code
like this one ?
wiced_gpio_input_get( WICED_GPIO_XX)
Solved! Go to Solution.
- Tags:
- gpio inputs
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Or you can use the higher-level APIs like wiced_gpio_init and wiced_gpio_deinit to switch back and forth between output and input
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Which board are you using? Please take a look at our sample GPIO app in <SDK>/snip/gpio/gpio.c which toggles the GPIO out and read GPIO in.
Thanks,
Jaeyoung
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I use the Board BCM94343W_AVN and i have a DHT11
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You should check the DHT11 datasheet how to read the temp/humility from DHT 11!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Currently this is not a straightforward task since the DHT11 is a single wire serial sensor and requires switching between output and input for control and read.
So in your case in the platform.c for the BCM94343W_AVN platform, you will have to write support for switching the GPIO for the IO you are using.
platform_gpio_init can be used to switch between output and input modes
and then platform_gpio_input_high, platfom_gpio_input_low and platform_gpio_input_get will have to be used to implement the DHT11 driver library
Currently we don't have sample code for this, but it is not too difficult for you to implement this on your own.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Or you can use the higher-level APIs like wiced_gpio_init and wiced_gpio_deinit to switch back and forth between output and input