If this is your first visit, be sure to
check out the FAQ by clicking the
link above. You may have to register
before you can post: click the register link above to proceed. To start viewing messages,
select the forum that you want to visit from the selection below.

In the webpage here for appnote AN1212 "Using USB Keyboard with an Embedded Host" I see that 18F26J50 and 18F26J53 are listed as applicable Pic devices but nothing in either datasheet would indicate that those devices were Host (as opposed to Device) capable. Is this just an error or is there some explanation? Anyone?

They can of course function as a HID
But why do you want to use a keyboard as a HOST?
Regards, Harm

Hi,
I have 16 ir leds to drive. The issue is I want as part of the development to have a adjustment of the brightness as I could flood the receivers.
The part is https://datasheet.lcsc.com/szlcsc/Everlight-Elec-IR17-21C-TR8_C131250.pdf
My supply V is either 12v or 5v. My system uses a number of boards talking back to a main controller. I...

For the initial test I would consider 4 lines of 4 in series / parallel and an LM317 in constant current mode.
If you want PIC control over the intensity then a PIC with an internal op-amp followed by a MosFET.
just search for constant current.
There was an LCD back light circuit I used previously that used a switching regulator and...

Hi All
I Just want to check if this family of devices are fully supported in Proton 24 (24FJ256GA702/4/5). Has anyone used them with their various features and functions etc?
I see they are in the .PPI files but, I would like to just check with other members if they have used the variants in the family group before purchasing samples, they are...

Hi All
I Just want to check if this family of devices are fully supported in Proton 24 (24FJ256GA702/4/5). Has anyone used them with their various features and functions etc?
I see they are in the .PPI files but, I would like to just check with other members if they have used the variants in the family group before purchasing samples, they are...

ignore this post I've found an error in the table (256)
I have a cdata table in my program. It has 360 entries (indeed, full circle).
I preceded it with an Org statement just to be sure
Now something very strange happend. When I read the .lst file I see what I think is some kind of anomaly
CData 234,235,236,237 ;60
CData 238,239,241,242...

The value 256 is not an 8-bit value, so the compiler has changed the asm directive to .word:
.byte 0xff,0xff,0xff,0xff
;
;
.word 0xff,0xff,256,0xff
8-bit values are converted to hex in the data listing, but greater value are left as decimal. I'll take a look in my notes to see why I converted 8-bit to hex, but I think I remember...

johngb has just uploaded Proton Studio - 1.0.2.1!
Two changes of significance:
Improved Keyword capitalisation - now responds immediately to changes in Options.
Improved Keyword Hints -now rendered in HTML and will appear exactly as they

John, the 64-bit version of Proton studio installs as 1.0.2.0 not 1.0.2.1
Cheers,
Bob

Hi Friends,
A very interesting project has come my way.
A company is putting up a RGB LED lighting system on a river-bridge which would be viewed from a distance of about 2 kilometers from an entertainment park on the riverbank.
After sundown a light & sound show is being planned in the park.....the colorful lights on the bridge would start...

Hi Les and all
I have a problem with the variable allocation of this processor.
If I write:
HSerOut
the response at serial line is "Lu 18 Ma 2000 68:68:00" , wrong and unchanged, even if I change the value of Anno, Ore, Minuti and Secondi.
If I write:
g = Giorno
a = Anno
h = Ore
m = Minuti

Thanks for the suggestions.
Today I hope find some time to declare some variable heap to avoid the overlapping problems.
But I want understand: the problem is only if my variable cross from bank0 to bank1 or in general crossing any banks?
About the second issue (print cstr): is better create a new post? For me the problem is similar, and it's...

Multiple functions by a single switch

This valuable resource relies upon the very
small amount of revenue generated by displaying online advertisements
to our visitors.

The advertisements we display are relevant to this web site and your
browsing history

Please consider supporting us by disabling your ad blocker.

Note: Some users have reported issues related to ad-blockers rendering
parts of this wesite unusable,
where possible we will rectify the issues to enable you to use this
resource with adblocking enabled.

Re: Multiple functions by a single switch

This valuable resource relies upon the very
small amount of revenue generated by displaying online advertisements
to our visitors.

The advertisements we display are relevant to this web site and your
browsing history

Please consider supporting us by disabling your ad blocker.

Note: Some users have reported issues related to ad-blockers rendering
parts of this wesite unusable,
where possible we will rectify the issues to enable you to use this
resource with adblocking enabled.

Re: Multiple functions by a single switch

