**********************
* Barcode Allocation *
**********************
Barcode
-------
Length: 14 bytes
Fields: [2|4|2|6]
Fieldnames: [valid|location|type|serial]
These are ASCII character arrays and _not_ numbers.
valid= 37
location= 0001
type|serial= 00|000000-999999 person
01|0a0r0g generic person (a=Age_enum r=Race_enum g=Gender_enum)
(type= 10+Service_enum)
10|000000 meal
11|000000-000008 clothing (serial= Clothing_enum)
12|000000 shower
13|000000 laundry
14|000000 bed (serial= Bed_enum)
15|000000-000001 benefits (serial= Benefits_enum)
16|000000-000005 others (serial= Others_enum)
17|000000-000010 meetings (serial= Meeting_enum)
Bed_enum
--------
0=Lodge, 1=UMOJA, 2=Wellington
Service_enum
------------
0=Meal, 1=Clothing, 2=Shower, 3=Laundry, 4=Bed, 5=Benefits, 6=Others
Age_enum
--------
0=below 20, 1=20-29, 2=30-39, 3=40-49, 4=50-59, 5=above 60
Gender_enum
-----------
0=Male, 1=Female
Race_enum
---------
0=White, 1=Black, 2=Asian, 3=Hispanic/Latino, 4=Pacific Islander, 5=Native Hawaiian, 6=American Indian, 7=Alaska Native, 8=Other
Benefits_enum
-------------
0=6 night stay, 1=Lunch to go
Clothing_enum
-----------
0=Other, 1=Coat, 2=Gloves, 3=Hat, 4=Shoes, 5=Socks, 6=Underwear, 7=Pants, 8=Shirt
Others_enum
-----------
0=Clinic, 1=Tri-city mental health, 2=Legal services, 3=Homestart, 4=Homeless veteran services, 5=Referral
Meeting_enum
------------
0=church, 1=bible study, 2=Meeting-Spiritual Recovery, 3=Meeting-Feelings Group, 4=Meeting-Relapse Prevention, 5=Meeting-Spiritual Focus, 6=Meeting-Group I, 7=Meeting-Group II, 8=AA/NA, 9=Study, 10=Life Skills, 11=Other
***********************
* PDA data structures *
***********************
** Custom types used in Palm storeage
Barcode
-------
Length: 15 bytes
Fields: [14|1]
Fieldnames: [barcode|null]
Stored as null terminated strings.
Clothing Bit Fields (indicated below as Clothing)
-------------------
Length: 32 bits
Fields: [4|4|4|4|4|3|3|3|3]
Fieldnames: [shirt|pants|undies|socks|shoes|hat|gloves|coat|other]
These are all interpreted as unsigned x-bit integers.
** PDA Record formats
All fields on the PDA side are word (2-byte) aligned. The compiler
inserts null bytes in the records to enforce this constraint.
This is indicated by a null* below.
Scan Record
-----------
Length: 38 bytes
Fields: [15|1|4|15|1|4]
Fieldnames: [personBarcode|null*|timestamp|serviceBarcode|null*|value]
union [personBarcode|null*|timestamp|serviceBarcode|null*|clothing]
personBarcode= Barcode
timestamp= int, # seconds from 12:00 A.M. on January 1, 1904 to present (Mac format)
serviceBarcode= Barcode
value= int (scan record type specific interpretation)
ClientInfo
----------
Length: 36 bytes
Fields: [15|1|21|1]
Fieldnames: [personBarcode|null*|name|null*]
The very last null* is a hypothesis that has not been tested. It may
be the case that null*'s are only needed between fields in a single
record and not for the last field of a record.