Applicability of PyBoard

General discussions and questions abound development of code with MicroPython that is not hardware specific.
Target audience: MicroPython Users.
Post Reply
VHD
Posts: 3
Joined: Mon Feb 27, 2017 2:30 pm

Applicability of PyBoard

Post by VHD » Mon Feb 27, 2017 2:45 pm

Greetings:

Before diving into pyboard and Micropython, I wanted to check the applicability of this microcontroller for an application that I want to port over.

I have 10 high speed pneumatically actuated valves, 24 volts 4 watts that I would like to control. One or more valves will need to actuated with approximately 100 ms pulses and the pulse sequence must be timed very precisely this sequence may need to run for 1000 or more cycles.

I also have 4 pressure transducers with a 0-10 output. I probably will have to use a voltage divider to capture this data.

I also have 2 TC imputs.

I would like to stream the input values and save them to a log file while also plotting them real time using something like Bokeh.

I would like to control all of this using Bokeh's JS widgets or through my python shell, not the native on-board micropython.

Is this an appropriate platform for me to accomplish these needs. I like the pyboard because it is python native and I currently have the setup using a Labjack and my control is through python and Bokeh. I want to really go open source and build my application streamlined with exactly the needs that I have.

Thanks.

VHD

User avatar
dhylands
Posts: 3821
Joined: Mon Jan 06, 2014 6:08 pm
Location: Peachland, BC, Canada
Contact:

Re: Applicability of PyBoard

Post by dhylands » Mon Feb 27, 2017 4:42 pm

Without knowing specifics, it sounds doable. MicroPython also has inline assembler, and if really needed you can create a module in C.

Obviously you're going to need a bunch of interface circuitry. There are hardware timers which can be used to help make precise pulses.

VHD
Posts: 3
Joined: Mon Feb 27, 2017 2:30 pm

Re: Applicability of PyBoard

Post by VHD » Mon Feb 27, 2017 6:40 pm

Thanks Dave:

A few questions:

1) Can I not use the pyboard's internal clock to create my precise pulses?
2) The pyboard is limited in the total number of ADCs to three, is there an expansion board you would recommend?

Thanks.

VHD

User avatar
dhylands
Posts: 3821
Joined: Mon Jan 06, 2014 6:08 pm
Location: Peachland, BC, Canada
Contact:

Re: Applicability of PyBoard

Post by dhylands » Mon Feb 27, 2017 7:39 pm

VHD wrote:Thanks Dave:

A few questions:

1) Can I not use the pyboard's internal clock to create my precise pulses?
I guess it all depends on your definition of precise. Using the timers allows you get right down to the precision of the source frequency used to drive them, 43 MHz or 84 MHz.

You can also generate the pulses purely using software, but they'll be less precise and have a bit of jitter, but it all boils down to just how precise you need to be.
2) The pyboard is limited in the total number of ADCs to three, is there an expansion board you would recommend?
I'm not sure how you arrived at that. I see 12 ADC inputs on the pyboard quick reference: http://docs.micropython.org/en/latest/p ... ckref.html
If you want to use an external ADC, it really depends on your specifications.

VHD
Posts: 3
Joined: Mon Feb 27, 2017 2:30 pm

Re: Applicability of PyBoard

Post by VHD » Wed Mar 01, 2017 2:30 pm

Thanks Dave:

I'm pretty sure I'm going to have several questions as I build up this project. We are going opensource python for hardware microcontroller to build a DAQ and valve control for vapor deposited reactor operation.

This is pretty cool, and I look forward to working with the pyboard.

-VHD

Post Reply