This valuable resource relies upon the very
small amount of revenue generated by displaying online advertisements
to our visitors.

The advertisements we display are relevant to this web site and your
browsing history

Please consider supporting us by disabling your ad blocker.

Note: Some users have reported issues related to ad-blockers rendering
parts of this wesite unusable,
where possible we will rectify the issues to enable you to use this
resource with adblocking enabled.

This valuable resource relies upon the very
small amount of revenue generated by displaying online advertisements
to our visitors.

The advertisements we display are relevant to this web site and your
browsing history

Please consider supporting us by disabling your ad blocker.

Note: Some users have reported issues related to ad-blockers rendering
parts of this wesite unusable,
where possible we will rectify the issues to enable you to use this
resource with adblocking enabled.

Re: Multiple functions by a single switch

Hello Amod

You can only read a 0 or a 1 from a Single Pole switch which can only give Two Functions.
Otherwise you could use Four Single Pole Switches
and connect them to a single pin under ADC and then put resistors between the four switches to give different Readings (Voltages) on the ADC
When each switch is pushed, It will give a different Voltage(ADC_Reading).
Then put a Select - Case Loop In to Read the different values and assign each to it's own Gosub routine to get your Four different functions.
Regards

This valuable resource relies upon the very
small amount of revenue generated by displaying online advertisements
to our visitors.

The advertisements we display are relevant to this web site and your
browsing history

Please consider supporting us by disabling your ad blocker.

Note: Some users have reported issues related to ad-blockers rendering
parts of this wesite unusable,
where possible we will rectify the issues to enable you to use this
resource with adblocking enabled.

Re: Multiple functions by a single switch

This valuable resource relies upon the very
small amount of revenue generated by displaying online advertisements
to our visitors.

The advertisements we display are relevant to this web site and your
browsing history

Please consider supporting us by disabling your ad blocker.

Note: Some users have reported issues related to ad-blockers rendering
parts of this wesite unusable,
where possible we will rectify the issues to enable you to use this
resource with adblocking enabled.

Re: Multiple functions by a single switch

Amod

Your Screenshot is a bit small to see clearly. The only thing I can think of if you wan't to use a Single button to do
Four different functions is to have a counter attached and lets say one press does task 1, Second Press does task 2 and so on.
You must de-bounce the switch and have a small delay to stop overlapping.

This valuable resource relies upon the very
small amount of revenue generated by displaying online advertisements
to our visitors.

The advertisements we display are relevant to this web site and your
browsing history

Please consider supporting us by disabling your ad blocker.

Note: Some users have reported issues related to ad-blockers rendering
parts of this wesite unusable,
where possible we will rectify the issues to enable you to use this
resource with adblocking enabled.

Re: Multiple functions by a single switch

I think what he wants is like Joseph suggested: hold the switch down for a short time is one function, a bit longer for the second and so on.
I seem to remember Les describing a single button that you could tap morse code into (a long long time ago) for a security system.

There is a bell push that rings the bell if held down, or opens the door after a short series of sharp stabs.

This valuable resource relies upon the very
small amount of revenue generated by displaying online advertisements
to our visitors.

The advertisements we display are relevant to this web site and your
browsing history

Please consider supporting us by disabling your ad blocker.

Note: Some users have reported issues related to ad-blockers rendering
parts of this wesite unusable,
where possible we will rectify the issues to enable you to use this
resource with adblocking enabled.

This valuable resource relies upon the very
small amount of revenue generated by displaying online advertisements
to our visitors.

The advertisements we display are relevant to this web site and your
browsing history

Please consider supporting us by disabling your ad blocker.

Note: Some users have reported issues related to ad-blockers rendering
parts of this wesite unusable,
where possible we will rectify the issues to enable you to use this
resource with adblocking enabled.

Re: Multiple functions by a single switch

So my example code works for you. I used that method long time ago and it works, maybe it needs some tweaks but it works. If you have an LCD attached it is even better because you can see at what stage your push sequence have arrived.

Not only it works with a push button. Long time ago I have managed to use a singe R/C channel with a spring loaded switch to activate 3 separate items depends on how many times I toggled the switch.

This valuable resource relies upon the very
small amount of revenue generated by displaying online advertisements
to our visitors.

The advertisements we display are relevant to this web site and your
browsing history

Please consider supporting us by disabling your ad blocker.

Note: Some users have reported issues related to ad-blockers rendering
parts of this wesite unusable,
where possible we will rectify the issues to enable you to use this
resource with adblocking enabled.