Qtouch button Xmega-A3BU Xplained in Bascom?

Go To Last Post
7 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I have this Xplained board and would like to work with it in Bascom. With its 132x32 display and buttons it has 'all you need'. It has a nice menu system too.

 

Problem is the qtouch button.

I can find the software in C in Atmel studio and compile. I have little experience in C and Studio. In the past I have used Studio only a few times to see some parts in assembly that I used in Bascom.

 

I would like that single qtouch button of Xmega-A3BU Xplained (from XMEGA_A3BU_XPLAINED_DEMO1) as a separate module that I can use in Bascom.

How can that be done?

Last Edited: Wed. Jan 12, 2022 - 09:16 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Not sure you are going to be able to do it in anything but C. I think Atmel provide the "clever bit" that does the input reading/timing stuff as a binary library so it has to be "linkable" to the code you write. That basically means either IAR or one of the GCC languages like Asm/C/C++.

 

I guess you could try contacting MSelec and see if they have some solution for linking it to Bascom ?

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

The guy (MAK3) that did most of the XMEGA adaptions for Bascom says it is not possible for the qtouch.

 

I hope someone who knows  what is happening inside can tell the variables that the routine needs.

It is only 1 button. May be the routine is not that complicated then?

I am thinking of compiling just that touch and switch a led. Build. Is it doable to try to disassemble, reassemble in assembly for bascom?

 

BTW, seeing this video it seems not that complex for only 1 button...: https://www.youtube.com/watch?v=...

Last Edited: Wed. Jan 12, 2022 - 05:13 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

If you just Google then you'll find pre-qtouch projects that show the general technique with IO pins and tin-foil squares. I was looking at this myself a while back with a view to making stylophone-esque "piano keys". ISTR it involves making the pin output and driving a voltage onto it then switching that back around to input and timing how long it takes the input to fall back from a one to a zero. It works on the basis that '1' switches to '0' when it falls through the Vcc*0.6 threshold or something like that. A hairy finger either holds the voltage up longer or makes it decay quicker (can't remember which way round it is)

 

EDIT so OK, this guy is a bit of a waffle merchant but he finally gets to the point (may be forward to where the scope is shown?) :

 

https://youtu.be/BO3umH4Ht8o

Last Edited: Wed. Jan 12, 2022 - 07:12 PM