Go to advanced search

by eslavko
Fri Jul 03, 2020 12:36 pm
Forum: General discussion
Topic: PIGPIO longest wave?
Replies: 2
Views: 110

Re: PIGPIO longest wave?

p.s.
In the test I generate only square wave. This is only in test. I had complex waveform in real situation.
by eslavko
Fri Jul 03, 2020 12:35 pm
Forum: General discussion
Topic: PIGPIO longest wave?
Replies: 2
Views: 110

PIGPIO longest wave?

Hello... What is longest wave that can be generated as one wave? I hit boundary at 2730 samples but there are still a lot of CBs free. Seems that socket limit the number of samples. Can we make it longer? Here is my test program: #!/usr/bin/env python import pigpio import time pin=6 pi = pigpio.pi('...
by eslavko
Wed Jul 01, 2020 2:07 pm
Forum: General discussion
Topic: PIGPIOd custom DMA CB.
Replies: 4
Views: 195

Re: PIGPIOd custom DMA CB.

You would have to add that yourself. pigpio reads and writes the GPIO level registers and reads the clock register. You would need to write to the mode register. I know that I need to do write in mode register. But is it possible to do that at all without recompiling? I didn't dig into source but k...
by eslavko
Wed Jul 01, 2020 1:10 pm
Forum: General discussion
Topic: PIGPIOd custom DMA CB.
Replies: 4
Views: 195

PIGPIOd custom DMA CB.

Hello...

Is it there some way to create custom DMA Control Block to be used with wave_chain?
Instead to DMA sample to GPIO I wish to write sample to other address (direction register)
by eslavko
Wed Jul 01, 2020 12:32 pm
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: GPIO fastest way to switch from OUTPUT to INPUT
Replies: 2
Views: 210

Re: GPIO fastest way to switch from OUTPUT to INPUT

Yes the application runs in python but as script I mean script for pigpiod daemon. http://abyz.me.uk/rpi/pigpio/python.html#run_script so they should be fast. As I read using one core for time critical program is option but even there can be glitch longer than 10us and that is not good. Seems that t...
by eslavko
Wed Jul 01, 2020 7:33 am
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: GPIO fastest way to switch from OUTPUT to INPUT
Replies: 2
Views: 210

GPIO fastest way to switch from OUTPUT to INPUT

Hello... I have some special serial transmission and that use single wire with half duplex. So I need to switch gpio from output to input after transmission. And I need to do that fast! For now I do transmission with gpio create_wave and encode data to it. And I have script where I switch pin from o...
by eslavko
Mon Jun 22, 2020 7:22 pm
Forum: General discussion
Topic: PIGPIO jitterless wave generation.
Replies: 38
Views: 1212

Re: PIGPIO jitterless wave generation.

the main problem in terms of uart, is that it returns low during hsync/vsync, which is invalid, other waveforms may not have that issue That's will wreck my waveforms. I don't know why on the world I expect to keep last level before sync. May be able to cope that for Vsync but for sure not for hsyn...
by eslavko
Mon Jun 22, 2020 6:20 pm
Forum: General discussion
Topic: PIGPIO jitterless wave generation.
Replies: 38
Views: 1212

Re: PIGPIO jitterless wave generation.

joan wrote:
Mon Jun 22, 2020 6:15 pm
eslavko wrote:
Mon Jun 22, 2020 6:08 pm
Confrimed.

I try versions 69, 73, 75 and 76.

