Eln Computer Probe

From Electrical Age
Revision as of 04:26, 5 February 2017 by Bloxgate (talk | contribs) (Add missing function)

Jump to: navigation, search

The Eln Computer Probe is a block which allows a computer to read and manipulate signals passing through it.

The functions it provides do not contain an internal API, so they will be defined here:

  • signalSetDir("side","in" or "out") - Sets the direction a signal flows on the specified side. Both arguments must be strings, and are case-sensitive. Always returns nil. This can be used to set a value before actually applying it to your ELN network, or to deactivate it without losing its value.
  • signalGetDir("side") - Used to determine if the specified side is in "in" or "out" mode.
  • signalGetIn("side") - Gets the signal strength as a percentage. Multiply by 50 to get exact voltage value.
  • signalSetOut() - If the side is set to "out" use this function to set the signal's strength as a percentage. Divide by 50 to use the exact voltage value.
  • wirelessGet("channel name") - Gets the wireless signal strength as a percentage, uses channel name rather than side.
  • wirelessSet("channel name",number) - Sets the signal strength of the specified channel name. Uses the same percentage value. Divide by 50 to use exact voltage value.
  • wirelessRemove("channel name") - Removes a wireless channel from the block by name.
  • wirelessRemoveAll() - Clears the wireless channels within the block. This is used to disable all wireless interactions in a single command.


Directions

When a probe is placed, 6 sides will appear printed on the sides of the block. These always face the same way, no matter which direction you place the block in. These are used to control the previous functions, usually to specify which side to operate the function on. Its naming structure is a reference to transistors, where P-type is considered positive and N-type is considered negative. The x and y refers to the co-ordinate value.

  • XN - Faces West
  • XP - Faces East
  • YN - Faces Ground
  • YP - Faces Skyward
  • ZN - Faces North
  • ZP - Faces South

Note: Some of the sides are written backwards on the block, and the top and bottom are completely unlabeled! An easy way to remember which side is which is to read the first letter as a co-ordinate value, and the second letter as a direction. YN is downwards on the Y axis, and thus faces the ground.