Expansion for wstablet in NetBSD
2008 gSoC Jason W. Beaudoin
What is it?
wscons is a platform-independent console driver for BSD systems that provides an abstraction layer between hardware devices and interested parties. This simplifies development on both sides of wscons, as a given set of requirements (and results) are known.
wscons consists of wsmouse, wskbd, and wsdisplay device drivers, but lacks an equivalent mechanism to interface with tablet devices. While support exists for tablet devices within BSD, wscons requires extensions to the framework to better incorporate (and continue) tablet development.
As an extension to the existing wscons framework, the wstablet API will be functionally similar to wsmouse and wskbd, and integrate into the wsevent mechanisms already in place. wstablet will be designed to support all current tablet functionality, whether or not it is available in the actual hardware device.
The original project proposal can be found.. here
Mandatory (must-have) components:
Optional (would-be-nice) components:
- design and implement the wstablet driver abstraction
- extend the wscons framework to support wstablet
- API and project documentation
- design and implement a wstablet X input driver
- design and implement a sample wstablet hardware driver
August 18th, 2008:
August 15th, 2008:
- "figured out" kernel/device driver integration.
- more wstablet testing and scrubbing of code.
- added support for "relative" tablet mode.
- added support for switching stylus devices and tablet modes.
- man pages and quick "how to test" documentation written.
- imported wsconsctl, as well as previous work done on wsconsctl code.
- updated wsconsctl, framework now in place, we just need to implement the get/set mode ioctls.
- began work on specialized (device-driver-independent) code for wstablet testing.
- update sent to tech-kern@
August 8th, 2008:
- The code is finally reflecting all the research required of a new kernel developer, this makes me happy :P
- We're getting close to the finish line, update coming on Monday.
July 31st, 2008:
- I've spent the week building my understanding (or attempting to) of the kernel build process, device setup within the kernel, and how to get a damn /dev/* device associated (and working!) with a device driver, and I stumbled across the read() necessity, almost by accident :P
- I had previously got a bit caught up in trying to use my (much more powerful) OpenBSD workstation to run build.sh, I'll try not to do the same here.
July 12th, 2008:
- Things have been quiet around wstablet for the last two weeks; the H.O.P.E. conference in NYC, final papers and presentations, and of course, pending doom, have all threatened my life equally. Although, I do have a feeling the fresh perspective will be of great help.
- focus is now turning towards a proper testing environment!
July 2nd, 2008:
- I've completed the API's design specification (working out a few more things in the process), and have passed this along to tech-kern
Here is the design spec document :)
- Now we await the pending discussion, and the results of any decisions we make together.
- In the meantime, it's back to work.
June 29th, 2008:
- This evening called in a complete overhaul to this page.. (exciting!)
- I have not been diligent enough about adding status updates, something I now wish I had been keen on sticking to.
- I shall be better about this from here on out (and back-dated entries will be added for that which I'm sure of)
June 24th, 2008:
- I've begun implementing the first bits of wstablet, in code. I'm a bit disappointed it has taken me this long to get here, but still totally excited that we're here. Either way, things will be coming together much faster over the next few weeks.
- the initial event and device types have been added to wsconsio.h, support for wscons_event.dev_id was added to wsevent.c, and the initial wstablet.c and wstabletvar.h files have been added.
- Next will be web updates, emailing tech-kern, opening the wacom dialog once again, and wrapping up r1.
June 17th, 2008:
- the design spec is out for review! With my mentors comments in hand, this will be taken to tech-kern. I'll probably get some code together and refine some of these thoughts beforehand.
- At some point I'll post the design spec up here.
June 12th, 2008:
- Michael requested a more thorough and better organized design document. After reviewing my first attempt, I'm inclined to agree.
June 4th, 2008:
- I've contacted wacom as an open source developer seeking hardware support (it would *really* help). I was put in touch with a fellow who, despite sounding a bit skeptical, seemed rather openminded and willing to help (pending the legitimacy test). More information was requested, so when a moment opens up (and once I've updated these pages a little bit more..) I'll point him here, and to the original proposal.
- I've also got my notes organized and a basic API proposal together for wstablet. We'll see what the mentors think..
June 2nd, 2008:
- I've spent my time making sense out of how wscons works. This includes the wsmouse API (good example for wstablet), wscons in general, how devices are created and initialized, how the kernel is configured, and ioctls.
- I've put my schedule together!
April 21: Community Bonding Period
May 28: Students begin coding for their GSoC projects
July 7: mid-term evaluations begin!
July 14: mid-term evaluation deadline
August 11: pencils down!
August 18: Firm 'pencils down' date. Mentors, students and organization administrators can begin submitting final evaluations to Google.
September 1, 2008: Final evaluation deadline; Google begins issuing student and mentoring organization payments provided forms and evaluations are on file.
looking back.. ]
- get familiar with code (wscons / device allocation, configuration, system management, etc)
- define what wstablet needs to do, and what capabilities to support
- find and understand existing kernel frameworks to implement these needs
- figure out how to implement non-existing frameworks
- code foundation of API
- add support to wsconsctl
- documentation and tying it all together
- generic tablet driver
- convert existing drivers/system to use wstablet
The SoC experience:
things I learned, gained, experienced.. ]
- figuring out how all the pieces work together can be a massively overwhelming task, but is sooooo rewarding in the end.
- similarly, in a project like this, 75% of your time can easily vanish in figuring out those pieces.
- grubbing for code is your best documentation (and a good skill to develop), in fact.. it's *how* you figure these things out.
- I've learned what "real-life" data structures look like
- how to implement more advanced C code, like effectively using function pointers for simple, robust code
- where and how to devote my time in development; it can be easy to get caught up (or in) less meaningful tasks, or try to think out code that requires something else to be resolved first. (we can always improve our time management skills)
- I have a better understanding of open source development and how the "pieces fit together" (i.e. how to find information, how to seek out assitance, and that we build off of one another's work, rather than reimplement the wheel - although, that is sometimes what is needed).
- cvs! vim! you rock!
- writing man pages and documentation *can* be fun!
- solid documentation is not to be underestimated, but appears to be more often than not.
- rewriting or redesigning your code 17 times is ok, it shows the growth and depth of your understanding of the system, over time.
- milestones help to give a good sense of direction
- even if they don't exist at first, fine tune those milestones as you go.
- APIs are cool, you get to tell people what to do, and how you want it done.
- taking some time away from your code (like not seeing it for a week), can evoke the *best* and the *worst* feelings, simultaneously.
- I absolutely LOVE this work!! and shall always devote some of my time, abilities, and efforts towards open source development, but of course..
my reading list:
Linux Wacom Project
design spec [originally emailed to tech-kern@ on July 13th, 2008]
testing wstablet [Short notes on testing wstablet]
SoC Final Status Update [emailed to tech-kern@ on August 18th, 2008]
| Jason W. Beaudoin <firstname.lastname@example.org> |
| $Id: index.html,v 1.11 2008/08/18 21:10:06 jasonbeaudoin Exp $ |