Only v 76 behave wrong!!!
Thanks for that. Do raise an issue (if you haven't already).
allready done
https://github.com/joan2937/pigpio/issues/363
by eslavko
Mon Jun 22, 2020 6:19 pm
Forum: General discussion
Topic: PIGPIO jitterless wave generation.
Replies: 38
Views: 1212

Re: PIGPIO jitterless wave generation.

Question about wave_send_using_mode! If I run wave with WAVE_MODE_REPEAT or WAVE_MODE_REPEAT_SYNC I get my wave running "permanently" Now if I create new wave and start it with WAVE_MODE_REPEAT_SYNC what exact will hapend? 1-Previous wave is terminated imediatly and new one started 2-Previous wave i...
by eslavko
Mon Jun 22, 2020 6:08 pm
Forum: General discussion
Topic: PIGPIO jitterless wave generation.
Replies: 38
Views: 1212

Re: PIGPIO jitterless wave generation.

Confrimed.

I try versions 69, 73, 75 and 76.

Only v 76 behave wrong!!!
by eslavko
Mon Jun 22, 2020 5:45 pm
Forum: General discussion
Topic: pigpio wave corruption
Replies: 9
Views: 324

Re: pigpio wave corruption

Well that increasing time instread of repeated writes sounds good practice to me. As for pigpio version, I just use the version that comes built in to raspbian. In days of old I used to just install with apt rather than pip as that way updates are part of automatic updating: [codesudo apt install ]...
by eslavko
Mon Jun 22, 2020 5:07 pm
Forum: General discussion
Topic: PIGPIO jitterless wave generation.
Replies: 38
Views: 1212

Re: PIGPIO jitterless wave generation.

I think pootle's stuff is to drive steppers which is probably closer to what the OP wants.. Well it's in reality close to stepper generator. But I can't find error in my code. Strange to be BUG but from my point of view seems to. Maybe I have wrecked pigpio install. As I remember I do install with ...
by eslavko
Mon Jun 22, 2020 2:53 pm
Forum: General discussion
Topic: pigpio wave corruption
Replies: 9
Views: 324

Re: pigpio wave corruption

...I miss you note about repeat.
I posted stripped waveform where values indeed is repeated. Even in my full generator sometime the value is repeated. The original value has 4000 entry's and around 30 of them have multiple write.
I assume that same point write should extend time to twice.
by eslavko
Mon Jun 22, 2020 2:47 pm
Forum: General discussion
Topic: pigpio wave corruption
Replies: 9
Views: 324

Re: pigpio wave corruption

I do similar but got wave corrupted before I actually start it.
I posted as issue here..
https://github.com/joan2937/pigpio/issues/363

Now I wondering if I maybe have version mismatch.
Can you tell me your versions?

at my system:

print pi.get_pigpio_version()
76

print pigpio.VERSION
1.46
by eslavko
Mon Jun 22, 2020 12:38 pm
Forum: General discussion
Topic: PIGPIO jitterless wave generation.
Replies: 38
Views: 1212

Re: PIGPIO jitterless wave generation.

So If I use resolution of 50x2000 pixels @ 5MHz clock I got: 49 samples for each line and 1 hsync (this should be 200ns for sample=10us per line) and 1999 active lines and one line as vsync so complete frame is 20ms. On that frame I can't aces 200ns each 10us, and can't aces 10us each 20ms. and prob...
by eslavko
Mon Jun 22, 2020 11:42 am
Forum: General discussion
Topic: PIGPIO pi instance has no attribute 'wave_create_and_pad'
Replies: 9
Views: 225

Re: PIGPIO pi instance has no attribute 'wave_create_and_pad'

Ahh found it...

I tried with print pigpio.__version__, but print pigpio.VERSION is correct.
And it's 1.46
by eslavko
Mon Jun 22, 2020 11:38 am
Forum: General discussion
Topic: PIGPIO pi instance has no attribute 'wave_create_and_pad'
Replies: 9
Views: 225

Re: PIGPIO pi instance has no attribute 'wave_create_and_pad'

I miss that you ask for python library. I assume it's replaced when I build code.
How to check that version ?
by eslavko
Mon Jun 22, 2020 10:30 am
Forum: General discussion
Topic: pigpio wave corruption
Replies: 9
Views: 324

Re: pigpio wave corruption

I found this unexpected behaviour of wave. I do generate two square waves one of 50Hz and other 100Hz as one wave. Then I create wave twice with same data (doesn't same efect with different) and when I play the 1st generated wave they came out corrupted and second one came out as should. I do captur...
by eslavko
Mon Jun 22, 2020 9:25 am
Forum: General discussion
Topic: pigpio wave corruption
Replies: 9
Views: 324

Re: pigpio wave corruption

I do some more tests and find verid response. I create two waves from same data (nonsense) and play them. Like this: wave=getWave() #get wave data from sub pi.wave_tx_stop() # stop waveform pi.wave_clear() # clear any existing waveforms pi.wave_add_generic(wave) # add waves sWave = pi.wave_create() ...
by eslavko
Mon Jun 22, 2020 9:00 am
Forum: General discussion
Topic: pigpio wave corruption
Replies: 9
Views: 324

Re: pigpio wave corruption

that's funny too... I do create wave and add twice to pigpio. The 1st one get corrupted! pi.wave_tx_stop() # stop waveform pi.wave_clear() # clear any existing waveforms pi.wave_add_generic(sineWaves) # PDM sine waves sWave = pi.wave_create() # create and save id pi.wave_add_generic(sineWaves) # PDM...
by eslavko
Mon Jun 22, 2020 8:51 am
Forum: General discussion
Topic: PIGPIO jitterless wave generation.
Replies: 38
Views: 1212

Re: PIGPIO jitterless wave generation.

Joan I was thinking like that. Is it possible at all? pi.wave_chain([ 255, 0, #main loop 255, 0, sinegen, 255, 1, 25, 0, #make 25 lops of sinegen (25x20ms=0.5s) sinegen, serial #add 20ms of sinegen + serial data 255, 3 #loop forever So waves are generated continous. Each half of second the serial da...
by eslavko
Mon Jun 22, 2020 8:08 am
Forum: General discussion
Topic: pigpio wave corruption
Replies: 9
Views: 324

pigpio wave corruption

Hello... When I try to do more complex output I got into trouble. The wave get corrupted somehow. I do generate complex sine waves like this. (the wave generator is omited for clearity) sineWaves=[] for i in range(2000): sineWaves.append(pigpio.pulse(...some data...)) sineWaves1=[] for i in range(20...
by eslavko
Mon Jun 22, 2020 6:51 am
Forum: General discussion
Topic: PIGPIO jitterless wave generation.
Replies: 38
Views: 1212

Re: PIGPIO jitterless wave generation.

That's seems nice but not for my project. I have data that are 20ms long and that must loop. The max time when all pins are in steady state is 12us. So I need frame buffer to be 20ms long and sync cannot be longer than 12us. And I need to change buffer on the fly. Does DPI have double buffering? I n...
by eslavko
Sun Jun 21, 2020 6:52 am
Forum: General discussion
Topic: PIGPIO jitterless wave generation.
Replies: 38
Views: 1212

Re: PIGPIO jitterless wave generation.

More questions about DPI.

1. If I understand correctly in time of vsync there is gap in stream (bad).
2. Can DPI be clocked under 5MHz.
3. When doing that pi can not be attached to monitor or DPI can have "other" frame buffer.
by eslavko
Sat Jun 20, 2020 6:26 pm
Forum: General discussion
Topic: PIGPIO jitterless wave generation.
Replies: 38
Views: 1212

Re: PIGPIO jitterless wave generation.

As I already write. I'm able to create waveform for generating 9 sinewaves. I do generate one period and then loop it with pi.wave_send_repeat. Work fine. sampling is done at 1MHz and that's fine for 50Hz sinewave. I can create serial data (with RS485 enable signal) and send with pi.wave_send_once. ...

Go to advanced search