Jump to content

speed - refresh rate dout pins


kapser
 Share

Recommended Posts

I want program a POV ( spinning leds ) application with MIOS_C. So I need to switch leds on/off with a very high speed. What kind of speeds can I achieve ? Does it depend on the amount of outputs ( I want to use all the 128 pins ). I calculated that I need a refreshrate of about 25kHz ( 38 us ).

Any tips or things people experienced. Or do I just have to start programming and measuring the outputs with a scope ?

Link to comment
Share on other sites

The DOUT registers are refreshed at 1 mS maximum, if you need higher frequencies, you need to write an own SR handler which is doing this (and nothing else) from the main thread (-> Tick()). The scan matrix examples are a good template, how to realize this.

Best Regards, Thorsten.

Link to comment
Share on other sites

Addendum: since the high update rate must be guaranteed for really good results, the MIOS ISRs should not run in background, the program should just loop itself. I'm also not sure, if programming this in C is a good choice, with assembly you would have better timings.

The MBHP_TV application is maybe a good programming example for such applications, it generates a TV picture which *must* be 100% accurate to the scanline frequency

Best Regards, Thorsten.

Link to comment
Share on other sites

Hi Kapser,

I 've made a POV display at school, with most code written in C

we used a 8051 micro so I'm sure this should work on a pic processor

(our processor was quite slow and limited)

PM me if you need help with anything

I can mail you our source if you want

Michaël

Link to comment
Share on other sites

Thank you for the fast answers. So if I understand it all well, its better to start with programming the PIC from scratch and not using the MIOS software (IRS?) at all ?

I wanted to use some midi control of the POV and doing some stuff on the BPM. It seemed to my it was easier to take the MIOS platform as basis ( as it already implements a lot of midi stuff of course ).

Any resources on programming assembly ?

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...