Jump to content

DOUT #2 : how to address it ?


goule

Recommended Posts

Hi Goule,

there are several possibilities. By using the MIOS_DOUT_PinSet function, you can address the appr. outputs with pin number 8-15.

With the MIOS_DOUT_SRSet function, you can write all 8 pins with a single function call - the SR number is 1 in this case (we are counting from 0)

A pintable can be found here: http://www.midibox.org/dokuwiki/doku.php?id=din_dout_pintable

Best Regards, Thorsten.

Link to comment
Share on other sites

Hi Thorsten, always great to have an answer directly from the technical father  ;D

I don't want to address the second shift register, I want to access the first shift register of the second DOUT module connected to te first one. So reading the pintable, I guess I can do it with MIOS_DOUT_PinSetX(32) .. MIOS_DOUT_PinSetX(63) ?

Is there a particular goal using MIOS_DOUT_SRSet function, for instance lighting up 8 leds in one single step ? Any other trick about that function that is frequently used ?

Last question : I could not find the schematics for connecting J2 of 1st DOUT to J1 of 2nd DOUT. I made completely parallel connexions : was that right ?

Thanks again, this project brings a lot of fun everyday !

Please tell me if by chance you come to Paris, one never knows !

Goule

Link to comment
Share on other sites

Okay, I understand my strange behaviours of my DOUT #2 : I still had :

MIOS_SRIO_NumberSet( 4 )

instead of :

MIOS_SRIO_NumberSet( 8 )

Now everything seems to work perfect !

But I'm still curious about SRSet function if you can give me the answer  ;D

Bye crew,

Goule

Link to comment
Share on other sites

The SRSet function is just the fastest way to change 8 bits at once. This is useful when setting patterns (-> time multiplexed circuits, like LED digits or LED rings), and it's useful if the state of digital outputs is mirrored somewhere in the application (useful if you want to switch between two or more "layers")

Best Regards, Thorsten.

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...
×
×
  • Create New...