github github
  • Pricing and Signup
  • Explore GitHub
  • Features
  • Blog
  • Login

davidcranor is using GitHub to share code with you!

GitHub is more than just a place to share code. It's a place to keep tabs on your favorite developers and projects, easily contribute fixes and new features, and visualize what's going on inside your codebase!

Sign Up Now

Free for open source

davidcranor / Thinner-Client

  • Admin
  • Watch Unwatch
  • Fork
  • Your Fork
    • 10
    • 1
  • Source
  • Commits
  • Network
  • Pull Requests (0)
  • Issues (0)
  • Graphs
  • Branch: master

click here to add a description

click here to add a homepage

  • Switch Branches (1)
    • master ✓
  • Switch Tags (0)
  • Branch List
Sending Request…
Downloads

This project implements an STM32F based thin client which can send and receive data over serial, read a PS/2 keyboard, and display the contents of a 480x240 framebuffer on an NTSC television. — Read more

  Cancel

  Cancel
  • HTTP
  • Git Read-Only

This URL has Read+Write access

Thinner-Client /

Dismiss Octotip: You've activated the file finder by pressing t Start typing to filter the file list. Use ↑ and ↓ to navigate, enter to view files.

 name
No matching files

Jump to Line

updated README 
davidcranor (author)
Tue Aug 31 15:26:39 -0700 2010
commit  94b56ce8ed1fa185df8d
tree    0350fc951a6c022232be
parent  e2db302f458203e68756
Thinner-Client /
name age
history
message
directory Datasheets and App Notes/ Mon Aug 30 17:28:56 -0700 2010 first commit [davidcranor]
directory Eagle Files/ Mon Aug 30 17:28:56 -0700 2010 first commit [davidcranor]
directory Font Stuff/ Mon Aug 30 17:28:56 -0700 2010 first commit [davidcranor]
directory Misc./ Mon Aug 30 17:28:56 -0700 2010 first commit [davidcranor]
directory Pictures/ Tue Aug 31 14:59:43 -0700 2010 updated pictures [davidcranor]
directory STM32F10x Standard Peripheral Library 3.3.0/ Mon Aug 30 17:28:56 -0700 2010 first commit [davidcranor]
directory Source Code/ Tue Aug 31 14:56:58 -0700 2010 updated README [davidcranor]
directory xvsmfbg/ Mon Aug 30 17:58:32 -0700 2010 updated readme, added xvsmfbg and images [davidcranor]
file README Tue Aug 31 15:26:39 -0700 2010 updated README [davidcranor]


README
This project implements an STM32F based thin client which can send and receive data over serial, read a PS/2 keyboard, and display the contents of a 480x240 framebuffer on an NTSC television.

The included main.c implements a vt100 serial terminal with 80x24 characters.  Tools are also included to upload vial the STM32F's build in bootloader and an FTDI cable.

In order to make it work (and if you are using bash and Ubuntu)

paste the following into /etc/init/ttyUSB0.conf:

******************************************************************

start on stopped rc RUNLEVEL=[2345]
stop on runlevel [!2345]

respawn
exec /sbin/getty -L 57600 ttyUSB0 vt100

******************************************************************

Now you can start and stop the ttyUSB0 login process

using sudo [start, stop] ttyUSB0

Put this in your /etc/bash.bashrc to actually give the serial port the login process:

******************************************************************

if [ "$TERM" == "vt100" ]; then
       export TERM=xterm
       export ROWS=25
       export COLUMNS=80
       export LANG=POSIX
       # Redundant settings, for other folks
       export LINES=$ROWS
       stty rows $ROWS
       stty cols $COLUMNS
fi

******************************************************************

The board is designed so that the top layer can be made at home, with some easy drillable/solderable vias to a ground plane on the back side.  The SD card slot is the only thing on the bottom of the 2 layer design, and is not important at this point (it isn't even supported in the code yet, and isn't included on the BOM).

If you want to write your own NTSC display stuff using this project, all you have to do (assuming you already have the arm toolchain) is make a main.c which includes the following:
 
stm32f10x.h
stm32f10x_exti.h
thinnerclient.h
 
as well as a call to thinnerClientSetup();
 
then, you have access to the following:
 
frameBuffer[BUFFER_VERT_SIZE][BUFFER_LINE_LENGTH];
uint8_t buffer_get_key()
uint8_t buf_dequeue()
 
anything written to frameBuffer appears on the screen.
buffer_get_key and buf_dequeue retrieve bytes from the keyboard buffer and USART receive buffer, respectively.
 
check out thinnerclient.h and thinnerclient.c for details.


Known bugs:

-Slight screen glitching because of serial receive and keyboard interrupts.  Fixing this may involve messing with the interrupt priorities
-A bit of RAM can be freed by putting the font into program memory.  However, this causes a small glitch near the top of the screen when the framebuffer is refreshed every frame.

******************************************************************

xvsmfbg stands for X virtual shared memory frame buffer grabber. It is designed to grab frames from Xvfb, and spit them at a fixed rate to stout. 

You can use it to send frames from your computer to a thinner client and display them on a TV.  The code to implement this is not currently in this repo, but it should be pretty simple to write - just read stuff out of the serial buffer and put into the frame buffer. 

******************************************************************


David Cranor
cranor (at) media (dot) mit (dot) edu
8/31/2010

Dedicated Server Powered by the Dedicated Servers and
Cloud Computing of Rackspace Hosting®
  • Blog
  • Support
  • Training
  • Job Board
  • Shop
  • Contact
  • API
  • Status
  • © 2011 GitHub Inc. All rights reserved.
  • Terms of Service
  • Privacy
  • Security
  • English
  • Deutsch
  • Français
  • 日本語
  • Português (BR)
  • Русский
  • 中文
  • See all available languages

Your current locale selection: English. Choose another?

  • English
  • Afrikaans
  • Català
  • Čeština
  • Deutsch
  • Español
  • Français
  • Hrvatski
  • Magyar
  • Indonesia
  • Italiano
  • 日本語
  • Nederlands
  • Norsk
  • Polski
  • Português (BR)
  • Русский
  • Српски
  • Svenska
  • 中文

Keyboard Shortcuts (see all)

Site wide shortcuts

s
Focus site search
?
Bring up this help dialog

Commit list

j
Move selected down
k
Move selected up
t
Open tree
p
Open parent
c or o or enter
Open commit

Pull request list

j
Move selected down
k
Move selected up
o or enter
Open issue

Issues

j
Move selected down
k
Move selected up
x
Toggle select target
o or enter
Open issue
I
Mark selected as read
U
Mark selected as unread
e
Close selected
y
Remove selected from view
c
Create issue
l
Create label
i
Back to inbox
u
Back to issues
/
Focus issues search

Network Graph

← or h
Scroll left
→ or l
Scroll right
↑ or k
Scroll up
↓ or j
Scroll down
t
Toggle visibility of head labels
shift ← or shift h
Scroll all the way left
shift → or shift l
Scroll all the way right
shift ↑ or shift k
Scroll all the way up
shift ↓ or shift j
Scroll all the way down

Source Code Browsing

t
Activates the file finder
l
Jump to line