Harsch-Systems / node-red-contrib-pi-plates

Control Pi-Plates from Node-RED
Apache License 2.0
6 stars 7 forks source link

ppDAC Node #4

Closed Murray274 closed 5 years ago

Murray274 commented 5 years ago

I was looking to use the DAQCPlate to provide an analog output (0-4V DC) to a Power controller. Am I missing something or has the ppDAQ Node not developed yet?

Murray274 commented 5 years ago

A day later and I now have a Pi plate relay plate working using a Python 3 Function Node. Yet to receive the DAQC plate. Can I submit the code I develop for the Digital to Analog conversion for you to use in your set of nodes? Or is it so simple that the node is not required?

pi-plates commented 5 years ago

Murray274, who did you order a DAQC from?

On Sat, Feb 2, 2019 at 5:34 AM Murray274 notifications@github.com wrote:

A day later and I now have a Pi plate relay plate working using a Python 3 Function Node. Yet to receive the DAQC plate. Can I submit the code I develop for the Digital to Analog conversion for you to use in your set of nodes? Or is it so simple that the node is not required?

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/mharsch/node-red-contrib-pi-plates/issues/4#issuecomment-459954505, or mute the thread https://github.com/notifications/unsubscribe-auth/AIAhAWSwr2bg14kaRwALlba01X8zUOtRks5vJWnNgaJpZM4admob .

-- Jerry Wasinger Pi-Plates.com

mharsch commented 5 years ago

@Murray274 this should be easy to add in. node-pi-plates will need support first, then this repo. Feel free to take a crack at it. Otherwise I should be able to get around to it in a few days.

Murray274 commented 5 years ago

I bought the DAQC from Mindkits in NZ but Element 14 (Farnell) has then listed. I have them working simply in Node-Red using the Python 3 node. Now I need to input a value to set the voltage rather than setting the voltage in the Python 3 node . More YouTube watching required to understand Python some more.

mharsch commented 5 years ago

@Murray274 I've added a ppDAC node along with support in the underlying pi-plates package. Could you try it out and let me know if it's working for you? You'll need to update node-red-contrib-pi-plates to the latest published version (0.0.5). This should update the underlying pi-plates package as well (to it's latest version which is 0.0.3).

pi-plates commented 5 years ago

Mike, will this work with the DACs on the DAQC2plate as well?

On Thu, Feb 7, 2019 at 11:34 AM Mike Harsch notifications@github.com wrote:

@Murray274 https://github.com/Murray274 I've added a ppDAC node along with support in the underlying pi-plates package. Could you try it out and let me know if it's working for you? You'll need to update node-red-contrib-pi-plates to the latest published version (0.0.5). This should update the underlying pi-plates package as well (to it's latest version which is 0.0.3).

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/mharsch/node-red-contrib-pi-plates/issues/4#issuecomment-461500950, or mute the thread https://github.com/notifications/unsubscribe-auth/AIAhAZnN03MbRdRubF8W8UrDAy3sTtT_ks5vLFWFgaJpZM4admob .

-- Jerry Wasinger Pi-Plates.com

mharsch commented 5 years ago

@pi-plates no, I haven't got around to implementing DAQC2 yet. See issue #1

Murray274 commented 5 years ago

Hi Mike. the new node is installed and running well. You do not note what should be on the Output. It looks to be the same as the input. Many thanks for your help

Murray274 commented 5 years ago

Hi Mike, I just inputted a negative value and received an error message on the output through a debug. Perfect Have you thought about providing a selection to give the user a choice of the output going to max or zero if an error occurs. I can stop the negative value with another node. The analog output has not changed in my case. Again I can provide a value of zero from the switch I use to inhibit the negative input so I have options. Just an idea.

mharsch commented 5 years ago

@Murray274 I think you're on the right track by using an upstream node (custom function) to filter the incoming values and apply whatever policy makes sense for your case. You could also use the range node if you need to scale an incoming value up or down to fit the DAC range.

mharsch commented 5 years ago

implemented in 3701d2bdf1ddcd8993e89897927dc477e8d32b73