Chapter 12: Cash Drawer Interface 12-5
2. Usethearmingbitataddressm_nIOPorttoenableanexternal
drivingcircuit,setthesolenoidbithigh,setthesolenoidlow
afterthechargetimeandfinallydisablethearmingbit.
QueryConf():
QueryConf()usesthePCIconfigurationcycleprotocolatBus
0,Device31andFunction0andoffset
0x58toobtainthe
contentsofGPIOBaseregister.WhenGPIOBaseisreferenced
inthefollowingparagraphsitisreferringtothecontentsof
registerGPIOBase[15:6].Theprimarydifferencesare:
a. Oneportaddressneedstobeconfiguredforreadingthe
statusbitandreading/writingtocontrolthecash
drawer
solenoids,andifnecessarytheARMbitusing
registerGPIOLevelforInputorOutput2Register
(GP_LVL2)offsetGPIOBase+0x38.
b. GPIOmustbeselectedforuseasGPIOthroughregister
GPIOUseSelect2Register(GPIO_USE_SEL2)offset
GPIOBase+0x30.
c. GPIObitsusedbythecash
drawermustbeselectedas
eitherinputoroutputthroughGPIOInput/Output
Select2Register(GP_IO_SEL2)GPIOBase+offset0x34.
d. AnARMbitmayneedtobesetupasoutputand
controlledwiththesolenoidandstatusportaddress.
Thisbitenablesthedrivingcircuitforthesolenoid
outputs.