Timeline for Communication between PIC18F26K80 and DAC7612
Current License: CC BY-SA 4.0
13 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Jun 22, 2021 at 11:53 | vote | accept | Untitled07 | ||
Jun 22, 2021 at 8:33 | comment | added | Untitled07 | ok Mike I didn't know that, thanks @polwel it's a code error, DamienD corrected me | |
Jun 22, 2021 at 5:17 | comment | added | Mike |
__delay() won't work with floating point numbers.
|
|
Jun 21, 2021 at 23:02 | comment | added | DamienWontContributeToAITheft | I've updated my answer to explain why you get these weird results | |
Jun 21, 2021 at 15:55 | comment | added | polwel | I don't follow your reasoning, but it is entirely irrelevant how many bits you send. The only thing that matters are the last 14 bits the moment LOADDACS is strobed. There is no reason why the SPI peripheral cannot be made to work here. | |
Jun 21, 2021 at 15:08 | comment | added | Untitled07 | Well @polwel , by sending two frames of 8 bits in SPI, I read a voltage in output but it is the mess. The output is either A and B (dac_value=0xPXXX where P ={0 - 2 - 4 - 6 - 8 - A - C - E}) or only B (dac_value=0xPXXX where P ={1 - 3 - 5 - 7 - 9 - B - D - F}). Thanks for your time. | |
Jun 21, 2021 at 14:06 | answer | added | DamienWontContributeToAITheft | timeline score: 0 | |
Jun 21, 2021 at 13:04 | history | edited | SamGibson♦ | CC BY-SA 4.0 |
appended answer 572164 as supplemental
|
Jun 21, 2021 at 12:15 | comment | added | polwel | If you send 16 bits, then the very first two will be clocked out and discarded. | |
Jun 21, 2021 at 12:03 | comment | added | Untitled07 | If I send two SPI frames, the DAC will receive 16 bits and not 14. I tried this code for the SPI communication but I still have nothing in output: | |
Jun 21, 2021 at 11:23 | comment | added | polwel | What makes you think that the SPI peripheral would not be suitable? Is it because 14 is not divisible by 8? | |
Jun 21, 2021 at 9:33 | review | First posts | |||
Jun 21, 2021 at 19:07 | |||||
Jun 21, 2021 at 9:27 | history | asked | Untitled07 | CC BY-SA 4.0 |