Bring your karma
Join the waitlist today
HUMBLECAT.ORG

Blind and Visually Impaired Community

Full History - 2015 - 01 - 26 - ID#2tpfjk
2
Python programming for blind/visually impaired? (self.Blind)
submitted 8y ago by bayesian_horse
I am sighted, but recently I got interested in accessibility and the question how blind computer users could learn programming. When looking around I found that most solutions seem to be very unsatisfying, and I quickly got inspired to try to make the situation better.

So I started to design a framework for text-to-speech user interfaces in the Python 3 programming language. It only requires a normal keyboard and headphones or a speaker. That way a cheap one-board computer like the Raspberry Pi is all that is needed to start using and even developing for it.

The disadvantage is of course, that any applications have to be written from scratch. The benefit is that the applications can be completely customized for text-to-speech.

A custom text editor would be used to write Python programs. By using key strokes the editor can pronounce the code or give orientation hints, like "line 42, column 8" or "line 42, class Contact, def get_mail_address, line 3".

Touch typing is a requirement, but a text-to-speech touch typing tutor/training program would be accessible with only the number keys. In my opinion braille displays with keyboards are not a good idea. The framework may eventually use braille displays, but they are extremely expensive, and not even that standardized. The integrated keyboards seem to be a bit cumbersome for programming. Depending on these devices would limit both the potential blind audience as well as sighted programmers willing to help out.

At first the goal would not be to completely replace a working PC setup or Android device, but rather a cheap platform which is easy to tinker with. The main goal is to get users writing their own applications as quickly as possible, and building up from there.

A computer running the software can be put together for $70 dollars or less (Raspberry Pi, SD Card, keyboard, headphone, power cable and optionally a wifi stick).

The project is in a very early stage, and I would like to hear what other people have to say about the topic.
dmazzoni 2 points
I think it's fantastic that you are interested in working on software for people who are blind, but I'd encourage you to maybe play a bit with existing assistive technology and try to build something complementary rather than from scratch.

I'm sighted but I'm a software engineer specializing in assistive technology and I work with many blind people, including several blind programmers. Most blind programmers I know use a refreshable braille display, like this:

http://www.freedomscientific.com/Products/Blindness/Focus40BrailleDisplay

While expensive, the braille display solves all of the problems of trying to figure out punctuation and indentation from speech. Most states will pay for a braille display and other AT for any blind student who wants one.

I'm curious why you found that most solutions seem to be unsatisfying. I'd say the blind programmers I know find programming to be one of the *most* accessible things they do. In comparison, browsing the web is very challenging because there are so many sites, each one is laid out differently, and people aren't good at providing alt text for images or labels for form controls.
Zach_of_Spades 2 points
This sounds great. Python is a great choice because A very popular windows screen reader, Nvda uses python for not only its core but it's ad on modules. Miniblind Deb's are already familiar with Python. Best of luck and please keep us posted.
simpleman84 1 points
Thank you for trying to make programming accessible for blind users. I think it's an excellent idea.

I have to venture offtopic for a minute though. I have just signed up for a Reddit account, and the capcha is inaccessible. There is no audio equivalent.

If I want to make a text post or send a private message, I have to enter it. I don't want to ask for sighted assistance, but I can't contact support here, because they also require the capcha.

I tried to post a comment in /r/help. All I can do is post comments. That is why I haven't made a specific post for this. If someone could, could you please link to my screen name and send a message to the admins? I tried it in /r/help and got some dumb troll. Noone else even answered me.
bayesian_horse [OP] 1 points
I didn't do a very thorough examination of assistive technology yet. What I found on youtube though didn't look very promising to me.

Two key parts of the system will be the custom editor, which will be very VIM-like, and the custom code-to-speech transformer.

In editing source code in a normal editor we as sighted people use visual feedback loops for just about anything. In VIM, a lot of these feedback loops are already abbreviated. If I want to delete a line in a normal texteditor, I have to select the line and then delete it with a key. In vim, I just press dd, and the line is gone. More complicated things like "delete everything inside this html tag" is also easy.

While a braille display could still be useful there, I don't want to require it (for now). The braille keyboards I have seen look as if they need several keystrokes for many characters. I don't believe that this is a good idea for an editor which relies on key combinations to do most of the work.

Another important factor in this framework is the way the user interface is programmed. For example, this is a rough design of how a user interaction with keyboard and tts would look like.


def addition_drill():
yield from speak("Mental Addition Drill.")
ndigits = yield from number_input("Enter number of digits")
yield from speak("Let's start.")
for i in range(10):
a = randint(0,10**ndigits)
b = randint(0,10**ndigits)
question = str(a) + " plus " + str(b)
c = yield from number_input (question)
if a+b == c:
yield from speak("Correct.")
else:
yield from speak("Wrong answer. " + q + " is " + str(c))

I haven't implemented all the details yet, but general keyboard events etc work already. The "yield from" syntax enables us to use coroutines/generators for asynchronous processing.

My thinking is that it would be easier for blind programmers, especially beginners, to write user interactions this way rather than create windows, widgets, html code etc which then have to be decoded again with the screen reader. And this model still allows for concurrency just as normal user interface frameworks do.

A nice benefit is that this user interface does not require a windowing system or even a screen.
This nonprofit website is run by volunteers.
Please contribute if you can. Thank you!
Our mission is to provide everyone with access to large-
scale community websites for the good of humanity.
Without ads, without tracking, without greed.
©2023 HumbleCat Inc   •   HumbleCat is a 501(c)3 nonprofit based in Michigan, USA.