How to set alias for pin?

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
JoWi_3984961
Level 4
Level 4
First like received First like given

It used to work on one set of pins.  Now it does not work on any of the sets of pins.

Output pin with no internal HW connection.

Non-contiguous set of a handful of pins.

They have an index that generates names, but you are supposed to be able to also define an alias:

PIN_0    alias PIN_SHINNY

To quote the data sheet:

"""

If you provide an alias name in the Pins configuration dialog, then an additional #define is

created with the form:

Pin_<AliasName>

Either of these aliases can be used. For example, "Pin" has an <AliasName> called "MyAlias."

This generates aliases, Pin_0 and Pin_MyAlias. To read this pin using the per-pin API function,

you can use either of these methods:

CyPins_ReadPin(Pin_0)

CyPins_ReadPin(Pin_MyAlias)

"""

Great idea.  Now, what does it take to make this work?

0 Likes
1 Solution

I figured it. All the pins are selected. You have to “click off” so only one pin is selected. Clicking or double clicking on a pin when all are selected does NOTHING.

Once only one pin is selected, it works normally.

I spent all my time clicking off.

When actually I’d rather golf.

If you don’t fix the IDE,

And the programmers hide,

Your tools I'm afraid I must doff.

View solution in original post

0 Likes
2 Replies
LinglingG_46
Moderator
Moderator
Moderator
500 solutions authored 1000 replies posted 10 questions asked

Could you tell us what kind of chip do you use?

Which IDE do you use?

0 Likes

I figured it. All the pins are selected. You have to “click off” so only one pin is selected. Clicking or double clicking on a pin when all are selected does NOTHING.

Once only one pin is selected, it works normally.

I spent all my time clicking off.

When actually I’d rather golf.

If you don’t fix the IDE,

And the programmers hide,

Your tools I'm afraid I must doff.

0 Likes