RLP on Raptor - seeking advice

Hello,
I need to develop a system that will count pulses from two sources. I want to use a Raptor with two pulse count modules. The pulse count values will be read when a high voltage is found either from a switch or from a frequency output by a turbine. This will be a pulse interpolation system for a liquid prover being used to calibrate turbines on a liquid system. C# is not going to be fast enough even if I disable GC by using only static memory allocation. I have written some simple RLP programs before and this is going be pretty basic as well.

I am seeking advice as I start out. Simon from Vilnius recommends Emblocks instead of Yagarto. Does anyone else have an opinion on this matter that they would share? Is Raptor the best platform? At this point I can change platform but I wanted the fastest processor to ensure success in this effort. Accessing the counts from the pulse count modules seems like something I can do as well.

Anyway, I value your opinions on this matter. Thank you.

There is a thread somewhere here where @ Duke Nukem compared speeds of different boards. Don’t remember which boards though.

@ Bill_Wyo - Interesting project, I not sure what requirement causes you to consider “C” and RPL.
Is it the frequency of the pulses from flow prover? The pulse counter (LS7366R) should be able to handle a wide range, the datasheet, states 20Mhz at 3 V.

How many times a second (or some other period) do you need to read the pulse counter?

Do you need non-quadrature or quadrature mode? I recently used quadrature mode on a noisy tacho signal from a BLDC motor controller, really made a difference differentiating between the tacho signal and lots for 5 nS pulses that where also emitted at some speeds.

Is there a large amount of CPU bound calculations required?

A time signal at 2 MHz is one of the pulse inputs. When a prover start signal is received the counts on the time pulse count module will be read. Then a turbine at about 100 Hz will be polled until a rising edge is detected. The time pulse count module will be read again as well as the pulse count module connected to the turbine. When the prover stop signal is received the counts on the time pulse module will be read. At the next turbine rising edge the time pulse module will be read and the counts at the turbine pulse module. 4 time reads and two turbine pulse count reads. The system uncertainty is very low which is why the 2 MHz time signal is required. These systems are available commercially but they are hard to interface with the data acquisition systems we use.

I do not need quadrature. Once the reads are finished then calculations can be performed in C#.

@ Bill_Wyo - Thanks for the detailed description, this thread may be of interest, it is an ADC but done in RPL on a G120 with some performance numbers achieved.
[url]https://www.ghielectronics.com/community/forum/topic?id=21877&page=1#msg204822[/url]

Good luck!

Hey Phitek,
Thanks for the link. Looks really useful. I appreciate the response. I will probably proceed with Yagarto as that is what I have used previously. I will look for the info that Architect referred to just to see if Raptor is the correct platform to use.

Yagarto ir deprecated by its creator, so you’ll either have to dig archives or use something else…

@ Simon from Vilnius - Well I guess that changes things. I assume you still recommend EmBlocks?

@ Bill_Wyo - Yes, I use it personally. If you look into my manual, note that G400 needs an updated RLP.h file (GHI changed address ranges in the latest update). G120 file should be fine.

@ Simon from Vilnius - I installed EmBitz and your template loaded nicely. Thanks for the heads up about the address.

@ Simon from Vilnius - I have a couple AD9850 function generator modules and a couple Cerbuino Bees, I think your template is going to entice me to play with this hardware. Thanks Simon!

Thanks, and good luck! :slight_smile: