FreeJoy-Team / FreeJoyConfigurator

GUI utility for configuration and setting up FreeJoy embedded controller
GNU General Public License v3.0
64 stars 12 forks source link

Cannot Set The Toggle Press Time plus Diode Question #30

Open speedbird5 opened 3 years ago

speedbird5 commented 3 years ago

Hi,

First a question on wiring. Do I really need to use diodes in my wiring for a button matrix as shown in the FreeJoy Wiki here: https://github.com/FreeJoy-Team/FreeJoyWiki/blob/master/eng/Connecting-buttons-directly-to-controller.md

Also, why are the diode directions different in the button matrix for only buttons, but are in the reverse direction when you include an encoder as shown here: https://github.com/FreeJoy-Team/FreeJoyWiki/blob/master/eng/Encoders-connection.md

You say in the FreeJoy Wiki here: https://github.com/FreeJoy-Team/FreeJoyWiki/blob/master/eng/Buttons-configuration.md

"...(the time while the logical button remains pressed is set in the Toggle Press Time field of the Advanced Settings section)..."

But in the Advanced settings section there is no way to set the Toggle Press Time.

I am using version 1.6.2b3

Thanks.

Capture

vostrenkov commented 3 years ago

Hi!

Do I really need to use diodes

You need them if you suppose some of your buttons can be pressed simultaneously. You will get ghost pressing without diodes

why are the diode directions different in the button matrix for only buttons, but are in the reverse direction when you include an encoder

If you look closer you will see that both diagrams have cathode to the row pin and anode to the column pin

But in the Advanced settings section there is no way to set the Toggle Press Time

Wiki is a bit outdated. This settings now available as "Press timer" on Buttons tab. It works now not only for toggle switches but also for other button types

speedbird5 commented 3 years ago

Thanks for the explanations. I will be using quite a few toggle switches that could have two or more latched on at the same time so diodes will be needed.

Thank you for your work on this project.

speedbird5 commented 3 years ago

Another question. If I want a logical button to be pressed for as long as I hold the physical button down, how do I do that ?

thanks.

vostrenkov commented 3 years ago

You do "button_nornal" and no timers applied

speedbird5 commented 3 years ago

Ok thanks again

On 23 Jan 2021, at 01:18, Yury Vostrenkov notifications@github.com wrote:

 You do "button_nornal" and no timers applied

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

speedbird5 commented 3 years ago

Forgive me as I am a noob with more dumb questions:

  1. Why do you have two options for wiring switches directly as VCC or GND ? Wouldn't you normally just use the GND option and use the Configurator to flip the output ?
  2. Is there a way to wire a 4 position rotary switch using the Configurator ? 105621439-0db20880-5e53-11eb-85a2-b7c2e6131cdc
vostrenkov commented 3 years ago
  1. It is supposed that some people may use freejoy to replace controller on their device. So if you already have your wiring done with external pull-up or pull-down you may choose required option
  2. Yes, there are several ways to do this:
    • just connect 4 button pins directly to switch contacts and rotary's common gnd/vcc to board gnd/vcc
    • make a hardware mode to connect it to analog input and use axis2buttons function

More information can be found here

speedbird5 commented 3 years ago

HI,

It is supposed that some people may use freejoy to replace controller on their device. So if you already have your wiring done with external pull-up or pull-down you may choose right option If I am making my own button box with switches, which is the right choice, VCC or GND or doesn’t it matter ?

Thankyou.

On 24 Jan 2021, at 16:44 , Yury Vostrenkov notifications@github.com wrote:

It is supposed that some people may use freejoy to replace controller on their device. So if you already have your wiring done with external pull-up or pull-down you may choose right option Yes, there are several ways to do this: just connect 4 button pins with common gnd/vcc make a hardware mode to connect it to analog input and use axis2buttons function More information can be found here https://forums.eagle.ru/topic/190451-rotary-switch-amp-arduino-help-needed — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/FreeJoy-Team/FreeJoyConfigurator/issues/30#issuecomment-766301331, or unsubscribe https://github.com/notifications/unsubscribe-auth/AE3DAPUT4FGN6VD5XNY2RALS3O6U7ANCNFSM4WOGSMSQ.

vostrenkov commented 3 years ago

I'd recommend to wire buttons with common GND

speedbird5 commented 3 years ago

Thankyou

On 24 Jan 2021, at 17:14 , Yury Vostrenkov notifications@github.com wrote:

I'd recommend to wire buttons with common GND

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/FreeJoy-Team/FreeJoyConfigurator/issues/30#issuecomment-766304001, or unsubscribe https://github.com/notifications/unsubscribe-auth/AE3DAPXTSKCDDWZ3IM6MJALS3PCHDANCNFSM4WOGSMSQ.

speedbird5 commented 3 years ago

Hi,

Is it possible to upload and run a normal Arduino sketch onto the STM 32 after flashing with your firmware and using the configurator ?

Thanks

On 24 Jan 2021, at 17:15, Yury Vostrenkov notifications@github.com wrote:

 I'd recommend to wire buttons with common GND

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

vostrenkov commented 3 years ago

Hi, it is possible. You just need to flash arduino bootloader to stm32

speedbird5 commented 3 years ago

Ok but confirm it will not erase the Freejoy configuration?

On 25 Jan 2021, at 16:23, Yury Vostrenkov notifications@github.com wrote:

 Hi, it is possible. You just need to flash arduino bootloader to stm32

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

vostrenkov commented 3 years ago

It will for sure

speedbird5 commented 3 years ago

So you’re saying I can’t do both ? It’s either Freejoy OR Arduino boot loader but not both ?

On 25 Jan 2021, at 16:56, Yury Vostrenkov notifications@github.com wrote:  It will for sure

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

vostrenkov commented 3 years ago

I don't know how exactly arduino bootloader works and where it placed in device memory. But freejoy also have its own bootloader in stm32's flash and I'm sure it will be overwritten by arduino bootloader or arduino sketch

speedbird5 commented 3 years ago

Ok thanks for clarifying