adafruit / Adafruit_WICED_Arduino

Adafruit WICED Feather Arduino BSP
https://www.adafruit.com/products/3056
27 stars 19 forks source link

DAC example doesn't work #53

Closed hathach closed 8 years ago

hathach commented 8 years ago

https://forums.adafruit.com/viewtopic.php?f=57&t=100553

code https://gist.github.com/kelu124/fa014ae6c96b7006268d37c72aa64bf7

kelu124 commented 8 years ago

Thanks for this quick follow-up! If you have tips, I'd be glad to contribute.

hathach commented 8 years ago

mcu's peripherals code is based on https://github.com/rogerclarkmelbourne/Arduino_STM32 , but it could be our modification's bug as well. Unfortunately, we are working on another project, please give us a bit of time to troubleshoot the issue.

PS: I would be helpful if you could provide the sketch that reproduce the issue, just to make sure we are working on the same piece of code.

kelu124 commented 8 years ago

No issues! Yes, the code was the gist included. No signal of any sort on any of the two DAC outputs.

kelu124 commented 8 years ago

You said you managed to plug a LED and see the waveform on the LED, did you manage to get the waveform on a oscillo? If so, can you confirm you were using the stock .ino file?

hathach commented 8 years ago

I plug the LED and saw it is at ~ 30-40% brightness, I guess the example sketch produce some kind of waveform, but isn't sure.

Google "Arduino Sawtooth" lead to this page https://www.baldengineer.com/sawtooth-waveform-with-the-arduino-dues-built-in-dac.html

sawtooth-banner

Unfortunately, I have no access to an oscillo just yet to confirm it. I will ask others at Adafruit to confirm it later.

kelu124 commented 8 years ago

Back here, have tried on another computer, and now seems to work (snipped here) gives what I expect.

I'll just be noting that DAC values below 128 are somehow tricky to work with, as they do not appear on the bitscope measuring.

hathach commented 8 years ago

thanks for confirmation, at least it is not useless at all :) , we are new with STM32 chip as well.

hathach commented 8 years ago

For DAC value below 128, maybe we should open an different issue. Please update the forum to let others know if it work for you now, thanks @kelu124