Citation :
[quote]getAdapter (adapterName, portName) : Finds, opens, and verifies the specified adapter on the indicated port.
getDefaultAdapter() : Finds, opens, and verifies the default adapter and port. Looks for the default adapter/port in the onewire.properties file
targetFamily(family) : Takes a hexadecimal value to selectively search for this desired family type. If this method is used, then no devices of other families will be found by any of the search methods. DS1990A: family = &H01
DS2406(P): family = &H12
setSpeed(speed) : Sets the new speed of data transfer on the 1-Wire Network. speed : ? 0 (SPEED_REGULAR) set to normal communication speed
? 1 (SPEED_FLEX) set to flexible communication speed used for long lines ? 2 (SPEED_OVERDRIVE) set to normal communication speed to overdrive ? 3 (SPEED_HYPERDRIVE) set to normal communication speed to hyper drive
? >3 future speeds beginExclusive(blocking) : Gets exclusive use of the 1-Wire to communicate with an iButton or 1-Wire Device.
If want to block waiting for an exclusive access to the adapter: blocking = true
reset() : Sends a Reset to the 1-Wire Network.
setSearchAllDevices() : Sets the 1-Wire Network search to find all iButtons and 1-Wire devices.
findFirstDevice() : Returns ?True? if the first iButton or 1-Wire device is found on the 1-Wire Network. If no devices are found, then ?False? will be returned.
findNextDevice() : Returns ?True? if the next iButton or 1-Wire device is found. The previous 1-Wire device found is used as a starting point in the search. If no more devices are found then ?False? will be returned.
getAddressAsString() : Gets the 'current' 1-Wire device address being used by the adapter as a String. This address is the last iButton or 1-Wire device found in a search (findNextDevice()...).
setupContainer (sourceAdapter, newAddress)
: Provides this container with the adapter object used to access this device and the address of the iButton or 1-Wire device. sourceAdapter : adapter object required to communicate with this iButton newAddress : address of this 1-Wire device
readDevice() : Retrieves the 1-Wire device sensor state.
getLatchState (channel, state) : Checks the latch state of the indicated channel.
Boolean function gives back ?True? if channel is open and ?False? if it is closed.
PIO A : channel = 0
PIO B : channel = 1
Dim state As Object / state = adapter.readDevice
setLatchState (channel, latchState, doSmart, state) : Sets the latch state of the indicated channel. PIO A : channel = 0
PIO B : channel = 1
To close: latchState = False To open: latchState = True Dim doSmart As Boolean / doSmart = False
Dim state As Object / state = adapter.readDevice
writeDevice (state) : Writes the 1-Wire device sensor state that have been changed by 'set' methods. getLevel (channel, state) : Checks the sensed level on the indicated channel.
Boolean function gives back ?True? if the channel
is activated, otherwise ?False?
PIO A : channel = 0
PIO B : channel = 1
Dim state As Object / state = adapter.readDevice
endExclusive() : Relinquishes exclusive control of the 1-Wire Network.
|